140 lines
1.6 MiB
140 lines
1.6 MiB
import{_ as ye,G as br,H as h8,J as X,R as Pt,K as VG,L as A,M as Qr,N as ue,O as aM,P as kd,Q as v8,r as Ur,U as d8,j as Ci,F as p8,a as g8}from"./index.741f95d2.js";function jG(e,r){return r.forEach(function(t){t&&typeof t!="string"&&!Array.isArray(t)&&Object.keys(t).forEach(function(i){if(i!=="default"&&!(i in e)){var n=Object.getOwnPropertyDescriptor(t,i);Object.defineProperty(e,i,n.get?n:{enumerable:!0,get:function(){return t[i]}})}})}),Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}var Ux=Object.freeze(Object.defineProperty({__proto__:null,get Base(){return Ia},get Circle(){return uut},get Ellipse(){return fut},get Image(){return vut},get Line(){return put},get Marker(){return mut},get Path(){return JE},get Polygon(){return Mut},get Polyline(){return Fut},get Rect(){return Lut},get Text(){return $ut}},Symbol.toStringTag,{value:"Module"})),qx=Object.freeze(Object.defineProperty({__proto__:null,get Base(){return ea},get Circle(){return cct},get Dom(){return hct},get Ellipse(){return dct},get Image(){return gct},get Line(){return mct},get Marker(){return _ct},get Path(){return wct},get Polygon(){return Sct},get Polyline(){return Tct},get Rect(){return Fct},get Text(){return Dct}},Symbol.toStringTag,{value:"Module"})),y8=function(){},Df=y8,Ui=function(e){return e!==null&&typeof e!="function"&&isFinite(e.length)},eo=function(e,r){return Ui(e)?e.indexOf(r)>-1:!1},jr=function(e,r){if(!Ui(e))return e;for(var t=[],i=0;i<e.length;i++){var n=e[i];r(n,i)&&t.push(n)}return t},HG=function(e,r){return r===void 0&&(r=[]),jr(e,function(t){return!eo(r,t)})},m8={}.toString,Zn=function(e,r){return m8.call(e)==="[object "+r+"]"},pt=function(e){return Zn(e,"Function")},K=function(e){return e==null},it=function(e){return Array.isArray?Array.isArray(e):Zn(e,"Array")},Zt=function(e){var r=typeof e;return e!==null&&r==="object"||r==="function"};function P(e,r){if(!!e){var t;if(it(e))for(var i=0,n=e.length;i<n&&(t=r(e[i],i),t!==!1);i++);else if(Zt(e)){for(var a in e)if(e.hasOwnProperty(a)&&(t=r(e[a],a),t===!1))break}}}var lc=Object.keys?function(e){return Object.keys(e)}:function(e){var r=[];return P(e,function(t,i){pt(e)&&i==="prototype"||r.push(i)}),r};function oM(e,r){var t=lc(r),i=t.length;if(K(e))return!i;for(var n=0;n<i;n+=1){var a=t[n];if(r[a]!==e[a]||!(a in e))return!1}return!0}var z0=function(e){return typeof e=="object"&&e!==null},wa=function(e){if(!z0(e)||!Zn(e,"Object"))return!1;if(Object.getPrototypeOf(e)===null)return!0;for(var r=e;Object.getPrototypeOf(r)!==null;)r=Object.getPrototypeOf(r);return Object.getPrototypeOf(e)===r};function Yn(e,r){if(!it(e))return null;var t;if(pt(r)&&(t=r),wa(r)&&(t=function(n){return oM(n,r)}),t){for(var i=0;i<e.length;i+=1)if(t(e[i]))return e[i]}return null}function lM(e,r,t){t===void 0&&(t=0);for(var i=t;i<e.length;i++)if(r(e[i],i))return i;return-1}var YG=function(e,r){for(var t=null,i=0;i<e.length;i++){var n=e[i],a=n[r];if(!K(a)){it(a)?t=a[0]:t=a;break}}return t},qi=function(e){if(!it(e))return[];for(var r=[],t=0;t<e.length;t++)r=r.concat(e[t]);return r},WG=function(e,r){if(r===void 0&&(r=[]),!it(e))r.push(e);else for(var t=0;t<e.length;t+=1)WG(e[t],r);return r},gr=function(e){if(!!it(e))return e.reduce(function(r,t){return Math.max(r,t)},e[0])},Or=function(e){if(!!it(e))return e.reduce(function(r,t){return Math.min(r,t)},e[0])},sM=function(e){var r=e.filter(function(o){return!isNaN(o)});if(!r.length)return{min:0,max:0};if(it(e[0])){for(var t=[],i=0;i<e.length;i++)t=t.concat(e[i]);r=t}var n=gr(r),a=Or(r);return{min:a,max:n}},XG=Array.prototype,x8=XG.splice,_8=XG.indexOf,b8=function(e){for(var r=[],t=1;t<arguments.length;t++)r[t-1]=arguments[t];for(var i=0;i<r.length;i++)for(var n=r[i],a=-1;(a=_8.call(e,n))>-1;)x8.call(e,a,1);return e},w8=Array.prototype.splice,UG=function(r,t){if(!Ui(r))return[];for(var i=r?t.length:0,n=i-1;i--;){var a=void 0,o=t[i];(i===n||o!==a)&&(a=o,w8.call(r,o,1))}return r},Kr=function(e,r,t){if(!it(e)&&!wa(e))return e;var i=t;return P(e,function(n,a){i=r(i,n,a)}),i},qG=function(e,r){var t=[];if(!Ui(e))return t;for(var i=-1,n=[],a=e.length;++i<a;){var o=e[i];r(o,i,e)&&(t.push(o),n.push(i))}return UG(e,n),t},Ct=function(e){return Zn(e,"String")};function ZG(e,r){var t;if(pt(r))t=function(n,a){return r(n)-r(a)};else{var i=[];Ct(r)?i.push(r):it(r)&&(i=r),t=function(n,a){for(var o=0;o<i.length;o+=1){var l=i[o];if(n[l]>a[l])return 1;if(n[l]<a[l])return-1}return 0}}return e.sort(t),e}function us(e,r){r===void 0&&(r=new Map);var t=[];if(Array.isArray(e))for(var i=0,n=e.length;i<n;i++){var a=e[i];r.has(a)||(t.push(a),r.set(a,!0))}return t}var C8=function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];return us([].concat.apply([],e))},Xn=function(e,r){for(var t=[],i={},n=0;n<e.length;n++){var a=e[n],o=a[r];if(!K(o)){it(o)||(o=[o]);for(var l=0;l<o.length;l++){var s=o[l];i[s]||(t.push(s),i[s]=!0)}}}return t};function Wi(e){if(Ui(e))return e[0]}function nr(e){if(Ui(e)){var r=e;return r[r.length-1]}}function S8(e,r){return it(e)||Ct(e)?e[0]===r:!1}function A8(e,r){return it(e)||Ct(e)?e[e.length-1]===r:!1}var Zx=function(e,r){for(var t=0;t<e.length;t++)if(!r(e[t],t))return!1;return!0},gp=function(e,r){for(var t=0;t<e.length;t++)if(r(e[t],t))return!0;return!1},T8=Object.prototype.hasOwnProperty;function Xi(e,r){if(!r||!it(e))return{};for(var t={},i=pt(r)?r:function(l){return l[r]},n,a=0;a<e.length;a++){var o=e[a];n=i(o),T8.call(t,n)?t[n].push(o):t[n]=[o]}return t}function uM(e,r){if(!r)return{0:e};if(!pt(r)){var t=it(r)?r:r.replace(/\s+/g,"").split("*");r=function(i){for(var n="_",a=0,o=t.length;a<o;a++)n+=i[t[a]]&&i[t[a]].toString();return n}}return Xi(e,r)}var QG=function(e,r){if(!r)return[e];var t=uM(e,r),i=[];for(var n in t)i.push(t[n]);return i};function M8(e,r){return e["_wrap_"+r]}function E8(e,r){if(e["_wrap_"+r])return e["_wrap_"+r];var t=function(i){e[r](i)};return e["_wrap_"+r]=t,t}var P2={};function F8(e){var r=P2[e];if(!r){for(var t=e.toString(16),i=t.length;i<6;i++)t="0"+t;r="#"+t,P2[e]=r}return r}function O8(e){var r=0,t=0,i=0,n=0;return it(e)?e.length===1?r=t=i=n=e[0]:e.length===2?(r=i=e[0],t=n=e[1]):e.length===3?(r=e[0],t=n=e[1],i=e[2]):(r=e[0],t=e[1],i=e[2],n=e[3]):r=t=i=n=e,{r1:r,r2:t,r3:i,r4:n}}var Ce=function(e,r,t){return e<r?r:e>t?t:e},p0=function(e,r){var t=r.toString(),i=t.indexOf(".");if(i===-1)return Math.round(e);var n=t.substr(i+1).length;return n>20&&(n=20),parseFloat(e.toFixed(n))},Mt=function(e){return Zn(e,"Number")},P8=function(e){return Mt(e)&&e%1!==0},I8=function(e){return Mt(e)&&e%2===0},L8=Number.isInteger?Number.isInteger:function(e){return Mt(e)&&e%1===0},D8=function(e){return Mt(e)&&e<0},$8=1e-5;function zr(e,r,t){return t===void 0&&(t=$8),Math.abs(e-r)<t}var k8=function(e){return Mt(e)&&e%2!==0},R8=function(e){return Mt(e)&&e>0},Qx=function(e,r){if(!!it(e)){for(var t,i=-1/0,n=0;n<e.length;n++){var a=e[n],o=pt(r)?r(a):a[r];o>i&&(t=a,i=o)}return t}},cM=function(e,r){if(!!it(e)){for(var t,i=1/0,n=0;n<e.length;n++){var a=e[n],o=pt(r)?r(a):a[r];o<i&&(t=a,i=o)}return t}},Kx=function(e,r){return(e%r+r)%r},B8=180/Math.PI,N8=function(e){return B8*e},G8=parseInt,z8=Math.PI/180,Jx=function(e){return z8*e},po=function(e,r){return e.hasOwnProperty(r)},_h=Object.values?function(e){return Object.values(e)}:function(e){var r=[];return P(e,function(t,i){pt(e)&&i==="prototype"||r.push(t)}),r},V8=function(e,r){return eo(_h(e),r)},Fs=function(e){return K(e)?"":e.toString()},sc=function(e){return Fs(e).toLowerCase()},j8=function(e){var r=Fs(e);return r.charAt(0).toLowerCase()+r.substring(1)};function fM(e,r){return!e||!r?e:e.replace(/\\?\{([^{}]+)\}/g,function(t,i){return t.charAt(0)==="\\"?t.slice(1):r[i]===void 0?"":r[i]})}var H8=function(e){return Fs(e).toUpperCase()},Os=function(e){var r=Fs(e);return r.charAt(0).toUpperCase()+r.substring(1)},Y8={}.toString,KG=function(e){return Y8.call(e).replace(/^\[object /,"").replace(/]$/,"")},W8=function(e){return Zn(e,"Arguments")},Yu=function(e){return Zn(e,"Boolean")},hM=function(e){return Zn(e,"Date")},X8=function(e){return Zn(e,"Error")};function U8(e){return Mt(e)&&isFinite(e)}var JG=function(e){return e===null},q8=Object.prototype,tz=function(e){var r=e&&e.constructor,t=typeof r=="function"&&r.prototype||q8;return e===t},Z8=function(e){return Zn(e,"RegExp")},Yl=function(e){return e===void 0},t1=function(e){return e instanceof Element||e instanceof HTMLDocument};function ez(e){var r=window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.msRequestAnimationFrame||function(t){return setTimeout(t,16)};return r(e)}function rz(e){var r=window.cancelAnimationFrame||window.webkitCancelAnimationFrame||window.mozCancelAnimationFrame||window.msCancelAnimationFrame||clearTimeout;r(e)}function Dw(e,r){for(var t in r)r.hasOwnProperty(t)&&t!=="constructor"&&r[t]!==void 0&&(e[t]=r[t])}function Kt(e,r,t,i){return r&&Dw(e,r),t&&Dw(e,t),i&&Dw(e,i),e}var Q8=function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];for(var t=e[0],i=1;i<e.length;i++){var n=e[i];pt(n)&&(n=n.prototype),Kt(t.prototype,n)}},di=function(e){if(typeof e!="object"||e===null)return e;var r;if(it(e)){r=[];for(var t=0,i=e.length;t<i;t++)typeof e[t]=="object"&&e[t]!=null?r[t]=di(e[t]):r[t]=e[t]}else{r={};for(var n in e)typeof e[n]=="object"&&e[n]!=null?r[n]=di(e[n]):r[n]=e[n]}return r};function e1(e,r,t){var i;return function(){var n=this,a=arguments,o=function(){i=null,t||e.apply(n,a)},l=t&&!i;clearTimeout(i),i=setTimeout(o,r),l&&e.apply(n,a)}}var uc=function(e,r){if(!pt(e))throw new TypeError("Expected a function");var t=function(){for(var i=[],n=0;n<arguments.length;n++)i[n]=arguments[n];var a=r?r.apply(this,i):i[0],o=t.cache;if(o.has(a))return o.get(a);var l=e.apply(this,i);return o.set(a,l),l};return t.cache=new Map,t},K8=5;function iz(e,r,t,i){t=t||0,i=i||K8;for(var n in r)if(r.hasOwnProperty(n)){var a=r[n];a!==null&&wa(a)?(wa(e[n])||(e[n]={}),t<i?iz(e[n],a,t+1,i):e[n]=r[n]):it(a)?(e[n]=[],e[n]=e[n].concat(a)):a!==void 0&&(e[n]=a)}}var ft=function(e){for(var r=[],t=1;t<arguments.length;t++)r[t-1]=arguments[t];for(var i=0;i<r.length;i+=1)iz(e,r[i]);return e},J8=function(e,r,t,i){pt(r)||(t=r,r=e,e=function(){});var n=Object.create?function(o,l){return Object.create(o,{constructor:{value:l}})}:function(o,l){function s(){}s.prototype=o;var u=new s;return u.constructor=l,u},a=n(r.prototype,e);return e.prototype=Kt(a,e.prototype),e.superclass=n(r.prototype,r),Kt(a,t),Kt(e,i),e},vM=function(e,r){if(!Ui(e))return-1;var t=Array.prototype.indexOf;if(t)return t.call(e,r);for(var i=-1,n=0;n<e.length;n++)if(e[n]===r){i=n;break}return i},t9=Object.prototype.hasOwnProperty;function gi(e){if(K(e))return!0;if(Ui(e))return!e.length;var r=KG(e);if(r==="Map"||r==="Set")return!e.size;if(tz(e))return!Object.keys(e).length;for(var t in e)if(t9.call(e,t))return!1;return!0}var Ge=function(e,r){if(e===r)return!0;if(!e||!r||Ct(e)||Ct(r))return!1;if(Ui(e)||Ui(r)){if(e.length!==r.length)return!1;for(var t=!0,i=0;i<e.length&&(t=Ge(e[i],r[i]),!!t);i++);return t}if(z0(e)||z0(r)){var n=Object.keys(e),a=Object.keys(r);if(n.length!==a.length)return!1;for(var t=!0,i=0;i<n.length&&(t=Ge(e[n[i]],r[n[i]]),!!t);i++);return t}return!1},e9=function(e,r,t){return pt(t)?!!t(e,r):Ge(e,r)},je=function(e,r){if(!Ui(e))return e;for(var t=[],i=0;i<e.length;i++){var n=e[i];t.push(r(n,i))}return t},r9=function(e){return e},nz=function(e,r){r===void 0&&(r=r9);var t={};return Zt(e)&&!K(e)&&Object.keys(e).forEach(function(i){t[i]=r(e[i],i)}),t},I=function(e,r,t){for(var i=0,n=Ct(r)?r.split("."):r;e&&i<n.length;)e=e[n[i++]];return e===void 0||i<n.length?t:e},jt=function(e,r,t){var i=e,n=Ct(r)?r.split("."):r;return n.forEach(function(a,o){o<n.length-1?(Zt(i[a])||(i[a]=Mt(n[o+1])?[]:{}),i=i[a]):i[a]=t}),e},i9=Object.prototype.hasOwnProperty,r1=function(e,r){if(e===null||!wa(e))return{};var t={};return P(r,function(i){i9.call(e,i)&&(t[i]=e[i])}),t},i1=function(e,r){return Kr(e,function(t,i,n){return r.includes(n)||(t[n]=i),t},{})},n1=function(e,r,t){var i,n,a,o,l=0;t||(t={});var s=function(){l=t.leading===!1?0:Date.now(),i=null,o=e.apply(n,a),i||(n=a=null)},u=function(){var c=Date.now();!l&&t.leading===!1&&(l=c);var f=r-(c-l);return n=this,a=arguments,f<=0||f>r?(i&&(clearTimeout(i),i=null),l=c,o=e.apply(n,a),i||(n=a=null)):!i&&t.trailing!==!1&&(i=setTimeout(s,f)),o};return u.cancel=function(){clearTimeout(i),l=0,i=n=a=null},u},az=function(e){return Ui(e)?Array.prototype.slice.call(e):[]},Ey={},Oa=function(e){return e=e||"g",Ey[e]?Ey[e]+=1:Ey[e]=1,e+Ey[e]},Wo=function(){},n9=function(e){return e};function yr(e){return K(e)?0:Ui(e)?e.length:Object.keys(e).length}var Fy,zv=uc(function(e,r){r===void 0&&(r={});var t=r.fontSize,i=r.fontFamily,n=r.fontWeight,a=r.fontStyle,o=r.fontVariant;return Fy||(Fy=document.createElement("canvas").getContext("2d")),Fy.font=[a,o,n,t+"px",i].join(" "),Fy.measureText(Ct(e)?e:"").width},function(e,r){return r===void 0&&(r={}),ye([e],_h(r)).join("")}),oz=function(e,r,t,i){i===void 0&&(i="...");var n=16,a=zv(i,t),o=Ct(e)?e:Fs(e),l=r,s=[],u,c;if(zv(e,t)<=r)return e;for(;u=o.substr(0,n),c=zv(u,t),!(c+a>l&&c>l);)if(s.push(u),l-=c,o=o.substr(n),!o)return s.join("");for(;u=o.substr(0,1),c=zv(u,t),!(c+a>l);)if(s.push(u),l-=c,o=o.substr(1),!o)return s.join("");return""+s.join("")+i},lz=function(){function e(){this.map={}}return e.prototype.has=function(r){return this.map[r]!==void 0},e.prototype.get=function(r,t){var i=this.map[r];return i===void 0?t:i},e.prototype.set=function(r,t){this.map[r]=t},e.prototype.clear=function(){this.map={}},e.prototype.delete=function(r){delete this.map[r]},e.prototype.size=function(){return Object.keys(this.map).length},e}(),sz=Object.freeze(Object.defineProperty({__proto__:null,contains:eo,includes:eo,difference:HG,find:Yn,findIndex:lM,firstValue:YG,flatten:qi,flattenDeep:WG,getRange:sM,pull:b8,pullAt:UG,reduce:Kr,remove:qG,sortBy:ZG,union:C8,uniq:us,valuesOfKey:Xn,head:Wi,last:nr,startsWith:S8,endsWith:A8,filter:jr,every:Zx,some:gp,group:QG,groupBy:Xi,groupToMap:uM,getWrapBehavior:M8,wrapBehavior:E8,number2color:F8,parseRadius:O8,clamp:Ce,fixedBase:p0,isDecimal:P8,isEven:I8,isInteger:L8,isNegative:D8,isNumberEqual:zr,isOdd:k8,isPositive:R8,max:gr,maxBy:Qx,min:Or,minBy:cM,mod:Kx,toDegree:N8,toInteger:G8,toRadian:Jx,forIn:P,has:po,hasKey:po,hasValue:V8,keys:lc,isMatch:oM,values:_h,lowerCase:sc,lowerFirst:j8,substitute:fM,upperCase:H8,upperFirst:Os,getType:KG,isArguments:W8,isArray:it,isArrayLike:Ui,isBoolean:Yu,isDate:hM,isError:X8,isFunction:pt,isFinite:U8,isNil:K,isNull:JG,isNumber:Mt,isObject:Zt,isObjectLike:z0,isPlainObject:wa,isPrototype:tz,isRegExp:Z8,isString:Ct,isType:Zn,isUndefined:Yl,isElement:t1,requestAnimationFrame:ez,clearAnimationFrame:rz,augment:Q8,clone:di,debounce:e1,memoize:uc,deepMix:ft,each:P,extend:J8,indexOf:vM,isEmpty:gi,isEqual:Ge,isEqualWith:e9,map:je,mapValues:nz,mix:Kt,assign:Kt,get:I,set:jt,pick:r1,omit:i1,throttle:n1,toArray:az,toString:Fs,uniqueId:Oa,noop:Wo,identity:n9,size:yr,measureTextWidth:zv,getEllipsisText:oz,Cache:lz},Symbol.toStringTag,{value:"Module"})),uz={},V=br(h8);function hu(e,r,t){if(e){if(typeof e.addEventListener=="function")return e.addEventListener(r,t,!1),{remove:function(){e.removeEventListener(r,t,!1)}};if(typeof e.attachEvent=="function")return e.attachEvent("on"+r,t),{remove:function(){e.detachEvent("on"+r,t)}}}}var Vv,$w,cz,uA;function a9(){Vv=document.createElement("table"),$w=document.createElement("tr"),cz=/^\s*<(\w+|!)[^>]*>/,uA={tr:document.createElement("tbody"),tbody:Vv,thead:Vv,tfoot:Vv,td:$w,th:$w,"*":document.createElement("div")}}function Zo(e){Vv||a9();var r=cz.test(e)&&RegExp.$1;(!r||!(r in uA))&&(r="*");var t=uA[r];e=typeof e=="string"?e.replace(/(^\s*)|(\s*$)/g,""):e,t.innerHTML=""+e;var i=t.childNodes[0];return i&&t.contains(i)&&t.removeChild(i),i}function Si(e,r,t){var i;try{i=window.getComputedStyle?window.getComputedStyle(e,null)[r]:e.style[r]}catch{}finally{i=i===void 0?t:i}return i}function fz(e,r){var t=Si(e,"height",r);return t==="auto"&&(t=e.offsetHeight),parseFloat(t)}function hz(e,r){var t=fz(e,r),i=parseFloat(Si(e,"borderTopWidth"))||0,n=parseFloat(Si(e,"paddingTop"))||0,a=parseFloat(Si(e,"paddingBottom"))||0,o=parseFloat(Si(e,"borderBottomWidth"))||0,l=parseFloat(Si(e,"marginTop"))||0,s=parseFloat(Si(e,"marginBottom"))||0;return t+i+o+n+a+l+s}function vz(e,r){var t=Si(e,"width",r);return t==="auto"&&(t=e.offsetWidth),parseFloat(t)}function dz(e,r){var t=vz(e,r),i=parseFloat(Si(e,"borderLeftWidth"))||0,n=parseFloat(Si(e,"paddingLeft"))||0,a=parseFloat(Si(e,"paddingRight"))||0,o=parseFloat(Si(e,"borderRightWidth"))||0,l=parseFloat(Si(e,"marginRight"))||0,s=parseFloat(Si(e,"marginLeft"))||0;return t+i+o+n+a+s+l}function o9(){return window.devicePixelRatio?window.devicePixelRatio:2}function qr(e,r){if(e)for(var t in r)r.hasOwnProperty(t)&&(e.style[t]=r[t]);return e}var l9=Object.freeze(Object.defineProperty({__proto__:null,addEventListener:hu,createDom:Zo,getHeight:fz,getOuterHeight:hz,getOuterWidth:dz,getRatio:o9,getStyle:Si,getWidth:vz,modifyCSS:qr},Symbol.toStringTag,{value:"Module"})),dM=br(l9),Y=br(sz),pM={},Ut={},cd=`
|
|
\v\f\r \xA0\u1680\u180E\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029`,s9=new RegExp("([a-z])["+cd+",]*((-?\\d*\\.?\\d*(?:e[\\-+]?\\d+)?["+cd+"]*,?["+cd+"]*)+)","ig"),u9=new RegExp("(-?\\d*\\.?\\d*(?:e[\\-+]?\\d+)?)["+cd+"]*,?["+cd+"]*","ig"),hf=function(e){if(!e)return null;if(it(e))return e;var r={a:7,c:6,o:2,h:1,l:2,m:2,r:4,q:4,s:4,t:2,v:1,u:3,z:0},t=[];return String(e).replace(s9,function(i,n,a){var o=[],l=n.toLowerCase();if(a.replace(u9,function(s,u){u&&o.push(+u)}),l==="m"&&o.length>2&&(t.push([n].concat(o.splice(0,2))),l="l",n=n==="m"?"l":"L"),l==="o"&&o.length===1&&t.push([n,o[0]]),l==="r")t.push([n].concat(o));else for(;o.length>=r[l]&&(t.push([n].concat(o.splice(0,r[l]))),!!r[l]););return e}),t},cA=function(e,r){for(var t=[],i=0,n=e.length;n-2*!r>i;i+=2){var a=[{x:+e[i-2],y:+e[i-1]},{x:+e[i],y:+e[i+1]},{x:+e[i+2],y:+e[i+3]},{x:+e[i+4],y:+e[i+5]}];r?i?n-4===i?a[3]={x:+e[0],y:+e[1]}:n-2===i&&(a[2]={x:+e[0],y:+e[1]},a[3]={x:+e[2],y:+e[3]}):a[0]={x:+e[n-2],y:+e[n-1]}:n-4===i?a[3]=a[2]:i||(a[0]={x:+e[i],y:+e[i+1]}),t.push(["C",(-a[0].x+6*a[1].x+a[2].x)/6,(-a[0].y+6*a[1].y+a[2].y)/6,(a[1].x+6*a[2].x-a[3].x)/6,(a[1].y+6*a[2].y-a[3].y)/6,a[2].x,a[2].y])}return t},Oy=function(e,r,t,i,n){var a=[];if(n===null&&i===null&&(i=t),e=+e,r=+r,t=+t,i=+i,n!==null){var o=Math.PI/180,l=e+t*Math.cos(-i*o),s=e+t*Math.cos(-n*o),u=r+t*Math.sin(-i*o),c=r+t*Math.sin(-n*o);a=[["M",l,u],["A",t,t,0,+(n-i>180),0,s,c]]}else a=[["M",e,r],["m",0,-i],["a",t,i,0,1,1,0,2*i],["a",t,i,0,1,1,0,-2*i],["z"]];return a},fA=function(e){if(e=hf(e),!e||!e.length)return[["M",0,0]];var r=[],t=0,i=0,n=0,a=0,o=0,l,s;e[0][0]==="M"&&(t=+e[0][1],i=+e[0][2],n=t,a=i,o++,r[0]=["M",t,i]);for(var u=e.length===3&&e[0][0]==="M"&&e[1][0].toUpperCase()==="R"&&e[2][0].toUpperCase()==="Z",c=void 0,f=void 0,h=o,v=e.length;h<v;h++){if(r.push(c=[]),f=e[h],l=f[0],l!==l.toUpperCase())switch(c[0]=l.toUpperCase(),c[0]){case"A":c[1]=f[1],c[2]=f[2],c[3]=f[3],c[4]=f[4],c[5]=f[5],c[6]=+f[6]+t,c[7]=+f[7]+i;break;case"V":c[1]=+f[1]+i;break;case"H":c[1]=+f[1]+t;break;case"R":s=[t,i].concat(f.slice(1));for(var d=2,p=s.length;d<p;d++)s[d]=+s[d]+t,s[++d]=+s[d]+i;r.pop(),r=r.concat(cA(s,u));break;case"O":r.pop(),s=Oy(t,i,f[1],f[2]),s.push(s[0]),r=r.concat(s);break;case"U":r.pop(),r=r.concat(Oy(t,i,f[1],f[2],f[3])),c=["U"].concat(r[r.length-1].slice(-2));break;case"M":n=+f[1]+t,a=+f[2]+i;break;default:for(var d=1,p=f.length;d<p;d++)c[d]=+f[d]+(d%2?t:i)}else if(l==="R")s=[t,i].concat(f.slice(1)),r.pop(),r=r.concat(cA(s,u)),c=["R"].concat(f.slice(-2));else if(l==="O")r.pop(),s=Oy(t,i,f[1],f[2]),s.push(s[0]),r=r.concat(s);else if(l==="U")r.pop(),r=r.concat(Oy(t,i,f[1],f[2],f[3])),c=["U"].concat(r[r.length-1].slice(-2));else for(var x=0,m=f.length;x<m;x++)c[x]=f[x];if(l=l.toUpperCase(),l!=="O")switch(c[0]){case"Z":t=+n,i=+a;break;case"H":t=c[1];break;case"V":i=c[1];break;case"M":n=c[c.length-2],a=c[c.length-1];break;default:t=c[c.length-2],i=c[c.length-1]}}return r},Py=function(e,r,t,i){return[e,r,t,i,t,i]},I2=function(e,r,t,i,n,a){var o=.3333333333333333,l=2/3;return[o*e+l*t,o*r+l*i,o*n+l*t,o*a+l*i,n,a]},pz=function(e,r,t,i,n,a,o,l,s,u){t===i&&(t+=1);var c=Math.PI*120/180,f=Math.PI/180*(+n||0),h=[],v,d,p,x,m,_=function(dt,ht,wt){var gt=dt*Math.cos(wt)-ht*Math.sin(wt),vt=dt*Math.sin(wt)+ht*Math.cos(wt);return{x:gt,y:vt}};if(u)d=u[0],p=u[1],x=u[2],m=u[3];else{v=_(e,r,-f),e=v.x,r=v.y,v=_(l,s,-f),l=v.x,s=v.y,e===l&&r===s&&(l+=1,s+=1);var b=(e-l)/2,w=(r-s)/2,S=b*b/(t*t)+w*w/(i*i);S>1&&(S=Math.sqrt(S),t=S*t,i=S*i);var M=t*t,F=i*i,O=(a===o?-1:1)*Math.sqrt(Math.abs((M*F-M*w*w-F*b*b)/(M*w*w+F*b*b)));x=O*t*w/i+(e+l)/2,m=O*-i*b/t+(r+s)/2,d=Math.asin(((r-m)/i).toFixed(9)),p=Math.asin(((s-m)/i).toFixed(9)),d=e<x?Math.PI-d:d,p=l<x?Math.PI-p:p,d<0&&(d=Math.PI*2+d),p<0&&(p=Math.PI*2+p),o&&d>p&&(d=d-Math.PI*2),!o&&p>d&&(p=p-Math.PI*2)}var L=p-d;if(Math.abs(L)>c){var D=p,k=l,H=s;p=d+c*(o&&p>d?1:-1),l=x+t*Math.cos(p),s=m+i*Math.sin(p),h=pz(l,s,t,i,n,0,o,k,H,[p,D,x,m])}L=p-d;var B=Math.cos(d),j=Math.sin(d),U=Math.cos(p),R=Math.sin(p),G=Math.tan(L/4),N=4/3*t*G,W=4/3*i*G,q=[e,r],tt=[e+N*j,r-W*B],ot=[l+N*R,s-W*U],st=[l,s];if(tt[0]=2*q[0]-tt[0],tt[1]=2*q[1]-tt[1],u)return[tt,ot,st].concat(h);h=[tt,ot,st].concat(h).join().split(",");for(var Z=[],et=0,lt=h.length;et<lt;et++)Z[et]=et%2?_(h[et-1],h[et],f).y:_(h[et],h[et+1],f).x;return Z},hA=function(e,r){var t=fA(e),i=r&&fA(r),n={x:0,y:0,bx:0,by:0,X:0,Y:0,qx:null,qy:null},a={x:0,y:0,bx:0,by:0,X:0,Y:0,qx:null,qy:null},o=[],l=[],s="",u="",c,f=function(b,w,S){var M,F;if(!b)return["C",w.x,w.y,w.x,w.y,w.x,w.y];switch(!(b[0]in{T:1,Q:1})&&(w.qx=w.qy=null),b[0]){case"M":w.X=b[1],w.Y=b[2];break;case"A":b=["C"].concat(pz.apply(0,[w.x,w.y].concat(b.slice(1))));break;case"S":S==="C"||S==="S"?(M=w.x*2-w.bx,F=w.y*2-w.by):(M=w.x,F=w.y),b=["C",M,F].concat(b.slice(1));break;case"T":S==="Q"||S==="T"?(w.qx=w.x*2-w.qx,w.qy=w.y*2-w.qy):(w.qx=w.x,w.qy=w.y),b=["C"].concat(I2(w.x,w.y,w.qx,w.qy,b[1],b[2]));break;case"Q":w.qx=b[1],w.qy=b[2],b=["C"].concat(I2(w.x,w.y,b[1],b[2],b[3],b[4]));break;case"L":b=["C"].concat(Py(w.x,w.y,b[1],b[2]));break;case"H":b=["C"].concat(Py(w.x,w.y,b[1],w.y));break;case"V":b=["C"].concat(Py(w.x,w.y,w.x,b[1]));break;case"Z":b=["C"].concat(Py(w.x,w.y,w.X,w.Y));break}return b},h=function(b,w){if(b[w].length>7){b[w].shift();for(var S=b[w];S.length;)o[w]="A",i&&(l[w]="A"),b.splice(w++,0,["C"].concat(S.splice(0,6)));b.splice(w,1),c=Math.max(t.length,i&&i.length||0)}},v=function(b,w,S,M,F){b&&w&&b[F][0]==="M"&&w[F][0]!=="M"&&(w.splice(F,0,["M",M.x,M.y]),S.bx=0,S.by=0,S.x=b[F][1],S.y=b[F][2],c=Math.max(t.length,i&&i.length||0))};c=Math.max(t.length,i&&i.length||0);for(var d=0;d<c;d++){t[d]&&(s=t[d][0]),s!=="C"&&(o[d]=s,d&&(u=o[d-1])),t[d]=f(t[d],n,u),o[d]!=="A"&&s==="C"&&(o[d]="C"),h(t,d),i&&(i[d]&&(s=i[d][0]),s!=="C"&&(l[d]=s,d&&(u=l[d-1])),i[d]=f(i[d],a,u),l[d]!=="A"&&s==="C"&&(l[d]="C"),h(i,d)),v(t,i,n,a,d),v(i,t,a,n,d);var p=t[d],x=i&&i[d],m=p.length,_=i&&x.length;n.x=p[m-2],n.y=p[m-1],n.bx=parseFloat(p[m-4])||n.x,n.by=parseFloat(p[m-3])||n.y,a.bx=i&&(parseFloat(x[_-4])||a.x),a.by=i&&(parseFloat(x[_-3])||a.y),a.x=i&&x[_-2],a.y=i&&x[_-1]}return i?[t,i]:t},c9=/,?([a-z]),?/gi,gz=function(e){return e.join(",").replace(c9,"$1")},L2=function(e,r,t,i,n){var a=-3*r+9*t-9*i+3*n,o=e*a+6*r-12*t+6*i;return e*o-3*r+3*t},D2=function(e,r,t,i,n,a,o,l,s){s===null&&(s=1),s=s>1?1:s<0?0:s;for(var u=s/2,c=12,f=[-.1252,.1252,-.3678,.3678,-.5873,.5873,-.7699,.7699,-.9041,.9041,-.9816,.9816],h=[.2491,.2491,.2335,.2335,.2032,.2032,.1601,.1601,.1069,.1069,.0472,.0472],v=0,d=0;d<c;d++){var p=u*f[d]+u,x=L2(p,e,t,n,o),m=L2(p,r,i,a,l),_=x*x+m*m;v+=h[d]*Math.sqrt(_)}return u*v},f9=function(e,r,t,i,n,a,o,l){for(var s=[],u=[[],[]],c,f,h,v,d=0;d<2;++d){if(d===0?(f=6*e-12*t+6*n,c=-3*e+9*t-9*n+3*o,h=3*t-3*e):(f=6*r-12*i+6*a,c=-3*r+9*i-9*a+3*l,h=3*i-3*r),Math.abs(c)<1e-12){if(Math.abs(f)<1e-12)continue;v=-h/f,v>0&&v<1&&s.push(v);continue}var p=f*f-4*h*c,x=Math.sqrt(p);if(!(p<0)){var m=(-f+x)/(2*c);m>0&&m<1&&s.push(m);var _=(-f-x)/(2*c);_>0&&_<1&&s.push(_)}}for(var b=s.length,w=b,S;b--;)v=s[b],S=1-v,u[0][b]=S*S*S*e+3*S*S*v*t+3*S*v*v*n+v*v*v*o,u[1][b]=S*S*S*r+3*S*S*v*i+3*S*v*v*a+v*v*v*l;return u[0][w]=e,u[1][w]=r,u[0][w+1]=o,u[1][w+1]=l,u[0].length=u[1].length=w+2,{min:{x:Math.min.apply(0,u[0]),y:Math.min.apply(0,u[1])},max:{x:Math.max.apply(0,u[0]),y:Math.max.apply(0,u[1])}}},h9=function(e,r,t,i,n,a,o,l){if(!(Math.max(e,t)<Math.min(n,o)||Math.min(e,t)>Math.max(n,o)||Math.max(r,i)<Math.min(a,l)||Math.min(r,i)>Math.max(a,l))){var s=(e*i-r*t)*(n-o)-(e-t)*(n*l-a*o),u=(e*i-r*t)*(a-l)-(r-i)*(n*l-a*o),c=(e-t)*(a-l)-(r-i)*(n-o);if(!!c){var f=s/c,h=u/c,v=+f.toFixed(2),d=+h.toFixed(2);if(!(v<+Math.min(e,t).toFixed(2)||v>+Math.max(e,t).toFixed(2)||v<+Math.min(n,o).toFixed(2)||v>+Math.max(n,o).toFixed(2)||d<+Math.min(r,i).toFixed(2)||d>+Math.max(r,i).toFixed(2)||d<+Math.min(a,l).toFixed(2)||d>+Math.max(a,l).toFixed(2)))return{x:f,y:h}}}},Cl=function(e,r,t){return r>=e.x&&r<=e.x+e.width&&t>=e.y&&t<=e.y+e.height},yz=function(e,r,t,i,n){if(n)return[["M",+e+ +n,r],["l",t-n*2,0],["a",n,n,0,0,1,n,n],["l",0,i-n*2],["a",n,n,0,0,1,-n,n],["l",n*2-t,0],["a",n,n,0,0,1,-n,-n],["l",0,n*2-i],["a",n,n,0,0,1,n,-n],["z"]];var a=[["M",e,r],["l",t,0],["l",0,i],["l",-t,0],["z"]];return a.parsePathArray=gz,a},vA=function(e,r,t,i){return e===null&&(e=r=t=i=0),r===null&&(r=e.y,t=e.width,i=e.height,e=e.x),{x:e,y:r,width:t,w:t,height:i,h:i,x2:e+t,y2:r+i,cx:e+t/2,cy:r+i/2,r1:Math.min(t,i)/2,r2:Math.max(t,i)/2,r0:Math.sqrt(t*t+i*i)/2,path:yz(e,r,t,i),vb:[e,r,t,i].join(" ")}},v9=function(e,r){return e=vA(e),r=vA(r),Cl(r,e.x,e.y)||Cl(r,e.x2,e.y)||Cl(r,e.x,e.y2)||Cl(r,e.x2,e.y2)||Cl(e,r.x,r.y)||Cl(e,r.x2,r.y)||Cl(e,r.x,r.y2)||Cl(e,r.x2,r.y2)||(e.x<r.x2&&e.x>r.x||r.x<e.x2&&r.x>e.x)&&(e.y<r.y2&&e.y>r.y||r.y<e.y2&&r.y>e.y)},$2=function(e,r,t,i,n,a,o,l){it(e)||(e=[e,r,t,i,n,a,o,l]);var s=f9.apply(null,e);return vA(s.min.x,s.min.y,s.max.x-s.min.x,s.max.y-s.min.y)},k2=function(e,r,t,i,n,a,o,l,s){var u=1-s,c=Math.pow(u,3),f=Math.pow(u,2),h=s*s,v=h*s,d=c*e+f*3*s*t+u*3*s*s*n+v*o,p=c*r+f*3*s*i+u*3*s*s*a+v*l,x=e+2*s*(t-e)+h*(n-2*t+e),m=r+2*s*(i-r)+h*(a-2*i+r),_=t+2*s*(n-t)+h*(o-2*n+t),b=i+2*s*(a-i)+h*(l-2*a+i),w=u*e+s*t,S=u*r+s*i,M=u*n+s*o,F=u*a+s*l,O=90-Math.atan2(x-_,m-b)*180/Math.PI;return{x:d,y:p,m:{x,y:m},n:{x:_,y:b},start:{x:w,y:S},end:{x:M,y:F},alpha:O}},d9=function(e,r,t){var i=$2(e),n=$2(r);if(!v9(i,n))return t?0:[];for(var a=D2.apply(0,e),o=D2.apply(0,r),l=~~(a/8),s=~~(o/8),u=[],c=[],f={},h=t?0:[],v=0;v<l+1;v++){var d=k2.apply(0,e.concat(v/l));u.push({x:d.x,y:d.y,t:v/l})}for(var v=0;v<s+1;v++){var d=k2.apply(0,r.concat(v/s));c.push({x:d.x,y:d.y,t:v/s})}for(var v=0;v<l;v++)for(var p=0;p<s;p++){var x=u[v],m=u[v+1],_=c[p],b=c[p+1],w=Math.abs(m.x-x.x)<.001?"y":"x",S=Math.abs(b.x-_.x)<.001?"y":"x",M=h9(x.x,x.y,m.x,m.y,_.x,_.y,b.x,b.y);if(M){if(f[M.x.toFixed(4)]===M.y.toFixed(4))continue;f[M.x.toFixed(4)]=M.y.toFixed(4);var F=x.t+Math.abs((M[w]-x[w])/(m[w]-x[w]))*(m.t-x.t),O=_.t+Math.abs((M[S]-_[S])/(b[S]-_[S]))*(b.t-_.t);F>=0&&F<=1&&O>=0&&O<=1&&(t?h+=1:h.push({x:M.x,y:M.y,t1:F,t2:O}))}}return h},p9=function(e,r,t){e=hA(e),r=hA(r);for(var i,n,a,o,l,s,u,c,f,h,v=t?0:[],d=0,p=e.length;d<p;d++){var x=e[d];if(x[0]==="M")i=l=x[1],n=s=x[2];else{x[0]==="C"?(f=[i,n].concat(x.slice(1)),i=f[6],n=f[7]):(f=[i,n,i,n,l,s,l,s],i=l,n=s);for(var m=0,_=r.length;m<_;m++){var b=r[m];if(b[0]==="M")a=u=b[1],o=c=b[2];else{b[0]==="C"?(h=[a,o].concat(b.slice(1)),a=h[6],o=h[7]):(h=[a,o,a,o,u,c,u,c],a=u,o=c);var w=d9(f,h,t);if(t)v+=w;else{for(var S=0,M=w.length;S<M;S++)w[S].segment1=d,w[S].segment2=m,w[S].bez1=f,w[S].bez2=h;v=v.concat(w)}}}}}return v},g9=function(e,r){return p9(e,r)};function y9(e,r){var t=[],i=[];function n(a,o){if(a.length===1)t.push(a[0]),i.push(a[0]);else{for(var l=[],s=0;s<a.length-1;s++)s===0&&t.push(a[0]),s===a.length-2&&i.push(a[s+1]),l[s]=[(1-o)*a[s][0]+o*a[s+1][0],(1-o)*a[s][1]+o*a[s+1][1]];n(l,o)}}return e.length&&n(e,r),{left:t,right:i.reverse()}}function m9(e,r,t){var i=[[e[1],e[2]]];t=t||2;var n=[];r[0]==="A"?(i.push(r[6]),i.push(r[7])):r[0]==="C"?(i.push([r[1],r[2]]),i.push([r[3],r[4]]),i.push([r[5],r[6]])):r[0]==="S"||r[0]==="Q"?(i.push([r[1],r[2]]),i.push([r[3],r[4]])):i.push([r[1],r[2]]);for(var a=i,o=1/t,l=0;l<t-1;l++){var s=o/(1-o*l),u=y9(a,s);n.push(u.left),a=u.right}n.push(a);var c=n.map(function(f){var h=[];return f.length===4&&(h.push("C"),h=h.concat(f[2])),f.length>=3&&(f.length===3&&h.push("Q"),h=h.concat(f[1])),f.length===2&&h.push("L"),h=h.concat(f[f.length-1]),h});return c}var x9=function(e,r,t){if(t===1)return[[].concat(e)];var i=[];if(r[0]==="L"||r[0]==="C"||r[0]==="Q")i=i.concat(m9(e,r,t));else{var n=[].concat(e);n[0]==="M"&&(n[0]="L");for(var a=0;a<=t-1;a++)i.push(n)}return i},_9=function(e,r){if(e.length===1)return e;var t=e.length-1,i=r.length-1,n=t/i,a=[];if(e.length===1&&e[0][0]==="M"){for(var o=0;o<i-t;o++)e.push(e[0]);return e}for(var o=0;o<i;o++){var l=Math.floor(n*o);a[l]=(a[l]||0)+1}var s=a.reduce(function(u,c,f){return f===t?u.concat(e[t]):u.concat(x9(e[f],e[f+1],c))},[]);return s.unshift(e[0]),(r[i]==="Z"||r[i]==="z")&&s.push("Z"),s},b9=function(e,r){if(e.length!==r.length)return!1;var t=!0;return P(e,function(i,n){if(i!==r[n])return t=!1,!1}),t};function w9(e,r,t){var i=null,n=t;return r<n&&(n=r,i="add"),e<n&&(n=e,i="del"),{type:i,min:n}}var C9=function(e,r){var t=e.length,i=r.length,n,a,o=0;if(t===0||i===0)return null;for(var l=[],s=0;s<=t;s++)l[s]=[],l[s][0]={min:s};for(var u=0;u<=i;u++)l[0][u]={min:u};for(var s=1;s<=t;s++){n=e[s-1];for(var u=1;u<=i;u++){a=r[u-1],b9(n,a)?o=0:o=1;var c=l[s-1][u].min+1,f=l[s][u-1].min+1,h=l[s-1][u-1].min+o;l[s][u]=w9(c,f,h)}}return l},mz=function(e,r){var t=C9(e,r),i=e.length,n=r.length,a=[],o=1,l=1;if(t[i][n].min!==i){for(var s=1;s<=i;s++){var u=t[s][s].min;l=s;for(var c=o;c<=n;c++)t[s][c].min<u&&(u=t[s][c].min,l=c);o=l,t[s][o].type&&a.push({index:s-1,type:t[s][o].type})}for(var s=a.length-1;s>=0;s--)o=a[s].index,a[s].type==="add"?e.splice(o,0,[].concat(e[o])):e.splice(o,1)}i=e.length;var f=n-i;if(i<n)for(var s=0;s<f;s++)e[i-1][0]==="z"||e[i-1][0]==="Z"?e.splice(i-2,0,e[i-2]):e.push(e[i-1]),i+=1;return e};function kw(e,r,t){for(var i=[].concat(e),n,a=1/(t+1),o=xz(r)[0],l=1;l<=t;l++)a*=l,n=Math.floor(e.length*a),n===0?i.unshift([o[0]*a+e[n][0]*(1-a),o[1]*a+e[n][1]*(1-a)]):i.splice(n,0,[o[0]*a+e[n][0]*(1-a),o[1]*a+e[n][1]*(1-a)]);return i}function xz(e){var r=[];switch(e[0]){case"M":r.push([e[1],e[2]]);break;case"L":r.push([e[1],e[2]]);break;case"A":r.push([e[6],e[7]]);break;case"Q":r.push([e[3],e[4]]),r.push([e[1],e[2]]);break;case"T":r.push([e[1],e[2]]);break;case"C":r.push([e[5],e[6]]),r.push([e[1],e[2]]),r.push([e[3],e[4]]);break;case"S":r.push([e[3],e[4]]),r.push([e[1],e[2]]);break;case"H":r.push([e[1],e[1]]);break;case"V":r.push([e[1],e[1]]);break}return r}var dA=function(e,r){if(e.length<=1)return e;for(var t,i=0;i<r.length;i++)if(e[i][0]!==r[i][0])switch(t=xz(e[i]),r[i][0]){case"M":e[i]=["M"].concat(t[0]);break;case"L":e[i]=["L"].concat(t[0]);break;case"A":e[i]=[].concat(r[i]),e[i][6]=t[0][0],e[i][7]=t[0][1];break;case"Q":if(t.length<2)if(i>0)t=kw(t,e[i-1],1);else{e[i]=r[i];break}e[i]=["Q"].concat(t.reduce(function(n,a){return n.concat(a)},[]));break;case"T":e[i]=["T"].concat(t[0]);break;case"C":if(t.length<3)if(i>0)t=kw(t,e[i-1],2);else{e[i]=r[i];break}e[i]=["C"].concat(t.reduce(function(n,a){return n.concat(a)},[]));break;case"S":if(t.length<2)if(i>0)t=kw(t,e[i-1],1);else{e[i]=r[i];break}e[i]=["S"].concat(t.reduce(function(n,a){return n.concat(a)},[]));break;default:e[i]=r[i]}return e},a1=Object.freeze(Object.defineProperty({__proto__:null,catmullRomToBezier:cA,fillPath:_9,fillPathByDiff:mz,formatPath:dA,intersection:g9,parsePathArray:gz,parsePathString:hf,pathToAbsolute:fA,pathToCurve:hA,rectPath:yz},Symbol.toStringTag,{value:"Module"})),bh=function(){function e(r,t){this.bubbles=!0,this.target=null,this.currentTarget=null,this.delegateTarget=null,this.delegateObject=null,this.defaultPrevented=!1,this.propagationStopped=!1,this.shape=null,this.fromShape=null,this.toShape=null,this.propagationPath=[],this.type=r,this.name=r,this.originalEvent=t,this.timeStamp=t.timeStamp}return e.prototype.preventDefault=function(){this.defaultPrevented=!0,this.originalEvent.preventDefault&&this.originalEvent.preventDefault()},e.prototype.stopPropagation=function(){this.propagationStopped=!0},e.prototype.toString=function(){var r=this.type;return"[Event (type="+r+")]"},e.prototype.save=function(){},e.prototype.restore=function(){},e}(),S9="*",yp=function(){function e(){this._events={}}return e.prototype.on=function(r,t,i){return this._events[r]||(this._events[r]=[]),this._events[r].push({callback:t,once:!!i}),this},e.prototype.once=function(r,t){return this.on(r,t,!0)},e.prototype.emit=function(r){for(var t=this,i=[],n=1;n<arguments.length;n++)i[n-1]=arguments[n];var a=this._events[r]||[],o=this._events[S9]||[],l=function(s){for(var u=s.length,c=0;c<u;c++)if(!!s[c]){var f=s[c],h=f.callback,v=f.once;v&&(s.splice(c,1),s.length===0&&delete t._events[r],u--,c--),h.apply(t,i)}};l(a),l(o)},e.prototype.off=function(r,t){if(!r)this._events={};else if(!t)delete this._events[r];else{for(var i=this._events[r]||[],n=i.length,a=0;a<n;a++)i[a].callback===t&&(i.splice(a,1),n--,a--);i.length===0&&delete this._events[r]}return this},e.prototype.getEvents=function(){return this._events},e}(),A9=Object.freeze(Object.defineProperty({__proto__:null,default:yp},Symbol.toStringTag,{value:"Module"}));function _z(e,r){var t=e.indexOf(r);t!==-1&&e.splice(t,1)}var R2=typeof window!="undefined"&&typeof window.document!="undefined";function bz(e,r){if(e.isCanvas())return!0;for(var t=r.getParent(),i=!1;t;){if(t===e){i=!0;break}t=t.getParent()}return i}function $f(e){return e.cfg.visible&&e.cfg.capture}var mp=function(e){X(r,e);function r(t){var i=e.call(this)||this;i.destroyed=!1;var n=i.getDefaultCfg();return i.cfg=Kt(n,t),i}return r.prototype.getDefaultCfg=function(){return{}},r.prototype.get=function(t){return this.cfg[t]},r.prototype.set=function(t,i){this.cfg[t]=i},r.prototype.destroy=function(){this.cfg={destroyed:!0},this.off(),this.destroyed=!0},r}(yp),B2=globalThis&&globalThis.__spreadArray||function(e,r,t){if(t||arguments.length===2)for(var i=0,n=r.length,a;i<n;i++)(a||!(i in r))&&(a||(a=Array.prototype.slice.call(r,0,i)),a[i]=r[i]);return e.concat(a||Array.prototype.slice.call(r))},wz=function(){function e(r,t,i){this.name=r,this.version=t,this.os=i,this.type="browser"}return e}(),Cz=function(){function e(r){this.version=r,this.type="node",this.name="node",this.os=process.platform}return e}(),Sz=function(){function e(r,t,i,n){this.name=r,this.version=t,this.os=i,this.bot=n,this.type="bot-device"}return e}(),Az=function(){function e(){this.type="bot",this.bot=!0,this.name="bot",this.version=null,this.os=null}return e}(),Tz=function(){function e(){this.type="react-native",this.name="react-native",this.version=null,this.os=null}return e}(),T9=/alexa|bot|crawl(er|ing)|facebookexternalhit|feedburner|google web preview|nagios|postrank|pingdom|slurp|spider|yahoo!|yandex/,M9=/(nuhk|curl|Googlebot|Yammybot|Openbot|Slurp|MSNBot|Ask\ Jeeves\/Teoma|ia_archiver)/,N2=3,E9=[["aol",/AOLShield\/([0-9\._]+)/],["edge",/Edge\/([0-9\._]+)/],["edge-ios",/EdgiOS\/([0-9\._]+)/],["yandexbrowser",/YaBrowser\/([0-9\._]+)/],["kakaotalk",/KAKAOTALK\s([0-9\.]+)/],["samsung",/SamsungBrowser\/([0-9\.]+)/],["silk",/\bSilk\/([0-9._-]+)\b/],["miui",/MiuiBrowser\/([0-9\.]+)$/],["beaker",/BeakerBrowser\/([0-9\.]+)/],["edge-chromium",/EdgA?\/([0-9\.]+)/],["chromium-webview",/(?!Chrom.*OPR)wv\).*Chrom(?:e|ium)\/([0-9\.]+)(:?\s|$)/],["chrome",/(?!Chrom.*OPR)Chrom(?:e|ium)\/([0-9\.]+)(:?\s|$)/],["phantomjs",/PhantomJS\/([0-9\.]+)(:?\s|$)/],["crios",/CriOS\/([0-9\.]+)(:?\s|$)/],["firefox",/Firefox\/([0-9\.]+)(?:\s|$)/],["fxios",/FxiOS\/([0-9\.]+)/],["opera-mini",/Opera Mini.*Version\/([0-9\.]+)/],["opera",/Opera\/([0-9\.]+)(?:\s|$)/],["opera",/OPR\/([0-9\.]+)(:?\s|$)/],["pie",/^Microsoft Pocket Internet Explorer\/(\d+\.\d+)$/],["pie",/^Mozilla\/\d\.\d+\s\(compatible;\s(?:MSP?IE|MSInternet Explorer) (\d+\.\d+);.*Windows CE.*\)$/],["netfront",/^Mozilla\/\d\.\d+.*NetFront\/(\d.\d)/],["ie",/Trident\/7\.0.*rv\:([0-9\.]+).*\).*Gecko$/],["ie",/MSIE\s([0-9\.]+);.*Trident\/[4-7].0/],["ie",/MSIE\s(7\.0)/],["bb10",/BB10;\sTouch.*Version\/([0-9\.]+)/],["android",/Android\s([0-9\.]+)/],["ios",/Version\/([0-9\._]+).*Mobile.*Safari.*/],["safari",/Version\/([0-9\._]+).*Safari/],["facebook",/FB[AS]V\/([0-9\.]+)/],["instagram",/Instagram\s([0-9\.]+)/],["ios-webview",/AppleWebKit\/([0-9\.]+).*Mobile/],["ios-webview",/AppleWebKit\/([0-9\.]+).*Gecko\)$/],["curl",/^curl\/([0-9\.]+)$/],["searchbot",T9]],G2=[["iOS",/iP(hone|od|ad)/],["Android OS",/Android/],["BlackBerry OS",/BlackBerry|BB10/],["Windows Mobile",/IEMobile/],["Amazon OS",/Kindle/],["Windows 3.11",/Win16/],["Windows 95",/(Windows 95)|(Win95)|(Windows_95)/],["Windows 98",/(Windows 98)|(Win98)/],["Windows 2000",/(Windows NT 5.0)|(Windows 2000)/],["Windows XP",/(Windows NT 5.1)|(Windows XP)/],["Windows Server 2003",/(Windows NT 5.2)/],["Windows Vista",/(Windows NT 6.0)/],["Windows 7",/(Windows NT 6.1)/],["Windows 8",/(Windows NT 6.2)/],["Windows 8.1",/(Windows NT 6.3)/],["Windows 10",/(Windows NT 10.0)/],["Windows ME",/Windows ME/],["Windows CE",/Windows CE|WinCE|Microsoft Pocket Internet Explorer/],["Open BSD",/OpenBSD/],["Sun OS",/SunOS/],["Chrome OS",/CrOS/],["Linux",/(Linux)|(X11)/],["Mac OS",/(Mac_PowerPC)|(Macintosh)/],["QNX",/QNX/],["BeOS",/BeOS/],["OS/2",/OS\/2/]];function gM(e){return e?pA(e):typeof document=="undefined"&&typeof navigator!="undefined"&&navigator.product==="ReactNative"?new Tz:typeof navigator!="undefined"?pA(navigator.userAgent):Fz()}function Mz(e){return e!==""&&E9.reduce(function(r,t){var i=t[0],n=t[1];if(r)return r;var a=n.exec(e);return!!a&&[i,a]},!1)}function F9(e){var r=Mz(e);return r?r[0]:null}function pA(e){var r=Mz(e);if(!r)return null;var t=r[0],i=r[1];if(t==="searchbot")return new Az;var n=i[1]&&i[1].split(".").join("_").split("_").slice(0,3);n?n.length<N2&&(n=B2(B2([],n,!0),O9(N2-n.length),!0)):n=[];var a=n.join("."),o=Ez(e),l=M9.exec(e);return l&&l[1]?new Sz(t,a,o,l[1]):new wz(t,a,o)}function Ez(e){for(var r=0,t=G2.length;r<t;r++){var i=G2[r],n=i[0],a=i[1],o=a.exec(e);if(o)return n}return null}function Fz(){var e=typeof process!="undefined"&&process.version;return e?new Cz(process.version.slice(1)):null}function O9(e){for(var r=[],t=0;t<e;t++)r.push("0");return r}var P9=Object.freeze(Object.defineProperty({__proto__:null,BrowserInfo:wz,NodeInfo:Cz,SearchBotDeviceInfo:Sz,BotInfo:Az,ReactNativeInfo:Tz,detect:gM,browserName:F9,parseUserAgent:pA,detectOS:Ez,getNodeVersion:Fz},Symbol.toStringTag,{value:"Module"})),Bi=1e-6,Un=typeof Float32Array!="undefined"?Float32Array:Array,gA=Math.random;Math.hypot||(Math.hypot=function(){for(var e=0,r=arguments.length;r--;)e+=arguments[r]*arguments[r];return Math.sqrt(e)});function I9(){var e=new Un(9);return Un!=Float32Array&&(e[1]=0,e[2]=0,e[3]=0,e[5]=0,e[6]=0,e[7]=0),e[0]=1,e[4]=1,e[8]=1,e}function L9(e,r){return e[0]=r[0],e[1]=r[1],e[2]=r[2],e[3]=r[4],e[4]=r[5],e[5]=r[6],e[6]=r[8],e[7]=r[9],e[8]=r[10],e}function D9(e){var r=new Un(9);return r[0]=e[0],r[1]=e[1],r[2]=e[2],r[3]=e[3],r[4]=e[4],r[5]=e[5],r[6]=e[6],r[7]=e[7],r[8]=e[8],r}function $9(e,r){return e[0]=r[0],e[1]=r[1],e[2]=r[2],e[3]=r[3],e[4]=r[4],e[5]=r[5],e[6]=r[6],e[7]=r[7],e[8]=r[8],e}function k9(e,r,t,i,n,a,o,l,s){var u=new Un(9);return u[0]=e,u[1]=r,u[2]=t,u[3]=i,u[4]=n,u[5]=a,u[6]=o,u[7]=l,u[8]=s,u}function R9(e,r,t,i,n,a,o,l,s,u){return e[0]=r,e[1]=t,e[2]=i,e[3]=n,e[4]=a,e[5]=o,e[6]=l,e[7]=s,e[8]=u,e}function B9(e){return e[0]=1,e[1]=0,e[2]=0,e[3]=0,e[4]=1,e[5]=0,e[6]=0,e[7]=0,e[8]=1,e}function N9(e,r){if(e===r){var t=r[1],i=r[2],n=r[5];e[1]=r[3],e[2]=r[6],e[3]=t,e[5]=r[7],e[6]=i,e[7]=n}else e[0]=r[0],e[1]=r[3],e[2]=r[6],e[3]=r[1],e[4]=r[4],e[5]=r[7],e[6]=r[2],e[7]=r[5],e[8]=r[8];return e}function Oz(e,r){var t=r[0],i=r[1],n=r[2],a=r[3],o=r[4],l=r[5],s=r[6],u=r[7],c=r[8],f=c*o-l*u,h=-c*a+l*s,v=u*a-o*s,d=t*f+i*h+n*v;return d?(d=1/d,e[0]=f*d,e[1]=(-c*i+n*u)*d,e[2]=(l*i-n*o)*d,e[3]=h*d,e[4]=(c*t-n*s)*d,e[5]=(-l*t+n*a)*d,e[6]=v*d,e[7]=(-u*t+i*s)*d,e[8]=(o*t-i*a)*d,e):null}function G9(e,r){var t=r[0],i=r[1],n=r[2],a=r[3],o=r[4],l=r[5],s=r[6],u=r[7],c=r[8];return e[0]=o*c-l*u,e[1]=n*u-i*c,e[2]=i*l-n*o,e[3]=l*s-a*c,e[4]=t*c-n*s,e[5]=n*a-t*l,e[6]=a*u-o*s,e[7]=i*s-t*u,e[8]=t*o-i*a,e}function z9(e){var r=e[0],t=e[1],i=e[2],n=e[3],a=e[4],o=e[5],l=e[6],s=e[7],u=e[8];return r*(u*a-o*s)+t*(-u*n+o*l)+i*(s*n-a*l)}function wh(e,r,t){var i=r[0],n=r[1],a=r[2],o=r[3],l=r[4],s=r[5],u=r[6],c=r[7],f=r[8],h=t[0],v=t[1],d=t[2],p=t[3],x=t[4],m=t[5],_=t[6],b=t[7],w=t[8];return e[0]=h*i+v*o+d*u,e[1]=h*n+v*l+d*c,e[2]=h*a+v*s+d*f,e[3]=p*i+x*o+m*u,e[4]=p*n+x*l+m*c,e[5]=p*a+x*s+m*f,e[6]=_*i+b*o+w*u,e[7]=_*n+b*l+w*c,e[8]=_*a+b*s+w*f,e}function V9(e,r,t){var i=r[0],n=r[1],a=r[2],o=r[3],l=r[4],s=r[5],u=r[6],c=r[7],f=r[8],h=t[0],v=t[1];return e[0]=i,e[1]=n,e[2]=a,e[3]=o,e[4]=l,e[5]=s,e[6]=h*i+v*o+u,e[7]=h*n+v*l+c,e[8]=h*a+v*s+f,e}function j9(e,r,t){var i=r[0],n=r[1],a=r[2],o=r[3],l=r[4],s=r[5],u=r[6],c=r[7],f=r[8],h=Math.sin(t),v=Math.cos(t);return e[0]=v*i+h*o,e[1]=v*n+h*l,e[2]=v*a+h*s,e[3]=v*o-h*i,e[4]=v*l-h*n,e[5]=v*s-h*a,e[6]=u,e[7]=c,e[8]=f,e}function H9(e,r,t){var i=t[0],n=t[1];return e[0]=i*r[0],e[1]=i*r[1],e[2]=i*r[2],e[3]=n*r[3],e[4]=n*r[4],e[5]=n*r[5],e[6]=r[6],e[7]=r[7],e[8]=r[8],e}function Pz(e,r){return e[0]=1,e[1]=0,e[2]=0,e[3]=0,e[4]=1,e[5]=0,e[6]=r[0],e[7]=r[1],e[8]=1,e}function Iz(e,r){var t=Math.sin(r),i=Math.cos(r);return e[0]=i,e[1]=t,e[2]=0,e[3]=-t,e[4]=i,e[5]=0,e[6]=0,e[7]=0,e[8]=1,e}function Lz(e,r){return e[0]=r[0],e[1]=0,e[2]=0,e[3]=0,e[4]=r[1],e[5]=0,e[6]=0,e[7]=0,e[8]=1,e}function Y9(e,r){return e[0]=r[0],e[1]=r[1],e[2]=0,e[3]=r[2],e[4]=r[3],e[5]=0,e[6]=r[4],e[7]=r[5],e[8]=1,e}function W9(e,r){var t=r[0],i=r[1],n=r[2],a=r[3],o=t+t,l=i+i,s=n+n,u=t*o,c=i*o,f=i*l,h=n*o,v=n*l,d=n*s,p=a*o,x=a*l,m=a*s;return e[0]=1-f-d,e[3]=c-m,e[6]=h+x,e[1]=c+m,e[4]=1-u-d,e[7]=v-p,e[2]=h-x,e[5]=v+p,e[8]=1-u-f,e}function X9(e,r){var t=r[0],i=r[1],n=r[2],a=r[3],o=r[4],l=r[5],s=r[6],u=r[7],c=r[8],f=r[9],h=r[10],v=r[11],d=r[12],p=r[13],x=r[14],m=r[15],_=t*l-i*o,b=t*s-n*o,w=t*u-a*o,S=i*s-n*l,M=i*u-a*l,F=n*u-a*s,O=c*p-f*d,L=c*x-h*d,D=c*m-v*d,k=f*x-h*p,H=f*m-v*p,B=h*m-v*x,j=_*B-b*H+w*k+S*D-M*L+F*O;return j?(j=1/j,e[0]=(l*B-s*H+u*k)*j,e[1]=(s*D-o*B-u*L)*j,e[2]=(o*H-l*D+u*O)*j,e[3]=(n*H-i*B-a*k)*j,e[4]=(t*B-n*D+a*L)*j,e[5]=(i*D-t*H-a*O)*j,e[6]=(p*F-x*M+m*S)*j,e[7]=(x*w-d*F-m*b)*j,e[8]=(d*M-p*w+m*_)*j,e):null}function U9(e,r,t){return e[0]=2/r,e[1]=0,e[2]=0,e[3]=0,e[4]=-2/t,e[5]=0,e[6]=-1,e[7]=1,e[8]=1,e}function q9(e){return"mat3("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+", "+e[4]+", "+e[5]+", "+e[6]+", "+e[7]+", "+e[8]+")"}function Z9(e){return Math.hypot(e[0],e[1],e[2],e[3],e[4],e[5],e[6],e[7],e[8])}function Q9(e,r,t){return e[0]=r[0]+t[0],e[1]=r[1]+t[1],e[2]=r[2]+t[2],e[3]=r[3]+t[3],e[4]=r[4]+t[4],e[5]=r[5]+t[5],e[6]=r[6]+t[6],e[7]=r[7]+t[7],e[8]=r[8]+t[8],e}function Dz(e,r,t){return e[0]=r[0]-t[0],e[1]=r[1]-t[1],e[2]=r[2]-t[2],e[3]=r[3]-t[3],e[4]=r[4]-t[4],e[5]=r[5]-t[5],e[6]=r[6]-t[6],e[7]=r[7]-t[7],e[8]=r[8]-t[8],e}function K9(e,r,t){return e[0]=r[0]*t,e[1]=r[1]*t,e[2]=r[2]*t,e[3]=r[3]*t,e[4]=r[4]*t,e[5]=r[5]*t,e[6]=r[6]*t,e[7]=r[7]*t,e[8]=r[8]*t,e}function J9(e,r,t,i){return e[0]=r[0]+t[0]*i,e[1]=r[1]+t[1]*i,e[2]=r[2]+t[2]*i,e[3]=r[3]+t[3]*i,e[4]=r[4]+t[4]*i,e[5]=r[5]+t[5]*i,e[6]=r[6]+t[6]*i,e[7]=r[7]+t[7]*i,e[8]=r[8]+t[8]*i,e}function t7(e,r){return e[0]===r[0]&&e[1]===r[1]&&e[2]===r[2]&&e[3]===r[3]&&e[4]===r[4]&&e[5]===r[5]&&e[6]===r[6]&&e[7]===r[7]&&e[8]===r[8]}function e7(e,r){var t=e[0],i=e[1],n=e[2],a=e[3],o=e[4],l=e[5],s=e[6],u=e[7],c=e[8],f=r[0],h=r[1],v=r[2],d=r[3],p=r[4],x=r[5],m=r[6],_=r[7],b=r[8];return Math.abs(t-f)<=Bi*Math.max(1,Math.abs(t),Math.abs(f))&&Math.abs(i-h)<=Bi*Math.max(1,Math.abs(i),Math.abs(h))&&Math.abs(n-v)<=Bi*Math.max(1,Math.abs(n),Math.abs(v))&&Math.abs(a-d)<=Bi*Math.max(1,Math.abs(a),Math.abs(d))&&Math.abs(o-p)<=Bi*Math.max(1,Math.abs(o),Math.abs(p))&&Math.abs(l-x)<=Bi*Math.max(1,Math.abs(l),Math.abs(x))&&Math.abs(s-m)<=Bi*Math.max(1,Math.abs(s),Math.abs(m))&&Math.abs(u-_)<=Bi*Math.max(1,Math.abs(u),Math.abs(_))&&Math.abs(c-b)<=Bi*Math.max(1,Math.abs(c),Math.abs(b))}var r7=wh,i7=Dz,n7=Object.freeze(Object.defineProperty({__proto__:null,create:I9,fromMat4:L9,clone:D9,copy:$9,fromValues:k9,set:R9,identity:B9,transpose:N9,invert:Oz,adjoint:G9,determinant:z9,multiply:wh,translate:V9,rotate:j9,scale:H9,fromTranslation:Pz,fromRotation:Iz,fromScaling:Lz,fromMat2d:Y9,fromQuat:W9,normalFromMat4:X9,projection:U9,str:q9,frob:Z9,add:Q9,subtract:Dz,multiplyScalar:K9,multiplyScalarAndAdd:J9,exactEquals:t7,equals:e7,mul:r7,sub:i7},Symbol.toStringTag,{value:"Module"}));function $z(){var e=new Un(3);return Un!=Float32Array&&(e[0]=0,e[1]=0,e[2]=0),e}function a7(e){var r=new Un(3);return r[0]=e[0],r[1]=e[1],r[2]=e[2],r}function kz(e){var r=e[0],t=e[1],i=e[2];return Math.hypot(r,t,i)}function o7(e,r,t){var i=new Un(3);return i[0]=e,i[1]=r,i[2]=t,i}function l7(e,r){return e[0]=r[0],e[1]=r[1],e[2]=r[2],e}function s7(e,r,t,i){return e[0]=r,e[1]=t,e[2]=i,e}function u7(e,r,t){return e[0]=r[0]+t[0],e[1]=r[1]+t[1],e[2]=r[2]+t[2],e}function Rz(e,r,t){return e[0]=r[0]-t[0],e[1]=r[1]-t[1],e[2]=r[2]-t[2],e}function Bz(e,r,t){return e[0]=r[0]*t[0],e[1]=r[1]*t[1],e[2]=r[2]*t[2],e}function Nz(e,r,t){return e[0]=r[0]/t[0],e[1]=r[1]/t[1],e[2]=r[2]/t[2],e}function c7(e,r){return e[0]=Math.ceil(r[0]),e[1]=Math.ceil(r[1]),e[2]=Math.ceil(r[2]),e}function f7(e,r){return e[0]=Math.floor(r[0]),e[1]=Math.floor(r[1]),e[2]=Math.floor(r[2]),e}function h7(e,r,t){return e[0]=Math.min(r[0],t[0]),e[1]=Math.min(r[1],t[1]),e[2]=Math.min(r[2],t[2]),e}function v7(e,r,t){return e[0]=Math.max(r[0],t[0]),e[1]=Math.max(r[1],t[1]),e[2]=Math.max(r[2],t[2]),e}function d7(e,r){return e[0]=Math.round(r[0]),e[1]=Math.round(r[1]),e[2]=Math.round(r[2]),e}function p7(e,r,t){return e[0]=r[0]*t,e[1]=r[1]*t,e[2]=r[2]*t,e}function g7(e,r,t,i){return e[0]=r[0]+t[0]*i,e[1]=r[1]+t[1]*i,e[2]=r[2]+t[2]*i,e}function Gz(e,r){var t=r[0]-e[0],i=r[1]-e[1],n=r[2]-e[2];return Math.hypot(t,i,n)}function zz(e,r){var t=r[0]-e[0],i=r[1]-e[1],n=r[2]-e[2];return t*t+i*i+n*n}function Vz(e){var r=e[0],t=e[1],i=e[2];return r*r+t*t+i*i}function y7(e,r){return e[0]=-r[0],e[1]=-r[1],e[2]=-r[2],e}function m7(e,r){return e[0]=1/r[0],e[1]=1/r[1],e[2]=1/r[2],e}function x7(e,r){var t=r[0],i=r[1],n=r[2],a=t*t+i*i+n*n;return a>0&&(a=1/Math.sqrt(a)),e[0]=r[0]*a,e[1]=r[1]*a,e[2]=r[2]*a,e}function jz(e,r){return e[0]*r[0]+e[1]*r[1]+e[2]*r[2]}function _7(e,r,t){var i=r[0],n=r[1],a=r[2],o=t[0],l=t[1],s=t[2];return e[0]=n*s-a*l,e[1]=a*o-i*s,e[2]=i*l-n*o,e}function b7(e,r,t,i){var n=r[0],a=r[1],o=r[2];return e[0]=n+i*(t[0]-n),e[1]=a+i*(t[1]-a),e[2]=o+i*(t[2]-o),e}function w7(e,r,t,i,n,a){var o=a*a,l=o*(2*a-3)+1,s=o*(a-2)+a,u=o*(a-1),c=o*(3-2*a);return e[0]=r[0]*l+t[0]*s+i[0]*u+n[0]*c,e[1]=r[1]*l+t[1]*s+i[1]*u+n[1]*c,e[2]=r[2]*l+t[2]*s+i[2]*u+n[2]*c,e}function C7(e,r,t,i,n,a){var o=1-a,l=o*o,s=a*a,u=l*o,c=3*a*l,f=3*s*o,h=s*a;return e[0]=r[0]*u+t[0]*c+i[0]*f+n[0]*h,e[1]=r[1]*u+t[1]*c+i[1]*f+n[1]*h,e[2]=r[2]*u+t[2]*c+i[2]*f+n[2]*h,e}function S7(e,r){r=r||1;var t=gA()*2*Math.PI,i=gA()*2-1,n=Math.sqrt(1-i*i)*r;return e[0]=Math.cos(t)*n,e[1]=Math.sin(t)*n,e[2]=i*r,e}function A7(e,r,t){var i=r[0],n=r[1],a=r[2],o=t[3]*i+t[7]*n+t[11]*a+t[15];return o=o||1,e[0]=(t[0]*i+t[4]*n+t[8]*a+t[12])/o,e[1]=(t[1]*i+t[5]*n+t[9]*a+t[13])/o,e[2]=(t[2]*i+t[6]*n+t[10]*a+t[14])/o,e}function kf(e,r,t){var i=r[0],n=r[1],a=r[2];return e[0]=i*t[0]+n*t[3]+a*t[6],e[1]=i*t[1]+n*t[4]+a*t[7],e[2]=i*t[2]+n*t[5]+a*t[8],e}function T7(e,r,t){var i=t[0],n=t[1],a=t[2],o=t[3],l=r[0],s=r[1],u=r[2],c=n*u-a*s,f=a*l-i*u,h=i*s-n*l,v=n*h-a*f,d=a*c-i*h,p=i*f-n*c,x=o*2;return c*=x,f*=x,h*=x,v*=2,d*=2,p*=2,e[0]=l+c+v,e[1]=s+f+d,e[2]=u+h+p,e}function M7(e,r,t,i){var n=[],a=[];return n[0]=r[0]-t[0],n[1]=r[1]-t[1],n[2]=r[2]-t[2],a[0]=n[0],a[1]=n[1]*Math.cos(i)-n[2]*Math.sin(i),a[2]=n[1]*Math.sin(i)+n[2]*Math.cos(i),e[0]=a[0]+t[0],e[1]=a[1]+t[1],e[2]=a[2]+t[2],e}function E7(e,r,t,i){var n=[],a=[];return n[0]=r[0]-t[0],n[1]=r[1]-t[1],n[2]=r[2]-t[2],a[0]=n[2]*Math.sin(i)+n[0]*Math.cos(i),a[1]=n[1],a[2]=n[2]*Math.cos(i)-n[0]*Math.sin(i),e[0]=a[0]+t[0],e[1]=a[1]+t[1],e[2]=a[2]+t[2],e}function F7(e,r,t,i){var n=[],a=[];return n[0]=r[0]-t[0],n[1]=r[1]-t[1],n[2]=r[2]-t[2],a[0]=n[0]*Math.cos(i)-n[1]*Math.sin(i),a[1]=n[0]*Math.sin(i)+n[1]*Math.cos(i),a[2]=n[2],e[0]=a[0]+t[0],e[1]=a[1]+t[1],e[2]=a[2]+t[2],e}function O7(e,r){var t=e[0],i=e[1],n=e[2],a=r[0],o=r[1],l=r[2],s=Math.sqrt(t*t+i*i+n*n),u=Math.sqrt(a*a+o*o+l*l),c=s*u,f=c&&jz(e,r)/c;return Math.acos(Math.min(Math.max(f,-1),1))}function P7(e){return e[0]=0,e[1]=0,e[2]=0,e}function I7(e){return"vec3("+e[0]+", "+e[1]+", "+e[2]+")"}function L7(e,r){return e[0]===r[0]&&e[1]===r[1]&&e[2]===r[2]}function D7(e,r){var t=e[0],i=e[1],n=e[2],a=r[0],o=r[1],l=r[2];return Math.abs(t-a)<=Bi*Math.max(1,Math.abs(t),Math.abs(a))&&Math.abs(i-o)<=Bi*Math.max(1,Math.abs(i),Math.abs(o))&&Math.abs(n-l)<=Bi*Math.max(1,Math.abs(n),Math.abs(l))}var $7=Rz,k7=Bz,R7=Nz,B7=Gz,N7=zz,G7=kz,z7=Vz,V7=function(){var e=$z();return function(r,t,i,n,a,o){var l,s;for(t||(t=3),i||(i=0),n?s=Math.min(n*t+i,r.length):s=r.length,l=i;l<s;l+=t)e[0]=r[l],e[1]=r[l+1],e[2]=r[l+2],a(e,e,o),r[l]=e[0],r[l+1]=e[1],r[l+2]=e[2];return r}}(),Hz=Object.freeze(Object.defineProperty({__proto__:null,create:$z,clone:a7,length:kz,fromValues:o7,copy:l7,set:s7,add:u7,subtract:Rz,multiply:Bz,divide:Nz,ceil:c7,floor:f7,min:h7,max:v7,round:d7,scale:p7,scaleAndAdd:g7,distance:Gz,squaredDistance:zz,squaredLength:Vz,negate:y7,inverse:m7,normalize:x7,dot:jz,cross:_7,lerp:b7,hermite:w7,bezier:C7,random:S7,transformMat4:A7,transformMat3:kf,transformQuat:T7,rotateX:M7,rotateY:E7,rotateZ:F7,angle:O7,zero:P7,str:I7,exactEquals:L7,equals:D7,sub:$7,mul:k7,div:R7,dist:B7,sqrDist:N7,len:G7,sqrLen:z7,forEach:V7},Symbol.toStringTag,{value:"Module"}));function Yz(){var e=new Un(2);return Un!=Float32Array&&(e[0]=0,e[1]=0),e}function j7(e){var r=new Un(2);return r[0]=e[0],r[1]=e[1],r}function H7(e,r){var t=new Un(2);return t[0]=e,t[1]=r,t}function Y7(e,r){return e[0]=r[0],e[1]=r[1],e}function W7(e,r,t){return e[0]=r,e[1]=t,e}function ma(e,r,t){return e[0]=r[0]+t[0],e[1]=r[1]+t[1],e}function yM(e,r,t){return e[0]=r[0]-t[0],e[1]=r[1]-t[1],e}function Wz(e,r,t){return e[0]=r[0]*t[0],e[1]=r[1]*t[1],e}function Xz(e,r,t){return e[0]=r[0]/t[0],e[1]=r[1]/t[1],e}function X7(e,r){return e[0]=Math.ceil(r[0]),e[1]=Math.ceil(r[1]),e}function U7(e,r){return e[0]=Math.floor(r[0]),e[1]=Math.floor(r[1]),e}function Cr(e,r,t){return e[0]=Math.min(r[0],t[0]),e[1]=Math.min(r[1],t[1]),e}function Sr(e,r,t){return e[0]=Math.max(r[0],t[0]),e[1]=Math.max(r[1],t[1]),e}function q7(e,r){return e[0]=Math.round(r[0]),e[1]=Math.round(r[1]),e}function pi(e,r,t){return e[0]=r[0]*t,e[1]=r[1]*t,e}function Z7(e,r,t,i){return e[0]=r[0]+t[0]*i,e[1]=r[1]+t[1]*i,e}function cs(e,r){var t=r[0]-e[0],i=r[1]-e[1];return Math.hypot(t,i)}function Uz(e,r){var t=r[0]-e[0],i=r[1]-e[1];return t*t+i*i}function Wl(e){var r=e[0],t=e[1];return Math.hypot(r,t)}function qz(e){var r=e[0],t=e[1];return r*r+t*t}function Q7(e,r){return e[0]=-r[0],e[1]=-r[1],e}function K7(e,r){return e[0]=1/r[0],e[1]=1/r[1],e}function mM(e,r){var t=r[0],i=r[1],n=t*t+i*i;return n>0&&(n=1/Math.sqrt(n)),e[0]=r[0]*n,e[1]=r[1]*n,e}function xM(e,r){return e[0]*r[0]+e[1]*r[1]}function J7(e,r,t){var i=r[0]*t[1]-r[1]*t[0];return e[0]=e[1]=0,e[2]=i,e}function tq(e,r,t,i){var n=r[0],a=r[1];return e[0]=n+i*(t[0]-n),e[1]=a+i*(t[1]-a),e}function eq(e,r){r=r||1;var t=gA()*2*Math.PI;return e[0]=Math.cos(t)*r,e[1]=Math.sin(t)*r,e}function rq(e,r,t){var i=r[0],n=r[1];return e[0]=t[0]*i+t[2]*n,e[1]=t[1]*i+t[3]*n,e}function iq(e,r,t){var i=r[0],n=r[1];return e[0]=t[0]*i+t[2]*n+t[4],e[1]=t[1]*i+t[3]*n+t[5],e}function Zz(e,r,t){var i=r[0],n=r[1];return e[0]=t[0]*i+t[3]*n+t[6],e[1]=t[1]*i+t[4]*n+t[7],e}function nq(e,r,t){var i=r[0],n=r[1];return e[0]=t[0]*i+t[4]*n+t[12],e[1]=t[1]*i+t[5]*n+t[13],e}function aq(e,r,t,i){var n=r[0]-t[0],a=r[1]-t[1],o=Math.sin(i),l=Math.cos(i);return e[0]=n*l-a*o+t[0],e[1]=n*o+a*l+t[1],e}function V0(e,r){var t=e[0],i=e[1],n=r[0],a=r[1],o=Math.sqrt(t*t+i*i)*Math.sqrt(n*n+a*a),l=o&&(t*n+i*a)/o;return Math.acos(Math.min(Math.max(l,-1),1))}function oq(e){return e[0]=0,e[1]=0,e}function lq(e){return"vec2("+e[0]+", "+e[1]+")"}function Qz(e,r){return e[0]===r[0]&&e[1]===r[1]}function sq(e,r){var t=e[0],i=e[1],n=r[0],a=r[1];return Math.abs(t-n)<=Bi*Math.max(1,Math.abs(t),Math.abs(n))&&Math.abs(i-a)<=Bi*Math.max(1,Math.abs(i),Math.abs(a))}var uq=Wl,Kl=yM,cq=Wz,fq=Xz,hq=cs,vq=Uz,dq=qz,pq=function(){var e=Yz();return function(r,t,i,n,a,o){var l,s;for(t||(t=2),i||(i=0),n?s=Math.min(n*t+i,r.length):s=r.length,l=i;l<s;l+=t)e[0]=r[l],e[1]=r[l+1],a(e,e,o),r[l]=e[0],r[l+1]=e[1];return r}}(),gq=Object.freeze(Object.defineProperty({__proto__:null,create:Yz,clone:j7,fromValues:H7,copy:Y7,set:W7,add:ma,subtract:yM,multiply:Wz,divide:Xz,ceil:X7,floor:U7,min:Cr,max:Sr,round:q7,scale:pi,scaleAndAdd:Z7,distance:cs,squaredDistance:Uz,length:Wl,squaredLength:qz,negate:Q7,inverse:K7,normalize:mM,dot:xM,cross:J7,lerp:tq,random:eq,transformMat2:rq,transformMat2d:iq,transformMat3:Zz,transformMat4:nq,rotate:aq,angle:V0,zero:oq,str:lq,exactEquals:Qz,equals:sq,len:uq,sub:Kl,mul:cq,div:fq,dist:hq,sqrDist:vq,sqrLen:dq,forEach:pq},Symbol.toStringTag,{value:"Module"}));function xu(e,r,t){var i=[0,0,0,0,0,0,0,0,0];return Pz(i,t),wh(e,i,r)}function o1(e,r,t){var i=[0,0,0,0,0,0,0,0,0];return Iz(i,t),wh(e,i,r)}function _M(e,r,t){var i=[0,0,0,0,0,0,0,0,0];return Lz(i,t),wh(e,i,r)}function yq(e,r,t){return wh(e,t,r)}function rr(e,r){for(var t=e?[].concat(e):[1,0,0,0,1,0,0,0,1],i=0,n=r.length;i<n;i++){var a=r[i];switch(a[0]){case"t":xu(t,t,[a[1],a[2]]);break;case"s":_M(t,t,[a[1],a[2]]);break;case"r":o1(t,t,a[1]);break;case"m":yq(t,t,a[1]);break}}return t}function Kz(e,r){return e[0]*r[1]-r[0]*e[1]}function l1(e,r,t){var i=V0(e,r),n=Kz(e,r)>=0;return t?n?Math.PI*2-i:i:n?i:Math.PI*2-i}function mq(e,r,t){return t?(e[0]=r[1],e[1]=-1*r[0]):(e[0]=-1*r[1],e[1]=r[0]),e}var xq=Object.freeze(Object.defineProperty({__proto__:null,leftTranslate:xu,leftRotate:o1,leftScale:_M,transform:rr,direction:Kz,angleTo:l1,vertical:mq},Symbol.toStringTag,{value:"Module"})),_q=Object.freeze(Object.defineProperty({__proto__:null,mat3:n7,vec2:gq,vec3:Hz,ext:xq},Symbol.toStringTag,{value:"Module"}));function z2(e,r){var t=[],i=e[0],n=e[1],a=e[2],o=e[3],l=e[4],s=e[5],u=e[6],c=e[7],f=e[8],h=r[0],v=r[1],d=r[2],p=r[3],x=r[4],m=r[5],_=r[6],b=r[7],w=r[8];return t[0]=h*i+v*o+d*u,t[1]=h*n+v*l+d*c,t[2]=h*a+v*s+d*f,t[3]=p*i+x*o+m*u,t[4]=p*n+x*l+m*c,t[5]=p*a+x*s+m*f,t[6]=_*i+b*o+w*u,t[7]=_*n+b*l+w*c,t[8]=_*a+b*s+w*f,t}function ro(e,r){var t=[],i=r[0],n=r[1];return t[0]=e[0]*i+e[3]*n+e[6],t[1]=e[1]*i+e[4]*n+e[7],t}function xp(e){var r=[],t=e[0],i=e[1],n=e[2],a=e[3],o=e[4],l=e[5],s=e[6],u=e[7],c=e[8],f=c*o-l*u,h=-c*a+l*s,v=u*a-o*s,d=t*f+i*h+n*v;return d?(d=1/d,r[0]=f*d,r[1]=(-c*i+n*u)*d,r[2]=(l*i-n*o)*d,r[3]=h*d,r[4]=(c*t-n*s)*d,r[5]=(-l*t+n*a)*d,r[6]=v*d,r[7]=(-u*t+i*s)*d,r[8]=(o*t-i*a)*d,r):null}var cv=rr,Rw="matrix",bq=["zIndex","capture","visible","type"],wq=["repeat"],Cq=":",Sq="*";function Aq(e){for(var r=[],t=0;t<e.length;t++)it(e[t])?r.push([].concat(e[t])):r.push(e[t]);return r}function Tq(e,r){var t={},i=r.attrs;for(var n in e)t[n]=i[n];return t}function Mq(e,r){var t={},i=r.attr();return P(e,function(n,a){wq.indexOf(a)===-1&&!Ge(i[a],n)&&(t[a]=n)}),t}function Eq(e,r){if(r.onFrame)return e;var t=r.startTime,i=r.delay,n=r.duration,a=Object.prototype.hasOwnProperty;return P(e,function(o){t+i<o.startTime+o.delay+o.duration&&n>o.delay&&P(r.toAttrs,function(l,s){a.call(o.toAttrs,s)&&(delete o.toAttrs[s],delete o.fromAttrs[s])})}),e}var Jz=function(e){X(r,e);function r(t){var i=e.call(this,t)||this;i.attrs={};var n=i.getDefaultAttrs();return Kt(n,t.attrs),i.attrs=n,i.initAttrs(n),i.initAnimate(),i}return r.prototype.getDefaultCfg=function(){return{visible:!0,capture:!0,zIndex:0}},r.prototype.getDefaultAttrs=function(){return{matrix:this.getDefaultMatrix(),opacity:1}},r.prototype.onCanvasChange=function(t){},r.prototype.initAttrs=function(t){},r.prototype.initAnimate=function(){this.set("animable",!0),this.set("animating",!1)},r.prototype.isGroup=function(){return!1},r.prototype.getParent=function(){return this.get("parent")},r.prototype.getCanvas=function(){return this.get("canvas")},r.prototype.attr=function(){for(var t,i=[],n=0;n<arguments.length;n++)i[n]=arguments[n];var a=i[0],o=i[1];if(!a)return this.attrs;if(Zt(a)){for(var l in a)this.setAttr(l,a[l]);return this.afterAttrsChange(a),this}return i.length===2?(this.setAttr(a,o),this.afterAttrsChange((t={},t[a]=o,t)),this):this.attrs[a]},r.prototype.isClipped=function(t,i){var n=this.getClip();return n&&!n.isHit(t,i)},r.prototype.setAttr=function(t,i){var n=this.attrs[t];n!==i&&(this.attrs[t]=i,this.onAttrChange(t,i,n))},r.prototype.onAttrChange=function(t,i,n){t==="matrix"&&this.set("totalMatrix",null)},r.prototype.afterAttrsChange=function(t){if(this.cfg.isClipShape){var i=this.cfg.applyTo;i&&i.onCanvasChange("clip")}else this.onCanvasChange("attr")},r.prototype.show=function(){return this.set("visible",!0),this.onCanvasChange("show"),this},r.prototype.hide=function(){return this.set("visible",!1),this.onCanvasChange("hide"),this},r.prototype.setZIndex=function(t){this.set("zIndex",t);var i=this.getParent();return i&&i.sort(),this},r.prototype.toFront=function(){var t=this.getParent();if(!!t){var i=t.getChildren();this.get("el");var n=i.indexOf(this);i.splice(n,1),i.push(this),this.onCanvasChange("zIndex")}},r.prototype.toBack=function(){var t=this.getParent();if(!!t){var i=t.getChildren();this.get("el");var n=i.indexOf(this);i.splice(n,1),i.unshift(this),this.onCanvasChange("zIndex")}},r.prototype.remove=function(t){t===void 0&&(t=!0);var i=this.getParent();i?(_z(i.getChildren(),this),i.get("clearing")||this.onCanvasChange("remove")):this.onCanvasChange("remove"),t&&this.destroy()},r.prototype.resetMatrix=function(){this.attr(Rw,this.getDefaultMatrix()),this.onCanvasChange("matrix")},r.prototype.getMatrix=function(){return this.attr(Rw)},r.prototype.setMatrix=function(t){this.attr(Rw,t),this.onCanvasChange("matrix")},r.prototype.getTotalMatrix=function(){var t=this.cfg.totalMatrix;if(!t){var i=this.attr("matrix"),n=this.cfg.parentMatrix;n&&i?t=z2(n,i):t=i||n,this.set("totalMatrix",t)}return t},r.prototype.applyMatrix=function(t){var i=this.attr("matrix"),n=null;t&&i?n=z2(t,i):n=i||t,this.set("totalMatrix",n),this.set("parentMatrix",t)},r.prototype.getDefaultMatrix=function(){return null},r.prototype.applyToMatrix=function(t){var i=this.attr("matrix");return i?ro(i,t):t},r.prototype.invertFromMatrix=function(t){var i=this.attr("matrix");if(i){var n=xp(i);if(n)return ro(n,t)}return t},r.prototype.setClip=function(t){var i=this.getCanvas(),n=null;if(t){var a=this.getShapeBase(),o=Os(t.type),l=a[o];l&&(n=new l({type:t.type,isClipShape:!0,applyTo:this,attrs:t.attrs,canvas:i}))}return this.set("clipShape",n),this.onCanvasChange("clip"),n},r.prototype.getClip=function(){var t=this.cfg.clipShape;return t||null},r.prototype.clone=function(){var t=this,i=this.attrs,n={};P(i,function(l,s){it(i[s])?n[s]=Aq(i[s]):n[s]=i[s]});var a=this.constructor,o=new a({attrs:n});return P(bq,function(l){o.set(l,t.get(l))}),o},r.prototype.destroy=function(){var t=this.destroyed;t||(this.attrs={},e.prototype.destroy.call(this))},r.prototype.isAnimatePaused=function(){return this.get("_pause").isPaused},r.prototype.animate=function(){for(var t=[],i=0;i<arguments.length;i++)t[i]=arguments[i];if(!(!this.get("timeline")&&!this.get("canvas"))){this.set("animating",!0);var n=this.get("timeline");n||(n=this.get("canvas").get("timeline"),this.set("timeline",n));var a=this.get("animations")||[];n.timer||n.initTimer();var o=t[0],l=t[1],s=t[2],u=s===void 0?"easeLinear":s,c=t[3],f=c===void 0?Wo:c,h=t[4],v=h===void 0?0:h,d,p,x,m,_;pt(o)?(d=o,o={}):Zt(o)&&o.onFrame&&(d=o.onFrame,p=o.repeat),Zt(l)?(_=l,l=_.duration,u=_.easing||"easeLinear",v=_.delay||0,p=_.repeat||p||!1,f=_.callback||Wo,x=_.pauseCallback||Wo,m=_.resumeCallback||Wo):(Mt(f)&&(v=f,f=null),pt(u)?(f=u,u="easeLinear"):u=u||"easeLinear");var b=Mq(o,this),w={fromAttrs:Tq(b,this),toAttrs:b,duration:l,easing:u,repeat:p,callback:f,pauseCallback:x,resumeCallback:m,delay:v,startTime:n.getTime(),id:Oa(),onFrame:d,pathFormatted:!1};a.length>0?a=Eq(a,w):n.addAnimator(this),a.push(w),this.set("animations",a),this.set("_pause",{isPaused:!1})}},r.prototype.stopAnimate=function(t){var i=this;t===void 0&&(t=!0);var n=this.get("animations");P(n,function(a){t&&(a.onFrame?i.attr(a.onFrame(1)):i.attr(a.toAttrs)),a.callback&&a.callback()}),this.set("animating",!1),this.set("animations",[])},r.prototype.pauseAnimate=function(){var t=this.get("timeline"),i=this.get("animations"),n=t.getTime();return P(i,function(a){a._paused=!0,a._pauseTime=n,a.pauseCallback&&a.pauseCallback()}),this.set("_pause",{isPaused:!0,pauseTime:n}),this},r.prototype.resumeAnimate=function(){var t=this.get("timeline"),i=t.getTime(),n=this.get("animations"),a=this.get("_pause").pauseTime;return P(n,function(o){o.startTime=o.startTime+(i-a),o._paused=!1,o._pauseTime=null,o.resumeCallback&&o.resumeCallback()}),this.set("_pause",{isPaused:!1}),this.set("animations",n),this},r.prototype.emitDelegation=function(t,i){var n=this,a=i.propagationPath;this.getEvents();var o;t==="mouseenter"?o=i.fromShape:t==="mouseleave"&&(o=i.toShape);for(var l=function(f){var h=a[f],v=h.get("name");if(v){if((h.isGroup()||h.isCanvas&&h.isCanvas())&&o&&bz(h,o))return"break";it(v)?P(v,function(d){n.emitDelegateEvent(h,d,i)}):s.emitDelegateEvent(h,v,i)}},s=this,u=0;u<a.length;u++){var c=l(u);if(c==="break")break}},r.prototype.emitDelegateEvent=function(t,i,n){var a=this.getEvents(),o=i+Cq+n.type;(a[o]||a[Sq])&&(n.name=o,n.currentTarget=t,n.delegateTarget=this,n.delegateObject=t.get("delegateObject"),this.emit(o,n))},r.prototype.translate=function(t,i){t===void 0&&(t=0),i===void 0&&(i=0);var n=this.getMatrix(),a=cv(n,[["t",t,i]]);return this.setMatrix(a),this},r.prototype.move=function(t,i){var n=this.attr("x")||0,a=this.attr("y")||0;return this.translate(t-n,i-a),this},r.prototype.moveTo=function(t,i){return this.move(t,i)},r.prototype.scale=function(t,i){var n=this.getMatrix(),a=cv(n,[["s",t,i||t]]);return this.setMatrix(a),this},r.prototype.rotate=function(t){var i=this.getMatrix(),n=cv(i,[["r",t]]);return this.setMatrix(n),this},r.prototype.rotateAtStart=function(t){var i=this.attr(),n=i.x,a=i.y,o=this.getMatrix(),l=cv(o,[["t",-n,-a],["r",t],["t",n,a]]);return this.setMatrix(l),this},r.prototype.rotateAtPoint=function(t,i,n){var a=this.getMatrix(),o=cv(a,[["t",-t,-i],["r",n],["t",t,i]]);return this.setMatrix(o),this},r}(mp),V2={},yA="_INDEX";function tV(e,r){if(e.set("canvas",r),e.isGroup()){var t=e.get("children");t.length&&t.forEach(function(i){tV(i,r)})}}function eV(e,r){if(e.set("timeline",r),e.isGroup()){var t=e.get("children");t.length&&t.forEach(function(i){eV(i,r)})}}function Fq(e,r,t){t===void 0&&(t=!0),t?r.destroy():(r.set("parent",null),r.set("canvas",null)),_z(e.getChildren(),r)}function Oq(e){return function(r,t){var i=e(r,t);return i===0?r[yA]-t[yA]:i}}var rV=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.isCanvas=function(){return!1},r.prototype.getBBox=function(){var t=1/0,i=-1/0,n=1/0,a=-1/0,o=[],l=[],s=this.getChildren().filter(function(c){return c.get("visible")&&(!c.isGroup()||c.isGroup()&&c.getChildren().length>0)});s.length>0?(P(s,function(c){var f=c.getBBox();o.push(f.minX,f.maxX),l.push(f.minY,f.maxY)}),t=Or(o),i=gr(o),n=Or(l),a=gr(l)):(t=0,i=0,n=0,a=0);var u={x:t,y:n,minX:t,minY:n,maxX:i,maxY:a,width:i-t,height:a-n};return u},r.prototype.getCanvasBBox=function(){var t=1/0,i=-1/0,n=1/0,a=-1/0,o=[],l=[],s=this.getChildren().filter(function(c){return c.get("visible")&&(!c.isGroup()||c.isGroup()&&c.getChildren().length>0)});s.length>0?(P(s,function(c){var f=c.getCanvasBBox();o.push(f.minX,f.maxX),l.push(f.minY,f.maxY)}),t=Or(o),i=gr(o),n=Or(l),a=gr(l)):(t=0,i=0,n=0,a=0);var u={x:t,y:n,minX:t,minY:n,maxX:i,maxY:a,width:i-t,height:a-n};return u},r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return t.children=[],t},r.prototype.onAttrChange=function(t,i,n){if(e.prototype.onAttrChange.call(this,t,i,n),t==="matrix"){var a=this.getTotalMatrix();this._applyChildrenMarix(a)}},r.prototype.applyMatrix=function(t){var i=this.getTotalMatrix();e.prototype.applyMatrix.call(this,t);var n=this.getTotalMatrix();n!==i&&this._applyChildrenMarix(n)},r.prototype._applyChildrenMarix=function(t){var i=this.getChildren();P(i,function(n){n.applyMatrix(t)})},r.prototype.addShape=function(){for(var t=[],i=0;i<arguments.length;i++)t[i]=arguments[i];var n=t[0],a=t[1];Zt(n)?a=n:a.type=n;var o=V2[a.type];o||(o=Os(a.type),V2[a.type]=o);var l=this.getShapeBase(),s=new l[o](a);return this.add(s),s},r.prototype.addGroup=function(){for(var t=[],i=0;i<arguments.length;i++)t[i]=arguments[i];var n=t[0],a=t[1],o;if(pt(n))a?o=new n(a):o=new n({parent:this});else{var l=n||{},s=this.getGroupBase();o=new s(l)}return this.add(o),o},r.prototype.getCanvas=function(){var t;return this.isCanvas()?t=this:t=this.get("canvas"),t},r.prototype.getShape=function(t,i,n){if(!$f(this))return null;var a=this.getChildren(),o;if(this.isCanvas())o=this._findShape(a,t,i,n);else{var l=[t,i,1];l=this.invertFromMatrix(l),this.isClipped(l[0],l[1])||(o=this._findShape(a,l[0],l[1],n))}return o},r.prototype._findShape=function(t,i,n,a){for(var o=null,l=t.length-1;l>=0;l--){var s=t[l];if($f(s)&&(s.isGroup()?o=s.getShape(i,n,a):s.isHit(i,n)&&(o=s)),o)break}return o},r.prototype.add=function(t){var i=this.getCanvas(),n=this.getChildren(),a=this.get("timeline"),o=t.getParent();o&&Fq(o,t,!1),t.set("parent",this),i&&tV(t,i),a&&eV(t,a),n.push(t),t.onCanvasChange("add"),this._applyElementMatrix(t)},r.prototype._applyElementMatrix=function(t){var i=this.getTotalMatrix();i&&t.applyMatrix(i)},r.prototype.getChildren=function(){return this.get("children")},r.prototype.sort=function(){var t=this.getChildren();P(t,function(i,n){return i[yA]=n,i}),t.sort(Oq(function(i,n){return i.get("zIndex")-n.get("zIndex")})),this.onCanvasChange("sort")},r.prototype.clear=function(){if(this.set("clearing",!0),!this.destroyed){for(var t=this.getChildren(),i=t.length-1;i>=0;i--)t[i].destroy();this.set("children",[]),this.onCanvasChange("clear"),this.set("clearing",!1)}},r.prototype.destroy=function(){this.get("destroyed")||(this.clear(),e.prototype.destroy.call(this))},r.prototype.getFirst=function(){return this.getChildByIndex(0)},r.prototype.getLast=function(){var t=this.getChildren();return this.getChildByIndex(t.length-1)},r.prototype.getChildByIndex=function(t){var i=this.getChildren();return i[t]},r.prototype.getCount=function(){var t=this.getChildren();return t.length},r.prototype.contain=function(t){var i=this.getChildren();return i.indexOf(t)>-1},r.prototype.removeChild=function(t,i){i===void 0&&(i=!0),this.contain(t)&&t.remove(i)},r.prototype.findAll=function(t){var i=[],n=this.getChildren();return P(n,function(a){t(a)&&i.push(a),a.isGroup()&&(i=i.concat(a.findAll(t)))}),i},r.prototype.find=function(t){var i=null,n=this.getChildren();return P(n,function(a){if(t(a)?i=a:a.isGroup()&&(i=a.find(t)),i)return!1}),i},r.prototype.findById=function(t){return this.find(function(i){return i.get("id")===t})},r.prototype.findByClassName=function(t){return this.find(function(i){return i.get("className")===t})},r.prototype.findAllByName=function(t){return this.findAll(function(i){return i.get("name")===t})},r}(Jz),Rf=0,jv=0,fv=0,iV=1e3,j0,Hv,H0=0,Wu=0,s1=0,Rd=typeof performance=="object"&&performance.now?performance:Date,nV=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function aV(){return Wu||(nV(Pq),Wu=Rd.now()+s1)}function Pq(){Wu=0}function mA(){this._call=this._time=this._next=null}mA.prototype=oV.prototype={constructor:mA,restart:function(e,r,t){if(typeof e!="function")throw new TypeError("callback is not a function");t=(t==null?aV():+t)+(r==null?0:+r),!this._next&&Hv!==this&&(Hv?Hv._next=this:j0=this,Hv=this),this._call=e,this._time=t,xA()},stop:function(){this._call&&(this._call=null,this._time=1/0,xA())}};function oV(e,r,t){var i=new mA;return i.restart(e,r,t),i}function Iq(){aV(),++Rf;for(var e=j0,r;e;)(r=Wu-e._time)>=0&&e._call.call(null,r),e=e._next;--Rf}function j2(){Wu=(H0=Rd.now())+s1,Rf=jv=0;try{Iq()}finally{Rf=0,Dq(),Wu=0}}function Lq(){var e=Rd.now(),r=e-H0;r>iV&&(s1-=r,H0=e)}function Dq(){for(var e,r=j0,t,i=1/0;r;)r._call?(i>r._time&&(i=r._time),e=r,r=r._next):(t=r._next,r._next=null,r=e?e._next=t:j0=t);Hv=e,xA(i)}function xA(e){if(!Rf){jv&&(jv=clearTimeout(jv));var r=e-Wu;r>24?(e<1/0&&(jv=setTimeout(j2,e-Rd.now()-s1)),fv&&(fv=clearInterval(fv))):(fv||(H0=Rd.now(),fv=setInterval(Lq,iV)),Rf=1,nV(j2))}}function bM(e,r,t){e.prototype=r.prototype=t,t.constructor=e}function lV(e,r){var t=Object.create(e.prototype);for(var i in r)t[i]=r[i];return t}function _p(){}var Bd=.7,Y0=1/Bd,wf="\\s*([+-]?\\d+)\\s*",Nd="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",so="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",$q=/^#([0-9a-f]{3,8})$/,kq=new RegExp(`^rgb\\(${wf},${wf},${wf}\\)$`),Rq=new RegExp(`^rgb\\(${so},${so},${so}\\)$`),Bq=new RegExp(`^rgba\\(${wf},${wf},${wf},${Nd}\\)$`),Nq=new RegExp(`^rgba\\(${so},${so},${so},${Nd}\\)$`),Gq=new RegExp(`^hsl\\(${Nd},${so},${so}\\)$`),zq=new RegExp(`^hsla\\(${Nd},${so},${so},${Nd}\\)$`),H2={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};bM(_p,Xu,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:Y2,formatHex:Y2,formatHex8:Vq,formatHsl:jq,formatRgb:W2,toString:W2});function Y2(){return this.rgb().formatHex()}function Vq(){return this.rgb().formatHex8()}function jq(){return sV(this).formatHsl()}function W2(){return this.rgb().formatRgb()}function Xu(e){var r,t;return e=(e+"").trim().toLowerCase(),(r=$q.exec(e))?(t=r[1].length,r=parseInt(r[1],16),t===6?X2(r):t===3?new Yi(r>>8&15|r>>4&240,r>>4&15|r&240,(r&15)<<4|r&15,1):t===8?Iy(r>>24&255,r>>16&255,r>>8&255,(r&255)/255):t===4?Iy(r>>12&15|r>>8&240,r>>8&15|r>>4&240,r>>4&15|r&240,((r&15)<<4|r&15)/255):null):(r=kq.exec(e))?new Yi(r[1],r[2],r[3],1):(r=Rq.exec(e))?new Yi(r[1]*255/100,r[2]*255/100,r[3]*255/100,1):(r=Bq.exec(e))?Iy(r[1],r[2],r[3],r[4]):(r=Nq.exec(e))?Iy(r[1]*255/100,r[2]*255/100,r[3]*255/100,r[4]):(r=Gq.exec(e))?Z2(r[1],r[2]/100,r[3]/100,1):(r=zq.exec(e))?Z2(r[1],r[2]/100,r[3]/100,r[4]):H2.hasOwnProperty(e)?X2(H2[e]):e==="transparent"?new Yi(NaN,NaN,NaN,0):null}function X2(e){return new Yi(e>>16&255,e>>8&255,e&255,1)}function Iy(e,r,t,i){return i<=0&&(e=r=t=NaN),new Yi(e,r,t,i)}function Hq(e){return e instanceof _p||(e=Xu(e)),e?(e=e.rgb(),new Yi(e.r,e.g,e.b,e.opacity)):new Yi}function Uu(e,r,t,i){return arguments.length===1?Hq(e):new Yi(e,r,t,i==null?1:i)}function Yi(e,r,t,i){this.r=+e,this.g=+r,this.b=+t,this.opacity=+i}bM(Yi,Uu,lV(_p,{brighter(e){return e=e==null?Y0:Math.pow(Y0,e),new Yi(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Bd:Math.pow(Bd,e),new Yi(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new Yi($u(this.r),$u(this.g),$u(this.b),W0(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:U2,formatHex:U2,formatHex8:Yq,formatRgb:q2,toString:q2}));function U2(){return`#${Au(this.r)}${Au(this.g)}${Au(this.b)}`}function Yq(){return`#${Au(this.r)}${Au(this.g)}${Au(this.b)}${Au((isNaN(this.opacity)?1:this.opacity)*255)}`}function q2(){const e=W0(this.opacity);return`${e===1?"rgb(":"rgba("}${$u(this.r)}, ${$u(this.g)}, ${$u(this.b)}${e===1?")":`, ${e})`}`}function W0(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function $u(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Au(e){return e=$u(e),(e<16?"0":"")+e.toString(16)}function Z2(e,r,t,i){return i<=0?e=r=t=NaN:t<=0||t>=1?e=r=NaN:r<=0&&(e=NaN),new ga(e,r,t,i)}function sV(e){if(e instanceof ga)return new ga(e.h,e.s,e.l,e.opacity);if(e instanceof _p||(e=Xu(e)),!e)return new ga;if(e instanceof ga)return e;e=e.rgb();var r=e.r/255,t=e.g/255,i=e.b/255,n=Math.min(r,t,i),a=Math.max(r,t,i),o=NaN,l=a-n,s=(a+n)/2;return l?(r===a?o=(t-i)/l+(t<i)*6:t===a?o=(i-r)/l+2:o=(r-t)/l+4,l/=s<.5?a+n:2-a-n,o*=60):l=s>0&&s<1?0:o,new ga(o,l,s,e.opacity)}function Wq(e,r,t,i){return arguments.length===1?sV(e):new ga(e,r,t,i==null?1:i)}function ga(e,r,t,i){this.h=+e,this.s=+r,this.l=+t,this.opacity=+i}bM(ga,Wq,lV(_p,{brighter(e){return e=e==null?Y0:Math.pow(Y0,e),new ga(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Bd:Math.pow(Bd,e),new ga(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,r=isNaN(e)||isNaN(this.s)?0:this.s,t=this.l,i=t+(t<.5?t:1-t)*r,n=2*t-i;return new Yi(Bw(e>=240?e-240:e+120,n,i),Bw(e,n,i),Bw(e<120?e+240:e-120,n,i),this.opacity)},clamp(){return new ga(Q2(this.h),Ly(this.s),Ly(this.l),W0(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=W0(this.opacity);return`${e===1?"hsl(":"hsla("}${Q2(this.h)}, ${Ly(this.s)*100}%, ${Ly(this.l)*100}%${e===1?")":`, ${e})`}`}}));function Q2(e){return e=(e||0)%360,e<0?e+360:e}function Ly(e){return Math.max(0,Math.min(1,e||0))}function Bw(e,r,t){return(e<60?r+(t-r)*e/60:e<180?t:e<240?r+(t-r)*(240-e)/60:r)*255}var wM=e=>()=>e;function Xq(e,r){return function(t){return e+t*r}}function Uq(e,r,t){return e=Math.pow(e,t),r=Math.pow(r,t)-e,t=1/t,function(i){return Math.pow(e+i*r,t)}}function qq(e){return(e=+e)==1?uV:function(r,t){return t-r?Uq(r,t,e):wM(isNaN(r)?t:r)}}function uV(e,r){var t=r-e;return t?Xq(e,t):wM(isNaN(e)?r:e)}var K2=function e(r){var t=qq(r);function i(n,a){var o=t((n=Uu(n)).r,(a=Uu(a)).r),l=t(n.g,a.g),s=t(n.b,a.b),u=uV(n.opacity,a.opacity);return function(c){return n.r=o(c),n.g=l(c),n.b=s(c),n.opacity=u(c),n+""}}return i.gamma=e,i}(1);function cV(e,r){r||(r=[]);var t=e?Math.min(r.length,e.length):0,i=r.slice(),n;return function(a){for(n=0;n<t;++n)i[n]=e[n]*(1-a)+r[n]*a;return i}}function fV(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function Zq(e,r){return(fV(r)?cV:hV)(e,r)}function hV(e,r){var t=r?r.length:0,i=e?Math.min(t,e.length):0,n=new Array(i),a=new Array(t),o;for(o=0;o<i;++o)n[o]=X0(e[o],r[o]);for(;o<t;++o)a[o]=r[o];return function(l){for(o=0;o<i;++o)a[o]=n[o](l);return a}}function Qq(e,r){var t=new Date;return e=+e,r=+r,function(i){return t.setTime(e*(1-i)+r*i),t}}function _A(e,r){return e=+e,r=+r,function(t){return e*(1-t)+r*t}}function Kq(e,r){var t={},i={},n;(e===null||typeof e!="object")&&(e={}),(r===null||typeof r!="object")&&(r={});for(n in r)n in e?t[n]=X0(e[n],r[n]):i[n]=r[n];return function(a){for(n in t)i[n]=t[n](a);return i}}var bA=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Nw=new RegExp(bA.source,"g");function Jq(e){return function(){return e}}function tZ(e){return function(r){return e(r)+""}}function eZ(e,r){var t=bA.lastIndex=Nw.lastIndex=0,i,n,a,o=-1,l=[],s=[];for(e=e+"",r=r+"";(i=bA.exec(e))&&(n=Nw.exec(r));)(a=n.index)>t&&(a=r.slice(t,a),l[o]?l[o]+=a:l[++o]=a),(i=i[0])===(n=n[0])?l[o]?l[o]+=n:l[++o]=n:(l[++o]=null,s.push({i:o,x:_A(i,n)})),t=Nw.lastIndex;return t<r.length&&(a=r.slice(t),l[o]?l[o]+=a:l[++o]=a),l.length<2?s[0]?tZ(s[0].x):Jq(r):(r=s.length,function(u){for(var c=0,f;c<r;++c)l[(f=s[c]).i]=f.x(u);return l.join("")})}function X0(e,r){var t=typeof r,i;return r==null||t==="boolean"?wM(r):(t==="number"?_A:t==="string"?(i=Xu(r))?(r=i,K2):eZ:r instanceof Xu?K2:r instanceof Date?Qq:fV(r)?cV:Array.isArray(r)?hV:typeof r.valueOf!="function"&&typeof r.toString!="function"||isNaN(r)?Kq:_A)(e,r)}function rZ(e){return+e}function iZ(e){return e*e}function nZ(e){return e*(2-e)}function J2(e){return((e*=2)<=1?e*e:--e*(2-e)+1)/2}function aZ(e){return e*e*e}function oZ(e){return--e*e*e+1}function tL(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}var CM=3,lZ=function e(r){r=+r;function t(i){return Math.pow(i,r)}return t.exponent=e,t}(CM),sZ=function e(r){r=+r;function t(i){return 1-Math.pow(1-i,r)}return t.exponent=e,t}(CM),eL=function e(r){r=+r;function t(i){return((i*=2)<=1?Math.pow(i,r):2-Math.pow(2-i,r))/2}return t.exponent=e,t}(CM),vV=Math.PI,dV=vV/2;function uZ(e){return+e==1?1:1-Math.cos(e*dV)}function cZ(e){return Math.sin(e*dV)}function rL(e){return(1-Math.cos(vV*e))/2}function fs(e){return(Math.pow(2,-10*e)-.0009765625)*1.0009775171065494}function fZ(e){return fs(1-+e)}function hZ(e){return 1-fs(e)}function iL(e){return((e*=2)<=1?fs(1-e):2-fs(e-1))/2}function vZ(e){return 1-Math.sqrt(1-e*e)}function dZ(e){return Math.sqrt(1- --e*e)}function nL(e){return((e*=2)<=1?1-Math.sqrt(1-e*e):Math.sqrt(1-(e-=2)*e)+1)/2}var wA=4/11,pZ=6/11,gZ=8/11,yZ=3/4,mZ=9/11,xZ=10/11,_Z=15/16,bZ=21/22,wZ=63/64,Dy=1/wA/wA;function CZ(e){return 1-Gd(1-e)}function Gd(e){return(e=+e)<wA?Dy*e*e:e<gZ?Dy*(e-=pZ)*e+yZ:e<xZ?Dy*(e-=mZ)*e+_Z:Dy*(e-=bZ)*e+wZ}function SZ(e){return((e*=2)<=1?1-Gd(1-e):Gd(e-1)+1)/2}var SM=1.70158,AZ=function e(r){r=+r;function t(i){return(i=+i)*i*(r*(i-1)+i)}return t.overshoot=e,t}(SM),TZ=function e(r){r=+r;function t(i){return--i*i*((i+1)*r+i)+1}return t.overshoot=e,t}(SM),aL=function e(r){r=+r;function t(i){return((i*=2)<1?i*i*((r+1)*i-r):(i-=2)*i*((r+1)*i+r)+2)/2}return t.overshoot=e,t}(SM),Bf=2*Math.PI,AM=1,TM=.3,MZ=function e(r,t){var i=Math.asin(1/(r=Math.max(1,r)))*(t/=Bf);function n(a){return r*fs(- --a)*Math.sin((i-a)/t)}return n.amplitude=function(a){return e(a,t*Bf)},n.period=function(a){return e(r,a)},n}(AM,TM),oL=function e(r,t){var i=Math.asin(1/(r=Math.max(1,r)))*(t/=Bf);function n(a){return 1-r*fs(a=+a)*Math.sin((a+i)/t)}return n.amplitude=function(a){return e(a,t*Bf)},n.period=function(a){return e(r,a)},n}(AM,TM),EZ=function e(r,t){var i=Math.asin(1/(r=Math.max(1,r)))*(t/=Bf);function n(a){return((a=a*2-1)<0?r*fs(-a)*Math.sin((i-a)/t):2-r*fs(a)*Math.sin((i+a)/t))/2}return n.amplitude=function(a){return e(a,t*Bf)},n.period=function(a){return e(r,a)},n}(AM,TM),FZ=Object.freeze(Object.defineProperty({__proto__:null,easeLinear:rZ,easeQuad:J2,easeQuadIn:iZ,easeQuadOut:nZ,easeQuadInOut:J2,easeCubic:tL,easeCubicIn:aZ,easeCubicOut:oZ,easeCubicInOut:tL,easePoly:eL,easePolyIn:lZ,easePolyOut:sZ,easePolyInOut:eL,easeSin:rL,easeSinIn:uZ,easeSinOut:cZ,easeSinInOut:rL,easeExp:iL,easeExpIn:fZ,easeExpOut:hZ,easeExpInOut:iL,easeCircle:nL,easeCircleIn:vZ,easeCircleOut:dZ,easeCircleInOut:nL,easeBounce:Gd,easeBounceIn:CZ,easeBounceOut:Gd,easeBounceInOut:SZ,easeBack:aL,easeBackIn:AZ,easeBackOut:TZ,easeBackInOut:aL,easeElastic:oL,easeElasticIn:MZ,easeElasticOut:oL,easeElasticInOut:EZ},Symbol.toStringTag,{value:"Module"})),pV={};function OZ(e){return pV[e.toLowerCase()]||FZ[e]}function MM(e,r){pV[e.toLowerCase()]=r}var PZ=function(e){return["fill","stroke","fillStyle","strokeStyle"].includes(e)},IZ=function(e){return/^[r,R,L,l]{1}[\s]*\(/.test(e)},lL=[1,0,0,0,1,0,0,0,1];function LZ(e,r,t){var i={},n=r.fromAttrs,a=r.toAttrs;if(!e.destroyed){var o;for(var l in a)if(!Ge(n[l],a[l]))if(l==="path"){var s=a[l],u=n[l];s.length>u.length?(s=hf(a[l]),u=hf(n[l]),u=mz(u,s),u=dA(u,s),r.fromAttrs.path=u,r.toAttrs.path=s):r.pathFormatted||(s=hf(a[l]),u=hf(n[l]),u=dA(u,s),r.fromAttrs.path=u,r.toAttrs.path=s,r.pathFormatted=!0),i[l]=[];for(var c=0;c<s.length;c++){for(var f=s[c],h=u[c],v=[],d=0;d<f.length;d++)Mt(f[d])&&h&&Mt(h[d])?(o=X0(h[d],f[d]),v.push(o(t))):v.push(f[d]);i[l].push(v)}}else if(l==="matrix"){var p=Zq(n[l]||lL,a[l]||lL),x=p(t);i[l]=x}else PZ(l)&&IZ(a[l])?i[l]=a[l]:pt(a[l])||(o=X0(n[l],a[l]),i[l]=o(t));e.attr(i)}}function DZ(e,r,t){var i=r.startTime,n=r.delay;if(t<i+n||r._paused)return!1;var a,o=r.duration,l=r.easing,s=OZ(l);if(t=t-i-r.delay,r.repeat)a=t%o/o,a=s(a);else if(a=t/o,a<1)a=s(a);else return r.onFrame?e.attr(r.onFrame(1)):e.attr(r.toAttrs),!0;if(r.onFrame){var u=r.onFrame(a);e.attr(u)}else LZ(e,r,a);return!1}var $Z=function(){function e(r){this.animators=[],this.current=0,this.timer=null,this.canvas=r}return e.prototype.initTimer=function(){var r=this,t=!1,i,n,a;this.timer=oV(function(o){if(r.current=o,r.animators.length>0){for(var l=r.animators.length-1;l>=0;l--){if(i=r.animators[l],i.destroyed){r.removeAnimator(l);continue}if(!i.isAnimatePaused()){n=i.get("animations");for(var s=n.length-1;s>=0;s--)a=n[s],t=DZ(i,a,o),t&&(n.splice(s,1),t=!1,a.callback&&a.callback())}n.length===0&&r.removeAnimator(l)}var u=r.canvas.get("autoDraw");u||r.canvas.draw()}})},e.prototype.addAnimator=function(r){this.animators.push(r)},e.prototype.removeAnimator=function(r){this.animators.splice(r,1)},e.prototype.isAnimating=function(){return!!this.animators.length},e.prototype.stop=function(){this.timer&&this.timer.stop()},e.prototype.stopAllAnimations=function(r){r===void 0&&(r=!0),this.animators.forEach(function(t){t.stopAnimate(r)}),this.animators=[],this.canvas.draw()},e.prototype.getTime=function(){return this.current},e}(),kZ=40,sL=0,uL=["mousedown","mouseup","dblclick","mouseout","mouseover","mousemove","mouseleave","mouseenter","touchstart","touchmove","touchend","dragenter","dragover","dragleave","drop","contextmenu","mousewheel"];function cL(e,r,t){t.name=r,t.target=e,t.currentTarget=e,t.delegateTarget=e,e.emit(r,t)}function RZ(e,r,t){if(t.bubbles){var i=void 0,n=!1;if(r==="mouseenter"?(i=t.fromShape,n=!0):r==="mouseleave"&&(n=!0,i=t.toShape),e.isCanvas()&&n)return;if(i&&bz(e,i)){t.bubbles=!1;return}t.name=r,t.currentTarget=e,t.delegateTarget=e,e.emit(r,t)}}var BZ=function(){function e(r){var t=this;this.draggingShape=null,this.dragging=!1,this.currentShape=null,this.mousedownShape=null,this.mousedownPoint=null,this._eventCallback=function(i){var n=i.type;t._triggerEvent(n,i)},this._onDocumentMove=function(i){var n=t.canvas,a=n.get("el");if(a!==i.target&&(t.dragging||t.currentShape)){var o=t._getPointInfo(i);t.dragging&&t._emitEvent("drag",i,o,t.draggingShape)}},this._onDocumentMouseUp=function(i){var n=t.canvas,a=n.get("el");if(a!==i.target&&t.dragging){var o=t._getPointInfo(i);t.draggingShape&&t._emitEvent("drop",i,o,null),t._emitEvent("dragend",i,o,t.draggingShape),t._afterDrag(t.draggingShape,o,i)}},this.canvas=r.canvas}return e.prototype.init=function(){this._bindEvents()},e.prototype._bindEvents=function(){var r=this,t=this.canvas.get("el");P(uL,function(i){t.addEventListener(i,r._eventCallback)}),document&&(document.addEventListener("mousemove",this._onDocumentMove),document.addEventListener("mouseup",this._onDocumentMouseUp))},e.prototype._clearEvents=function(){var r=this,t=this.canvas.get("el");P(uL,function(i){t.removeEventListener(i,r._eventCallback)}),document&&(document.removeEventListener("mousemove",this._onDocumentMove),document.removeEventListener("mouseup",this._onDocumentMouseUp))},e.prototype._getEventObj=function(r,t,i,n,a,o){var l=new bh(r,t);return l.fromShape=a,l.toShape=o,l.x=i.x,l.y=i.y,l.clientX=i.clientX,l.clientY=i.clientY,l.propagationPath.push(n),l},e.prototype._getShape=function(r,t){return this.canvas.getShape(r.x,r.y,t)},e.prototype._getPointInfo=function(r){var t=this.canvas,i=t.getClientByEvent(r),n=t.getPointByEvent(r);return{x:n.x,y:n.y,clientX:i.x,clientY:i.y}},e.prototype._triggerEvent=function(r,t){var i=this._getPointInfo(t),n=this._getShape(i,t),a=this["_on"+r],o=!1;if(a)a.call(this,i,n,t);else{var l=this.currentShape;r==="mouseenter"||r==="dragenter"||r==="mouseover"?(this._emitEvent(r,t,i,null,null,n),n&&this._emitEvent(r,t,i,n,null,n),r==="mouseenter"&&this.draggingShape&&this._emitEvent("dragenter",t,i,null)):r==="mouseleave"||r==="dragleave"||r==="mouseout"?(o=!0,l&&this._emitEvent(r,t,i,l,l,null),this._emitEvent(r,t,i,null,l,null),r==="mouseleave"&&this.draggingShape&&this._emitEvent("dragleave",t,i,null)):this._emitEvent(r,t,i,n,null,null)}if(o||(this.currentShape=n),n&&!n.get("destroyed")){var s=this.canvas,u=s.get("el");u.style.cursor=n.attr("cursor")||s.get("cursor")}},e.prototype._onmousedown=function(r,t,i){i.button===sL&&(this.mousedownShape=t,this.mousedownPoint=r,this.mousedownTimeStamp=i.timeStamp),this._emitEvent("mousedown",i,r,t,null,null)},e.prototype._emitMouseoverEvents=function(r,t,i,n){var a=this.canvas.get("el");i!==n&&(i&&(this._emitEvent("mouseout",r,t,i,i,n),this._emitEvent("mouseleave",r,t,i,i,n),(!n||n.get("destroyed"))&&(a.style.cursor=this.canvas.get("cursor"))),n&&(this._emitEvent("mouseover",r,t,n,i,n),this._emitEvent("mouseenter",r,t,n,i,n)))},e.prototype._emitDragoverEvents=function(r,t,i,n,a){n?(n!==i&&(i&&this._emitEvent("dragleave",r,t,i,i,n),this._emitEvent("dragenter",r,t,n,i,n)),a||this._emitEvent("dragover",r,t,n)):i&&this._emitEvent("dragleave",r,t,i,i,n),a&&this._emitEvent("dragover",r,t,n)},e.prototype._afterDrag=function(r,t,i){r&&(r.set("capture",!0),this.draggingShape=null),this.dragging=!1;var n=this._getShape(t,i);n!==r&&this._emitMouseoverEvents(i,t,r,n),this.currentShape=n},e.prototype._onmouseup=function(r,t,i){if(i.button===sL){var n=this.draggingShape;this.dragging?(n&&this._emitEvent("drop",i,r,t),this._emitEvent("dragend",i,r,n),this._afterDrag(n,r,i)):(this._emitEvent("mouseup",i,r,t),t===this.mousedownShape&&this._emitEvent("click",i,r,t),this.mousedownShape=null,this.mousedownPoint=null)}},e.prototype._ondragover=function(r,t,i){i.preventDefault();var n=this.currentShape;this._emitDragoverEvents(i,r,n,t,!0)},e.prototype._onmousemove=function(r,t,i){var n=this.canvas,a=this.currentShape,o=this.draggingShape;if(this.dragging)o&&this._emitDragoverEvents(i,r,a,t,!1),this._emitEvent("drag",i,r,o);else{var l=this.mousedownPoint;if(l){var s=this.mousedownShape,u=i.timeStamp,c=u-this.mousedownTimeStamp,f=l.clientX-r.clientX,h=l.clientY-r.clientY,v=f*f+h*h;c>120||v>kZ?s&&s.get("draggable")?(o=this.mousedownShape,o.set("capture",!1),this.draggingShape=o,this.dragging=!0,this._emitEvent("dragstart",i,r,o),this.mousedownShape=null,this.mousedownPoint=null):!s&&n.get("draggable")?(this.dragging=!0,this._emitEvent("dragstart",i,r,null),this.mousedownShape=null,this.mousedownPoint=null):(this._emitMouseoverEvents(i,r,a,t),this._emitEvent("mousemove",i,r,t)):(this._emitMouseoverEvents(i,r,a,t),this._emitEvent("mousemove",i,r,t))}else this._emitMouseoverEvents(i,r,a,t),this._emitEvent("mousemove",i,r,t)}},e.prototype._emitEvent=function(r,t,i,n,a,o){var l=this._getEventObj(r,t,i,n,a,o);if(n){l.shape=n,cL(n,r,l);for(var s=n.getParent();s;)s.emitDelegation(r,l),l.propagationStopped||RZ(s,r,l),l.propagationPath.push(s),s=s.getParent()}else{var u=this.canvas;cL(u,r,l)}},e.prototype.destroy=function(){this._clearEvents(),this.canvas=null,this.currentShape=null,this.draggingShape=null,this.mousedownPoint=null,this.mousedownShape=null,this.mousedownTimeStamp=null},e}(),fL="px",hL=gM(),NZ=hL&&hL.name==="firefox",bp=function(e){X(r,e);function r(t){var i=e.call(this,t)||this;return i.initContainer(),i.initDom(),i.initEvents(),i.initTimeline(),i}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return t.cursor="default",t.supportCSSTransform=!1,t},r.prototype.initContainer=function(){var t=this.get("container");Ct(t)&&(t=document.getElementById(t),this.set("container",t))},r.prototype.initDom=function(){var t=this.createDom();this.set("el",t);var i=this.get("container");i.appendChild(t),this.setDOMSize(this.get("width"),this.get("height"))},r.prototype.initEvents=function(){var t=new BZ({canvas:this});t.init(),this.set("eventController",t)},r.prototype.initTimeline=function(){var t=new $Z(this);this.set("timeline",t)},r.prototype.setDOMSize=function(t,i){var n=this.get("el");R2&&(n.style.width=t+fL,n.style.height=i+fL)},r.prototype.changeSize=function(t,i){this.setDOMSize(t,i),this.set("width",t),this.set("height",i),this.onCanvasChange("changeSize")},r.prototype.getRenderer=function(){return this.get("renderer")},r.prototype.getCursor=function(){return this.get("cursor")},r.prototype.setCursor=function(t){this.set("cursor",t);var i=this.get("el");R2&&i&&(i.style.cursor=t)},r.prototype.getPointByEvent=function(t){var i=this.get("supportCSSTransform");if(i){if(NZ&&!K(t.layerX)&&t.layerX!==t.offsetX)return{x:t.layerX,y:t.layerY};if(!K(t.offsetX))return{x:t.offsetX,y:t.offsetY}}var n=this.getClientByEvent(t),a=n.x,o=n.y;return this.getPointByClient(a,o)},r.prototype.getClientByEvent=function(t){var i=t;return t.touches&&(t.type==="touchend"?i=t.changedTouches[0]:i=t.touches[0]),{x:i.clientX,y:i.clientY}},r.prototype.getPointByClient=function(t,i){var n=this.get("el"),a=n.getBoundingClientRect();return{x:t-a.left,y:i-a.top}},r.prototype.getClientByPoint=function(t,i){var n=this.get("el"),a=n.getBoundingClientRect();return{x:t+a.left,y:i+a.top}},r.prototype.draw=function(){},r.prototype.removeDom=function(){var t=this.get("el");t.parentNode.removeChild(t)},r.prototype.clearEvents=function(){var t=this.get("eventController");t.destroy()},r.prototype.isCanvas=function(){return!0},r.prototype.getParent=function(){return null},r.prototype.destroy=function(){var t=this.get("timeline");this.get("destroyed")||(this.clear(),t&&t.stop(),this.clearEvents(),this.removeDom(),e.prototype.destroy.call(this))},r}(rV),wp=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.isGroup=function(){return!0},r.prototype.isEntityGroup=function(){return!1},r.prototype.clone=function(){for(var t=e.prototype.clone.call(this),i=this.getChildren(),n=0;n<i.length;n++){var a=i[n];t.add(a.clone())}return t},r}(rV),Cp=function(e){X(r,e);function r(t){return e.call(this,t)||this}return r.prototype._isInBBox=function(t,i){var n=this.getBBox();return n.minX<=t&&n.maxX>=t&&n.minY<=i&&n.maxY>=i},r.prototype.afterAttrsChange=function(t){e.prototype.afterAttrsChange.call(this,t),this.clearCacheBBox()},r.prototype.getBBox=function(){var t=this.cfg.bbox;return t||(t=this.calculateBBox(),this.set("bbox",t)),t},r.prototype.getCanvasBBox=function(){var t=this.cfg.canvasBBox;return t||(t=this.calculateCanvasBBox(),this.set("canvasBBox",t)),t},r.prototype.applyMatrix=function(t){e.prototype.applyMatrix.call(this,t),this.set("canvasBBox",null)},r.prototype.calculateCanvasBBox=function(){var t=this.getBBox(),i=this.getTotalMatrix(),n=t.minX,a=t.minY,o=t.maxX,l=t.maxY;if(i){var s=ro(i,[t.minX,t.minY]),u=ro(i,[t.maxX,t.minY]),c=ro(i,[t.minX,t.maxY]),f=ro(i,[t.maxX,t.maxY]);n=Math.min(s[0],u[0],c[0],f[0]),o=Math.max(s[0],u[0],c[0],f[0]),a=Math.min(s[1],u[1],c[1],f[1]),l=Math.max(s[1],u[1],c[1],f[1])}var h=this.attrs;if(h.shadowColor){var v=h.shadowBlur,d=v===void 0?0:v,p=h.shadowOffsetX,x=p===void 0?0:p,m=h.shadowOffsetY,_=m===void 0?0:m,b=n-d+x,w=o+d+x,S=a-d+_,M=l+d+_;n=Math.min(n,b),o=Math.max(o,w),a=Math.min(a,S),l=Math.max(l,M)}return{x:n,y:a,minX:n,minY:a,maxX:o,maxY:l,width:o-n,height:l-a}},r.prototype.clearCacheBBox=function(){this.set("bbox",null),this.set("canvasBBox",null)},r.prototype.isClipShape=function(){return this.get("isClipShape")},r.prototype.isInShape=function(t,i){return!1},r.prototype.isOnlyHitBox=function(){return!1},r.prototype.isHit=function(t,i){var n=this.get("startArrowShape"),a=this.get("endArrowShape"),o=[t,i,1];o=this.invertFromMatrix(o);var l=o[0],s=o[1],u=this._isInBBox(l,s);return this.isOnlyHitBox()?u:!!(u&&!this.isClipped(l,s)&&(this.isInShape(l,s)||n&&n.isHit(l,s)||a&&a.isHit(l,s)))},r}(Jz),gV=new Map;function wn(e,r){gV.set(e,r)}function Sp(e){return gV.get(e)}function yV(e){var r=e.attr(),t=r.x,i=r.y,n=r.width,a=r.height;return{x:t,y:i,width:n,height:a}}function mV(e){var r=e.attr(),t=r.x,i=r.y,n=r.r;return{x:t-n,y:i-n,width:n*2,height:n*2}}function Jr(e,r,t,i){var n=e-t,a=r-i;return Math.sqrt(n*n+a*a)}function fd(e,r){return Math.abs(e-r)<.001}function cc(e,r){var t=Or(e),i=Or(r),n=gr(e),a=gr(r);return{x:t,y:i,width:n-t,height:a-i}}function GZ(e,r,t,i){return{minX:Or([e,t]),maxX:gr([e,t]),minY:Or([r,i]),maxY:gr([r,i])}}function Ap(e){return(e+Math.PI*2)%(Math.PI*2)}var zZ=Object.freeze(Object.defineProperty({__proto__:null,distance:Jr,isNumberEqual:fd,getBBoxByArray:cc,getBBoxRange:GZ,piMod:Ap},Symbol.toStringTag,{value:"Module"})),Er={box:function(e,r,t,i){return cc([e,t],[r,i])},length:function(e,r,t,i){return Jr(e,r,t,i)},pointAt:function(e,r,t,i,n){return{x:(1-n)*e+n*t,y:(1-n)*r+n*i}},pointDistance:function(e,r,t,i,n,a){var o=(t-e)*(n-e)+(i-r)*(a-r);if(o<0)return Jr(e,r,n,a);var l=(t-e)*(t-e)+(i-r)*(i-r);return o>l?Jr(t,i,n,a):this.pointToLine(e,r,t,i,n,a)},pointToLine:function(e,r,t,i,n,a){var o=[t-e,i-r];if(Qz(o,[0,0]))return Math.sqrt((n-e)*(n-e)+(a-r)*(a-r));var l=[-o[1],o[0]];mM(l,l);var s=[n-e,a-r];return Math.abs(xM(s,l))},tangentAngle:function(e,r,t,i){return Math.atan2(i-r,t-e)}},VZ=1e-4;function xV(e,r,t,i,n,a){var o,l=1/0,s=[t,i],u=20;a&&a>200&&(u=a/10);for(var c=1/u,f=c/10,h=0;h<=u;h++){var v=h*c,d=[n.apply(null,e.concat([v])),n.apply(null,r.concat([v]))],p=Jr(s[0],s[1],d[0],d[1]);p<l&&(o=v,l=p)}if(o===0)return{x:e[0],y:r[0]};if(o===1){var x=e.length;return{x:e[x-1],y:r[x-1]}}l=1/0;for(var h=0;h<32&&!(f<VZ);h++){var m=o-f,_=o+f,d=[n.apply(null,e.concat([m])),n.apply(null,r.concat([m]))],p=Jr(s[0],s[1],d[0],d[1]);if(m>=0&&p<l)o=m,l=p;else{var b=[n.apply(null,e.concat([_])),n.apply(null,r.concat([_]))],w=Jr(s[0],s[1],b[0],b[1]);_<=1&&w<l?(o=_,l=w):f*=.5}}return{x:n.apply(null,e.concat([o])),y:n.apply(null,r.concat([o]))}}function jZ(e,r){for(var t=0,i=e.length,n=0;n<i;n++){var a=e[n],o=r[n],l=e[(n+1)%i],s=r[(n+1)%i];t+=Jr(a,o,l,s)}return t/2}function Nl(e,r,t,i){var n=1-i;return n*n*e+2*i*n*r+i*i*t}function vL(e,r,t){var i=e+t-2*r;if(fd(i,0))return[.5];var n=(e-r)/i;return n<=1&&n>=0?[n]:[]}function dL(e,r,t,i){return 2*(1-i)*(r-e)+2*i*(t-r)}function _V(e,r,t,i,n,a,o){var l=Nl(e,t,n,o),s=Nl(r,i,a,o),u=Er.pointAt(e,r,t,i,o),c=Er.pointAt(t,i,n,a,o);return[[e,r,u.x,u.y,l,s],[l,s,c.x,c.y,n,a]]}function CA(e,r,t,i,n,a,o){if(o===0)return(Jr(e,r,t,i)+Jr(t,i,n,a)+Jr(e,r,n,a))/2;var l=_V(e,r,t,i,n,a,.5),s=l[0],u=l[1];return s.push(o-1),u.push(o-1),CA.apply(null,s)+CA.apply(null,u)}var EM={box:function(e,r,t,i,n,a){var o=vL(e,t,n)[0],l=vL(r,i,a)[0],s=[e,n],u=[r,a];return o!==void 0&&s.push(Nl(e,t,n,o)),l!==void 0&&u.push(Nl(r,i,a,l)),cc(s,u)},length:function(e,r,t,i,n,a){return CA(e,r,t,i,n,a,3)},nearestPoint:function(e,r,t,i,n,a,o,l){return xV([e,t,n],[r,i,a],o,l,Nl)},pointDistance:function(e,r,t,i,n,a,o,l){var s=this.nearestPoint(e,r,t,i,n,a,o,l);return Jr(s.x,s.y,o,l)},interpolationAt:Nl,pointAt:function(e,r,t,i,n,a,o){return{x:Nl(e,t,n,o),y:Nl(r,i,a,o)}},divide:function(e,r,t,i,n,a,o){return _V(e,r,t,i,n,a,o)},tangentAngle:function(e,r,t,i,n,a,o){var l=dL(e,t,n,o),s=dL(r,i,a,o),u=Math.atan2(s,l);return Ap(u)}};function Gl(e,r,t,i,n){var a=1-n;return a*a*a*e+3*r*n*a*a+3*t*n*n*a+i*n*n*n}function pL(e,r,t,i,n){var a=1-n;return 3*(a*a*(r-e)+2*a*n*(t-r)+n*n*(i-t))}function Gw(e,r,t,i){var n=-3*e+9*r-9*t+3*i,a=6*e-12*r+6*t,o=3*r-3*e,l=[],s,u,c;if(fd(n,0))fd(a,0)||(s=-o/a,s>=0&&s<=1&&l.push(s));else{var f=a*a-4*n*o;fd(f,0)?l.push(-a/(2*n)):f>0&&(c=Math.sqrt(f),s=(-a+c)/(2*n),u=(-a-c)/(2*n),s>=0&&s<=1&&l.push(s),u>=0&&u<=1&&l.push(u))}return l}function bV(e,r,t,i,n,a,o,l,s){var u=Gl(e,t,n,o,s),c=Gl(r,i,a,l,s),f=Er.pointAt(e,r,t,i,s),h=Er.pointAt(t,i,n,a,s),v=Er.pointAt(n,a,o,l,s),d=Er.pointAt(f.x,f.y,h.x,h.y,s),p=Er.pointAt(h.x,h.y,v.x,v.y,s);return[[e,r,f.x,f.y,d.x,d.y,u,c],[u,c,p.x,p.y,v.x,v.y,o,l]]}function SA(e,r,t,i,n,a,o,l,s){if(s===0)return jZ([e,t,n,o],[r,i,a,l]);var u=bV(e,r,t,i,n,a,o,l,.5),c=u[0],f=u[1];return c.push(s-1),f.push(s-1),SA.apply(null,c)+SA.apply(null,f)}var Cf={extrema:Gw,box:function(e,r,t,i,n,a,o,l){for(var s=[e,o],u=[r,l],c=Gw(e,t,n,o),f=Gw(r,i,a,l),h=0;h<c.length;h++)s.push(Gl(e,t,n,o,c[h]));for(var h=0;h<f.length;h++)u.push(Gl(r,i,a,l,f[h]));return cc(s,u)},length:function(e,r,t,i,n,a,o,l){return SA(e,r,t,i,n,a,o,l,3)},nearestPoint:function(e,r,t,i,n,a,o,l,s,u,c){return xV([e,t,n,o],[r,i,a,l],s,u,Gl,c)},pointDistance:function(e,r,t,i,n,a,o,l,s,u,c){var f=this.nearestPoint(e,r,t,i,n,a,o,l,s,u,c);return Jr(f.x,f.y,s,u)},interpolationAt:Gl,pointAt:function(e,r,t,i,n,a,o,l,s){return{x:Gl(e,t,n,o,s),y:Gl(r,i,a,l,s)}},divide:function(e,r,t,i,n,a,o,l,s){return bV(e,r,t,i,n,a,o,l,s)},tangentAngle:function(e,r,t,i,n,a,o,l,s){var u=pL(e,t,n,o,s),c=pL(r,i,a,l,s);return Ap(Math.atan2(c,u))}};function gL(e,r){var t=Math.abs(e);return r>0?t:t*-1}var HZ={box:function(e,r,t,i){return{x:e-t,y:r-i,width:t*2,height:i*2}},length:function(e,r,t,i){return Math.PI*(3*(t+i)-Math.sqrt((3*t+i)*(t+3*i)))},nearestPoint:function(e,r,t,i,n,a){var o=t,l=i;if(o===0||l===0)return{x:e,y:r};for(var s=n-e,u=a-r,c=Math.abs(s),f=Math.abs(u),h=o*o,v=l*l,d=Math.PI/4,p,x,m=0;m<4;m++){p=o*Math.cos(d),x=l*Math.sin(d);var _=(h-v)*Math.pow(Math.cos(d),3)/o,b=(v-h)*Math.pow(Math.sin(d),3)/l,w=p-_,S=x-b,M=c-_,F=f-b,O=Math.hypot(S,w),L=Math.hypot(F,M),D=O*Math.asin((w*F-S*M)/(O*L)),k=D/Math.sqrt(h+v-p*p-x*x);d+=k,d=Math.min(Math.PI/2,Math.max(0,d))}return{x:e+gL(p,s),y:r+gL(x,u)}},pointDistance:function(e,r,t,i,n,a){var o=this.nearestPoint(e,r,t,i,n,a);return Jr(o.x,o.y,n,a)},pointAt:function(e,r,t,i,n){var a=2*Math.PI*n;return{x:e+t*Math.cos(a),y:r+i*Math.sin(a)}},tangentAngle:function(e,r,t,i,n){var a=2*Math.PI*n,o=Math.atan2(i*Math.cos(a),-t*Math.sin(a));return Ap(o)}};function YZ(e,r,t,i,n,a,o,l){return-1*t*Math.cos(n)*Math.sin(l)-i*Math.sin(n)*Math.cos(l)}function WZ(e,r,t,i,n,a,o,l){return-1*t*Math.sin(n)*Math.sin(l)+i*Math.cos(n)*Math.cos(l)}function XZ(e,r,t){return Math.atan(-r/e*Math.tan(t))}function UZ(e,r,t){return Math.atan(r/(e*Math.tan(t)))}function yL(e,r,t,i,n,a){return t*Math.cos(n)*Math.cos(a)-i*Math.sin(n)*Math.sin(a)+e}function mL(e,r,t,i,n,a){return t*Math.sin(n)*Math.cos(a)+i*Math.cos(n)*Math.sin(a)+r}function qZ(e,r,t,i){var n=Math.atan2(i*e,t*r);return(n+Math.PI*2)%(Math.PI*2)}function xL(e,r,t){return{x:e*Math.cos(t),y:r*Math.sin(t)}}function _L(e,r,t){var i=Math.cos(t),n=Math.sin(t);return[e*i-r*n,e*n+r*i]}var wV={box:function(e,r,t,i,n,a,o){for(var l=XZ(t,i,n),s=1/0,u=-1/0,c=[a,o],f=-Math.PI*2;f<=Math.PI*2;f+=Math.PI){var h=l+f;a<o?a<h&&h<o&&c.push(h):o<h&&h<a&&c.push(h)}for(var f=0;f<c.length;f++){var v=yL(e,r,t,i,n,c[f]);v<s&&(s=v),v>u&&(u=v)}for(var d=UZ(t,i,n),p=1/0,x=-1/0,m=[a,o],f=-Math.PI*2;f<=Math.PI*2;f+=Math.PI){var _=d+f;a<o?a<_&&_<o&&m.push(_):o<_&&_<a&&m.push(_)}for(var f=0;f<m.length;f++){var b=mL(e,r,t,i,n,m[f]);b<p&&(p=b),b>x&&(x=b)}return{x:s,y:p,width:u-s,height:x-p}},length:function(e,r,t,i,n,a,o){},nearestPoint:function(e,r,t,i,n,a,o,l,s){var u=_L(l-e,s-r,-n),c=u[0],f=u[1],h=HZ.nearestPoint(0,0,t,i,c,f),v=qZ(t,i,h.x,h.y);v<a?h=xL(t,i,a):v>o&&(h=xL(t,i,o));var d=_L(h.x,h.y,n);return{x:d[0]+e,y:d[1]+r}},pointDistance:function(e,r,t,i,n,a,o,l,s){var u=this.nearestPoint(e,r,t,i,l,s);return Jr(u.x,u.y,l,s)},pointAt:function(e,r,t,i,n,a,o,l){var s=(o-a)*l+a;return{x:yL(e,r,t,i,n,s),y:mL(e,r,t,i,n,s)}},tangentAngle:function(e,r,t,i,n,a,o,l){var s=(o-a)*l+a,u=YZ(e,r,t,i,n,a,o,s),c=WZ(e,r,t,i,n,a,o,s);return Ap(Math.atan2(c,u))}};function CV(e){for(var r=0,t=[],i=0;i<e.length-1;i++){var n=e[i],a=e[i+1],o=Jr(n[0],n[1],a[0],a[1]),l={from:n,to:a,length:o};t.push(l),r+=o}return{segments:t,totalLength:r}}function SV(e){if(e.length<2)return 0;for(var r=0,t=0;t<e.length-1;t++){var i=e[t],n=e[t+1];r+=Jr(i[0],i[1],n[0],n[1])}return r}function AV(e,r){if(r>1||r<0||e.length<2)return null;var t=CV(e),i=t.segments,n=t.totalLength;if(n===0)return{x:e[0][0],y:e[0][1]};for(var a=0,o=null,l=0;l<i.length;l++){var s=i[l],u=s.from,c=s.to,f=s.length/n;if(r>=a&&r<=a+f){var h=(r-a)/f;o=Er.pointAt(u[0],u[1],c[0],c[1],h);break}a+=f}return o}function TV(e,r){if(r>1||r<0||e.length<2)return 0;for(var t=CV(e),i=t.segments,n=t.totalLength,a=0,o=0,l=0;l<i.length;l++){var s=i[l],u=s.from,c=s.to,f=s.length/n;if(r>=a&&r<=a+f){o=Math.atan2(c[1]-u[1],c[0]-u[0]);break}a+=f}return o}function MV(e,r,t){for(var i=1/0,n=0;n<e.length-1;n++){var a=e[n],o=e[n+1],l=Er.pointDistance(a[0],a[1],o[0],o[1],r,t);l<i&&(i=l)}return i}var u1={box:function(e){for(var r=[],t=[],i=0;i<e.length;i++){var n=e[i];r.push(n[0]),t.push(n[1])}return cc(r,t)},length:function(e){return SV(e)},pointAt:function(e,r){return AV(e,r)},pointDistance:function(e,r,t){return MV(e,r,t)},tangentAngle:function(e,r){return TV(e,r)}};function $y(e){var r=e.slice(0);return e.length&&r.push(e[0]),r}var ZZ={box:function(e){return u1.box(e)},length:function(e){return SV($y(e))},pointAt:function(e,r){return AV($y(e),r)},pointDistance:function(e,r,t){return MV($y(e),r,t)},tangentAngle:function(e,r){return TV($y(e),r)}},QZ=Object.freeze(Object.defineProperty({__proto__:null,Quad:EM,Cubic:Cf,Arc:wV,Line:Er,Polygon:ZZ,Polyline:u1,Util:zZ},Symbol.toStringTag,{value:"Module"}));function bL(e,r){return!e||!r?e||r:{minX:Math.min(e.minX,r.minX),minY:Math.min(e.minY,r.minY),maxX:Math.max(e.maxX,r.maxX),maxY:Math.max(e.maxY,r.maxY)}}function FM(e,r){var t=e.get("startArrowShape"),i=e.get("endArrowShape"),n=null,a=null;return t&&(n=t.getCanvasBBox(),r=bL(r,n)),i&&(a=i.getCanvasBBox(),r=bL(r,a)),r}function KZ(e){for(var r=e.attr(),t=r.points,i=[],n=[],a=0;a<t.length;a++){var o=t[a];i.push(o[0]),n.push(o[1])}var l=cc(i,n),s=l.x,u=l.y,c=l.width,f=l.height,h={minX:s,minY:u,maxX:s+c,maxY:u+f};return h=FM(e,h),{x:h.minX,y:h.minY,width:h.maxX-h.minX,height:h.maxY-h.minY}}function JZ(e){for(var r=e.attr(),t=r.points,i=[],n=[],a=0;a<t.length;a++){var o=t[a];i.push(o[0]),n.push(o[1])}return cc(i,n)}var zw=null;function Tp(){if(!zw){var e=document.createElement("canvas");e.width=1,e.height=1,zw=e.getContext("2d")}return zw}function Mp(e,r,t){var i=1;if(Ct(e)&&(i=e.split(`
|
|
`).length),i>1){var n=tQ(r,t);return r*i+n*(i-1)}return r}function tQ(e,r){return r?r-e:e*.14}function eQ(e,r){var t=Tp(),i=0;if(K(e)||e==="")return i;if(t.save(),t.font=r,Ct(e)&&e.includes(`
|
|
`)){var n=e.split(`
|
|
`);P(n,function(a){var o=t.measureText(a).width;i<o&&(i=o)})}else i=t.measureText(e).width;return t.restore(),i}function Ep(e){var r=e.fontSize,t=e.fontFamily,i=e.fontWeight,n=e.fontStyle,a=e.fontVariant;return[n,a,i,r+"px",t].join(" ").trim()}function rQ(e){var r=e.attr(),t=r.x,i=r.y,n=r.text,a=r.fontSize,o=r.lineHeight,l=r.font;l||(l=Ep(r));var s=eQ(n,l),u;if(!s)u={x:t,y:i,width:0,height:0};else{var c=r.textAlign,f=r.textBaseline,h=Mp(n,a,o),v={x:t,y:i-h};c&&(c==="end"||c==="right"?v.x-=s:c==="center"&&(v.x-=s/2)),f&&(f==="top"?v.y+=h:f==="middle"&&(v.y+=h/2)),u={x:v.x,y:v.y,width:s,height:h}}return u}var iQ=/[MLHVQTCSAZ]([^MLHVQTCSAZ]*)/ig,nQ=/[^\s\,]+/ig;function EV(e){var r=e||[];if(it(r))return r;if(Ct(r))return r=r.match(iQ),P(r,function(t,i){if(t=t.match(nQ),t[0].length>1){var n=t[0].charAt(0);t.splice(1,0,t[0].substr(1)),t[0]=n}P(t,function(a,o){isNaN(a)||(t[o]=+a)}),r[i]=t}),r}function aQ(e,r,t,i){var n=[],a=!!i,o,l,s,u,c,f,h;if(a){s=i[0],u=i[1];for(var v=0,d=e.length;v<d;v+=1){var p=e[v];s=Cr([0,0],s,p),u=Sr([0,0],u,p)}}for(var v=0,x=e.length;v<x;v+=1){var p=e[v];if(v===0&&!t)h=p;else if(v===x-1&&!t)f=p,n.push(h),n.push(f);else{var m=[v?v-1:x-1,v-1][t?0:1];o=e[m],l=e[t?(v+1)%x:v+1];var _=[0,0];_=Kl(_,l,o),_=pi(_,_,r);var b=cs(p,o),w=cs(p,l),S=b+w;S!==0&&(b/=S,w/=S);var M=pi([0,0],_,-b),F=pi([0,0],_,w);f=ma([0,0],p,M),c=ma([0,0],p,F),c=Cr([0,0],c,Sr([0,0],l,p)),c=Sr([0,0],c,Cr([0,0],l,p)),M=Kl([0,0],c,p),M=pi([0,0],M,-b/w),f=ma([0,0],p,M),f=Cr([0,0],f,Sr([0,0],o,p)),f=Sr([0,0],f,Cr([0,0],o,p)),F=Kl([0,0],p,f),F=pi([0,0],F,w/b),c=ma([0,0],p,F),a&&(f=Sr([0,0],f,s),f=Cr([0,0],f,u),c=Sr([0,0],c,s),c=Cr([0,0],c,u)),n.push(h),n.push(f),h=c}}return t&&n.push(n.shift()),n}function FV(e,r,t){r===void 0&&(r=!1),t===void 0&&(t=[[0,0],[1,1]]);for(var i=!!r,n=[],a=0,o=e.length;a<o;a+=2)n.push([e[a],e[a+1]]);for(var l=aQ(n,.4,i,t),s=n.length,u=[],c,f,h,a=0;a<s-1;a+=1)c=l[a*2],f=l[a*2+1],h=n[a+1],u.push(["C",c[0],c[1],f[0],f[1],h[0],h[1]]);return i&&(c=l[s],f=l[s+1],h=n[0],u.push(["C",c[0],c[1],f[0],f[1],h[0],h[1]])),u}function oQ(e,r){var t=[],i=[];function n(a,o){if(a.length===1)t.push(a[0]),i.push(a[0]);else{for(var l=[],s=0;s<a.length-1;s++)s===0&&t.push(a[0]),s===a.length-2&&i.push(a[s+1]),l[s]=[(1-o)*a[s][0]+o*a[s+1][0],(1-o)*a[s][1]+o*a[s+1][1]];n(l,o)}}return e.length&&n(e,r),{left:t,right:i.reverse()}}function lQ(e,r,t){var i=[[e[1],e[2]]];t=t||2;var n=[];r[0]==="A"?(i.push(r[6]),i.push(r[7])):r[0]==="C"?(i.push([r[1],r[2]]),i.push([r[3],r[4]]),i.push([r[5],r[6]])):r[0]==="S"||r[0]==="Q"?(i.push([r[1],r[2]]),i.push([r[3],r[4]])):i.push([r[1],r[2]]);for(var a=i,o=1/t,l=0;l<t-1;l++){var s=o/(1-o*l),u=oQ(a,s);n.push(u.left),a=u.right}n.push(a);var c=n.map(function(f){var h=[];return f.length===4&&(h.push("C"),h=h.concat(f[2])),f.length>=3&&(f.length===3&&h.push("Q"),h=h.concat(f[1])),f.length===2&&h.push("L"),h=h.concat(f[f.length-1]),h});return c}function sQ(e,r,t){if(t===1)return[[].concat(e)];var i=[];if(r[0]==="L"||r[0]==="C"||r[0]==="Q")i=i.concat(lQ(e,r,t));else{var n=[].concat(e);n[0]==="M"&&(n[0]="L");for(var a=0;a<=t-1;a++)i.push(n)}return i}function uQ(e,r){if(e.length===1)return e;var t=e.length-1,i=r.length-1,n=t/i,a=[];if(e.length===1&&e[0][0]==="M"){for(var o=0;o<i-t;o++)e.push(e[0]);return e}for(var o=0;o<i;o++){var l=Math.floor(n*o);a[l]=(a[l]||0)+1}var s=a.reduce(function(u,c,f){return f===t?u.concat(e[t]):u.concat(sQ(e[f],e[f+1],c))},[]);return s.unshift(e[0]),(r[i]==="Z"||r[i]==="z")&&s.push("Z"),s}function cQ(e,r,t){var i=null,n=t;return r<n&&(n=r,i="add"),e<n&&(n=e,i="del"),{type:i,min:n}}var fQ=function(e,r){var t=e.length,i=r.length,n,a,o=0;if(t===0||i===0)return null;for(var l=[],s=0;s<=t;s++)l[s]=[],l[s][0]={min:s};for(var u=0;u<=i;u++)l[0][u]={min:u};for(var s=1;s<=t;s++){n=e[s-1];for(var u=1;u<=i;u++){a=r[u-1],Ge(n,a)?o=0:o=1;var c=l[s-1][u].min+1,f=l[s][u-1].min+1,h=l[s-1][u-1].min+o;l[s][u]=cQ(c,f,h)}}return l};function hQ(e,r){var t=fQ(e,r),i=e.length,n=r.length,a=[],o=1,l=1;if(t[i][n]!==i){for(var s=1;s<=i;s++){var u=t[s][s].min;l=s;for(var c=o;c<=n;c++)t[s][c].min<u&&(u=t[s][c].min,l=c);o=l,t[s][o].type&&a.push({index:s-1,type:t[s][o].type})}for(var s=a.length-1;s>=0;s--)o=a[s].index,a[s].type==="add"?e.splice(o,0,[].concat(e[o])):e.splice(o,1)}if(i=e.length,i<n)for(var s=0;s<n-i;s++)e[i-1][0]==="z"||e[i-1][0]==="Z"?e.splice(i-2,0,e[i-2]):e.push(e[i-1]);return e}function OV(e){var r=[];switch(e[0]){case"M":r.push([e[1],e[2]]);break;case"L":r.push([e[1],e[2]]);break;case"A":r.push([e[6],e[7]]);break;case"Q":r.push([e[3],e[4]]),r.push([e[1],e[2]]);break;case"T":r.push([e[1],e[2]]);break;case"C":r.push([e[5],e[6]]),r.push([e[1],e[2]]),r.push([e[3],e[4]]);break;case"S":r.push([e[3],e[4]]),r.push([e[1],e[2]]);break;case"H":r.push([e[1],e[1]]);break;case"V":r.push([e[1],e[1]]);break}return r}function Vw(e,r,t){for(var i=[].concat(e),n,a=1/(t+1),o=OV(r)[0],l=1;l<=t;l++)a*=l,n=Math.floor(e.length*a),n===0?i.unshift([o[0]*a+e[n][0]*(1-a),o[1]*a+e[n][1]*(1-a)]):i.splice(n,0,[o[0]*a+e[n][0]*(1-a),o[1]*a+e[n][1]*(1-a)]);return i}function vQ(e,r){if(e.length<=1)return e;for(var t,i=0;i<r.length;i++)if(e[i][0]!==r[i][0])switch(t=OV(e[i]),r[i][0]){case"M":e[i]=["M"].concat(t[0]);break;case"L":e[i]=["L"].concat(t[0]);break;case"A":e[i]=[].concat(r[i]),e[i][6]=t[0][0],e[i][7]=t[0][1];break;case"Q":if(t.length<2)if(i>0)t=Vw(t,e[i-1],1);else{e[i]=r[i];break}e[i]=["Q"].concat(t.reduce(function(n,a){return n.concat(a)},[]));break;case"T":e[i]=["T"].concat(t[0]);break;case"C":if(t.length<3)if(i>0)t=Vw(t,e[i-1],2);else{e[i]=r[i];break}e[i]=["C"].concat(t.reduce(function(n,a){return n.concat(a)},[]));break;case"S":if(t.length<2)if(i>0)t=Vw(t,e[i-1],1);else{e[i]=r[i];break}e[i]=["S"].concat(t.reduce(function(n,a){return n.concat(a)},[]));break;default:e[i]=r[i]}return e}function PV(e,r,t,i,n){return n?[["M",+e+ +n,r],["l",t-n*2,0],["a",n,n,0,0,1,n,n],["l",0,i-n*2],["a",n,n,0,0,1,-n,n],["l",n*2-t,0],["a",n,n,0,0,1,-n,-n],["l",0,n*2-i],["a",n,n,0,0,1,n,-n],["z"]]:[["M",e,r],["l",t,0],["l",0,i],["l",-t,0],["z"]]}var hd=`
|
|
\v\f\r \xA0\u1680\u180E\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029`,dQ=new RegExp("([a-z])["+hd+",]*((-?\\d*\\.?\\d*(?:e[\\-+]?\\d+)?["+hd+"]*,?["+hd+"]*)+)","ig"),pQ=new RegExp("(-?\\d*\\.?\\d*(?:e[\\-+]?\\d+)?)["+hd+"]*,?["+hd+"]*","ig");function c1(e){if(!e)return null;if(it(e))return e;var r={a:7,c:6,o:2,h:1,l:2,m:2,r:4,q:4,s:4,t:2,v:1,u:3,z:0},t=[];return String(e).replace(dQ,function(i,n,a){var o=[],l=n.toLowerCase();if(a.replace(pQ,function(s,u){u&&o.push(+u)}),l==="m"&&o.length>2&&(t.push([n].concat(o.splice(0,2))),l="l",n=n==="m"?"l":"L"),l==="o"&&o.length===1&&t.push([n,o[0]]),l==="r")t.push([n].concat(o));else for(;o.length>=r[l]&&(t.push([n].concat(o.splice(0,r[l]))),!!r[l]););return""}),t}var gQ=/[a-z]/;function wL(e,r){return[r[0]+(r[0]-e[0]),r[1]+(r[1]-e[1])]}function f1(e){var r=c1(e);if(!r||!r.length)return[["M",0,0]];for(var t=!1,i=0;i<r.length;i++){var n=r[i][0];if(gQ.test(n)||["V","H","T","S"].indexOf(n)>=0){t=!0;break}}if(!t)return r;var a=[],o=0,l=0,s=0,u=0,c=0,f=r[0];(f[0]==="M"||f[0]==="m")&&(o=+f[1],l=+f[2],s=o,u=l,c++,a[0]=["M",o,l]);for(var i=c,h=r.length;i<h;i++){var v=r[i],d=a[i-1],p=[],n=v[0],x=n.toUpperCase();if(n!==x)switch(p[0]=x,x){case"A":p[1]=v[1],p[2]=v[2],p[3]=v[3],p[4]=v[4],p[5]=v[5],p[6]=+v[6]+o,p[7]=+v[7]+l;break;case"V":p[1]=+v[1]+l;break;case"H":p[1]=+v[1]+o;break;case"M":s=+v[1]+o,u=+v[2]+l,p[1]=s,p[2]=u;break;default:for(var m=1,_=v.length;m<_;m++)p[m]=+v[m]+(m%2?o:l)}else p=r[i];switch(x){case"Z":o=+s,l=+u;break;case"H":o=p[1],p=["L",o,l];break;case"V":l=p[1],p=["L",o,l];break;case"T":o=p[1],l=p[2];var b=wL([d[1],d[2]],[d[3],d[4]]);p=["Q",b[0],b[1],o,l];break;case"S":o=p[p.length-2],l=p[p.length-1];var w=d.length,S=wL([d[w-4],d[w-3]],[d[w-2],d[w-1]]);p=["C",S[0],S[1],p[1],p[2],o,l];break;case"M":s=p[p.length-2],u=p[p.length-1];break;default:o=p[p.length-2],l=p[p.length-1]}a.push(p)}return a}var vd=Math.PI*2,jw=function(e,r,t,i,n,a,o){var l=e.x,s=e.y;l*=r,s*=t;var u=i*l-n*s,c=n*l+i*s;return{x:u+a,y:c+o}},yQ=function(e,r){var t=r===1.5707963267948966?.551915024494:r===-1.5707963267948966?-.551915024494:1.3333333333333333*Math.tan(r/4),i=Math.cos(e),n=Math.sin(e),a=Math.cos(e+r),o=Math.sin(e+r);return[{x:i-n*t,y:n+i*t},{x:a+o*t,y:o-a*t},{x:a,y:o}]},CL=function(e,r,t,i){var n=e*i-r*t<0?-1:1,a=e*t+r*i;return a>1&&(a=1),a<-1&&(a=-1),n*Math.acos(a)},mQ=function(e,r,t,i,n,a,o,l,s,u,c,f){var h=Math.pow(n,2),v=Math.pow(a,2),d=Math.pow(c,2),p=Math.pow(f,2),x=h*v-h*p-v*d;x<0&&(x=0),x/=h*p+v*d,x=Math.sqrt(x)*(o===l?-1:1);var m=x*n/a*f,_=x*-a/n*c,b=u*m-s*_+(e+t)/2,w=s*m+u*_+(r+i)/2,S=(c-m)/n,M=(f-_)/a,F=(-c-m)/n,O=(-f-_)/a,L=CL(1,0,S,M),D=CL(S,M,F,O);return l===0&&D>0&&(D-=vd),l===1&&D<0&&(D+=vd),[b,w,L,D]},xQ=function(e){var r=e.px,t=e.py,i=e.cx,n=e.cy,a=e.rx,o=e.ry,l=e.xAxisRotation,s=l===void 0?0:l,u=e.largeArcFlag,c=u===void 0?0:u,f=e.sweepFlag,h=f===void 0?0:f,v=[];if(a===0||o===0)return[{x1:0,y1:0,x2:0,y2:0,x:i,y:n}];var d=Math.sin(s*vd/360),p=Math.cos(s*vd/360),x=p*(r-i)/2+d*(t-n)/2,m=-d*(r-i)/2+p*(t-n)/2;if(x===0&&m===0)return[{x1:0,y1:0,x2:0,y2:0,x:i,y:n}];a=Math.abs(a),o=Math.abs(o);var _=Math.pow(x,2)/Math.pow(a,2)+Math.pow(m,2)/Math.pow(o,2);_>1&&(a*=Math.sqrt(_),o*=Math.sqrt(_));var b=mQ(r,t,i,n,a,o,c,h,d,p,x,m),w=b[0],S=b[1],M=b[2],F=b[3],O=Math.abs(F)/(vd/4);Math.abs(1-O)<1e-7&&(O=1);var L=Math.max(Math.ceil(O),1);F/=L;for(var D=0;D<L;D++)v.push(yQ(M,F)),M+=F;return v.map(function(k){var H=jw(k[0],a,o,p,d,w,S),B=H.x,j=H.y,U=jw(k[1],a,o,p,d,w,S),R=U.x,G=U.y,N=jw(k[2],a,o,p,d,w,S),W=N.x,q=N.y;return{x1:B,y1:j,x2:R,y2:G,x:W,y:q}})};function _Q(e,r,t,i,n,a,o,l,s){var u=xQ({px:e,py:r,cx:l,cy:s,rx:t,ry:i,xAxisRotation:n,largeArcFlag:a,sweepFlag:o});return u.reduce(function(c,f){var h=f.x1,v=f.y1,d=f.x2,p=f.y2,x=f.x,m=f.y;return c.push(h,v,d,p,x,m),c},[])}function bQ(e,r,t,i,n,a){var o=.3333333333333333,l=2/3;return[o*e+l*t,o*r+l*i,o*n+l*t,o*a+l*i,n,a]}function ky(e,r,t,i){return[e,r,t,i,t,i]}function wQ(e,r){"TQ".indexOf(e[0])<0&&(r.qx=null,r.qy=null);var t=e.slice(1),i=t[0],n=t[1];switch(e[0]){case"M":return r.x=i,r.y=n,e;case"A":return["C"].concat(_Q.apply(0,[r.x1,r.y1].concat(e.slice(1))));case"Q":return r.qx=i,r.qy=n,["C"].concat(bQ.apply(0,[r.x1,r.y1].concat(e.slice(1))));case"L":return["C"].concat(ky(r.x1,r.y1,e[1],e[2]));case"H":return["C"].concat(ky(r.x1,r.y1,e[1],r.y1));case"V":return["C"].concat(ky(r.x1,r.y1,r.x1,e[1]));case"Z":return["C"].concat(ky(r.x1,r.y1,r.x,r.y))}return e}function AA(e,r){r===void 0&&(r=!1);for(var t=f1(e),i={x1:0,y1:0,x2:0,y2:0,x:0,y:0,qx:null,qy:null},n=[],a="",o=t.length,l,s,u=[],c=0;c<o;c+=1)t[c]&&(a=t[c][0]),n[c]=a,t[c]=wQ(t[c],i),CQ(t,n,c),o=t.length,a==="Z"&&u.push(c),l=t[c],s=l.length,i.x1=+l[s-2],i.y1=+l[s-1],i.x2=+l[s-4]||i.x1,i.y2=+l[s-3]||i.y1;return r?[t,u]:t}function CQ(e,r,t){if(e[t].length>7){e[t].shift();for(var i=e[t],n=t;i.length;)r[t]="A",e.splice(n+=1,0,["C"].concat(i.splice(0,6)));e.splice(t,1)}}var SL=function(e,r,t,i,n){var a=-3*r+9*t-9*i+3*n,o=e*a+6*r-12*t+6*i;return e*o-3*r+3*t},AL=function(e,r,t,i,n,a,o,l,s){s===null&&(s=1),s=s>1?1:s<0?0:s;for(var u=s/2,c=12,f=[-.1252,.1252,-.3678,.3678,-.5873,.5873,-.7699,.7699,-.9041,.9041,-.9816,.9816],h=[.2491,.2491,.2335,.2335,.2032,.2032,.1601,.1601,.1069,.1069,.0472,.0472],v=0,d=0;d<c;d++){var p=u*f[d]+u,x=SL(p,e,t,n,o),m=SL(p,r,i,a,l),_=x*x+m*m;v+=h[d]*Math.sqrt(_)}return u*v},SQ=function(e,r,t,i,n,a,o,l){for(var s=[],u=[[],[]],c,f,h,v,d=0;d<2;++d){if(d===0?(f=6*e-12*t+6*n,c=-3*e+9*t-9*n+3*o,h=3*t-3*e):(f=6*r-12*i+6*a,c=-3*r+9*i-9*a+3*l,h=3*i-3*r),Math.abs(c)<1e-12){if(Math.abs(f)<1e-12)continue;v=-h/f,v>0&&v<1&&s.push(v);continue}var p=f*f-4*h*c,x=Math.sqrt(p);if(!(p<0)){var m=(-f+x)/(2*c);m>0&&m<1&&s.push(m);var _=(-f-x)/(2*c);_>0&&_<1&&s.push(_)}}for(var b=s.length,w=b,S;b--;)v=s[b],S=1-v,u[0][b]=S*S*S*e+3*S*S*v*t+3*S*v*v*n+v*v*v*o,u[1][b]=S*S*S*r+3*S*S*v*i+3*S*v*v*a+v*v*v*l;return u[0][w]=e,u[1][w]=r,u[0][w+1]=o,u[1][w+1]=l,u[0].length=u[1].length=w+2,{min:{x:Math.min.apply(0,u[0]),y:Math.min.apply(0,u[1])},max:{x:Math.max.apply(0,u[0]),y:Math.max.apply(0,u[1])}}},AQ=function(e,r,t,i,n,a,o,l){if(!(Math.max(e,t)<Math.min(n,o)||Math.min(e,t)>Math.max(n,o)||Math.max(r,i)<Math.min(a,l)||Math.min(r,i)>Math.max(a,l))){var s=(e*i-r*t)*(n-o)-(e-t)*(n*l-a*o),u=(e*i-r*t)*(a-l)-(r-i)*(n*l-a*o),c=(e-t)*(a-l)-(r-i)*(n-o);if(!!c){var f=s/c,h=u/c,v=+f.toFixed(2),d=+h.toFixed(2);if(!(v<+Math.min(e,t).toFixed(2)||v>+Math.max(e,t).toFixed(2)||v<+Math.min(n,o).toFixed(2)||v>+Math.max(n,o).toFixed(2)||d<+Math.min(r,i).toFixed(2)||d>+Math.max(r,i).toFixed(2)||d<+Math.min(a,l).toFixed(2)||d>+Math.max(a,l).toFixed(2)))return{x:f,y:h}}}},Sl=function(e,r,t){return r>=e.x&&r<=e.x+e.width&&t>=e.y&&t<=e.y+e.height},TA=function(e,r,t,i){return e===null&&(e=r=t=i=0),r===null&&(r=e.y,t=e.width,i=e.height,e=e.x),{x:e,y:r,width:t,w:t,height:i,h:i,x2:e+t,y2:r+i,cx:e+t/2,cy:r+i/2,r1:Math.min(t,i)/2,r2:Math.max(t,i)/2,r0:Math.sqrt(t*t+i*i)/2,path:PV(e,r,t,i),vb:[e,r,t,i].join(" ")}},TQ=function(e,r){return e=TA(e),r=TA(r),Sl(r,e.x,e.y)||Sl(r,e.x2,e.y)||Sl(r,e.x,e.y2)||Sl(r,e.x2,e.y2)||Sl(e,r.x,r.y)||Sl(e,r.x2,r.y)||Sl(e,r.x,r.y2)||Sl(e,r.x2,r.y2)||(e.x<r.x2&&e.x>r.x||r.x<e.x2&&r.x>e.x)&&(e.y<r.y2&&e.y>r.y||r.y<e.y2&&r.y>e.y)},TL=function(e,r,t,i,n,a,o,l){it(e)||(e=[e,r,t,i,n,a,o,l]);var s=SQ.apply(null,e);return TA(s.min.x,s.min.y,s.max.x-s.min.x,s.max.y-s.min.y)},ML=function(e,r,t,i,n,a,o,l,s){var u=1-s,c=Math.pow(u,3),f=Math.pow(u,2),h=s*s,v=h*s,d=c*e+f*3*s*t+u*3*s*s*n+v*o,p=c*r+f*3*s*i+u*3*s*s*a+v*l,x=e+2*s*(t-e)+h*(n-2*t+e),m=r+2*s*(i-r)+h*(a-2*i+r),_=t+2*s*(n-t)+h*(o-2*n+t),b=i+2*s*(a-i)+h*(l-2*a+i),w=u*e+s*t,S=u*r+s*i,M=u*n+s*o,F=u*a+s*l,O=90-Math.atan2(x-_,m-b)*180/Math.PI;return{x:d,y:p,m:{x,y:m},n:{x:_,y:b},start:{x:w,y:S},end:{x:M,y:F},alpha:O}},MQ=function(e,r,t){var i=TL(e),n=TL(r);if(!TQ(i,n))return t?0:[];for(var a=AL.apply(0,e),o=AL.apply(0,r),l=~~(a/8),s=~~(o/8),u=[],c=[],f={},h=t?0:[],v=0;v<l+1;v++){var d=ML.apply(0,e.concat(v/l));u.push({x:d.x,y:d.y,t:v/l})}for(var v=0;v<s+1;v++){var d=ML.apply(0,r.concat(v/s));c.push({x:d.x,y:d.y,t:v/s})}for(var v=0;v<l;v++)for(var p=0;p<s;p++){var x=u[v],m=u[v+1],_=c[p],b=c[p+1],w=Math.abs(m.x-x.x)<.001?"y":"x",S=Math.abs(b.x-_.x)<.001?"y":"x",M=AQ(x.x,x.y,m.x,m.y,_.x,_.y,b.x,b.y);if(M){if(f[M.x.toFixed(4)]===M.y.toFixed(4))continue;f[M.x.toFixed(4)]=M.y.toFixed(4);var F=x.t+Math.abs((M[w]-x[w])/(m[w]-x[w]))*(m.t-x.t),O=_.t+Math.abs((M[S]-_[S])/(b[S]-_[S]))*(b.t-_.t);F>=0&&F<=1&&O>=0&&O<=1&&(t?h++:h.push({x:M.x,y:M.y,t1:F,t2:O}))}}return h},EQ=function(e,r,t){e=AA(e),r=AA(r);for(var i,n,a,o,l,s,u,c,f,h,v=t?0:[],d=0,p=e.length;d<p;d++){var x=e[d];if(x[0]==="M")i=l=x[1],n=s=x[2];else{x[0]==="C"?(f=[i,n].concat(x.slice(1)),i=f[6],n=f[7]):(f=[i,n,i,n,l,s,l,s],i=l,n=s);for(var m=0,_=r.length;m<_;m++){var b=r[m];if(b[0]==="M")a=u=b[1],o=c=b[2];else{b[0]==="C"?(h=[a,o].concat(b.slice(1)),a=h[6],o=h[7]):(h=[a,o,a,o,u,c,u,c],a=u,o=c);var w=MQ(f,h,t);if(t)v+=w;else{for(var S=0,M=w.length;S<M;S++)w[S].segment1=d,w[S].segment2=m,w[S].bez1=f,w[S].bez2=h;v=v.concat(w)}}}}}return v};function FQ(e,r){return EQ(e,r)}var OQ=/,?([a-z]),?/gi;function PQ(e){return e.join(",").replace(OQ,"$1")}function Ry(e){return Math.sqrt(e[0]*e[0]+e[1]*e[1])}function MA(e,r){return Ry(e)*Ry(r)?(e[0]*r[0]+e[1]*r[1])/(Ry(e)*Ry(r)):1}function EL(e,r){return(e[0]*r[1]<e[1]*r[0]?-1:1)*Math.acos(MA(e,r))}function EA(e,r){return e[0]===r[0]&&e[1]===r[1]}function IV(e,r){var t=r[1],i=r[2],n=Kx(Jx(r[3]),Math.PI*2),a=r[4],o=r[5],l=e[0],s=e[1],u=r[6],c=r[7],f=Math.cos(n)*(l-u)/2+Math.sin(n)*(s-c)/2,h=-1*Math.sin(n)*(l-u)/2+Math.cos(n)*(s-c)/2,v=f*f/(t*t)+h*h/(i*i);v>1&&(t*=Math.sqrt(v),i*=Math.sqrt(v));var d=t*t*(h*h)+i*i*(f*f),p=d?Math.sqrt((t*t*(i*i)-d)/d):1;a===o&&(p*=-1),isNaN(p)&&(p=0);var x=i?p*t*h/i:0,m=t?p*-i*f/t:0,_=(l+u)/2+Math.cos(n)*x-Math.sin(n)*m,b=(s+c)/2+Math.sin(n)*x+Math.cos(n)*m,w=[(f-x)/t,(h-m)/i],S=[(-1*f-x)/t,(-1*h-m)/i],M=EL([1,0],w),F=EL(w,S);return MA(w,S)<=-1&&(F=Math.PI),MA(w,S)>=1&&(F=0),o===0&&F>0&&(F=F-2*Math.PI),o===1&&F<0&&(F=F+2*Math.PI),{cx:_,cy:b,rx:EA(e,[u,c])?0:t,ry:EA(e,[u,c])?0:i,startAngle:M,endAngle:M+F,xRotation:n,arcFlag:a,sweepFlag:o}}function FL(e,r){return[r[0]+(r[0]-e[0]),r[1]+(r[1]-e[1])]}function OM(e){e=EV(e);for(var r=[],t=null,i=null,n=null,a=0,o=e.length,l=0;l<o;l++){var s=e[l];i=e[l+1];var u=s[0],c={command:u,prePoint:t,params:s,startTangent:null,endTangent:null};switch(u){case"M":n=[s[1],s[2]],a=l;break;case"A":var f=IV(t,s);c.arcParams=f;break}if(u==="Z")t=n,i=e[a+1];else{var h=s.length;t=[s[h-2],s[h-1]]}i&&i[0]==="Z"&&(i=e[a],r[a]&&(r[a].prePoint=t)),c.currentPoint=t,r[a]&&EA(t,r[a].currentPoint)&&(r[a].prePoint=c.prePoint);var v=i?[i[i.length-2],i[i.length-1]]:null;c.nextPoint=v;var d=c.prePoint;if(["L","H","V"].includes(u))c.startTangent=[d[0]-t[0],d[1]-t[1]],c.endTangent=[t[0]-d[0],t[1]-d[1]];else if(u==="Q"){var p=[s[1],s[2]];c.startTangent=[d[0]-p[0],d[1]-p[1]],c.endTangent=[t[0]-p[0],t[1]-p[1]]}else if(u==="T"){var x=r[l-1],p=FL(x.currentPoint,d);x.command==="Q"?(c.command="Q",c.startTangent=[d[0]-p[0],d[1]-p[1]],c.endTangent=[t[0]-p[0],t[1]-p[1]]):(c.command="TL",c.startTangent=[d[0]-t[0],d[1]-t[1]],c.endTangent=[t[0]-d[0],t[1]-d[1]])}else if(u==="C"){var m=[s[1],s[2]],_=[s[3],s[4]];c.startTangent=[d[0]-m[0],d[1]-m[1]],c.endTangent=[t[0]-_[0],t[1]-_[1]],c.startTangent[0]===0&&c.startTangent[1]===0&&(c.startTangent=[m[0]-_[0],m[1]-_[1]]),c.endTangent[0]===0&&c.endTangent[1]===0&&(c.endTangent=[_[0]-m[0],_[1]-m[1]])}else if(u==="S"){var x=r[l-1],m=FL(x.currentPoint,d),_=[s[1],s[2]];x.command==="C"?(c.command="C",c.startTangent=[d[0]-m[0],d[1]-m[1]],c.endTangent=[t[0]-_[0],t[1]-_[1]]):(c.command="SQ",c.startTangent=[d[0]-_[0],d[1]-_[1]],c.endTangent=[t[0]-_[0],t[1]-_[1]])}else if(u==="A"){var b=.001,w=c.arcParams||{},S=w.cx,M=S===void 0?0:S,F=w.cy,O=F===void 0?0:F,L=w.rx,D=L===void 0?0:L,k=w.ry,H=k===void 0?0:k,B=w.sweepFlag,j=B===void 0?0:B,U=w.startAngle,R=U===void 0?0:U,G=w.endAngle,N=G===void 0?0:G;j===0&&(b*=-1);var W=D*Math.cos(R-b)+M,q=H*Math.sin(R-b)+O;c.startTangent=[W-n[0],q-n[1]];var tt=D*Math.cos(R+N+b)+M,ot=H*Math.sin(R+N-b)+O;c.endTangent=[d[0]-tt,d[1]-ot]}r.push(c)}return r}var OL=function(e,r,t){return e>=r&&e<=t};function LV(e,r,t,i){var n=.001,a={x:t.x-e.x,y:t.y-e.y},o={x:r.x-e.x,y:r.y-e.y},l={x:i.x-t.x,y:i.y-t.y},s=o.x*l.y-o.y*l.x,u=s*s,c=o.x*o.x+o.y*o.y,f=l.x*l.x+l.y*l.y,h=null;if(u>n*c*f){var v=(a.x*l.y-a.y*l.x)/s,d=(a.x*o.y-a.y*o.x)/s;OL(v,0,1)&&OL(d,0,1)&&(h={x:e.x+v*o.x,y:e.y+v*o.y})}return h}var IQ=1e-6;function Hw(e){return Math.abs(e)<IQ?0:e<0?-1:1}function LQ(e,r,t){return(t[0]-e[0])*(r[1]-e[1])===(r[0]-e[0])*(t[1]-e[1])&&Math.min(e[0],r[0])<=t[0]&&t[0]<=Math.max(e[0],r[0])&&Math.min(e[1],r[1])<=t[1]&&t[1]<=Math.max(e[1],r[1])}function FA(e,r,t){var i=!1,n=e.length;if(n<=2)return!1;for(var a=0;a<n;a++){var o=e[a],l=e[(a+1)%n];if(LQ(o,l,[r,t]))return!0;Hw(o[1]-t)>0!=Hw(l[1]-t)>0&&Hw(r-(t-o[1])*(o[0]-l[0])/(o[1]-l[1])-o[0])<0&&(i=!i)}return i}function PL(e){for(var r=[],t=e.length,i=0;i<t-1;i++){var n=e[i],a=e[i+1];r.push({from:{x:n[0],y:n[1]},to:{x:a[0],y:a[1]}})}if(r.length>1){var o=e[0],l=e[t-1];r.push({from:{x:l[0],y:l[1]},to:{x:o[0],y:o[1]}})}return r}function DQ(e,r){var t=!1;return P(e,function(i){if(LV(i.from,i.to,r.from,r.to))return t=!0,!1}),t}function IL(e){var r=e.map(function(i){return i[0]}),t=e.map(function(i){return i[1]});return{minX:Math.min.apply(null,r),maxX:Math.max.apply(null,r),minY:Math.min.apply(null,t),maxY:Math.max.apply(null,t)}}function $Q(e,r){return!(r.minX>e.maxX||r.maxX<e.minX||r.minY>e.maxY||r.maxY<e.minY)}function DV(e,r){if(e.length<2||r.length<2)return!1;var t=IL(e),i=IL(r);if(!$Q(t,i))return!1;var n=!1;if(P(r,function(s){if(FA(e,s[0],s[1]))return n=!0,!1}),n||(P(e,function(s){if(FA(r,s[0],s[1]))return n=!0,!1}),n))return!0;var a=PL(e),o=PL(r),l=!1;return P(o,function(s){if(DQ(a,s))return l=!0,!1}),l}var kQ=Object.freeze(Object.defineProperty({__proto__:null,parsePath:EV,catmullRom2Bezier:FV,fillPath:uQ,fillPathByDiff:hQ,formatPath:vQ,pathIntersection:FQ,parsePathArray:PQ,parsePathString:c1,path2Curve:AA,path2Absolute:f1,reactPath:PV,getArcParams:IV,path2Segments:OM,getLineIntersect:LV,isPolygonsIntersect:DV,isPointInPolygon:FA},Symbol.toStringTag,{value:"Module"}));function RQ(e,r){for(var t=[],i=[],n=[],a=0;a<e.length;a++){var o=e[a],l=o.currentPoint,s=o.params,u=o.prePoint,c=void 0;switch(o.command){case"Q":c=EM.box(u[0],u[1],s[1],s[2],s[3],s[4]);break;case"C":c=Cf.box(u[0],u[1],s[1],s[2],s[3],s[4],s[5],s[6]);break;case"A":var f=o.arcParams;c=wV.box(f.cx,f.cy,f.rx,f.ry,f.xRotation,f.startAngle,f.endAngle);break;default:t.push(l[0]),i.push(l[1]);break}c&&(o.box=c,t.push(c.x,c.x+c.width),i.push(c.y,c.y+c.height)),r&&(o.command==="L"||o.command==="M")&&o.prePoint&&o.nextPoint&&n.push(o)}t=t.filter(function(m){return!Number.isNaN(m)&&m!==1/0&&m!==-1/0}),i=i.filter(function(m){return!Number.isNaN(m)&&m!==1/0&&m!==-1/0});var h=Or(t),v=Or(i),d=gr(t),p=gr(i);if(n.length===0)return{x:h,y:v,width:d-h,height:p-v};for(var a=0;a<n.length;a++){var o=n[a],l=o.currentPoint,x=void 0;l[0]===h?(x=By(o,r),h=h-x.xExtra):l[0]===d&&(x=By(o,r),d=d+x.xExtra),l[1]===v?(x=By(o,r),v=v-x.yExtra):l[1]===p&&(x=By(o,r),p=p+x.yExtra)}return{x:h,y:v,width:d-h,height:p-v}}function By(e,r){var t=e.prePoint,i=e.currentPoint,n=e.nextPoint,a=Math.pow(i[0]-t[0],2)+Math.pow(i[1]-t[1],2),o=Math.pow(i[0]-n[0],2)+Math.pow(i[1]-n[1],2),l=Math.pow(t[0]-n[0],2)+Math.pow(t[1]-n[1],2),s=Math.acos((a+o-l)/(2*Math.sqrt(a)*Math.sqrt(o)));if(!s||Math.sin(s)===0||zr(s,0))return{xExtra:0,yExtra:0};var u=Math.abs(Math.atan2(n[1]-i[1],n[0]-i[0])),c=Math.abs(Math.atan2(n[0]-i[0],n[1]-i[1]));u=u>Math.PI/2?Math.PI-u:u,c=c>Math.PI/2?Math.PI-c:c;var f={xExtra:Math.cos(s/2-u)*(r/2*(1/Math.sin(s/2)))-r/2||0,yExtra:Math.cos(c-s/2)*(r/2*(1/Math.sin(s/2)))-r/2||0};return f}function BQ(e){var r=e.attr(),t=r.path,i=r.stroke,n=i?r.lineWidth:0,a=e.get("segments")||OM(t),o=RQ(a,n),l=o.x,s=o.y,u=o.width,c=o.height,f={minX:l,minY:s,maxX:l+u,maxY:s+c};return f=FM(e,f),{x:f.minX,y:f.minY,width:f.maxX-f.minX,height:f.maxY-f.minY}}function NQ(e){var r=e.attr(),t=r.x1,i=r.y1,n=r.x2,a=r.y2,o=Math.min(t,n),l=Math.max(t,n),s=Math.min(i,a),u=Math.max(i,a),c={minX:o,maxX:l,minY:s,maxY:u};return c=FM(e,c),{x:c.minX,y:c.minY,width:c.maxX-c.minX,height:c.maxY-c.minY}}function GQ(e){var r=e.attr(),t=r.x,i=r.y,n=r.rx,a=r.ry;return{x:t-n,y:i-a,width:n*2,height:a*2}}wn("rect",yV);wn("image",yV);wn("circle",mV);wn("marker",mV);wn("polyline",KZ);wn("polygon",JZ);wn("text",rQ);wn("path",BQ);wn("line",NQ);wn("ellipse",GQ);var zQ="0.5.11",VQ=Object.freeze(Object.defineProperty({__proto__:null,PathUtil:a1,version:zQ,Event:bh,Base:mp,AbstractCanvas:bp,AbstractGroup:wp,AbstractShape:Cp,getBBoxMethod:Sp,registerBBox:wn,getTextHeight:Mp,assembleFont:Ep,isAllowCapture:$f,multiplyVec2:ro,invert:xp,getOffScreenContext:Tp,registerEasing:MM},Symbol.toStringTag,{value:"Module"})),ii=br(VQ);Object.defineProperty(Ut,"__esModule",{value:!0});Ut.clipTextTwoLines=Ut.getTextWidth=Ut.getTextPoint=Ut.toPx=Ut.updateClip=Ut.getBBoxWithClip=Ut.mergeBBox=Ut.intersectBBox=Ut.near=Ut.wait=Ut.distance=Ut.getCirclePoint=Ut.getValueByPercent=Ut.createBBox=Ut.pointsToBBox=Ut.regionToBBox=Ut.hasClass=$V=Ut.clearDom=Ut.formatPadding=void 0;var jQ=ii,Vo=Y;function HQ(e){var r=0,t=0,i=0,n=0;return Vo.isNumber(e)?r=t=i=n=e:Vo.isArray(e)&&(r=e[0],i=Vo.isNil(e[1])?e[0]:e[1],n=Vo.isNil(e[2])?e[0]:e[2],t=Vo.isNil(e[3])?i:e[3]),[r,i,n,t]}Ut.formatPadding=HQ;function YQ(e){for(var r=e.childNodes,t=r.length,i=t-1;i>=0;i--)e.removeChild(r[i])}var $V=Ut.clearDom=YQ;function WQ(e,r){return!!e.className.match(new RegExp("(\\s|^)"+r+"(\\s|$)"))}Ut.hasClass=WQ;function XQ(e){var r=e.start,t=e.end,i=Math.min(r.x,t.x),n=Math.min(r.y,t.y),a=Math.max(r.x,t.x),o=Math.max(r.y,t.y);return{x:i,y:n,minX:i,minY:n,maxX:a,maxY:o,width:a-i,height:o-n}}Ut.regionToBBox=XQ;function UQ(e){var r=e.map(function(l){return l.x}),t=e.map(function(l){return l.y}),i=Math.min.apply(Math,r),n=Math.min.apply(Math,t),a=Math.max.apply(Math,r),o=Math.max.apply(Math,t);return{x:i,y:n,minX:i,minY:n,maxX:a,maxY:o,width:a-i,height:o-n}}Ut.pointsToBBox=UQ;function h1(e,r,t,i){var n=e+t,a=r+i;return{x:e,y:r,width:t,height:i,minX:e,minY:r,maxX:isNaN(n)?0:n,maxY:isNaN(a)?0:a}}Ut.createBBox=h1;function OA(e,r,t){return(1-t)*e+r*t}Ut.getValueByPercent=OA;function qQ(e,r,t){return{x:e.x+Math.cos(t)*r,y:e.y+Math.sin(t)*r}}Ut.getCirclePoint=qQ;function kV(e,r){var t=r.x-e.x,i=r.y-e.y;return Math.sqrt(t*t+i*i)}Ut.distance=kV;Ut.wait=function(e){return new Promise(function(r){setTimeout(r,e)})};Ut.near=function(e,r,t){return t===void 0&&(t=Math.pow(Number.EPSILON,.5)),[e,r].includes(1/0)?Math.abs(e)===Math.abs(r):Math.abs(e-r)<t};function RV(e,r){var t=Math.max(e.minX,r.minX),i=Math.max(e.minY,r.minY),n=Math.min(e.maxX,r.maxX),a=Math.min(e.maxY,r.maxY);return h1(t,i,n-t,a-i)}Ut.intersectBBox=RV;function ZQ(e,r){var t=Math.min(e.minX,r.minX),i=Math.min(e.minY,r.minY),n=Math.max(e.maxX,r.maxX),a=Math.max(e.maxY,r.maxY);return h1(t,i,n-t,a-i)}Ut.mergeBBox=ZQ;function BV(e){var r=e.getClip(),t=r&&r.getBBox(),i;if(!e.isGroup())i=e.getBBox();else{var n=1/0,a=-1/0,o=1/0,l=-1/0,s=e.getChildren();s.length>0?Vo.each(s,function(u){if(u.get("visible")){if(u.isGroup()&&u.get("children").length===0)return!0;var c=BV(u),f=u.applyToMatrix([c.minX,c.minY,1]),h=u.applyToMatrix([c.minX,c.maxY,1]),v=u.applyToMatrix([c.maxX,c.minY,1]),d=u.applyToMatrix([c.maxX,c.maxY,1]),p=Math.min(f[0],h[0],v[0],d[0]),x=Math.max(f[0],h[0],v[0],d[0]),m=Math.min(f[1],h[1],v[1],d[1]),_=Math.max(f[1],h[1],v[1],d[1]);p<n&&(n=p),x>a&&(a=x),m<o&&(o=m),_>l&&(l=_)}}):(n=0,a=0,o=0,l=0),i=h1(n,o,a-n,l-o)}return t?RV(i,t):i}Ut.getBBoxWithClip=BV;function QQ(e,r){if(!(!e.getClip()&&!r.getClip())){var t=r.getClip();if(!t){e.setClip(null);return}var i={type:t.get("type"),attrs:t.attr()};e.setClip(i)}}Ut.updateClip=QQ;function KQ(e){return e+"px"}Ut.toPx=KQ;function JQ(e,r,t,i){var n=kV(e,r),a=i/n,o=0;return t==="start"?o=0-a:t==="end"&&(o=1+a),{x:OA(e.x,r.x,o),y:OA(e.y,r.y,o)}}Ut.getTextPoint=JQ;function NV(e,r){var t=jQ.getOffScreenContext(),i=0;if(Vo.isNil(e)||e==="")return i;if(t.save(),t.font=r,Vo.isString(e)&&e.includes(`
|
|
`)){var n=e.split(`
|
|
`);Vo.each(n,function(a){var o=t.measureText(a).width;i<o&&(i=o)})}else i=t.measureText(e).width;return t.restore(),i}Ut.getTextWidth=NV;function tK(e,r,t){if(Date.parse(e))return e.split(" ").join(`
|
|
`);function i(o,l){for(var s=0;s<o.length;s++){var u=o.slice(0,s+1),c=NV(u,t);if(c>r){l(s);return}}}var n="",a="";return i(e,function(o){n=e.slice(0,o),a=e.slice(o)}),i(a,function(o){a=a.slice(0,o-1)+"..."}),n+`
|
|
`+a}Ut.clipTextTwoLines=tK;var PM={};Object.defineProperty(PM,"__esModule",{value:!0});var LL=V,eK=ii,Io=Y,rK={none:[],point:["x","y"],region:["start","end"],points:["points"],circle:["center","radius","startAngle","endAngle"]},iK=function(e){LL.__extends(r,e);function r(t){var i=e.call(this,t)||this;return i.initCfg(),i}return r.prototype.getDefaultCfg=function(){return{id:"",name:"",type:"",locationType:"none",offsetX:0,offsetY:0,animate:!1,capture:!0,updateAutoRender:!1,animateOption:{appear:null,update:{duration:400,easing:"easeQuadInOut"},enter:{duration:400,easing:"easeQuadInOut"},leave:{duration:350,easing:"easeQuadIn"}},events:null,defaultCfg:{},visible:!0}},r.prototype.clear=function(){},r.prototype.update=function(t){var i=this,n=this.get("defaultCfg")||{};Io.each(t,function(a,o){var l=i.get(o),s=a;l!==a&&(Io.isObject(a)&&n[o]&&(s=Io.deepMix({},n[o],a)),i.set(o,s))}),this.updateInner(t),this.afterUpdate(t)},r.prototype.updateInner=function(t){},r.prototype.afterUpdate=function(t){Io.hasKey(t,"visible")&&(t.visible?this.show():this.hide()),Io.hasKey(t,"capture")&&this.setCapture(t.capture)},r.prototype.getLayoutBBox=function(){return this.getBBox()},r.prototype.getLocationType=function(){return this.get("locationType")},r.prototype.getOffset=function(){return{offsetX:this.get("offsetX"),offsetY:this.get("offsetY")}},r.prototype.setOffset=function(t,i){this.update({offsetX:t,offsetY:i})},r.prototype.setLocation=function(t){var i=LL.__assign({},t);this.update(i)},r.prototype.getLocation=function(){var t=this,i={},n=this.get("locationType"),a=rK[n];return Io.each(a,function(o){i[o]=t.get(o)}),i},r.prototype.isList=function(){return!1},r.prototype.isSlider=function(){return!1},r.prototype.init=function(){},r.prototype.initCfg=function(){var t=this,i=this.get("defaultCfg");Io.each(i,function(n,a){var o=t.get(a);if(Io.isObject(o)){var l=Io.deepMix({},n,o);t.set(a,l)}})},r}(eK.Base);PM.default=iK;Object.defineProperty(pM,"__esModule",{value:!0});var Yw=V,Ny=dM,Js=Y,Ww=Ut,nK=PM,aK=function(e){Yw.__extends(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return Yw.__assign(Yw.__assign({},t),{container:null,containerTpl:"<div></div>",updateAutoRender:!0,containerClassName:"",parent:null})},r.prototype.getContainer=function(){return this.get("container")},r.prototype.show=function(){var t=this.get("container");t.style.display="",this.set("visible",!0)},r.prototype.hide=function(){var t=this.get("container");t.style.display="none",this.set("visible",!1)},r.prototype.setCapture=function(t){var i=this.getContainer(),n=t?"auto":"none";i.style.pointerEvents=n,this.set("capture",t)},r.prototype.getBBox=function(){var t=this.getContainer(),i=parseFloat(t.style.left)||0,n=parseFloat(t.style.top)||0;return Ww.createBBox(i,n,t.clientWidth,t.clientHeight)},r.prototype.clear=function(){var t=this.get("container");Ww.clearDom(t)},r.prototype.destroy=function(){this.removeEvent(),this.removeDom(),e.prototype.destroy.call(this)},r.prototype.init=function(){e.prototype.init.call(this),this.initContainer(),this.initDom(),this.resetStyles(),this.applyStyles(),this.initEvent(),this.initCapture(),this.initVisible()},r.prototype.initCapture=function(){this.setCapture(this.get("capture"))},r.prototype.initVisible=function(){this.get("visible")?this.show():this.hide()},r.prototype.initDom=function(){},r.prototype.initContainer=function(){var t=this.get("container");if(Js.isNil(t)){t=this.createDom();var i=this.get("parent");Js.isString(i)&&(i=document.getElementById(i),this.set("parent",i)),i.appendChild(t),this.get("containerId")&&t.setAttribute("id",this.get("containerId")),this.set("container",t)}else Js.isString(t)&&(t=document.getElementById(t),this.set("container",t));this.get("parent")||this.set("parent",t.parentNode)},r.prototype.resetStyles=function(){var t=this.get("domStyles"),i=this.get("defaultStyles");t?t=Js.deepMix({},i,t):t=i,this.set("domStyles",t)},r.prototype.applyStyles=function(){var t=this.get("domStyles");if(!!t){var i=this.getContainer();this.applyChildrenStyles(i,t);var n=this.get("containerClassName");if(n&&Ww.hasClass(i,n)){var a=t[n];Ny.modifyCSS(i,a)}}},r.prototype.applyChildrenStyles=function(t,i){Js.each(i,function(n,a){var o=t.getElementsByClassName(a);Js.each(o,function(l){Ny.modifyCSS(l,n)})})},r.prototype.applyStyle=function(t,i){var n=this.get("domStyles");Ny.modifyCSS(i,n[t])},r.prototype.createDom=function(){var t=this.get("containerTpl");return Ny.createDom(t)},r.prototype.initEvent=function(){},r.prototype.removeDom=function(){var t=this.get("container");t&&t.parentNode&&t.parentNode.removeChild(t)},r.prototype.removeEvent=function(){},r.prototype.updateInner=function(t){Js.hasKey(t,"domStyles")&&(this.resetStyles(),this.applyStyles()),this.resetPosition()},r.prototype.resetPosition=function(){},r}(nK.default);pM.default=aK;Object.defineProperty(uz,"__esModule",{value:!0});var Xw=V,Gy=dM,zy=Y,oK=pM,lK=Ut,sK=function(e){Xw.__extends(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return Xw.__assign(Xw.__assign({},t),{name:"annotation",type:"html",locationType:"point",x:0,y:0,containerTpl:'<div class="g2-html-annotation" style="position:absolute"></div>',alignX:"left",alignY:"top",html:"",zIndex:7})},r.prototype.render=function(){var t=this.getContainer(),i=this.get("html");lK.clearDom(t);var n=zy.isFunction(i)?i(t):i;if(zy.isElement(n))t.appendChild(n);else if(zy.isString(n)||zy.isNumber(n)){var a=Gy.createDom(""+n);a&&t.appendChild(a)}this.resetPosition()},r.prototype.resetPosition=function(){var t=this.getContainer(),i=this.getLocation(),n=i.x,a=i.y,o=this.get("alignX"),l=this.get("alignY"),s=this.get("offsetX"),u=this.get("offsetY"),c=Gy.getOuterWidth(t),f=Gy.getOuterHeight(t),h={x:n,y:a};o==="middle"?h.x-=Math.round(c/2):o==="right"&&(h.x-=Math.round(c)),l==="middle"?h.y-=Math.round(f/2):l==="bottom"&&(h.y-=Math.round(f)),s&&(h.x+=s),u&&(h.y+=u),Gy.modifyCSS(t,{position:"absolute",left:h.x+"px",top:h.y+"px",zIndex:this.get("zIndex")})},r}(oK.default),uK=uz.default=sK,v1={},Jt={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.COMPONENT_MAX_VIEW_PERCENTAGE=e.MIN_CHART_HEIGHT=e.MIN_CHART_WIDTH=e.FIELD_ORIGIN=e.GROUP_ATTRS=e.ELEMENT_STATE=e.PLOT_EVENTS=e.GEOMETRY_LIFE_CIRCLE=e.VIEW_LIFE_CIRCLE=e.GROUP_Z_INDEX=e.COMPONENT_TYPE=e.DIRECTION=e.LAYER=void 0,function(r){r.FORE="fore",r.MID="mid",r.BG="bg"}(e.LAYER||(e.LAYER={})),function(r){r.TOP="top",r.TOP_LEFT="top-left",r.TOP_RIGHT="top-right",r.RIGHT="right",r.RIGHT_TOP="right-top",r.RIGHT_BOTTOM="right-bottom",r.LEFT="left",r.LEFT_TOP="left-top",r.LEFT_BOTTOM="left-bottom",r.BOTTOM="bottom",r.BOTTOM_LEFT="bottom-left",r.BOTTOM_RIGHT="bottom-right",r.RADIUS="radius",r.CIRCLE="circle",r.NONE="none"}(e.DIRECTION||(e.DIRECTION={})),function(r){r.AXIS="axis",r.GRID="grid",r.LEGEND="legend",r.TOOLTIP="tooltip",r.ANNOTATION="annotation",r.SLIDER="slider",r.SCROLLBAR="scrollbar",r.OTHER="other"}(e.COMPONENT_TYPE||(e.COMPONENT_TYPE={})),e.GROUP_Z_INDEX={FORE:3,MID:2,BG:1},function(r){r.BEFORE_RENDER="beforerender",r.AFTER_RENDER="afterrender",r.BEFORE_PAINT="beforepaint",r.AFTER_PAINT="afterpaint",r.BEFORE_CHANGE_DATA="beforechangedata",r.AFTER_CHANGE_DATA="afterchangedata",r.BEFORE_CLEAR="beforeclear",r.AFTER_CLEAR="afterclear",r.BEFORE_DESTROY="beforedestroy",r.BEFORE_CHANGE_SIZE="beforechangesize",r.AFTER_CHANGE_SIZE="afterchangesize"}(e.VIEW_LIFE_CIRCLE||(e.VIEW_LIFE_CIRCLE={})),function(r){r.BEFORE_DRAW_ANIMATE="beforeanimate",r.AFTER_DRAW_ANIMATE="afteranimate"}(e.GEOMETRY_LIFE_CIRCLE||(e.GEOMETRY_LIFE_CIRCLE={})),function(r){r.MOUSE_ENTER="plot:mouseenter",r.MOUSE_DOWN="plot:mousedown",r.MOUSE_MOVE="plot:mousemove",r.MOUSE_UP="plot:mouseup",r.MOUSE_LEAVE="plot:mouseleave",r.TOUCH_START="plot:touchstart",r.TOUCH_MOVE="plot:touchmove",r.TOUCH_END="plot:touchend",r.TOUCH_CANCEL="plot:touchcancel",r.CLICK="plot:click",r.DBLCLICK="plot:dblclick",r.CONTEXTMENU="plot:contextmenu",r.LEAVE="plot:leave",r.ENTER="plot:enter"}(e.PLOT_EVENTS||(e.PLOT_EVENTS={})),function(r){r.ACTIVE="active",r.INACTIVE="inactive",r.SELECTED="selected",r.DEFAULT="default"}(e.ELEMENT_STATE||(e.ELEMENT_STATE={})),e.GROUP_ATTRS=["color","shape","size"],e.FIELD_ORIGIN="_origin",e.MIN_CHART_WIDTH=1,e.MIN_CHART_HEIGHT=1,e.COMPONENT_MAX_VIEW_PERCENTAGE=.25})(Jt);(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.modifyCSS=e.createDom=e.removeDom=e.getChartSize=void 0;var r=Jt;function t(l){var s=getComputedStyle(l);return{width:(l.clientWidth||parseInt(s.width,10))-parseInt(s.paddingLeft,10)-parseInt(s.paddingRight,10),height:(l.clientHeight||parseInt(s.height,10))-parseInt(s.paddingTop,10)-parseInt(s.paddingBottom,10)}}function i(l){return typeof l=="number"&&!isNaN(l)}function n(l,s,u,c){var f=u,h=c;if(s){var v=t(l);f=v.width?v.width:f,h=v.height?v.height:h}return{width:Math.max(i(f)?f:r.MIN_CHART_WIDTH,r.MIN_CHART_WIDTH),height:Math.max(i(h)?h:r.MIN_CHART_HEIGHT,r.MIN_CHART_HEIGHT)}}e.getChartSize=n;function a(l){var s=l.parentNode;s&&s.removeChild(l)}e.removeDom=a;var o=dM;Object.defineProperty(e,"createDom",{enumerable:!0,get:function(){return o.createDom}}),Object.defineProperty(e,"modifyCSS",{enumerable:!0,get:function(){return o.modifyCSS}})})(v1);uK.prototype.render=function(){if(this.get("isReactElement")){var e=this.getContainer(),r=this.get("content"),t=this.get("refreshDeps"),i=Pt.isValidElement(r)?r:r(e);(this.preRefreshDeps===void 0||!Ge(this.preRefreshDeps,t))&&(VG.render(i,e),this.preRefreshDeps=t)}else{var e=this.getContainer(),n=this.get("html");$V(e);var i=pt(n)?n(e):n;t1(i)?e.appendChild(i):Ct(i)&&e.appendChild(v1.createDom(i))}this.resetPosition()};var IM={},Qn={},DL=0,cK=1/2,fK=1/2,hK=.05,Fp=function(){function e(r){var t=r.xField,i=r.yField,n=r.adjustNames,a=n===void 0?["x","y"]:n,o=r.dimValuesMap;this.adjustNames=a,this.xField=t,this.yField=i,this.dimValuesMap=o}return e.prototype.isAdjust=function(r){return this.adjustNames.indexOf(r)>=0},e.prototype.getAdjustRange=function(r,t,i){var n=this.yField,a=i.indexOf(t),o=i.length,l,s;return!n&&this.isAdjust("y")?(l=0,s=1):o>1?(l=i[a===0?0:a-1],s=i[a===o-1?o-1:a+1],a!==0?l+=(t-l)/2:l-=(s-t)/2,a!==o-1?s-=(s-t)/2:s+=(t-i[o-2])/2):(l=t===0?0:t-.5,s=t===0?1:t+.5),{pre:l,next:s}},e.prototype.adjustData=function(r,t){var i=this,n=this.getDimValues(t);P(r,function(a,o){P(n,function(l,s){i.adjustDim(s,l,a,o)})})},e.prototype.groupData=function(r,t){return P(r,function(i){i[t]===void 0&&(i[t]=DL)}),Xi(r,t)},e.prototype.adjustDim=function(r,t,i,n){},e.prototype.getDimValues=function(r){var t=this,i=t.xField,n=t.yField,a=Kt({},this.dimValuesMap),o=[];if(i&&this.isAdjust("x")&&o.push(i),n&&this.isAdjust("y")&&o.push(n),o.forEach(function(s){a&&a[s]||(a[s]=Xn(r,s).sort(function(u,c){return u-c}))}),!n&&this.isAdjust("y")){var l="y";a[l]=[DL,1]}return a},e}(),GV={},LM=function(e){return GV[e.toLowerCase()]},Op=function(e,r){if(LM(e))throw new Error("Adjust type '"+e+"' existed.");GV[e.toLowerCase()]=r};/*! *****************************************************************************
|
|
Copyright (c) Microsoft Corporation.
|
|
|
|
Permission to use, copy, modify, and/or distribute this software for any
|
|
purpose with or without fee is hereby granted.
|
|
|
|
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
PERFORMANCE OF THIS SOFTWARE.
|
|
***************************************************************************** */var PA=function(e,r){return PA=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,i){t.__proto__=i}||function(t,i){for(var n in i)i.hasOwnProperty(n)&&(t[n]=i[n])},PA(e,r)};function d1(e,r){PA(e,r);function t(){this.constructor=e}e.prototype=r===null?Object.create(r):(t.prototype=r.prototype,new t)}var io=function(){return io=Object.assign||function(r){for(var t,i=1,n=arguments.length;i<n;i++){t=arguments[i];for(var a in t)Object.prototype.hasOwnProperty.call(t,a)&&(r[a]=t[a])}return r},io.apply(this,arguments)},vK=function(e){d1(r,e);function r(t){var i=e.call(this,t)||this;i.cacheMap={},i.adjustDataArray=[],i.mergeData=[];var n=t.marginRatio,a=n===void 0?cK:n,o=t.dodgeRatio,l=o===void 0?fK:o,s=t.dodgeBy,u=t.intervalPadding,c=t.dodgePadding,f=t.xDimensionLength,h=t.groupNum,v=t.defaultSize,d=t.maxColumnWidth,p=t.minColumnWidth,x=t.columnWidthRatio,m=t.customOffset;return i.marginRatio=a,i.dodgeRatio=l,i.dodgeBy=s,i.intervalPadding=u,i.dodgePadding=c,i.xDimensionLegenth=f,i.groupNum=h,i.defaultSize=v,i.maxColumnWidth=d,i.minColumnWidth=p,i.columnWidthRatio=x,i.customOffset=m,i}return r.prototype.process=function(t){var i=di(t),n=qi(i),a=this.dodgeBy,o=a?QG(n,a):i;return this.cacheMap={},this.adjustDataArray=o,this.mergeData=n,this.adjustData(o,n),this.adjustDataArray=[],this.mergeData=[],i},r.prototype.adjustDim=function(t,i,n,a){var o=this,l=this.customOffset,s=this.getDistribution(t),u=this.groupData(n,t);return P(u,function(c,f){var h;i.length===1?h={pre:i[0]-1,next:i[0]+1}:h=o.getAdjustRange(t,parseFloat(f),i),P(c,function(v){var d=v[t],p=s[d],x=p.indexOf(a);if(K(l))v[t]=o.getDodgeOffset(h,x,p.length);else{var m=h.pre,_=h.next;v[t]=pt(l)?l(v,h):(m+_)/2+l}})}),[]},r.prototype.getDodgeOffset=function(t,i,n){var a=this,o=a.dodgeRatio,l=a.marginRatio,s=a.intervalPadding,u=a.dodgePadding,c=t.pre,f=t.next,h=f-c,v;if(!K(s)&&K(u)&&s>=0){var d=this.getIntervalOnlyOffset(n,i);v=c+d}else if(!K(u)&&K(s)&&u>=0){var d=this.getDodgeOnlyOffset(n,i);v=c+d}else if(!K(s)&&!K(u)&&s>=0&&u>=0){var d=this.getIntervalAndDodgeOffset(n,i);v=c+d}else{var p=h*o/n,x=l*p,d=1/2*(h-n*p-(n-1)*x)+((i+1)*p+i*x)-1/2*p-1/2*h;v=(c+f)/2+d}return v},r.prototype.getIntervalOnlyOffset=function(t,i){var n=this,a=n.defaultSize,o=n.intervalPadding,l=n.xDimensionLegenth,s=n.groupNum,u=n.dodgeRatio,c=n.maxColumnWidth,f=n.minColumnWidth,h=n.columnWidthRatio,v=o/l,d=(1-(s-1)*v)/s*u/(t-1),p=((1-v*(s-1))/s-d*(t-1))/t;if(p=K(h)?p:1/s/t*h,!K(c)){var x=c/l;p=Math.min(p,x)}if(!K(f)){var m=f/l;p=Math.max(p,m)}p=a?a/l:p,d=((1-(s-1)*v)/s-t*p)/(t-1);var _=((1/2+i)*p+i*d+1/2*v)*s-v/2;return _},r.prototype.getDodgeOnlyOffset=function(t,i){var n=this,a=n.defaultSize,o=n.dodgePadding,l=n.xDimensionLegenth,s=n.groupNum,u=n.marginRatio,c=n.maxColumnWidth,f=n.minColumnWidth,h=n.columnWidthRatio,v=o/l,d=1*u/(s-1),p=((1-d*(s-1))/s-v*(t-1))/t;if(p=h?1/s/t*h:p,!K(c)){var x=c/l;p=Math.min(p,x)}if(!K(f)){var m=f/l;p=Math.max(p,m)}p=a?a/l:p,d=(1-(p*t+v*(t-1))*s)/(s-1);var _=((1/2+i)*p+i*v+1/2*d)*s-d/2;return _},r.prototype.getIntervalAndDodgeOffset=function(t,i){var n=this,a=n.intervalPadding,o=n.dodgePadding,l=n.xDimensionLegenth,s=n.groupNum,u=a/l,c=o/l,f=((1-u*(s-1))/s-c*(t-1))/t,h=((1/2+i)*f+i*c+1/2*u)*s-u/2;return h},r.prototype.getDistribution=function(t){var i=this.adjustDataArray,n=this.cacheMap,a=n[t];return a||(a={},P(i,function(o,l){var s=Xn(o,t);s.length||s.push(0),P(s,function(u){a[u]||(a[u]=[]),a[u].push(l)})}),n[t]=a),a},r}(Fp);function dK(e,r){return(r-e)*Math.random()+e}var pK=function(e){d1(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.process=function(t){var i=di(t),n=qi(i);return this.adjustData(i,n),i},r.prototype.adjustDim=function(t,i,n){var a=this,o=this.groupData(n,t);return P(o,function(l,s){return a.adjustGroup(l,t,parseFloat(s),i)})},r.prototype.getAdjustOffset=function(t){var i=t.pre,n=t.next,a=(n-i)*hK;return dK(i+a,n-a)},r.prototype.adjustGroup=function(t,i,n,a){var o=this,l=this.getAdjustRange(i,n,a);return P(t,function(s){s[i]=o.getAdjustOffset(l)}),t},r}(Fp),Uw=lz,gK=function(e){d1(r,e);function r(t){var i=e.call(this,t)||this,n=t.adjustNames,a=n===void 0?["y"]:n,o=t.height,l=o===void 0?NaN:o,s=t.size,u=s===void 0?10:s,c=t.reverseOrder,f=c===void 0?!1:c;return i.adjustNames=a,i.height=l,i.size=u,i.reverseOrder=f,i}return r.prototype.process=function(t){var i=this,n=i.yField,a=i.reverseOrder,o=n?this.processStack(t):this.processOneDimStack(t);return a?this.reverse(o):o},r.prototype.reverse=function(t){return t.slice(0).reverse()},r.prototype.processStack=function(t){var i=this,n=i.xField,a=i.yField,o=i.reverseOrder,l=o?this.reverse(t):t,s=new Uw,u=new Uw;return l.map(function(c){return c.map(function(f){var h,v=I(f,n,0),d=I(f,[a]),p=v.toString();if(d=it(d)?d[1]:d,!K(d)){var x=d>=0?s:u;x.has(p)||x.set(p,0);var m=x.get(p),_=d+m;return x.set(p,_),io(io({},f),(h={},h[a]=[m,_],h))}return f})})},r.prototype.processOneDimStack=function(t){var i=this,n=this,a=n.xField,o=n.height,l=n.reverseOrder,s="y",u=l?this.reverse(t):t,c=new Uw;return u.map(function(f){return f.map(function(h){var v,d=i.size,p=h[a],x=d*2/o;c.has(p)||c.set(p,x/2);var m=c.get(p);return c.set(p,m+x),io(io({},h),(v={},v[s]=m,v))})})},r}(Fp),yK=function(e){d1(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.process=function(t){var i=qi(t),n=this,a=n.xField,o=n.yField,l=this.getXValuesMaxMap(i),s=Math.max.apply(Math,Object.keys(l).map(function(u){return l[u]}));return je(t,function(u){return je(u,function(c){var f,h,v=c[o],d=c[a];if(it(v)){var p=(s-l[d])/2;return io(io({},c),(f={},f[o]=je(v,function(m){return p+m}),f))}var x=(s-v)/2;return io(io({},c),(h={},h[o]=[x,v+x],h))})})},r.prototype.getXValuesMaxMap=function(t){var i=this,n=this,a=n.xField,o=n.yField,l=Xi(t,function(s){return s[a]});return nz(l,function(s){return i.getDimMaxValue(s,o)})},r.prototype.getDimMaxValue=function(t,i){var n=je(t,function(o){return I(o,i,[])}),a=qi(n);return Math.max.apply(Math,a)},r}(Fp);Op("Dodge",vK);Op("Jitter",pK);Op("Stack",gK);Op("Symmetric",yK);var mK=Object.freeze(Object.defineProperty({__proto__:null,getAdjust:LM,registerAdjust:Op,Adjust:Fp},Symbol.toStringTag,{value:"Module"})),zV=br(mK),$L=function(e,r){return Ct(r)?r:e.invert(e.scale(r))},Ch=function(){function e(r){this.names=[],this.scales=[],this.linear=!1,this.values=[],this.callback=function(){return[]},this._parseCfg(r)}return e.prototype.mapping=function(){for(var r=this,t=[],i=0;i<arguments.length;i++)t[i]=arguments[i];var n=t.map(function(a,o){return r._toOriginParam(a,r.scales[o])});return this.callback.apply(this,n)},e.prototype.getLinearValue=function(r){var t=this.values.length-1,i=Math.floor(t*r),n=t*r-i,a=this.values[i],o=i===t?a:this.values[i+1];return a+(o-a)*n},e.prototype.getNames=function(){for(var r=this.scales,t=this.names,i=Math.min(r.length,t.length),n=[],a=0;a<i;a+=1)n.push(t[a]);return n},e.prototype.getFields=function(){return this.scales.map(function(r){return r.field})},e.prototype.getScale=function(r){return this.scales[this.names.indexOf(r)]},e.prototype.defaultCallback=function(){for(var r=this,t=[],i=0;i<arguments.length;i++)t[i]=arguments[i];return t.length===0?this.values:t.map(function(n,a){var o=r.scales[a];return o.type==="identity"?o.values[0]:r._getAttributeValue(o,n)})},e.prototype._parseCfg=function(r){var t=this,i=r.type,n=i===void 0?"base":i,a=r.names,o=a===void 0?[]:a,l=r.scales,s=l===void 0?[]:l,u=r.values,c=u===void 0?[]:u,f=r.callback;this.type=n,this.scales=s,this.values=c,this.names=o,this.callback=function(){for(var h=[],v=0;v<arguments.length;v++)h[v]=arguments[v];if(f){var d=f.apply(void 0,h);if(!K(d))return[d]}return t.defaultCallback.apply(t,h)}},e.prototype._getAttributeValue=function(r,t){if(r.isCategory&&!this.linear){var i=r.translate(t);return this.values[i%this.values.length]}var n=r.scale(t);return this.getLinearValue(n)},e.prototype._toOriginParam=function(r,t){return t.isLinear?r:it(r)?r.map(function(i){return $L(t,i)}):$L(t,r)},e}(),xK=/rgba?\(([\s.,0-9]+)\)/,_K=/^l\s*\(\s*([\d.]+)\s*\)\s*(.*)/i,bK=/^r\s*\(\s*([\d.]+)\s*,\s*([\d.]+)\s*,\s*([\d.]+)\s*\)\s*(.*)/i,wK=/[\d.]+:(#[^\s]+|[^\)]+\))/gi,CK=function(e){return/^[r,R,L,l]{1}[\s]*\(/.test(e)},SK=function(){var e=document.createElement("i");return e.title="Web Colour Picker",e.style.display="none",document.body.appendChild(e),e},qw=function(e,r,t,i){return e[i]+(r[i]-e[i])*t};function VV(e){return"#"+Zw(e[0])+Zw(e[1])+Zw(e[2])}var jV=function(e){return[parseInt(e.substr(1,2),16),parseInt(e.substr(3,2),16),parseInt(e.substr(5,2),16)]},Zw=function(e){var r=Math.round(e).toString(16);return r.length===1?"0"+r:r},AK=function(e,r){var t=isNaN(Number(r))||r<0?0:r>1?1:Number(r),i=e.length-1,n=Math.floor(i*t),a=i*t-n,o=e[n],l=n===i?o:e[n+1];return VV([qw(o,l,a,0),qw(o,l,a,1),qw(o,l,a,2)])},Vy,HV=function(e){if(e[0]==="#"&&e.length===7)return e;Vy||(Vy=SK()),Vy.style.color=e;var r=document.defaultView.getComputedStyle(Vy,"").getPropertyValue("color"),t=xK.exec(r),i=t[1].split(/\s*,\s*/).map(function(n){return Number(n)});return r=VV(i),r},TK=function(e){var r=Ct(e)?e.split("-"):e,t=je(r,function(i){return jV(i.indexOf("#")===-1?HV(i):i)});return function(i){return AK(t,i)}},MK=function(e){if(CK(e)){var r,t=void 0;if(e[0]==="l"){var i=_K.exec(e),n=+i[1]+90;t=i[2],r="linear-gradient("+n+"deg, "}else if(e[0]==="r"){r="radial-gradient(";var i=bK.exec(e);t=i[4]}var a=t.match(wK);return P(a,function(o,l){var s=o.split(":");r+=s[1]+" "+s[0]*100+"%",l!==a.length-1&&(r+=", ")}),r+=")",r}return e},Qo={rgb2arr:jV,gradient:TK,toRGB:uc(HV),toCSSGradient:MK},EK=Object.freeze(Object.defineProperty({__proto__:null,default:Qo},Symbol.toStringTag,{value:"Module"})),YV=function(e){X(r,e);function r(t){var i=e.call(this,t)||this;return i.type="color",i.names=["color"],Ct(i.values)&&(i.linear=!0),i.gradient=Qo.gradient(i.values),i}return r.prototype.getLinearValue=function(t){return this.gradient(t)},r}(Ch),WV=function(e){X(r,e);function r(t){var i=e.call(this,t)||this;return i.type="opacity",i.names=["opacity"],i}return r}(Ch),XV=function(e){X(r,e);function r(t){var i=e.call(this,t)||this;return i.names=["x","y"],i.type="position",i}return r.prototype.mapping=function(t,i){var n=this.scales,a=n[0],o=n[1];return K(t)||K(i)?[]:[it(t)?t.map(function(l){return a.scale(l)}):a.scale(t),it(i)?i.map(function(l){return o.scale(l)}):o.scale(i)]},r}(Ch),UV=function(e){X(r,e);function r(t){var i=e.call(this,t)||this;return i.type="shape",i.names=["shape"],i}return r.prototype.getLinearValue=function(t){var i=Math.round((this.values.length-1)*t);return this.values[i]},r}(Ch),qV=function(e){X(r,e);function r(t){var i=e.call(this,t)||this;return i.type="size",i.names=["size"],i}return r}(Ch),ZV={};function QV(e){return ZV[e]}function Kn(e,r){ZV[e]=r}var Sh=function(){function e(r){this.type="base",this.isCategory=!1,this.isLinear=!1,this.isContinuous=!1,this.isIdentity=!1,this.values=[],this.range=[0,1],this.ticks=[],this.__cfg__=r,this.initCfg(),this.init()}return e.prototype.translate=function(r){return r},e.prototype.change=function(r){Kt(this.__cfg__,r),this.init()},e.prototype.clone=function(){return this.constructor(this.__cfg__)},e.prototype.getTicks=function(){var r=this;return je(this.ticks,function(t,i){return Zt(t)?t:{text:r.getText(t,i),tickValue:t,value:r.scale(t)}})},e.prototype.getText=function(r,t){var i=this.formatter,n=i?i(r,t):r;return K(n)||!pt(n.toString)?"":n.toString()},e.prototype.getConfig=function(r){return this.__cfg__[r]},e.prototype.init=function(){Kt(this,this.__cfg__),this.setDomain(),gi(this.getConfig("ticks"))&&(this.ticks=this.calculateTicks())},e.prototype.initCfg=function(){},e.prototype.setDomain=function(){},e.prototype.calculateTicks=function(){var r=this.tickMethod,t=[];if(Ct(r)){var i=QV(r);if(!i)throw new Error("There is no method to to calculate ticks!");t=i(this)}else pt(r)&&(t=r(this));return t},e.prototype.rangeMin=function(){return this.range[0]},e.prototype.rangeMax=function(){return this.range[1]},e.prototype.calcPercent=function(r,t,i){return Mt(r)?(r-t)/(i-t):NaN},e.prototype.calcValue=function(r,t,i){return t+r*(i-t)},e}(),Pp=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="cat",t.isCategory=!0,t}return r.prototype.buildIndexMap=function(){if(!this.translateIndexMap){this.translateIndexMap=new Map;for(var t=0;t<this.values.length;t++)this.translateIndexMap.set(this.values[t],t)}},r.prototype.translate=function(t){this.buildIndexMap();var i=this.translateIndexMap.get(t);return i===void 0&&(i=Mt(t)?t:NaN),i},r.prototype.scale=function(t){var i=this.translate(t),n=this.calcPercent(i,this.min,this.max);return this.calcValue(n,this.rangeMin(),this.rangeMax())},r.prototype.invert=function(t){var i=this.max-this.min,n=this.calcPercent(t,this.rangeMin(),this.rangeMax()),a=Math.round(i*n)+this.min;return a<this.min||a>this.max?NaN:this.values[a]},r.prototype.getText=function(t){for(var i=[],n=1;n<arguments.length;n++)i[n-1]=arguments[n];var a=t;return Mt(t)&&!this.values.includes(t)&&(a=this.values[a]),e.prototype.getText.apply(this,ye([a],i))},r.prototype.initCfg=function(){this.tickMethod="cat"},r.prototype.setDomain=function(){if(K(this.getConfig("min"))&&(this.min=0),K(this.getConfig("max"))){var t=this.values.length;this.max=t>1?t-1:t}this.translateIndexMap&&(this.translateIndexMap=void 0)},r}(Sh),KV=/d{1,4}|M{1,4}|YY(?:YY)?|S{1,3}|Do|ZZ|Z|([HhMsDm])\1?|[aA]|"[^"]*"|'[^']*'/g,Dl="\\d\\d?",Al="\\d\\d",FK="\\d{3}",OK="\\d{4}",dd="[^\\s]+",JV=/\[([^]*?)\]/gm;function t5(e,r){for(var t=[],i=0,n=e.length;i<n;i++)t.push(e[i].substr(0,r));return t}var kL=function(e){return function(r,t){var i=t[e].map(function(a){return a.toLowerCase()}),n=i.indexOf(r.toLowerCase());return n>-1?n:null}};function hs(e){for(var r=[],t=1;t<arguments.length;t++)r[t-1]=arguments[t];for(var i=0,n=r;i<n.length;i++){var a=n[i];for(var o in a)e[o]=a[o]}return e}var e5=["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],r5=["January","February","March","April","May","June","July","August","September","October","November","December"],PK=t5(r5,3),IK=t5(e5,3),DM={dayNamesShort:IK,dayNames:e5,monthNamesShort:PK,monthNames:r5,amPm:["am","pm"],DoFn:function(e){return e+["th","st","nd","rd"][e%10>3?0:(e-e%10!==10?1:0)*e%10]}},U0=hs({},DM),i5=function(e){return U0=hs(U0,e)},RL=function(e){return e.replace(/[|\\{()[^$+*?.-]/g,"\\$&")},ki=function(e,r){for(r===void 0&&(r=2),e=String(e);e.length<r;)e="0"+e;return e},LK={D:function(e){return String(e.getDate())},DD:function(e){return ki(e.getDate())},Do:function(e,r){return r.DoFn(e.getDate())},d:function(e){return String(e.getDay())},dd:function(e){return ki(e.getDay())},ddd:function(e,r){return r.dayNamesShort[e.getDay()]},dddd:function(e,r){return r.dayNames[e.getDay()]},M:function(e){return String(e.getMonth()+1)},MM:function(e){return ki(e.getMonth()+1)},MMM:function(e,r){return r.monthNamesShort[e.getMonth()]},MMMM:function(e,r){return r.monthNames[e.getMonth()]},YY:function(e){return ki(String(e.getFullYear()),4).substr(2)},YYYY:function(e){return ki(e.getFullYear(),4)},h:function(e){return String(e.getHours()%12||12)},hh:function(e){return ki(e.getHours()%12||12)},H:function(e){return String(e.getHours())},HH:function(e){return ki(e.getHours())},m:function(e){return String(e.getMinutes())},mm:function(e){return ki(e.getMinutes())},s:function(e){return String(e.getSeconds())},ss:function(e){return ki(e.getSeconds())},S:function(e){return String(Math.round(e.getMilliseconds()/100))},SS:function(e){return ki(Math.round(e.getMilliseconds()/10),2)},SSS:function(e){return ki(e.getMilliseconds(),3)},a:function(e,r){return e.getHours()<12?r.amPm[0]:r.amPm[1]},A:function(e,r){return e.getHours()<12?r.amPm[0].toUpperCase():r.amPm[1].toUpperCase()},ZZ:function(e){var r=e.getTimezoneOffset();return(r>0?"-":"+")+ki(Math.floor(Math.abs(r)/60)*100+Math.abs(r)%60,4)},Z:function(e){var r=e.getTimezoneOffset();return(r>0?"-":"+")+ki(Math.floor(Math.abs(r)/60),2)+":"+ki(Math.abs(r)%60,2)}},BL=function(e){return+e-1},NL=[null,Dl],GL=[null,dd],zL=["isPm",dd,function(e,r){var t=e.toLowerCase();return t===r.amPm[0]?0:t===r.amPm[1]?1:null}],VL=["timezoneOffset","[^\\s]*?[\\+\\-]\\d\\d:?\\d\\d|[^\\s]*?Z?",function(e){var r=(e+"").match(/([+-]|\d\d)/gi);if(r){var t=+r[1]*60+parseInt(r[2],10);return r[0]==="+"?t:-t}return 0}],DK={D:["day",Dl],DD:["day",Al],Do:["day",Dl+dd,function(e){return parseInt(e,10)}],M:["month",Dl,BL],MM:["month",Al,BL],YY:["year",Al,function(e){var r=new Date,t=+(""+r.getFullYear()).substr(0,2);return+(""+(+e>68?t-1:t)+e)}],h:["hour",Dl,void 0,"isPm"],hh:["hour",Al,void 0,"isPm"],H:["hour",Dl],HH:["hour",Al],m:["minute",Dl],mm:["minute",Al],s:["second",Dl],ss:["second",Al],YYYY:["year",OK],S:["millisecond","\\d",function(e){return+e*100}],SS:["millisecond",Al,function(e){return+e*10}],SSS:["millisecond",FK],d:NL,dd:NL,ddd:GL,dddd:GL,MMM:["month",dd,kL("monthNamesShort")],MMMM:["month",dd,kL("monthNames")],a:zL,A:zL,ZZ:VL,Z:VL},q0={default:"ddd MMM DD YYYY HH:mm:ss",shortDate:"M/D/YY",mediumDate:"MMM D, YYYY",longDate:"MMMM D, YYYY",fullDate:"dddd, MMMM D, YYYY",isoDate:"YYYY-MM-DD",isoDateTime:"YYYY-MM-DDTHH:mm:ssZ",shortTime:"HH:mm",mediumTime:"HH:mm:ss",longTime:"HH:mm:ss.SSS"},n5=function(e){return hs(q0,e)},a5=function(e,r,t){if(r===void 0&&(r=q0.default),t===void 0&&(t={}),typeof e=="number"&&(e=new Date(e)),Object.prototype.toString.call(e)!=="[object Date]"||isNaN(e.getTime()))throw new Error("Invalid Date pass to format");r=q0[r]||r;var i=[];r=r.replace(JV,function(a,o){return i.push(o),"@@@"});var n=hs(hs({},U0),t);return r=r.replace(KV,function(a){return LK[a](e,n)}),r.replace(/@@@/g,function(){return i.shift()})};function o5(e,r,t){if(t===void 0&&(t={}),typeof r!="string")throw new Error("Invalid format in fecha parse");if(r=q0[r]||r,e.length>1e3)return null;var i=new Date,n={year:i.getFullYear(),month:0,day:1,hour:0,minute:0,second:0,millisecond:0,isPm:null,timezoneOffset:null},a=[],o=[],l=r.replace(JV,function(w,S){return o.push(RL(S)),"@@@"}),s={},u={};l=RL(l).replace(KV,function(w){var S=DK[w],M=S[0],F=S[1],O=S[3];if(s[M])throw new Error("Invalid format. "+M+" specified twice in format");return s[M]=!0,O&&(u[O]=!0),a.push(S),"("+F+")"}),Object.keys(u).forEach(function(w){if(!s[w])throw new Error("Invalid format. "+w+" is required in specified format")}),l=l.replace(/@@@/g,function(){return o.shift()});var c=e.match(new RegExp(l,"i"));if(!c)return null;for(var f=hs(hs({},U0),t),h=1;h<c.length;h++){var v=a[h-1],d=v[0],p=v[2],x=p?p(c[h],f):+c[h];if(x==null)return null;n[d]=x}n.isPm===1&&n.hour!=null&&+n.hour!=12?n.hour=+n.hour+12:n.isPm===0&&+n.hour==12&&(n.hour=0);var m;if(n.timezoneOffset==null){m=new Date(n.year,n.month,n.day,n.hour,n.minute,n.second,n.millisecond);for(var _=[["month","getMonth"],["day","getDate"],["hour","getHours"],["minute","getMinutes"],["second","getSeconds"]],h=0,b=_.length;h<b;h++)if(s[_[h][0]]&&n[_[h][0]]!==m[_[h][1]]())return null}else if(m=new Date(Date.UTC(n.year,n.month,n.day,n.hour,n.minute-n.timezoneOffset,n.second,n.millisecond)),n.month>11||n.month<0||n.day>31||n.day<1||n.hour>23||n.hour<0||n.minute>59||n.minute<0||n.second>59||n.second<0)return null;return m}var l5={format:a5,parse:o5,defaultI18n:DM,setGlobalDateI18n:i5,setGlobalDateMasks:n5},$K=Object.freeze(Object.defineProperty({__proto__:null,default:l5,assign:hs,format:a5,parse:o5,defaultI18n:DM,setGlobalDateI18n:i5,setGlobalDateMasks:n5},Symbol.toStringTag,{value:"Module"}));function kK(e){return function(r,t,i,n){for(var a=K(i)?0:i,o=K(n)?r.length:n;a<o;){var l=a+o>>>1;e(r[l])>t?o=l:a=l+1}return a}}var jL="format";function s5(e,r){var t=$K[jL]||l5[jL];return t(e,r)}function Z0(e){return Ct(e)&&(e.indexOf("T")>0?e=new Date(e).getTime():e=new Date(e.replace(/-/gi,"/")).getTime()),hM(e)&&(e=e.getTime()),e}var pa=1e3,ku=60*pa,Ru=60*ku,Xo=24*Ru,pd=Xo*31,HL=Xo*365,hv=[["HH:mm:ss",pa],["HH:mm:ss",pa*10],["HH:mm:ss",pa*30],["HH:mm",ku],["HH:mm",ku*10],["HH:mm",ku*30],["HH",Ru],["HH",Ru*6],["HH",Ru*12],["YYYY-MM-DD",Xo],["YYYY-MM-DD",Xo*4],["YYYY-WW",Xo*7],["YYYY-MM",pd],["YYYY-MM",pd*4],["YYYY-MM",pd*6],["YYYY",Xo*380]];function RK(e,r,t){var i=(r-e)/t,n=kK(function(o){return o[1]})(hv,i)-1,a=hv[n];return n<0?a=hv[0]:n>=hv.length&&(a=nr(hv)),a}var u5=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="timeCat",t}return r.prototype.translate=function(t){t=Z0(t);var i=this.values.indexOf(t);return i===-1&&(Mt(t)&&t<this.values.length?i=t:i=NaN),i},r.prototype.getText=function(t,i){var n=this.translate(t);if(n>-1){var a=this.values[n],o=this.formatter;return a=o?o(a,i):s5(a,this.mask),a}return t},r.prototype.initCfg=function(){this.tickMethod="time-cat",this.mask="YYYY-MM-DD",this.tickCount=7},r.prototype.setDomain=function(){var t=this.values;P(t,function(i,n){t[n]=Z0(i)}),t.sort(function(i,n){return i-n}),e.prototype.setDomain.call(this)},r}(Pp),p1=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.isContinuous=!0,t}return r.prototype.scale=function(t){if(K(t))return NaN;var i=this.rangeMin(),n=this.rangeMax(),a=this.max,o=this.min;if(a===o)return i;var l=this.getScalePercent(t);return i+l*(n-i)},r.prototype.init=function(){e.prototype.init.call(this);var t=this.ticks,i=Wi(t),n=nr(t);i<this.min&&(this.min=i),n>this.max&&(this.max=n),K(this.minLimit)||(this.min=i),K(this.maxLimit)||(this.max=n)},r.prototype.setDomain=function(){var t=sM(this.values),i=t.min,n=t.max;K(this.min)&&(this.min=i),K(this.max)&&(this.max=n),this.min>this.max&&(this.min=i,this.max=n)},r.prototype.calculateTicks=function(){var t=this,i=e.prototype.calculateTicks.call(this);return this.nice||(i=jr(i,function(n){return n>=t.min&&n<=t.max})),i},r.prototype.getScalePercent=function(t){var i=this.max,n=this.min;return(t-n)/(i-n)},r.prototype.getInvertPercent=function(t){return(t-this.rangeMin())/(this.rangeMax()-this.rangeMin())},r}(Sh),Ah=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="linear",t.isLinear=!0,t}return r.prototype.invert=function(t){var i=this.getInvertPercent(t);return this.min+i*(this.max-this.min)},r.prototype.initCfg=function(){this.tickMethod="wilkinson-extended",this.nice=!1},r}(p1);function zl(e,r){var t=Math.E,i;return r>=0?i=Math.pow(t,Math.log(r)/e):i=Math.pow(t,Math.log(-r)/e)*-1,i}function Gn(e,r){return e===1?1:Math.log(r)/Math.log(e)}function c5(e,r,t){K(t)&&(t=Math.max.apply(null,e));var i=t;return P(e,function(n){n>0&&n<i&&(i=n)}),i===t&&(i=t/r),i>1&&(i=1),i}var f5=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="log",t}return r.prototype.invert=function(t){var i=this.base,n=Gn(i,this.max),a=this.rangeMin(),o=this.rangeMax()-a,l,s=this.positiveMin;if(s){if(t===0)return 0;l=Gn(i,s/i);var u=1/(n-l)*o;if(t<u)return t/u*s}else l=Gn(i,this.min);var c=(t-a)/o,f=c*(n-l)+l;return Math.pow(i,f)},r.prototype.initCfg=function(){this.tickMethod="log",this.base=10,this.tickCount=6,this.nice=!0},r.prototype.setDomain=function(){e.prototype.setDomain.call(this);var t=this.min;if(t<0)throw new Error("When you use log scale, the minimum value must be greater than zero!");t===0&&(this.positiveMin=c5(this.values,this.base,this.max))},r.prototype.getScalePercent=function(t){var i=this.max,n=this.min;if(i===n||t<=0)return 0;var a=this.base,o=this.positiveMin;o&&(n=o*1/a);var l;return t<o?l=t/o/(Gn(a,i)-Gn(a,n)):l=(Gn(a,t)-Gn(a,n))/(Gn(a,i)-Gn(a,n)),l},r}(p1),h5=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="pow",t}return r.prototype.invert=function(t){var i=this.getInvertPercent(t),n=this.exponent,a=zl(n,this.max),o=zl(n,this.min),l=i*(a-o)+o,s=l>=0?1:-1;return Math.pow(l,n)*s},r.prototype.initCfg=function(){this.tickMethod="pow",this.exponent=2,this.tickCount=5,this.nice=!0},r.prototype.getScalePercent=function(t){var i=this.max,n=this.min;if(i===n)return 0;var a=this.exponent,o=(zl(a,t)-zl(a,n))/(zl(a,i)-zl(a,n));return o},r}(p1),v5=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="time",t}return r.prototype.getText=function(t,i){var n=this.translate(t),a=this.formatter;return a?a(n,i):s5(n,this.mask)},r.prototype.scale=function(t){var i=t;return(Ct(i)||hM(i))&&(i=this.translate(i)),e.prototype.scale.call(this,i)},r.prototype.translate=function(t){return Z0(t)},r.prototype.initCfg=function(){this.tickMethod="time-pretty",this.mask="YYYY-MM-DD",this.tickCount=7,this.nice=!1},r.prototype.setDomain=function(){var t=this.values,i=this.getConfig("min"),n=this.getConfig("max");if((!K(i)||!Mt(i))&&(this.min=this.translate(this.min)),(!K(n)||!Mt(n))&&(this.max=this.translate(this.max)),t&&t.length){var a=[],o=1/0,l=o,s=0;P(t,function(u){var c=Z0(u);if(isNaN(c))throw new TypeError("Invalid Time: "+u+" in time scale!");o>c?(l=o,o=c):l>c&&(l=c),s<c&&(s=c),a.push(c)}),t.length>1&&(this.minTickInterval=l-o),K(i)&&(this.min=o),K(n)&&(this.max=s)}},r}(Ah),$M=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="quantize",t}return r.prototype.invert=function(t){var i=this.ticks,n=i.length,a=this.getInvertPercent(t),o=Math.floor(a*(n-1));if(o>=n-1)return nr(i);if(o<0)return Wi(i);var l=i[o],s=i[o+1],u=o/(n-1),c=(o+1)/(n-1);return l+(a-u)/(c-u)*(s-l)},r.prototype.initCfg=function(){this.tickMethod="r-pretty",this.tickCount=5,this.nice=!0},r.prototype.calculateTicks=function(){var t=e.prototype.calculateTicks.call(this);return this.nice||(nr(t)!==this.max&&t.push(this.max),Wi(t)!==this.min&&t.unshift(this.min)),t},r.prototype.getScalePercent=function(t){var i=this.ticks;if(t<Wi(i))return 0;if(t>nr(i))return 1;var n=0;return P(i,function(a,o){if(t>=a)n=o;else return!1}),n/(i.length-1)},r}(p1),d5=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="quantile",t}return r.prototype.initCfg=function(){this.tickMethod="quantile",this.tickCount=5,this.nice=!0},r}($M),p5={};function zd(e){return p5[e]}function Jn(e,r){if(zd(e))throw new Error("type '"+e+"' existed.");p5[e]=r}var g5=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="identity",t.isIdentity=!0,t}return r.prototype.calculateTicks=function(){return this.values},r.prototype.scale=function(t){return this.values[0]!==t&&Mt(t)?t:this.range[0]},r.prototype.invert=function(t){var i=this.range;return t<i[0]||t>i[1]?NaN:this.values[0]},r}(Sh);function y5(e){var r=e.values,t=e.tickInterval,i=e.tickCount,n=e.showLast;if(Mt(t)){var a=jr(r,function(d,p){return p%t===0}),o=nr(r);return n&&nr(a)!==o&&a.push(o),a}var l=r.length,s=e.min,u=e.max;if(K(s)&&(s=0),K(u)&&(u=r.length-1),!Mt(i)||i>=l)return r.slice(s,u+1);if(i<=0||u<=0)return[];for(var c=i===1?l:Math.floor(l/(i-1)),f=[],h=s,v=0;v<i&&!(h>=u);v++)h=Math.min(s+v*c,u),v===i-1&&n?f.push(r[u]):f.push(r[h]);return f}function BK(e){var r=e.min,t=e.max,i=e.nice,n=e.tickCount,a=new NK;return a.domain([r,t]),i&&a.nice(n),a.ticks(n)}var Qw=5,YL=Math.sqrt(50),WL=Math.sqrt(10),XL=Math.sqrt(2),NK=function(){function e(){this._domain=[0,1]}return e.prototype.domain=function(r){return r?(this._domain=Array.from(r,Number),this):this._domain.slice()},e.prototype.nice=function(r){var t,i;r===void 0&&(r=Qw);var n=this._domain.slice(),a=0,o=this._domain.length-1,l=this._domain[a],s=this._domain[o],u;return s<l&&(t=[s,l],l=t[0],s=t[1],i=[o,a],a=i[0],o=i[1]),u=g0(l,s,r),u>0?(l=Math.floor(l/u)*u,s=Math.ceil(s/u)*u,u=g0(l,s,r)):u<0&&(l=Math.ceil(l*u)/u,s=Math.floor(s*u)/u,u=g0(l,s,r)),u>0?(n[a]=Math.floor(l/u)*u,n[o]=Math.ceil(s/u)*u,this.domain(n)):u<0&&(n[a]=Math.ceil(l*u)/u,n[o]=Math.floor(s*u)/u,this.domain(n)),this},e.prototype.ticks=function(r){return r===void 0&&(r=Qw),GK(this._domain[0],this._domain[this._domain.length-1],r||Qw)},e}();function GK(e,r,t){var i,n=-1,a,o,l;if(r=+r,e=+e,t=+t,e===r&&t>0)return[e];if((i=r<e)&&(a=e,e=r,r=a),(l=g0(e,r,t))===0||!isFinite(l))return[];if(l>0)for(e=Math.ceil(e/l),r=Math.floor(r/l),o=new Array(a=Math.ceil(r-e+1));++n<a;)o[n]=(e+n)*l;else for(e=Math.floor(e*l),r=Math.ceil(r*l),o=new Array(a=Math.ceil(e-r+1));++n<a;)o[n]=(e-n)/l;return i&&o.reverse(),o}function g0(e,r,t){var i=(r-e)/Math.max(0,t),n=Math.floor(Math.log(i)/Math.LN10),a=i/Math.pow(10,n);return n>=0?(a>=YL?10:a>=WL?5:a>=XL?2:1)*Math.pow(10,n):-Math.pow(10,-n)/(a>=YL?10:a>=WL?5:a>=XL?2:1)}function UL(e,r,t){var i;return t==="ceil"?i=Math.ceil(e/r):t==="floor"?i=Math.floor(e/r):i=Math.round(e/r),i*r}function kM(e,r,t){var i=UL(e,t,"floor"),n=UL(r,t,"ceil");i=p0(i,t),n=p0(n,t);for(var a=[],o=Math.max((n-i)/(Math.pow(2,12)-1),t),l=i;l<=n;l=l+o){var s=p0(l,o);a.push(s)}return{min:i,max:n,ticks:a}}function RM(e,r,t){var i,n=e.minLimit,a=e.maxLimit,o=e.min,l=e.max,s=e.tickCount,u=s===void 0?5:s,c=K(n)?K(r)?o:r:n,f=K(a)?K(t)?l:t:a;if(c>f&&(i=[c,f],f=i[0],c=i[1]),u<=2)return[c,f];for(var h=(f-c)/(u-1),v=[],d=0;d<u;d++)v.push(c+h*d);return v}function zK(e){var r=e.min,t=e.max,i=e.tickInterval,n=e.minLimit,a=e.maxLimit,o=BK(e);return!K(n)||!K(a)?RM(e,Wi(o),nr(o)):i?kM(r,t,i).ticks:o}function vu(e){return Math.abs(e)<1e-15?e:parseFloat(e.toFixed(15))}var VK=[1,5,2,2.5,4,3],qL=Number.EPSILON*100;function jK(e,r){return(e%r+r)%r}function HK(e){return Math.round(e*1e12)/1e12}function YK(e,r,t,i,n,a){var o=yr(r),l=vM(r,e),s=0,u=jK(i,a);return(u<qL||a-u<qL)&&i<=0&&n>=0&&(s=1),1-l/(o-1)-t+s}function WK(e,r,t){var i=yr(r),n=vM(r,e),a=1;return 1-n/(i-1)-t+a}function XK(e,r,t,i,n,a){var o=(e-1)/(a-n),l=(r-1)/(Math.max(a,i)-Math.min(t,n));return 2-Math.max(o/l,l/o)}function UK(e,r){return e>=r?2-(e-1)/(r-1):1}function qK(e,r,t,i){var n=r-e;return 1-.5*(Math.pow(r-i,2)+Math.pow(e-t,2))/Math.pow(.1*n,2)}function ZK(e,r,t){var i=r-e;if(t>i){var n=(t-i)/2;return 1-Math.pow(n,2)/Math.pow(.1*i,2)}return 1}function QK(){return 1}function KK(e,r,t,i,n,a){t===void 0&&(t=5),i===void 0&&(i=!0),n===void 0&&(n=VK),a===void 0&&(a=[.25,.2,.5,.05]);var o=t<0?0:Math.round(t);if(Number.isNaN(e)||Number.isNaN(r)||typeof e!="number"||typeof r!="number"||!o)return{min:0,max:0,ticks:[]};if(r-e<1e-15||o===1)return{min:e,max:r,ticks:[e]};if(r-e>1e148){var l=t||5,s=(r-e)/l;return{min:e,max:r,ticks:Array(l).fill(null).map(function(tt,ot){return vu(e+s*ot)})}}for(var u={score:-2,lmin:0,lmax:0,lstep:0},c=1;c<1/0;){for(var f=0;f<n.length;f+=1){var h=n[f],v=WK(h,n,c);if(a[0]*v+a[1]+a[2]+a[3]<u.score){c=1/0;break}for(var d=2;d<1/0;){var p=UK(d,o);if(a[0]*v+a[1]+a[2]*p+a[3]<u.score)break;for(var x=(r-e)/(d+1)/c/h,m=Math.ceil(Math.log10(x));m<1/0;){var _=c*h*Math.pow(10,m),b=ZK(e,r,_*(d-1));if(a[0]*v+a[1]*b+a[2]*p+a[3]<u.score)break;var w=Math.floor(r/_)*c-(d-1)*c,S=Math.ceil(e/_)*c;if(w<=S)for(var l=S-w,M=0;M<=l;M+=1){var F=w+M,O=F*(_/c),L=O+_*(d-1),D=_,k=YK(h,n,c,O,L,D),H=qK(e,r,O,L),B=XK(d,o,e,r,O,L),j=QK(),U=a[0]*k+a[1]*H+a[2]*B+a[3]*j;U>u.score&&(!i||O<=e&&L>=r)&&(u.lmin=O,u.lmax=L,u.lstep=D,u.score=U)}m+=1}d+=1}}c+=1}var R=vu(u.lmax),G=vu(u.lmin),N=vu(u.lstep),W=Math.floor(HK((R-G)/N))+1,q=new Array(W);q[0]=vu(G);for(var f=1;f<W;f++)q[f]=vu(q[f-1]+N);return{min:Math.min(e,Wi(q)),max:Math.max(r,nr(q)),ticks:q}}function JK(e){var r=e.min,t=e.max,i=e.tickCount,n=e.nice,a=e.tickInterval,o=e.minLimit,l=e.maxLimit,s=KK(r,t,i,n).ticks;return!K(o)||!K(l)?RM(e,Wi(s),nr(s)):a?kM(r,t,a).ticks:s}function tJ(e){var r=e.base,t=e.tickCount,i=e.min,n=e.max,a=e.values,o,l=Gn(r,n);if(i>0)o=Math.floor(Gn(r,i));else{var s=c5(a,r,n);o=Math.floor(Gn(r,s))}for(var u=l-o,c=Math.ceil(u/t),f=[],h=o;h<l+c;h=h+c)f.push(Math.pow(r,h));return i<=0&&f.unshift(0),f}function m5(e,r,t){if(t===void 0&&(t=5),e===r)return{max:r,min:e,ticks:[e]};var i=t<0?0:Math.round(t);if(i===0)return{max:r,min:e,ticks:[]};var n=1.5,a=.5+1.5*n,o=r-e,l=o/i,s=Math.pow(10,Math.floor(Math.log10(l))),u=s;2*s-l<n*(l-u)&&(u=2*s,5*s-l<a*(l-u)&&(u=5*s,10*s-l<n*(l-u)&&(u=10*s)));for(var c=Math.ceil(r/u),f=Math.floor(e/u),h=Math.max(c*u,r),v=Math.min(f*u,e),d=Math.floor((h-v)/u)+1,p=new Array(d),x=0;x<d;x++)p[x]=vu(v+x*u);return{min:v,max:h,ticks:p}}function eJ(e){var r=e.exponent,t=e.tickCount,i=Math.ceil(zl(r,e.max)),n=Math.floor(zl(r,e.min)),a=m5(n,i,t).ticks;return a.map(function(o){var l=o>=0?1:-1;return Math.pow(o,r)*l})}function rJ(e,r){var t=e.length*r;return r===1?e[e.length-1]:r===0?e[0]:t%1!==0?e[Math.ceil(t)-1]:e.length%2===0?(e[t-1]+e[t])/2:e[t]}function iJ(e){var r=e.tickCount,t=e.values;if(!t||!t.length)return[];for(var i=t.slice().sort(function(l,s){return l-s}),n=[],a=0;a<r;a++){var o=a/(r-1);n.push(rJ(i,o))}return n}function nJ(e){var r=e.min,t=e.max,i=e.tickCount,n=e.tickInterval,a=e.minLimit,o=e.maxLimit,l=m5(r,t,i).ticks;return!K(a)||!K(o)?RM(e,Wi(l),nr(l)):n?kM(r,t,n).ticks:l}function aJ(e){var r=e.min,t=e.max,i=e.minTickInterval,n=e.tickInterval,a=e.tickCount;if(n)a=Math.ceil((t-r)/n);else{n=RK(r,t,a)[1];var o=(t-r)/n,l=o/a;l>1&&(n=n*Math.ceil(l)),i&&n<i&&(n=i)}n=Math.max(Math.floor((t-r)/(Math.pow(2,12)-1)),n);for(var s=[],u=r;u<t+n;u+=n)s.push(u);return s}function oJ(e){var r=y5(A({showLast:!0},e));return r}function Q0(e){return new Date(e).getFullYear()}function lJ(e){return new Date(e,0,1).getTime()}function IA(e){return new Date(e).getMonth()}function sJ(e,r){var t=Q0(e),i=Q0(r),n=IA(e),a=IA(r);return(i-t)*12+(a-n)%12}function uJ(e,r){return new Date(e,r,1).getTime()}function cJ(e,r){return Math.ceil((r-e)/Xo)}function fJ(e,r){return Math.ceil((r-e)/Ru)}function hJ(e,r){return Math.ceil((r-e)/(60*1e3))}function vJ(e){var r=e.min,t=e.max,i=e.minTickInterval,n=e.tickCount,a=e.tickInterval,o=[];a||(a=(t-r)/n,i&&a<i&&(a=i)),a=Math.max(Math.floor((t-r)/(Math.pow(2,12)-1)),a);var l=Q0(r);if(a>HL)for(var s=Q0(t),u=Math.ceil(a/HL),c=l;c<=s+u;c=c+u)o.push(lJ(c));else if(a>pd)for(var f=Math.ceil(a/pd),h=IA(r),v=sJ(r,t),c=0;c<=v+f;c=c+f)o.push(uJ(l,c+h));else if(a>Xo)for(var d=new Date(r),p=d.getFullYear(),x=d.getMonth(),m=d.getDate(),_=Math.ceil(a/Xo),b=cJ(r,t),c=0;c<b+_;c=c+_)o.push(new Date(p,x,m+c).getTime());else if(a>Ru)for(var d=new Date(r),p=d.getFullYear(),x=d.getMonth(),_=d.getDate(),w=d.getHours(),S=Math.ceil(a/Ru),M=fJ(r,t),c=0;c<=M+S;c=c+S)o.push(new Date(p,x,_,w+c).getTime());else if(a>ku)for(var F=hJ(r,t),O=Math.ceil(a/ku),c=0;c<=F+O;c=c+O)o.push(r+c*ku);else{var L=a;L<pa&&(L=pa);for(var D=Math.floor(r/pa)*pa,k=Math.ceil((t-r)/pa),H=Math.ceil(L/pa),c=0;c<k+H;c=c+H)o.push(D+c*pa)}return o.length>=512&&console.warn("Notice: current ticks length("+o.length+') >= 512, may cause performance issues, even out of memory. Because of the configure "tickInterval"(in milliseconds, current is '+a+") is too small, increase the value to solve the problem!"),o}Kn("cat",y5);Kn("time-cat",oJ);Kn("wilkinson-extended",JK);Kn("r-pretty",nJ);Kn("time",aJ);Kn("time-pretty",vJ);Kn("log",tJ);Kn("pow",eJ);Kn("quantile",iJ);Kn("d3-linear",zK);Jn("cat",Pp);Jn("category",Pp);Jn("identity",g5);Jn("linear",Ah);Jn("log",f5);Jn("pow",h5);Jn("time",v5);Jn("timeCat",u5);Jn("quantize",$M);Jn("quantile",d5);var dJ=Object.freeze(Object.defineProperty({__proto__:null,Category:Pp,Identity:g5,Linear:Ah,Log:f5,Pow:h5,Time:v5,TimeCat:u5,Quantile:d5,Quantize:$M,Scale:Sh,getScale:zd,registerScale:Jn,getTickMethod:QV,registerTickMethod:Kn},Symbol.toStringTag,{value:"Module"})),x5={},BM=function(e){return x5[e.toLowerCase()]},Th=function(e,r){if(BM(e))throw new Error("Attribute type '".concat(e,"' existed."));x5[e.toLowerCase()]=r};Th("Color",YV);Th("Opacity",WV);Th("Position",XV);Th("Shape",UV);Th("Size",qV);var pJ=Object.freeze(Object.defineProperty({__proto__:null,registerAttribute:Th,getAttribute:BM,Attribute:Ch,Color:YV,Opacity:WV,Position:XV,Shape:UV,Size:qV,Scale:Sh},Symbol.toStringTag,{value:"Module"})),LA=br(pJ),Ip=function(){function e(r){this.type="coordinate",this.isRect=!1,this.isHelix=!1,this.isPolar=!1,this.isReflectX=!1,this.isReflectY=!1;var t=r.start,i=r.end,n=r.matrix,a=n===void 0?[1,0,0,0,1,0,0,0,1]:n,o=r.isTransposed,l=o===void 0?!1:o;this.start=t,this.end=i,this.matrix=a,this.originalMatrix=Qr([],a),this.isTransposed=l}return e.prototype.initial=function(){this.center={x:(this.start.x+this.end.x)/2,y:(this.start.y+this.end.y)/2},this.width=Math.abs(this.end.x-this.start.x),this.height=Math.abs(this.end.y-this.start.y)},e.prototype.update=function(r){Kt(this,r),this.initial()},e.prototype.convertDim=function(r,t){var i,n=this[t],a=n.start,o=n.end;return this.isReflect(t)&&(i=[o,a],a=i[0],o=i[1]),a+r*(o-a)},e.prototype.invertDim=function(r,t){var i,n=this[t],a=n.start,o=n.end;return this.isReflect(t)&&(i=[o,a],a=i[0],o=i[1]),(r-a)/(o-a)},e.prototype.applyMatrix=function(r,t,i){i===void 0&&(i=0);var n=this.matrix,a=[r,t,i];return kf(a,a,n),a},e.prototype.invertMatrix=function(r,t,i){i===void 0&&(i=0);var n=this.matrix,a=Oz([0,0,0,0,0,0,0,0,0],n),o=[r,t,i];return a&&kf(o,o,a),o},e.prototype.convert=function(r){var t=this.convertPoint(r),i=t.x,n=t.y,a=this.applyMatrix(i,n,1);return{x:a[0],y:a[1]}},e.prototype.invert=function(r){var t=this.invertMatrix(r.x,r.y,1);return this.invertPoint({x:t[0],y:t[1]})},e.prototype.rotate=function(r){var t=this.matrix,i=this.center;return xu(t,t,[-i.x,-i.y]),o1(t,t,r),xu(t,t,[i.x,i.y]),this},e.prototype.reflect=function(r){return r==="x"?this.isReflectX=!this.isReflectX:this.isReflectY=!this.isReflectY,this},e.prototype.scale=function(r,t){var i=this.matrix,n=this.center;return xu(i,i,[-n.x,-n.y]),_M(i,i,[r,t]),xu(i,i,[n.x,n.y]),this},e.prototype.translate=function(r,t){var i=this.matrix;return xu(i,i,[r,t]),this},e.prototype.transpose=function(){return this.isTransposed=!this.isTransposed,this},e.prototype.getCenter=function(){return this.center},e.prototype.getWidth=function(){return this.width},e.prototype.getHeight=function(){return this.height},e.prototype.getRadius=function(){return this.radius},e.prototype.isReflect=function(r){return r==="x"?this.isReflectX:this.isReflectY},e.prototype.resetMatrix=function(r){this.matrix=r||Qr([],this.originalMatrix)},e}(),_5=function(e){X(r,e);function r(t){var i=e.call(this,t)||this;return i.isRect=!0,i.type="cartesian",i.initial(),i}return r.prototype.initial=function(){e.prototype.initial.call(this);var t=this.start,i=this.end;this.x={start:t.x,end:i.x},this.y={start:t.y,end:i.y}},r.prototype.convertPoint=function(t){var i,n=t.x,a=t.y;return this.isTransposed&&(i=[a,n],n=i[0],a=i[1]),{x:this.convertDim(n,"x"),y:this.convertDim(a,"y")}},r.prototype.invertPoint=function(t){var i,n=this.invertDim(t.x,"x"),a=this.invertDim(t.y,"y");return this.isTransposed&&(i=[a,n],n=i[0],a=i[1]),{x:n,y:a}},r}(Ip),gJ=function(e){X(r,e);function r(t){var i=e.call(this,t)||this;i.isHelix=!0,i.type="helix";var n=t.startAngle,a=n===void 0?1.25*Math.PI:n,o=t.endAngle,l=o===void 0?7.25*Math.PI:o,s=t.innerRadius,u=s===void 0?0:s,c=t.radius;return i.startAngle=a,i.endAngle=l,i.innerRadius=u,i.radius=c,i.initial(),i}return r.prototype.initial=function(){e.prototype.initial.call(this);var t=(this.endAngle-this.startAngle)/(2*Math.PI)+1,i=Math.min(this.width,this.height)/2;this.radius&&this.radius>=0&&this.radius<=1&&(i=i*this.radius),this.d=Math.floor(i*(1-this.innerRadius)/t),this.a=this.d/(Math.PI*2),this.x={start:this.startAngle,end:this.endAngle},this.y={start:this.innerRadius*i,end:this.innerRadius*i+this.d*.99}},r.prototype.convertPoint=function(t){var i,n=t.x,a=t.y;this.isTransposed&&(i=[a,n],n=i[0],a=i[1]);var o=this.convertDim(n,"x"),l=this.a*o,s=this.convertDim(a,"y");return{x:this.center.x+Math.cos(o)*(l+s),y:this.center.y+Math.sin(o)*(l+s)}},r.prototype.invertPoint=function(t){var i,n=this.d+this.y.start,a=yM([0,0],[t.x,t.y],[this.center.x,this.center.y]),o=l1(a,[1,0],!0),l=o*this.a;Wl(a)<l&&(l=Wl(a));var s=Math.floor((Wl(a)-l)/n);o=2*s*Math.PI+o;var u=this.a*o,c=Wl(a)-u;c=zr(c,0)?0:c;var f=this.invertDim(o,"x"),h=this.invertDim(c,"y");return f=zr(f,0)?0:f,h=zr(h,0)?0:h,this.isTransposed&&(i=[h,f],f=i[0],h=i[1]),{x:f,y:h}},r}(Ip),yJ=function(e){X(r,e);function r(t){var i=e.call(this,t)||this;i.isPolar=!0,i.type="polar";var n=t.startAngle,a=n===void 0?-Math.PI/2:n,o=t.endAngle,l=o===void 0?Math.PI*3/2:o,s=t.innerRadius,u=s===void 0?0:s,c=t.radius;return i.startAngle=a,i.endAngle=l,i.innerRadius=u,i.radius=c,i.initial(),i}return r.prototype.initial=function(){for(e.prototype.initial.call(this);this.endAngle<this.startAngle;)this.endAngle+=Math.PI*2;var t=this.getOneBox(),i=t.maxX-t.minX,n=t.maxY-t.minY,a=Math.abs(t.minX)/i,o=Math.abs(t.minY)/n,l;this.height/n>this.width/i?(l=this.width/i,this.circleCenter={x:this.center.x-(.5-a)*this.width,y:this.center.y-(.5-o)*l*n}):(l=this.height/n,this.circleCenter={x:this.center.x-(.5-a)*l*i,y:this.center.y-(.5-o)*this.height}),this.polarRadius=this.radius,this.radius?this.radius>0&&this.radius<=1?this.polarRadius=l*this.radius:(this.radius<=0||this.radius>l)&&(this.polarRadius=l):this.polarRadius=l,this.x={start:this.startAngle,end:this.endAngle},this.y={start:this.innerRadius*this.polarRadius,end:this.polarRadius}},r.prototype.getRadius=function(){return this.polarRadius},r.prototype.convertPoint=function(t){var i,n=this.getCenter(),a=t.x,o=t.y;return this.isTransposed&&(i=[o,a],a=i[0],o=i[1]),a=this.convertDim(a,"x"),o=this.convertDim(o,"y"),{x:n.x+Math.cos(a)*o,y:n.y+Math.sin(a)*o}},r.prototype.invertPoint=function(t){var i,n=this.getCenter(),a=[t.x-n.x,t.y-n.y],o=this,l=o.startAngle,s=o.endAngle;this.isReflect("x")&&(i=[s,l],l=i[0],s=i[1]);var u=[1,0,0,0,1,0,0,0,1];o1(u,u,l);var c=[1,0,0];kf(c,c,u);var f=[c[0],c[1]],h=l1(f,a,s<l);zr(h,Math.PI*2)&&(h=0);var v=Wl(a),d=h/(s-l);d=s-l>0?d:-d;var p=this.invertDim(v,"y"),x={x:0,y:0};return x.x=this.isTransposed?p:d,x.y=this.isTransposed?d:p,x},r.prototype.getCenter=function(){return this.circleCenter},r.prototype.getOneBox=function(){var t=this.startAngle,i=this.endAngle;if(Math.abs(i-t)>=Math.PI*2)return{minX:-1,maxX:1,minY:-1,maxY:1};for(var n=[0,Math.cos(t),Math.cos(i)],a=[0,Math.sin(t),Math.sin(i)],o=Math.min(t,i);o<Math.max(t,i);o+=Math.PI/18)n.push(Math.cos(o)),a.push(Math.sin(o));return{minX:Math.min.apply(Math,n),maxX:Math.max.apply(Math,n),minY:Math.min.apply(Math,a),maxY:Math.max.apply(Math,a)}},r}(Ip),b5={},w5=function(e){return b5[e.toLowerCase()]},Lp=function(e,r){b5[e.toLowerCase()]=r};Lp("rect",_5);Lp("cartesian",_5);Lp("polar",yJ);Lp("helix",gJ);var mJ=Object.freeze(Object.defineProperty({__proto__:null,getCoordinate:w5,registerCoordinate:Lp,Coordinate:Ip},Symbol.toStringTag,{value:"Module"})),xJ=br(mJ),_J=br(dJ);function NM(e,r,t){var i=new bh(r,t);i.target=e,i.propagationPath.push(e),e.emitDelegation(r,i);for(var n=e.getParent();n;)n.emitDelegation(r,i),i.propagationPath.push(n),n=n.getParent()}var C5=[1,0,0,0,1,0,0,0,1];function qu(e,r,t){if(t===void 0&&(t=C5),!r)return null;var i=rr(t,[["t",-e.x,-e.y],["r",r],["t",e.x,e.y]]);return i}function GM(e,r){return!e.x&&!e.y?null:rr(r||C5,[["t",e.x,e.y]])}function bJ(e){var r=[1,0,0],t=[0,0,0];return kf(t,r,e),Math.atan2(t[1],t[0])}function jy(e,r){var t=[0,0];return Zz(t,r,e),t}function wJ(e,r){var t=jy(e,[r.minX,r.minY]),i=jy(e,[r.maxX,r.minY]),n=jy(e,[r.minX,r.maxY]),a=jy(e,[r.maxX,r.maxY]),o=Math.min(t[0],i[0],n[0],a[0]),l=Math.max(t[0],i[0],n[0],a[0]),s=Math.min(t[1],i[1],n[1],a[1]),u=Math.max(t[1],i[1],n[1],a[1]);return{x:o,y:s,minX:o,minY:s,maxX:l,maxY:u,width:l-o,height:u-s}}function S5(e,r,t,i){if(r){var n=qu({x:t,y:i},r,e.getMatrix());e.setMatrix(n)}}function gd(e,r,t){var i=GM({x:r,y:t});e.attr("matrix",i)}function K0(e){var r=0,t=0,i=0,n=0;return Mt(e)?r=t=i=n=e:it(e)&&(r=e[0],i=K(e[1])?e[0]:e[1],n=K(e[2])?e[0]:e[2],t=K(e[3])?i:e[3]),[r,i,n,t]}function zM(e){for(var r=e.childNodes,t=r.length,i=t-1;i>=0;i--)e.removeChild(r[i])}function CJ(e,r){return!!e.className.match(new RegExp("(\\s|^)"+r+"(\\s|$)"))}function Vd(e){var r=e.start,t=e.end,i=Math.min(r.x,t.x),n=Math.min(r.y,t.y),a=Math.max(r.x,t.x),o=Math.max(r.y,t.y);return{x:i,y:n,minX:i,minY:n,maxX:a,maxY:o,width:a-i,height:o-n}}function SJ(e){var r=e.map(function(l){return l.x}),t=e.map(function(l){return l.y}),i=Math.min.apply(Math,r),n=Math.min.apply(Math,t),a=Math.max.apply(Math,r),o=Math.max.apply(Math,t);return{x:i,y:n,minX:i,minY:n,maxX:a,maxY:o,width:a-i,height:o-n}}function g1(e,r,t,i){var n=e+t,a=r+i;return{x:e,y:r,width:t,height:i,minX:e,minY:r,maxX:isNaN(n)?0:n,maxY:isNaN(a)?0:a}}function Bu(e,r,t){return(1-t)*e+r*t}function Sf(e,r,t){return{x:e.x+Math.cos(t)*r,y:e.y+Math.sin(t)*r}}function AJ(e,r){var t=r.x-e.x,i=r.y-e.y;return Math.sqrt(t*t+i*i)}var J0=function(e,r,t){return t===void 0&&(t=Math.pow(Number.EPSILON,.5)),[e,r].includes(1/0)?Math.abs(e)===Math.abs(r):Math.abs(e-r)<t};function TJ(e,r){var t=Math.max(e.minX,r.minX),i=Math.max(e.minY,r.minY),n=Math.min(e.maxX,r.maxX),a=Math.min(e.maxY,r.maxY);return g1(t,i,n-t,a-i)}function A5(e){var r=e.getClip(),t=r&&r.getBBox(),i;if(!e.isGroup())i=e.getBBox();else{var n=1/0,a=-1/0,o=1/0,l=-1/0,s=e.getChildren();s.length>0?P(s,function(u){if(u.get("visible")){if(u.isGroup()&&u.get("children").length===0)return!0;var c=A5(u),f=u.applyToMatrix([c.minX,c.minY,1]),h=u.applyToMatrix([c.minX,c.maxY,1]),v=u.applyToMatrix([c.maxX,c.minY,1]),d=u.applyToMatrix([c.maxX,c.maxY,1]),p=Math.min(f[0],h[0],v[0],d[0]),x=Math.max(f[0],h[0],v[0],d[0]),m=Math.min(f[1],h[1],v[1],d[1]),_=Math.max(f[1],h[1],v[1],d[1]);p<n&&(n=p),x>a&&(a=x),m<o&&(o=m),_>l&&(l=_)}}):(n=0,a=0,o=0,l=0),i=g1(n,o,a-n,l-o)}return t?TJ(i,t):i}function MJ(e,r){if(!(!e.getClip()&&!r.getClip())){var t=r.getClip();if(!t){e.setClip(null);return}var i={type:t.get("type"),attrs:t.attr()};e.setClip(i)}}function Ni(e){return e+"px"}function T5(e,r,t,i){var n=AJ(e,r),a=i/n,o=0;return t==="start"?o=0-a:t==="end"&&(o=1+a),{x:Bu(e.x,r.x,o),y:Bu(e.y,r.y,o)}}var EJ={none:[],point:["x","y"],region:["start","end"],points:["points"],circle:["center","radius","startAngle","endAngle"]},VM=function(e){X(r,e);function r(t){var i=e.call(this,t)||this;return i.initCfg(),i}return r.prototype.getDefaultCfg=function(){return{id:"",name:"",type:"",locationType:"none",offsetX:0,offsetY:0,animate:!1,capture:!0,updateAutoRender:!1,animateOption:{appear:null,update:{duration:400,easing:"easeQuadInOut"},enter:{duration:400,easing:"easeQuadInOut"},leave:{duration:350,easing:"easeQuadIn"}},events:null,defaultCfg:{},visible:!0}},r.prototype.clear=function(){},r.prototype.update=function(t){var i=this,n=this.get("defaultCfg")||{};P(t,function(a,o){var l=i.get(o),s=a;l!==a&&(Zt(a)&&n[o]&&(s=ft({},n[o],a)),i.set(o,s))}),this.updateInner(t),this.afterUpdate(t)},r.prototype.updateInner=function(t){},r.prototype.afterUpdate=function(t){po(t,"visible")&&(t.visible?this.show():this.hide()),po(t,"capture")&&this.setCapture(t.capture)},r.prototype.getLayoutBBox=function(){return this.getBBox()},r.prototype.getLocationType=function(){return this.get("locationType")},r.prototype.getOffset=function(){return{offsetX:this.get("offsetX"),offsetY:this.get("offsetY")}},r.prototype.setOffset=function(t,i){this.update({offsetX:t,offsetY:i})},r.prototype.setLocation=function(t){var i=A({},t);this.update(i)},r.prototype.getLocation=function(){var t=this,i={},n=this.get("locationType"),a=EJ[n];return P(a,function(o){i[o]=t.get(o)}),i},r.prototype.isList=function(){return!1},r.prototype.isSlider=function(){return!1},r.prototype.init=function(){},r.prototype.initCfg=function(){var t=this,i=this.get("defaultCfg");P(i,function(n,a){var o=t.get(a);if(Zt(o)){var l=ft({},n,o);t.set(a,l)}})},r}(mp),tu="update_status",FJ=["visible","tip","delegateObject"],OJ=["container","group","shapesMap","isRegister","isUpdating","destroyed"],Hr=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{container:null,shapesMap:{},group:null,capture:!0,isRegister:!1,isUpdating:!1,isInit:!0})},r.prototype.remove=function(){this.clear();var t=this.get("group");t.remove()},r.prototype.clear=function(){var t=this.get("group");t.clear(),this.set("shapesMap",{}),this.clearOffScreenCache(),this.set("isInit",!0)},r.prototype.getChildComponentById=function(t){var i=this.getElementById(t),n=i&&i.get("component");return n},r.prototype.getElementById=function(t){return this.get("shapesMap")[t]},r.prototype.getElementByLocalId=function(t){var i=this.getElementId(t);return this.getElementById(i)},r.prototype.getElementsByName=function(t){var i=[];return P(this.get("shapesMap"),function(n){n.get("name")===t&&i.push(n)}),i},r.prototype.getContainer=function(){return this.get("container")},r.prototype.updateInner=function(t){this.offScreenRender(),this.get("updateAutoRender")&&this.render()},r.prototype.render=function(){var t=this.get("offScreenGroup");t||(t=this.offScreenRender());var i=this.get("group");this.updateElements(t,i),this.deleteElements(),this.applyOffset(),this.get("eventInitted")||(this.initEvent(),this.set("eventInitted",!0)),this.set("isInit",!1)},r.prototype.show=function(){var t=this.get("group");t.show(),this.set("visible",!0)},r.prototype.hide=function(){var t=this.get("group");t.hide(),this.set("visible",!1)},r.prototype.setCapture=function(t){var i=this.get("group");i.set("capture",t),this.set("capture",t)},r.prototype.destroy=function(){this.removeEvent(),this.remove(),e.prototype.destroy.call(this)},r.prototype.getBBox=function(){return this.get("group").getCanvasBBox()},r.prototype.getLayoutBBox=function(){var t=this.get("group"),i=this.getInnerLayoutBBox(),n=t.getTotalMatrix();return n&&(i=wJ(n,i)),i},r.prototype.on=function(t,i,n){var a=this.get("group");return a.on(t,i,n),this},r.prototype.off=function(t,i){var n=this.get("group");return n&&n.off(t,i),this},r.prototype.emit=function(t,i){var n=this.get("group");n.emit(t,i)},r.prototype.init=function(){e.prototype.init.call(this),this.get("group")||this.initGroup(),this.offScreenRender()},r.prototype.getInnerLayoutBBox=function(){return this.get("offScreenBBox")||this.get("group").getBBox()},r.prototype.delegateEmit=function(t,i){var n=this.get("group");i.target=n,n.emit(t,i),NM(n,t,i)},r.prototype.createOffScreenGroup=function(){var t=this.get("group"),i=t.getGroupBase(),n=new i({delegateObject:this.getDelegateObject()});return n},r.prototype.applyOffset=function(){var t=this.get("offsetX"),i=this.get("offsetY");this.moveElementTo(this.get("group"),{x:t,y:i})},r.prototype.initGroup=function(){var t=this.get("container");this.set("group",t.addGroup({id:this.get("id"),name:this.get("name"),capture:this.get("capture"),visible:this.get("visible"),isComponent:!0,component:this,delegateObject:this.getDelegateObject()}))},r.prototype.offScreenRender=function(){this.clearOffScreenCache();var t=this.createOffScreenGroup();return this.renderInner(t),this.set("offScreenGroup",t),this.set("offScreenBBox",A5(t)),t},r.prototype.addGroup=function(t,i){this.appendDelegateObject(t,i);var n=t.addGroup(i);return this.get("isRegister")&&this.registerElement(n),n},r.prototype.addShape=function(t,i){this.appendDelegateObject(t,i);var n=t.addShape(i);return this.get("isRegister")&&this.registerElement(n),n},r.prototype.addComponent=function(t,i){var n=i.id,a=i.component,o=ue(i,["id","component"]),l=new a(A(A({},o),{id:n,container:t,updateAutoRender:this.get("updateAutoRender")}));return l.init(),l.render(),this.get("isRegister")&&this.registerElement(l.get("group")),l},r.prototype.initEvent=function(){},r.prototype.removeEvent=function(){var t=this.get("group");t.off()},r.prototype.getElementId=function(t){var i=this.get("id"),n=this.get("name");return i+"-"+n+"-"+t},r.prototype.registerElement=function(t){var i=t.get("id");this.get("shapesMap")[i]=t},r.prototype.unregisterElement=function(t){var i=t.get("id");delete this.get("shapesMap")[i]},r.prototype.moveElementTo=function(t,i){var n=GM(i);t.attr("matrix",n)},r.prototype.addAnimation=function(t,i,n){var a=i.attr("opacity");K(a)&&(a=1),i.attr("opacity",0),i.animate({opacity:a},n)},r.prototype.removeAnimation=function(t,i,n){i.animate({opacity:0},n)},r.prototype.updateAnimation=function(t,i,n,a){i.animate(n,a)},r.prototype.updateElements=function(t,i){var n=this,a=this.get("animate"),o=this.get("animateOption"),l=t.getChildren().slice(0),s;P(l,function(u){var c=u.get("id"),f=n.getElementById(c),h=u.get("name");if(f)if(u.get("isComponent")){var v=u.get("component"),d=f.get("component"),p=r1(v.cfg,HG(lc(v.cfg),OJ));d.update(p),f.set(tu,"update")}else{var x=n.getReplaceAttrs(f,u);a&&o.update?n.updateAnimation(h,f,x,o.update):f.attr(x),u.isGroup()&&n.updateElements(u,f),P(FJ,function(w){f.set(w,u.get(w))}),MJ(f,u),s=f,f.set(tu,"update")}else{i.add(u);var m=i.getChildren();if(m.splice(m.length-1,1),s){var _=m.indexOf(s);m.splice(_+1,0,u)}else m.unshift(u);if(n.registerElement(u),u.set(tu,"add"),u.get("isComponent")){var v=u.get("component");v.set("container",i)}else u.isGroup()&&n.registerNewGroup(u);if(s=u,a){var b=n.get("isInit")?o.appear:o.enter;b&&n.addAnimation(h,u,b)}}})},r.prototype.clearUpdateStatus=function(t){var i=t.getChildren();P(i,function(n){n.set(tu,null)})},r.prototype.clearOffScreenCache=function(){var t=this.get("offScreenGroup");t&&t.destroy(),this.set("offScreenGroup",null),this.set("offScreenBBox",null)},r.prototype.getDelegateObject=function(){var t,i=this.get("name"),n=(t={},t[i]=this,t.component=this,t);return n},r.prototype.appendDelegateObject=function(t,i){var n=t.get("delegateObject");i.delegateObject||(i.delegateObject={}),Kt(i.delegateObject,n)},r.prototype.getReplaceAttrs=function(t,i){var n=t.attr(),a=i.attr();return P(n,function(o,l){a[l]===void 0&&(a[l]=void 0)}),a},r.prototype.registerNewGroup=function(t){var i=this,n=t.getChildren();P(n,function(a){i.registerElement(a),a.set(tu,"add"),a.isGroup()&&i.registerNewGroup(a)})},r.prototype.deleteElements=function(){var t=this,i=this.get("shapesMap"),n=[];P(i,function(l,s){!l.get(tu)||l.destroyed?n.push([s,l]):l.set(tu,null)});var a=this.get("animate"),o=this.get("animateOption");P(n,function(l){var s=l[0],u=l[1];if(!u.destroyed){var c=u.get("name");if(a&&o.leave){var f=Kt({callback:function(){t.removeElement(u)}},o.leave);t.removeAnimation(c,u,f)}else t.removeElement(u)}delete i[s]})},r.prototype.removeElement=function(t){if(t.get("isGroup")){var i=t.get("component");i&&i.destroy()}t.remove()},r}(VM),Kw="\u2026";function PJ(e){for(var r=0,t=0;t<e.length;t++)r+=du(e,t);return r}function du(e,r){return e.charCodeAt(r)>0&&e.charCodeAt(r)<128?1:2}function IJ(e,r,t){t===void 0&&(t="tail");var i=e.length,n="";if(t==="tail"){for(var a=0,o=0;a<r;){var l=du(e,o);if(a+l<=r)n+=e[o],a+=du(e,o),o++;else break}n+=Kw}else if(t==="head"){for(var a=0,o=i-1;a<r;){var l=du(e,o);if(a+l<=r)n+=e[o],a+=du(e,o),o--;else break}n=Kw+n}else{for(var s="",u="",a=0,c=0,f=i-1;a<r;){var h=du(e,c),v=!1;h+a<=r&&(s+=e[c],c++,a+=h,v=!0);var d=du(e,f);if(d+a<=r&&(u=e[f]+u,a+=d,f--,v=!0),!v)break}n=s+Kw+u}return n}var LJ="\u2026",DJ=2,$J=400;function kJ(e){for(var r=e.map(function(s){var u=s.attr("text");return K(u)?"":""+u}),t=0,i=0,n=0;n<r.length;n+=1){for(var a=0,o=0;o<=r[n].length;o+=1){var l=r[n].charCodeAt(o);l>=19968&&l<=40869?a+=2:a+=1}a>t&&(t=a,i=n)}return e[i].getBBox().width}function DA(e){if(e.length>$J)return kJ(e);var r=0;return P(e,function(t){var i=t.getBBox(),n=i.width;r<n&&(r=n)}),r}function RJ(e,r){var t=r.getCanvasBBox();return e?t.width:t.height}function yd(e,r,t,i){var n;i===void 0&&(i="tail");var a=(n=r.attr("text"))!==null&&n!==void 0?n:"";if(i==="tail"){var o=r1(r.attr(),["fontSize","fontFamily","fontWeight","fontStyle","fontVariant"]),l=oz(a,t,o,"\u2026");return a!==l?(r.attr("text",l),r.set("tip",a),!0):(r.set("tip",null),!1)}var s=RJ(e,r),u=PJ(a),c=!1;if(t<s){var f=Math.floor(t/s*u)-DJ,h=void 0;f>=0?h=IJ(a,f,i):h=LJ,h&&(r.attr("text",h),c=!0)}return c?r.set("tip",a):r.set("tip",null),c}function y1(e,r){var t=r.x,i=r.y,n=r.content,a=r.style,o=r.id,l=r.name,s=r.rotate,u=r.maxLength,c=r.autoEllipsis,f=r.isVertical,h=r.ellipsisPosition,v=r.background,d=e.addGroup({id:o+"-group",name:l+"-group",attrs:{x:t,y:i}}),p=d.addShape({type:"text",id:o,name:l,attrs:A({x:0,y:0,text:n},a)}),x=K0(I(v,"padding",0));if(u&&c){var m=u-(x[1]+x[3]);yd(!f,p,m,h)}if(v){var _=I(v,"style",{}),b=p.getCanvasBBox(),w=b.minX,S=b.minY,M=b.width,F=b.height,O=d.addShape("rect",{id:o+"-bg",name:o+"-bg",attrs:A({x:w-x[3],y:S-x[0],width:M+x[1]+x[3],height:F+x[0]+x[2]},_)});O.toBack()}gd(d,t,i),S5(d,s,t,i)}var Ht={fontFamily:`
|
|
BlinkMacSystemFont, "Segoe UI", Roboto,"Helvetica Neue",
|
|
Helvetica, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei",
|
|
SimSun, "sans-serif"`,textColor:"#2C3542",activeTextColor:"#333333",uncheckedColor:"#D8D8D8",lineColor:"#416180",regionColor:"#CCD7EB",verticalAxisRotate:-Math.PI/4,horizontalAxisRotate:Math.PI/4,descriptionIconStroke:"#fff",descriptionIconFill:"rgba(58, 73, 101, .25)"},BJ=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{name:"annotation",type:"line",locationType:"region",start:null,end:null,style:{},text:null,defaultCfg:{style:{fill:Ht.textColor,fontSize:12,textAlign:"center",textBaseline:"bottom",fontFamily:Ht.fontFamily},text:{position:"center",autoRotate:!0,content:null,offsetX:0,offsetY:0,style:{stroke:Ht.lineColor,lineWidth:1}}}})},r.prototype.renderInner=function(t){this.renderLine(t),this.get("text")&&this.renderLabel(t)},r.prototype.renderLine=function(t){var i=this.get("start"),n=this.get("end"),a=this.get("style");this.addShape(t,{type:"line",id:this.getElementId("line"),name:"annotation-line",attrs:A({x1:i.x,y1:i.y,x2:n.x,y2:n.y},a)})},r.prototype.getLabelPoint=function(t,i,n){var a;return n==="start"?a=0:n==="center"?a=.5:Ct(n)&&n.indexOf("%")!==-1?a=parseInt(n,10)/100:Mt(n)?a=n:a=1,(a>1||a<0)&&(a=1),{x:Bu(t.x,i.x,a),y:Bu(t.y,i.y,a)}},r.prototype.renderLabel=function(t){var i=this.get("text"),n=this.get("start"),a=this.get("end"),o=i.position,l=i.content,s=i.style,u=i.offsetX,c=i.offsetY,f=i.autoRotate,h=i.maxLength,v=i.autoEllipsis,d=i.ellipsisPosition,p=i.background,x=i.isVertical,m=x===void 0?!1:x,_=this.getLabelPoint(n,a,o),b=_.x+u,w=_.y+c,S={id:this.getElementId("line-text"),name:"annotation-line-text",x:b,y:w,content:l,style:s,maxLength:h,autoEllipsis:v,ellipsisPosition:d,background:p,isVertical:m};if(f){var M=[a.x-n.x,a.y-n.y];S.rotate=Math.atan2(M[1],M[0])}y1(t,S)},r}(Hr),NJ=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{name:"annotation",type:"text",locationType:"point",x:0,y:0,content:"",rotate:null,style:{},background:null,maxLength:null,autoEllipsis:!0,isVertical:!1,ellipsisPosition:"tail",defaultCfg:{style:{fill:Ht.textColor,fontSize:12,textAlign:"center",textBaseline:"middle",fontFamily:Ht.fontFamily}}})},r.prototype.setLocation=function(t){this.set("x",t.x),this.set("y",t.y),this.resetLocation()},r.prototype.renderInner=function(t){var i=this.getLocation(),n=i.x,a=i.y,o=this.get("content"),l=this.get("style"),s=this.getElementId("text"),u=this.get("name")+"-text",c=this.get("maxLength"),f=this.get("autoEllipsis"),h=this.get("isVertical"),v=this.get("ellipsisPosition"),d=this.get("background"),p=this.get("rotate"),x={id:s,name:u,x:n,y:a,content:o,style:l,maxLength:c,autoEllipsis:f,isVertical:h,ellipsisPosition:v,background:d,rotate:p};y1(t,x)},r.prototype.resetLocation=function(){var t=this.getElementByLocalId("text-group");if(t){var i=this.getLocation(),n=i.x,a=i.y,o=this.get("rotate");gd(t,n,a),S5(t,o,n,a)}},r}(Hr),GJ=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{name:"annotation",type:"arc",locationType:"circle",center:null,radius:100,startAngle:-Math.PI/2,endAngle:Math.PI*3/2,style:{stroke:"#999",lineWidth:1}})},r.prototype.renderInner=function(t){this.renderArc(t)},r.prototype.getArcPath=function(){var t=this.getLocation(),i=t.center,n=t.radius,a=t.startAngle,o=t.endAngle,l=Sf(i,n,a),s=Sf(i,n,o),u=o-a>Math.PI?1:0,c=[["M",l.x,l.y]];if(o-a===Math.PI*2){var f=Sf(i,n,a+Math.PI);c.push(["A",n,n,0,u,1,f.x,f.y]),c.push(["A",n,n,0,u,1,s.x,s.y])}else c.push(["A",n,n,0,u,1,s.x,s.y]);return c},r.prototype.renderArc=function(t){var i=this.getArcPath(),n=this.get("style");this.addShape(t,{type:"path",id:this.getElementId("arc"),name:"annotation-arc",attrs:A({path:i},n)})},r}(Hr),zJ=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{name:"annotation",type:"region",locationType:"region",start:null,end:null,style:{},defaultCfg:{style:{lineWidth:0,fill:Ht.regionColor,opacity:.4}}})},r.prototype.renderInner=function(t){this.renderRegion(t)},r.prototype.renderRegion=function(t){var i=this.get("start"),n=this.get("end"),a=this.get("style"),o=Vd({start:i,end:n});this.addShape(t,{type:"rect",id:this.getElementId("region"),name:"annotation-region",attrs:A({x:o.x,y:o.y,width:o.width,height:o.height},a)})},r}(Hr),VJ=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{name:"annotation",type:"image",locationType:"region",start:null,end:null,src:null,style:{}})},r.prototype.renderInner=function(t){this.renderImage(t)},r.prototype.getImageAttrs=function(){var t=this.get("start"),i=this.get("end"),n=this.get("style"),a=Vd({start:t,end:i}),o=this.get("src");return A({x:a.x,y:a.y,img:o,width:a.width,height:a.height},n)},r.prototype.renderImage=function(t){this.addShape(t,{type:"image",id:this.getElementId("image"),name:"annotation-image",attrs:this.getImageAttrs()})},r}(Hr),jJ=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{name:"annotation",type:"dataMarker",locationType:"point",x:0,y:0,point:{},line:{},text:{},direction:"upward",autoAdjust:!0,coordinateBBox:null,defaultCfg:{point:{display:!0,style:{r:3,fill:"#FFFFFF",stroke:"#1890FF",lineWidth:2}},line:{display:!0,length:20,style:{stroke:Ht.lineColor,lineWidth:1}},text:{content:"",display:!0,style:{fill:Ht.textColor,opacity:.65,fontSize:12,textAlign:"start",fontFamily:Ht.fontFamily}}}})},r.prototype.renderInner=function(t){I(this.get("line"),"display")&&this.renderLine(t),I(this.get("text"),"display")&&this.renderText(t),I(this.get("point"),"display")&&this.renderPoint(t),this.get("autoAdjust")&&this.autoAdjust(t)},r.prototype.applyOffset=function(){this.moveElementTo(this.get("group"),{x:this.get("x")+this.get("offsetX"),y:this.get("y")+this.get("offsetY")})},r.prototype.renderPoint=function(t){var i=this.getShapeAttrs().point;this.addShape(t,{type:"circle",id:this.getElementId("point"),name:"annotation-point",attrs:i})},r.prototype.renderLine=function(t){var i=this.getShapeAttrs().line;this.addShape(t,{type:"path",id:this.getElementId("line"),name:"annotation-line",attrs:i})},r.prototype.renderText=function(t){var i=this.getShapeAttrs().text,n=i.x,a=i.y,o=i.text,l=ue(i,["x","y","text"]),s=this.get("text"),u=s.background,c=s.maxLength,f=s.autoEllipsis,h=s.isVertival,v=s.ellipsisPosition,d={x:n,y:a,id:this.getElementId("text"),name:"annotation-text",content:o,style:l,background:u,maxLength:c,autoEllipsis:f,isVertival:h,ellipsisPosition:v};y1(t,d)},r.prototype.autoAdjust=function(t){var i=this.get("direction"),n=this.get("x"),a=this.get("y"),o=I(this.get("line"),"length",0),l=this.get("coordinateBBox"),s=t.getBBox(),u=s.minX,c=s.maxX,f=s.minY,h=s.maxY,v=t.findById(this.getElementId("text-group")),d=t.findById(this.getElementId("text")),p=t.findById(this.getElementId("line"));if(!!l){if(v){if(n+u<=l.minX){var x=l.minX-(n+u);gd(v,v.attr("x")+x,v.attr("y"))}if(n+c>=l.maxX){var x=n+c-l.maxX;gd(v,v.attr("x")-x,v.attr("y"))}}if(i==="upward"&&a+f<=l.minY||i!=="upward"&&a+h>=l.maxY){var m=void 0,_=void 0;i==="upward"&&a+f<=l.minY?(m="top",_=1):(m="bottom",_=-1),d.attr("textBaseline",m),p&&p.attr("path",[["M",0,0],["L",0,o*_]]),gd(v,v.attr("x"),(o+2)*_)}}},r.prototype.getShapeAttrs=function(){var t=I(this.get("line"),"display"),i=I(this.get("point"),"style",{}),n=I(this.get("line"),"style",{}),a=I(this.get("text"),"style",{}),o=this.get("direction"),l=t?I(this.get("line"),"length",0):0,s=o==="upward"?-1:1;return{point:A({x:0,y:0},i),line:A({path:[["M",0,0],["L",0,l*s]]},n),text:A({x:0,y:(l+2)*s,text:I(this.get("text"),"content",""),textBaseline:o==="upward"?"bottom":"top"},a)}},r}(Hr),HJ=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{name:"annotation",type:"dataRegion",locationType:"points",points:[],lineLength:0,region:{},text:{},defaultCfg:{region:{style:{lineWidth:0,fill:Ht.regionColor,opacity:.4}},text:{content:"",style:{textAlign:"center",textBaseline:"bottom",fontSize:12,fill:Ht.textColor,fontFamily:Ht.fontFamily}}}})},r.prototype.renderInner=function(t){var i=I(this.get("region"),"style",{});I(this.get("text"),"style",{});var n=this.get("lineLength")||0,a=this.get("points");if(!!a.length){var o=SJ(a),l=[];l.push(["M",a[0].x,o.minY-n]),a.forEach(function(u){l.push(["L",u.x,u.y])}),l.push(["L",a[a.length-1].x,a[a.length-1].y-n]),this.addShape(t,{type:"path",id:this.getElementId("region"),name:"annotation-region",attrs:A({path:l},i)});var s=A({id:this.getElementId("text"),name:"annotation-text",x:(o.minX+o.maxX)/2,y:o.minY-n},this.get("text"));y1(t,s)}},r}(Hr),YJ=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{name:"annotation",type:"regionFilter",locationType:"region",start:null,end:null,color:null,shape:[]})},r.prototype.renderInner=function(t){var i=this,n=this.get("start"),a=this.get("end"),o=this.addGroup(t,{id:this.getElementId("region-filter"),capture:!1});P(this.get("shapes"),function(s,u){var c=s.get("type"),f=di(s.attr());i.adjustShapeAttrs(f),i.addShape(o,{id:i.getElementId("shape-"+c+"-"+u),capture:!1,type:c,attrs:f})});var l=Vd({start:n,end:a});o.setClip({type:"rect",attrs:{x:l.minX,y:l.minY,width:l.width,height:l.height}})},r.prototype.adjustShapeAttrs=function(t){var i=this.get("color");t.fill&&(t.fill=t.fillStyle=i),t.stroke=t.strokeStyle=i},r}(Hr),WJ=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{name:"annotation",type:"shape",draw:Wo})},r.prototype.renderInner=function(t){var i=this.get("render");pt(i)&&i(t)},r}(Hr),m1=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{container:null,containerTpl:"<div></div>",updateAutoRender:!0,containerClassName:"",parent:null})},r.prototype.getContainer=function(){return this.get("container")},r.prototype.show=function(){var t=this.get("container");t.style.display="",this.set("visible",!0)},r.prototype.hide=function(){var t=this.get("container");t.style.display="none",this.set("visible",!1)},r.prototype.setCapture=function(t){var i=this.getContainer(),n=t?"auto":"none";i.style.pointerEvents=n,this.set("capture",t)},r.prototype.getBBox=function(){var t=this.getContainer(),i=parseFloat(t.style.left)||0,n=parseFloat(t.style.top)||0;return g1(i,n,t.clientWidth,t.clientHeight)},r.prototype.clear=function(){var t=this.get("container");zM(t)},r.prototype.destroy=function(){this.removeEvent(),this.removeDom(),e.prototype.destroy.call(this)},r.prototype.init=function(){e.prototype.init.call(this),this.initContainer(),this.initDom(),this.resetStyles(),this.applyStyles(),this.initEvent(),this.initCapture(),this.initVisible()},r.prototype.initCapture=function(){this.setCapture(this.get("capture"))},r.prototype.initVisible=function(){this.get("visible")?this.show():this.hide()},r.prototype.initDom=function(){},r.prototype.initContainer=function(){var t=this.get("container");if(K(t)){t=this.createDom();var i=this.get("parent");Ct(i)&&(i=document.getElementById(i),this.set("parent",i)),i.appendChild(t),this.get("containerId")&&t.setAttribute("id",this.get("containerId")),this.set("container",t)}else Ct(t)&&(t=document.getElementById(t),this.set("container",t));this.get("parent")||this.set("parent",t.parentNode)},r.prototype.resetStyles=function(){var t=this.get("domStyles"),i=this.get("defaultStyles");t?t=ft({},i,t):t=i,this.set("domStyles",t)},r.prototype.applyStyles=function(){var t=this.get("domStyles");if(!!t){var i=this.getContainer();this.applyChildrenStyles(i,t);var n=this.get("containerClassName");if(n&&CJ(i,n)){var a=t[n];qr(i,a)}}},r.prototype.applyChildrenStyles=function(t,i){P(i,function(n,a){var o=t.getElementsByClassName(a);P(o,function(l){qr(l,n)})})},r.prototype.applyStyle=function(t,i){var n=this.get("domStyles");qr(i,n[t])},r.prototype.createDom=function(){var t=this.get("containerTpl");return Zo(t)},r.prototype.initEvent=function(){},r.prototype.removeDom=function(){var t=this.get("container");t&&t.parentNode&&t.parentNode.removeChild(t)},r.prototype.removeEvent=function(){},r.prototype.updateInner=function(t){po(t,"domStyles")&&(this.resetStyles(),this.applyStyles()),this.resetPosition()},r.prototype.resetPosition=function(){},r}(VM),XJ=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{name:"annotation",type:"html",locationType:"point",x:0,y:0,containerTpl:'<div class="g2-html-annotation" style="position:absolute"></div>',alignX:"left",alignY:"top",html:"",zIndex:7})},r.prototype.render=function(){var t=this.getContainer(),i=this.get("html");zM(t);var n=pt(i)?i(t):i;if(t1(n))t.appendChild(n);else if(Ct(n)||Mt(n)){var a=Zo(""+n);a&&t.appendChild(a)}this.resetPosition()},r.prototype.resetPosition=function(){var t=this.getContainer(),i=this.getLocation(),n=i.x,a=i.y,o=this.get("alignX"),l=this.get("alignY"),s=this.get("offsetX"),u=this.get("offsetY"),c=dz(t),f=hz(t),h={x:n,y:a};o==="middle"?h.x-=Math.round(c/2):o==="right"&&(h.x-=Math.round(c)),l==="middle"?h.y-=Math.round(f/2):l==="bottom"&&(h.y-=Math.round(f)),s&&(h.x+=s),u&&(h.y+=u),qr(t,{position:"absolute",left:h.x+"px",top:h.y+"px",zIndex:this.get("zIndex")})},r}(m1),M5=Object.freeze(Object.defineProperty({__proto__:null,Line:BJ,Text:NJ,Arc:GJ,Region:zJ,Image:VJ,DataMarker:jJ,DataRegion:HJ,RegionFilter:YJ,Shape:WJ,Html:XJ},Symbol.toStringTag,{value:"Module"}));function Yv(e,r,t){var i=r+"Style",n=null;return P(t,function(a,o){e[o]&&a[i]&&(n||(n={}),Kt(n,a[i]))}),n}var jM=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{name:"axis",ticks:[],line:{},tickLine:{},subTickLine:null,title:null,label:{},verticalFactor:1,verticalLimitLength:null,overlapOrder:["autoRotate","autoEllipsis","autoHide"],tickStates:{},optimize:{},defaultCfg:{line:{style:{lineWidth:1,stroke:Ht.lineColor}},tickLine:{style:{lineWidth:1,stroke:Ht.lineColor},alignTick:!0,length:5,displayWithLabel:!0},subTickLine:{style:{lineWidth:1,stroke:Ht.lineColor},count:4,length:2},label:{autoRotate:!0,autoHide:!1,autoEllipsis:!1,style:{fontSize:12,fill:Ht.textColor,fontFamily:Ht.fontFamily,fontWeight:"normal"},offset:10,offsetX:0,offsetY:0},title:{autoRotate:!0,spacing:5,position:"center",style:{fontSize:12,fill:Ht.textColor,textBaseline:"middle",fontFamily:Ht.fontFamily,textAlign:"center"},iconStyle:{fill:Ht.descriptionIconFill,stroke:Ht.descriptionIconStroke},description:""},tickStates:{active:{labelStyle:{fontWeight:500},tickLineStyle:{lineWidth:2}},inactive:{labelStyle:{fill:Ht.uncheckedColor}}},optimize:{enable:!0,threshold:400}},theme:{}})},r.prototype.renderInner=function(t){this.get("line")&&this.drawLine(t),this.drawTicks(t),this.get("title")&&this.drawTitle(t)},r.prototype.isList=function(){return!0},r.prototype.getItems=function(){return this.get("ticks")},r.prototype.setItems=function(t){this.update({ticks:t})},r.prototype.updateItem=function(t,i){Kt(t,i),this.clear(),this.render()},r.prototype.clearItems=function(){var t=this.getElementByLocalId("label-group");t&&t.clear()},r.prototype.setItemState=function(t,i,n){t[i]=n,this.updateTickStates(t)},r.prototype.hasState=function(t,i){return!!t[i]},r.prototype.getItemStates=function(t){var i=this.get("tickStates"),n=[];return P(i,function(a,o){t[o]&&n.push(o)}),n},r.prototype.clearItemsState=function(t){var i=this,n=this.getItemsByState(t);P(n,function(a){i.setItemState(a,t,!1)})},r.prototype.getItemsByState=function(t){var i=this,n=this.getItems();return jr(n,function(a){return i.hasState(a,t)})},r.prototype.getSidePoint=function(t,i){var n=this,a=n.getSideVector(i,t);return{x:t.x+a[0],y:t.y+a[1]}},r.prototype.getTextAnchor=function(t){var i;return zr(t[0],0)?i="center":t[0]>0?i="start":t[0]<0&&(i="end"),i},r.prototype.getTextBaseline=function(t){var i;return zr(t[1],0)?i="middle":t[1]>0?i="top":t[1]<0&&(i="bottom"),i},r.prototype.processOverlap=function(t){},r.prototype.drawLine=function(t){var i=this.getLinePath(),n=this.get("line");this.addShape(t,{type:"path",id:this.getElementId("line"),name:"axis-line",attrs:Kt({path:i},n.style)})},r.prototype.getTickLineItems=function(t){var i=this,n=[],a=this.get("tickLine"),o=a.alignTick,l=a.length,s=1,u=t.length;return u>=2&&(s=t[1].value-t[0].value),P(t,function(c){var f=c.point;o||(f=i.getTickPoint(c.value-s/2));var h=i.getSidePoint(f,l);n.push({startPoint:f,tickValue:c.value,endPoint:h,tickId:c.id,id:"tickline-"+c.id})}),n},r.prototype.getSubTickLineItems=function(t){var i=[],n=this.get("subTickLine"),a=n.count,o=t.length;if(o>=2)for(var l=0;l<o-1;l++)for(var s=t[l],u=t[l+1],c=0;c<a;c++){var f=(c+1)/(a+1),h=(1-f)*s.tickValue+f*u.tickValue,v=this.getTickPoint(h),d=this.getSidePoint(v,n.length);i.push({startPoint:v,endPoint:d,tickValue:h,id:"sub-"+s.id+"-"+c})}return i},r.prototype.getTickLineAttrs=function(t,i,n,a){var o=this.get(i).style,l={points:[t.startPoint,t.endPoint]},s=I(this.get("theme"),["tickLine","style"],{});o=pt(o)?Kt({},s,o(l,n,a)):o;var u=t.startPoint,c=t.endPoint;return A({x1:u.x,y1:u.y,x2:c.x,y2:c.y},o)},r.prototype.drawTick=function(t,i,n,a,o){this.addShape(i,{type:"line",id:this.getElementId(t.id),name:"axis-"+n,attrs:this.getTickLineAttrs(t,n,a,o)})},r.prototype.drawTickLines=function(t){var i=this,n=this.get("ticks"),a=this.get("subTickLine"),o=this.getTickLineItems(n),l=this.addGroup(t,{name:"axis-tickline-group",id:this.getElementId("tickline-group")}),s=this.get("tickLine");if(P(o,function(c,f){if(s.displayWithLabel){var h=i.getElementId("label-"+c.tickId);t.findById(h)&&i.drawTick(c,l,"tickLine",f,o)}else i.drawTick(c,l,"tickLine",f,o)}),a){var u=this.getSubTickLineItems(o);P(u,function(c,f){i.drawTick(c,l,"subTickLine",f,u)})}},r.prototype.processTicks=function(){var t=this,i=this.get("ticks");P(i,function(n){n.point=t.getTickPoint(n.value),K(n.id)&&(n.id=n.name)})},r.prototype.drawTicks=function(t){var i=this;this.optimizeTicks(),this.processTicks(),this.get("label")&&this.drawLabels(t),this.get("tickLine")&&this.drawTickLines(t);var n=this.get("ticks");P(n,function(a){i.applyTickStates(a,t)})},r.prototype.optimizeTicks=function(){var t=this.get("optimize"),i=this.get("ticks");if(t&&t.enable&&t.threshold>0){var n=yr(i);if(n>t.threshold){var a=Math.ceil(n/t.threshold),o=i.filter(function(l,s){return s%a===0});this.set("ticks",o),this.set("originalTicks",i)}}},r.prototype.getLabelAttrs=function(t,i,n){var a=this.get("label"),o=a.offset,l=a.offsetX,s=a.offsetY,u=a.rotate,c=a.formatter,f=this.getSidePoint(t.point,o),h=this.getSideVector(o,f),v=c?c(t.name,t,i):t.name,d=a.style;d=pt(d)?I(this.get("theme"),["label","style"],{}):d;var p=Kt({x:f.x+l,y:f.y+s,text:v,textAlign:this.getTextAnchor(h),textBaseline:this.getTextBaseline(h)},d);return u&&(p.matrix=qu(f,u)),p},r.prototype.drawLabels=function(t){var i=this,n=this.get("ticks"),a=this.addGroup(t,{name:"axis-label-group",id:this.getElementId("label-group")});P(n,function(h,v){i.addShape(a,{type:"text",name:"axis-label",id:i.getElementId("label-"+h.id),attrs:i.getLabelAttrs(h,v,n),delegateObject:{tick:h,item:h,index:v}})}),this.processOverlap(a);var o=a.getChildren(),l=I(this.get("theme"),["label","style"],{}),s=this.get("label"),u=s.style,c=s.formatter;if(pt(u)){var f=o.map(function(h){return I(h.get("delegateObject"),"tick")});P(o,function(h,v){var d=h.get("delegateObject").tick,p=c?c(d.name,d,v):d.name,x=Kt({},l,u(p,v,f));h.attr(x)})}},r.prototype.getTitleAttrs=function(){var t=this.get("title"),i=t.style,n=t.position,a=t.offset,o=t.spacing,l=o===void 0?0:o,s=t.autoRotate,u=i.fontSize,c=.5;n==="start"?c=0:n==="end"&&(c=1);var f=this.getTickPoint(c),h=this.getSidePoint(f,a||l+u/2),v=Kt({x:h.x,y:h.y,text:t.text},i),d=t.rotate,p=d;if(K(d)&&s){var x=this.getAxisVector(f),m=[1,0];p=l1(x,m,!0)}if(p){var _=qu(h,p);v.matrix=_}return v},r.prototype.drawTitle=function(t){var i,n=this.getTitleAttrs(),a=this.addShape(t,{type:"text",id:this.getElementId("title"),name:"axis-title",attrs:n});!((i=this.get("title"))===null||i===void 0)&&i.description&&this.drawDescriptionIcon(t,a,n.matrix)},r.prototype.drawDescriptionIcon=function(t,i,n){var a=this.addGroup(t,{name:"axis-description",id:this.getElementById("description")}),o=i.getBBox(),l=o.maxX,s=o.maxY,u=o.height,c=this.get("title").iconStyle,f=4,h=u/2,v=h/6,d=l+f,p=s-u/2,x=[d+h,p-h],m=x[0],_=x[1],b=[m+h,_+h],w=b[0],S=b[1],M=[m,S+h],F=M[0],O=M[1],L=[d,_+h],D=L[0],k=L[1],H=[d+h,p-u/4],B=H[0],j=H[1],U=[B,j+v],R=U[0],G=U[1],N=[R,G+v],W=N[0],q=N[1],tt=[W,q+h*3/4],ot=tt[0],st=tt[1];this.addShape(a,{type:"path",id:this.getElementId("title-description-icon"),name:"axis-title-description-icon",attrs:A({path:[["M",m,_],["A",h,h,0,0,1,w,S],["A",h,h,0,0,1,F,O],["A",h,h,0,0,1,D,k],["A",h,h,0,0,1,m,_],["M",B,j],["L",R,G],["M",W,q],["L",ot,st]],lineWidth:v,matrix:n},c)}),this.addShape(a,{type:"rect",id:this.getElementId("title-description-rect"),name:"axis-title-description-rect",attrs:{x:d,y:p-u/2,width:u,height:u,stroke:"#000",fill:"#000",opacity:0,matrix:n,cursor:"pointer"}})},r.prototype.applyTickStates=function(t,i){var n=this.getItemStates(t);if(n.length){var a=this.get("tickStates"),o=this.getElementId("label-"+t.id),l=i.findById(o);if(l){var s=Yv(t,"label",a);s&&l.attr(s)}var u=this.getElementId("tickline-"+t.id),c=i.findById(u);if(c){var f=Yv(t,"tickLine",a);f&&c.attr(f)}}},r.prototype.updateTickStates=function(t){var i=this.getItemStates(t),n=this.get("tickStates"),a=this.get("label"),o=this.getElementByLocalId("label-"+t.id),l=this.get("tickLine"),s=this.getElementByLocalId("tickline-"+t.id);if(i.length){if(o){var u=Yv(t,"label",n);u&&o.attr(u)}if(s){var c=Yv(t,"tickLine",n);c&&s.attr(c)}}else o&&o.attr(a.style),s&&s.attr(l.style)},r}(Hr);function HM(e,r,t,i){var n=r.getChildren(),a=!1;return P(n,function(o){var l=yd(e,o,t,i);a=a||l}),a}function UJ(){return E5}function qJ(e,r,t){return HM(e,r,t,"head")}function E5(e,r,t){return HM(e,r,t,"tail")}function ZJ(e,r,t){return HM(e,r,t,"middle")}var QJ=Object.freeze(Object.defineProperty({__proto__:null,getDefault:UJ,ellipsisHead:qJ,ellipsisTail:E5,ellipsisMiddle:ZJ},Symbol.toStringTag,{value:"Module"}));function KJ(e){var r=e.attr("matrix");return r&&r[0]!==1}function F5(e){var r=KJ(e)?bJ(e.attr("matrix")):0;return r%360}function $A(e,r,t,i){var n=!1,a=F5(r),o=Math.abs(e?t.attr("y")-r.attr("y"):t.attr("x")-r.attr("x")),l=(e?t.attr("y")>r.attr("y"):t.attr("x")>r.attr("x"))?r.getBBox():t.getBBox();if(e){var s=Math.abs(Math.cos(a));J0(s,0,Math.PI/180)?n=l.width+i>o:n=l.height/s+i>o}else{var s=Math.abs(Math.sin(a));J0(s,0,Math.PI/180)?n=l.width+i>o:n=l.height/s+i>o}return n}function jd(e,r,t,i){var n=(i==null?void 0:i.minGap)||0,a=r.getChildren().slice().filter(function(v){return v.get("visible")});if(!a.length)return!1;var o=!1;t&&a.reverse();for(var l=a.length,s=a[0],u=s,c=1;c<l;c++){var f=a[c];f.getBBox();var h=$A(e,u,f,n);h?(f.hide(),o=!0):u=f}return o}function O5(e,r,t){var i=(t==null?void 0:t.minGap)||0,n=r.getChildren().slice();if(n.length<2)return!1;var a=!1,o=n[0],l=o.getBBox(),s=n[1],u=n.length,c=F5(o),f=Math.abs(e?s.attr("y")-o.attr("y"):s.attr("x")-o.attr("x")),h=0;if(e){var v=Math.abs(Math.cos(c));if(J0(v,0,Math.PI/180)){var d=DA(n);h=(d+i)/f}else h=(l.height/v+i)/f}else{var v=Math.abs(Math.sin(c));if(J0(v,0,Math.PI/180)){var d=DA(n);h=(d+i)/f}else h=(l.height/v+i)/f}if(h>1){h=Math.ceil(h);for(var p=0;p<u;p++)p%h!==0&&(n[p].hide(),a=!0)}return a}function JJ(){return P5}function ttt(e,r,t,i){return jd(e,r,!1,i)}function ett(e,r,t,i){return jd(e,r,!0,i)}function rtt(e,r,t,i){var n=(i==null?void 0:i.minGap)||0,a=r.getChildren().slice();if(a.length<=2)return!1;for(var o=!1,l=a.length,s=a[0],u=a[l-1],c=s,f=1;f<l-1;f++){var h=a[f];h.getBBox();var v=$A(e,c,h,n);v?(h.hide(),o=!0):c=h}var d=$A(e,c,u,n);return d&&(c.hide(),o=!0),o}function P5(e,r,t,i){var n=O5(e,r,i);return jd(e,r,!1)&&(n=!0),n}function itt(e,r,t,i){var n=r.getChildren().slice(),a=O5(e,r,i);if(n.length>2){var o=n[0],l=n[n.length-1];o.get("visible")||(o.show(),jd(e,r,!1,i)&&(a=!0)),l.get("visible")||(l.show(),jd(e,r,!0,i)&&(a=!0))}return a}var ntt=Object.freeze(Object.defineProperty({__proto__:null,getDefault:JJ,reserveFirst:ttt,reserveLast:ett,reserveBoth:rtt,equidistance:P5,equidistanceWithReverseBoth:itt},Symbol.toStringTag,{value:"Module"}));function att(e,r){P(e,function(t){var i=t.attr("x"),n=t.attr("y"),a=qu({x:i,y:n},r);t.attr("matrix",a)})}function I5(e,r,t,i){var n=r.getChildren();if(!n.length||!e&&n.length<2)return!1;var a=DA(n),o=!1;if(e)o=!!t&&a>t;else{var l=Math.abs(n[1].attr("x")-n[0].attr("x"));o=a>l}if(o){var s=i(t,a);att(n,s)}return o}function ott(){return L5}function L5(e,r,t,i){return I5(e,r,t,function(){return Mt(i)?i:e?Ht.verticalAxisRotate:Ht.horizontalAxisRotate})}function ltt(e,r,t){return I5(e,r,t,function(i,n){if(!i)return e?Ht.verticalAxisRotate:Ht.horizontalAxisRotate;if(e)return-Math.acos(i/n);var a=0;return i>n?a=Math.PI/4:(a=Math.asin(i/n),a>Math.PI/4&&(a=Math.PI/4)),a})}var stt=Object.freeze(Object.defineProperty({__proto__:null,getDefault:ott,fixedAngle:L5,unfixedAngle:ltt},Symbol.toStringTag,{value:"Module"})),D5=Object.freeze(Object.defineProperty({__proto__:null,autoHide:ntt,autoRotate:stt,autoEllipsis:QJ},Symbol.toStringTag,{value:"Module"})),$5=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{type:"line",locationType:"region",start:null,end:null})},r.prototype.getLinePath=function(){var t=this.get("start"),i=this.get("end"),n=[];return n.push(["M",t.x,t.y]),n.push(["L",i.x,i.y]),n},r.prototype.getInnerLayoutBBox=function(){var t=this.get("start"),i=this.get("end"),n=e.prototype.getInnerLayoutBBox.call(this),a=Math.min(t.x,i.x,n.x),o=Math.min(t.y,i.y,n.y),l=Math.max(t.x,i.x,n.maxX),s=Math.max(t.y,i.y,n.maxY);return{x:a,y:o,minX:a,minY:o,maxX:l,maxY:s,width:l-a,height:s-o}},r.prototype.isVertical=function(){var t=this.get("start"),i=this.get("end");return zr(t.x,i.x)},r.prototype.isHorizontal=function(){var t=this.get("start"),i=this.get("end");return zr(t.y,i.y)},r.prototype.getTickPoint=function(t){var i=this,n=i.get("start"),a=i.get("end"),o=a.x-n.x,l=a.y-n.y;return{x:n.x+o*t,y:n.y+l*t}},r.prototype.getSideVector=function(t){var i=this.getAxisVector(),n=mM([0,0],i),a=this.get("verticalFactor"),o=[n[1],n[0]*-1];return pi([0,0],o,t*a)},r.prototype.getAxisVector=function(){var t=this.get("start"),i=this.get("end");return[i.x-t.x,i.y-t.y]},r.prototype.processOverlap=function(t){var i=this,n=this.isVertical(),a=this.isHorizontal();if(!(!n&&!a)){var o=this.get("label"),l=this.get("title"),s=this.get("verticalLimitLength"),u=o.offset,c=s,f=0,h=0;l&&(f=l.style.fontSize,h=l.spacing),c&&(c=c-u-h-f);var v=this.get("overlapOrder");if(P(v,function(x){o[x]&&i.canProcessOverlap(x)&&i.autoProcessOverlap(x,o[x],t,c)}),l&&K(l.offset)){var d=t.getCanvasBBox(),p=n?d.width:d.height;l.offset=u+p+h+f/2}}},r.prototype.canProcessOverlap=function(t){var i=this.get("label");return t==="autoRotate"?K(i.rotate):!0},r.prototype.autoProcessOverlap=function(t,i,n,a){var o=this,l=this.isVertical(),s=!1,u=D5[t];if(i===!0)this.get("label"),s=u.getDefault()(l,n,a);else if(pt(i))s=i(l,n,a);else if(Zt(i)){var c=i;u[c.type]&&(s=u[c.type](l,n,a,c.cfg))}else u[i]&&(s=u[i](l,n,a));if(t==="autoRotate"){if(s){var f=n.getChildren(),h=this.get("verticalFactor");P(f,function(d){var p=d.attr("textAlign");if(p==="center"){var x=h>0?"end":"start";d.attr("textAlign",x)}})}}else if(t==="autoHide"){var v=n.getChildren().slice(0);P(v,function(d){d.get("visible")||(o.get("isRegister")&&o.unregisterElement(d),d.remove())})}},r}(jM),k5=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{type:"circle",locationType:"circle",center:null,radius:null,startAngle:-Math.PI/2,endAngle:Math.PI*3/2})},r.prototype.getLinePath=function(){var t=this.get("center"),i=t.x,n=t.y,a=this.get("radius"),o=a,l=this.get("startAngle"),s=this.get("endAngle"),u=[];if(Math.abs(s-l)===Math.PI*2)u=[["M",i,n-o],["A",a,o,0,1,1,i,n+o],["A",a,o,0,1,1,i,n-o],["Z"]];else{var c=this.getCirclePoint(l),f=this.getCirclePoint(s),h=Math.abs(s-l)>Math.PI?1:0,v=l>s?0:1;u=[["M",i,n],["L",c.x,c.y],["A",a,o,0,h,v,f.x,f.y],["L",i,n]]}return u},r.prototype.getTickPoint=function(t){var i=this.get("startAngle"),n=this.get("endAngle"),a=i+(n-i)*t;return this.getCirclePoint(a)},r.prototype.getSideVector=function(t,i){var n=this.get("center"),a=[i.x-n.x,i.y-n.y],o=this.get("verticalFactor"),l=Wl(a);return pi(a,a,o*t/l),a},r.prototype.getAxisVector=function(t){var i=this.get("center"),n=[t.x-i.x,t.y-i.y];return[n[1],-1*n[0]]},r.prototype.getCirclePoint=function(t,i){var n=this.get("center");return i=i||this.get("radius"),{x:n.x+Math.cos(t)*i,y:n.y+Math.sin(t)*i}},r.prototype.canProcessOverlap=function(t){var i=this.get("label");return t==="autoRotate"?K(i.rotate):!0},r.prototype.processOverlap=function(t){var i=this,n=this.get("label"),a=this.get("title"),o=this.get("verticalLimitLength"),l=n.offset,s=o,u=0,c=0;a&&(u=a.style.fontSize,c=a.spacing),s&&(s=s-l-c-u);var f=this.get("overlapOrder");if(P(f,function(v){n[v]&&i.canProcessOverlap(v)&&i.autoProcessOverlap(v,n[v],t,s)}),a&&K(a.offset)){var h=t.getCanvasBBox().height;a.offset=l+h+c+u/2}},r.prototype.autoProcessOverlap=function(t,i,n,a){var o=this,l=!1,s=D5[t];if(a>0)if(i===!0)l=s.getDefault()(!1,n,a);else if(pt(i))l=i(!1,n,a);else if(Zt(i)){var u=i;s[u.type]&&(l=s[u.type](!1,n,a,u.cfg))}else s[i]&&(l=s[i](!1,n,a));if(t==="autoRotate"){if(l){var c=n.getChildren(),f=this.get("verticalFactor");P(c,function(v){var d=v.attr("textAlign");if(d==="center"){var p=f>0?"end":"start";v.attr("textAlign",p)}})}}else if(t==="autoHide"){var h=n.getChildren().slice(0);P(h,function(v){v.get("visible")||(o.get("isRegister")&&o.unregisterElement(v),v.remove())})}},r}(jM),utt=Object.freeze(Object.defineProperty({__proto__:null,Line:$5,Circle:k5,Base:jM},Symbol.toStringTag,{value:"Module"})),YM=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{name:"crosshair",type:"base",line:{},text:null,textBackground:{},capture:!1,defaultCfg:{line:{style:{lineWidth:1,stroke:Ht.lineColor}},text:{position:"start",offset:10,autoRotate:!1,content:null,style:{fill:Ht.textColor,textAlign:"center",textBaseline:"middle",fontFamily:Ht.fontFamily}},textBackground:{padding:5,style:{stroke:Ht.lineColor}}}})},r.prototype.renderInner=function(t){this.get("line")&&this.renderLine(t),this.get("text")&&(this.renderText(t),this.renderBackground(t))},r.prototype.renderText=function(t){var i=this.get("text"),n=i.style,a=i.autoRotate,o=i.content;if(!K(o)){var l=this.getTextPoint(),s=null;if(a){var u=this.getRotateAngle();s=qu(l,u)}this.addShape(t,{type:"text",name:"crosshair-text",id:this.getElementId("text"),attrs:A(A(A({},l),{text:o,matrix:s}),n)})}},r.prototype.renderLine=function(t){var i=this.getLinePath(),n=this.get("line"),a=n.style;this.addShape(t,{type:"path",name:"crosshair-line",id:this.getElementId("line"),attrs:A({path:i},a)})},r.prototype.renderBackground=function(t){var i=this.getElementId("text"),n=t.findById(i),a=this.get("textBackground");if(a&&n){var o=n.getBBox(),l=K0(a.padding),s=a.style,u=this.addShape(t,{type:"rect",name:"crosshair-text-background",id:this.getElementId("text-background"),attrs:A({x:o.x-l[3],y:o.y-l[0],width:o.width+l[1]+l[3],height:o.height+l[0]+l[2],matrix:n.attr("matrix")},s)});u.toBack()}},r}(Hr),R5=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{type:"line",locationType:"region",start:null,end:null})},r.prototype.getRotateAngle=function(){var t=this.getLocation(),i=t.start,n=t.end,a=this.get("text").position,o=Math.atan2(n.y-i.y,n.x-i.x),l=a==="start"?o-Math.PI/2:o+Math.PI/2;return l},r.prototype.getTextPoint=function(){var t=this.getLocation(),i=t.start,n=t.end,a=this.get("text"),o=a.position,l=a.offset;return T5(i,n,o,l)},r.prototype.getLinePath=function(){var t=this.getLocation(),i=t.start,n=t.end;return[["M",i.x,i.y],["L",n.x,n.y]]},r}(YM),ctt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{type:"circle",locationType:"circle",center:null,radius:100,startAngle:-Math.PI/2,endAngle:Math.PI*3/2})},r.prototype.getRotateAngle=function(){var t=this.getLocation(),i=t.startAngle,n=t.endAngle,a=this.get("text").position,o=a==="start"?i+Math.PI/2:n-Math.PI/2;return o},r.prototype.getTextPoint=function(){var t=this.get("text"),i=t.position,n=t.offset,a=this.getLocation(),o=a.center,l=a.radius,s=a.startAngle,u=a.endAngle,c=i==="start"?s:u,f=this.getRotateAngle()-Math.PI,h=Sf(o,l,c),v=Math.cos(f)*n,d=Math.sin(f)*n;return{x:h.x+v,y:h.y+d}},r.prototype.getLinePath=function(){var t=this.getLocation(),i=t.center,n=t.radius,a=t.startAngle,o=t.endAngle,l=null;if(o-a===Math.PI*2){var s=i.x,u=i.y;l=[["M",s,u-n],["A",n,n,0,1,1,s,u+n],["A",n,n,0,1,1,s,u-n],["Z"]]}else{var c=Sf(i,n,a),f=Sf(i,n,o),h=Math.abs(o-a)>Math.PI?1:0,v=a>o?0:1;l=[["M",c.x,c.y],["A",n,n,0,h,v,f.x,f.y]]}return l},r}(YM),Hd="g2-crosshair",kA=Hd+"-line",RA=Hd+"-text",vv,ftt=(vv={},vv[""+Hd]={position:"relative"},vv[""+kA]={position:"absolute",backgroundColor:"rgba(0, 0, 0, 0.25)"},vv[""+RA]={position:"absolute",color:Ht.textColor,fontFamily:Ht.fontFamily},vv),htt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{name:"crosshair",type:"html",locationType:"region",start:{x:0,y:0},end:{x:0,y:0},capture:!1,text:null,containerTpl:'<div class="'+Hd+'"></div>',crosshairTpl:'<div class="'+kA+'"></div>',textTpl:'<span class="'+RA+'">{content}</span>',domStyles:null,containerClassName:Hd,defaultStyles:ftt,defaultCfg:{text:{position:"start",content:null,align:"center",offset:10}}})},r.prototype.render=function(){this.resetText(),this.resetPosition()},r.prototype.initCrossHair=function(){var t=this.getContainer(),i=this.get("crosshairTpl"),n=Zo(i);t.appendChild(n),this.applyStyle(kA,n),this.set("crosshairEl",n)},r.prototype.getTextPoint=function(){var t=this.getLocation(),i=t.start,n=t.end,a=this.get("text"),o=a.position,l=a.offset;return T5(i,n,o,l)},r.prototype.resetText=function(){var t=this.get("text"),i=this.get("textEl");if(t){var n=t.content;if(!i){var a=this.getContainer(),o=fM(this.get("textTpl"),t);i=Zo(o),a.appendChild(i),this.applyStyle(RA,i),this.set("textEl",i)}i.innerHTML=n}else i&&i.remove()},r.prototype.isVertical=function(t,i){return t.x===i.x},r.prototype.resetPosition=function(){var t=this.get("crosshairEl");t||(this.initCrossHair(),t=this.get("crosshairEl"));var i=this.get("start"),n=this.get("end"),a=Math.min(i.x,n.x),o=Math.min(i.y,n.y);this.isVertical(i,n)?qr(t,{width:"1px",height:Ni(Math.abs(n.y-i.y))}):qr(t,{height:"1px",width:Ni(Math.abs(n.x-i.x))}),qr(t,{top:Ni(o),left:Ni(a)}),this.alignText()},r.prototype.alignText=function(){var t=this.get("textEl");if(t){var i=this.get("text").align,n=t.clientWidth,a=this.getTextPoint();switch(i){case"center":a.x=a.x-n/2;break;case"right":a.x=a.x-n}qr(t,{top:Ni(a.y),left:Ni(a.x)})}},r.prototype.updateInner=function(t){po(t,"text")&&this.resetText(),e.prototype.updateInner.call(this,t)},r}(m1),BA=Object.freeze(Object.defineProperty({__proto__:null,Line:R5,Circle:ctt,Base:YM,Html:htt},Symbol.toStringTag,{value:"Module"})),WM=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{name:"grid",line:{},alternateColor:null,capture:!1,items:[],closed:!1,defaultCfg:{line:{type:"line",style:{lineWidth:1,stroke:Ht.lineColor}}}})},r.prototype.getLineType=function(){var t=this.get("line")||this.get("defaultCfg").line;return t.type},r.prototype.renderInner=function(t){this.drawGrid(t)},r.prototype.getAlternatePath=function(t,i){var n=this.getGridPath(t),a=i.slice(0).reverse(),o=this.getGridPath(a,!0),l=this.get("closed");return l?n=n.concat(o):(o[0][0]="L",n=n.concat(o),n.push(["Z"])),n},r.prototype.getPathStyle=function(){return this.get("line").style},r.prototype.drawGrid=function(t){var i=this,n=this.get("line"),a=this.get("items"),o=this.get("alternateColor"),l=null;P(a,function(s,u){var c=s.id||u;if(n){var f=i.getPathStyle();f=pt(f)?f(s,u,a):f;var h=i.getElementId("line-"+c),v=i.getGridPath(s.points);i.addShape(t,{type:"path",name:"grid-line",id:h,attrs:Kt({path:v},f)})}if(o&&u>0){var d=i.getElementId("region-"+c),p=u%2===0;if(Ct(o))p&&i.drawAlternateRegion(d,t,l.points,s.points,o);else{var x=p?o[1]:o[0];i.drawAlternateRegion(d,t,l.points,s.points,x)}}l=s})},r.prototype.drawAlternateRegion=function(t,i,n,a,o){var l=this.getAlternatePath(n,a);this.addShape(i,{type:"path",id:t,name:"grid-region",attrs:{path:l,fill:o}})},r}(Hr);function vtt(e,r,t,i){var n=t-e,a=i-r;return Math.sqrt(n*n+a*a)}var B5=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{type:"circle",center:null,closed:!0})},r.prototype.getGridPath=function(t,i){var n=this.getLineType(),a=this.get("closed"),o=[];if(t.length)if(n==="circle"){var l=this.get("center"),s=t[0],u=vtt(l.x,l.y,s.x,s.y),c=i?0:1;a?(o.push(["M",l.x,l.y-u]),o.push(["A",u,u,0,0,c,l.x,l.y+u]),o.push(["A",u,u,0,0,c,l.x,l.y-u]),o.push(["Z"])):P(t,function(f,h){h===0?o.push(["M",f.x,f.y]):o.push(["A",u,u,0,0,c,f.x,f.y])})}else P(t,function(f,h){h===0?o.push(["M",f.x,f.y]):o.push(["L",f.x,f.y])}),a&&o.push(["Z"]);return o},r}(WM),N5=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{type:"line"})},r.prototype.getGridPath=function(t){var i=[];return P(t,function(n,a){a===0?i.push(["M",n.x,n.y]):i.push(["L",n.x,n.y])}),i},r}(WM),dtt=Object.freeze(Object.defineProperty({__proto__:null,Base:WM,Circle:B5,Line:N5},Symbol.toStringTag,{value:"Module"})),XM=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{name:"legend",layout:"horizontal",locationType:"point",x:0,y:0,offsetX:0,offsetY:0,title:null,background:null})},r.prototype.getLayoutBBox=function(){var t=e.prototype.getLayoutBBox.call(this),i=this.get("maxWidth"),n=this.get("maxHeight"),a=t.width,o=t.height;return i&&(a=Math.min(a,i)),n&&(o=Math.min(o,n)),g1(t.minX,t.minY,a,o)},r.prototype.setLocation=function(t){this.set("x",t.x),this.set("y",t.y),this.resetLocation()},r.prototype.resetLocation=function(){var t=this.get("x"),i=this.get("y"),n=this.get("offsetX"),a=this.get("offsetY");this.moveElementTo(this.get("group"),{x:t+n,y:i+a})},r.prototype.applyOffset=function(){this.resetLocation()},r.prototype.getDrawPoint=function(){return this.get("currentPoint")},r.prototype.setDrawPoint=function(t){return this.set("currentPoint",t)},r.prototype.renderInner=function(t){this.resetDraw(),this.get("title")&&this.drawTitle(t),this.drawLegendContent(t),this.get("background")&&this.drawBackground(t)},r.prototype.drawBackground=function(t){var i=this.get("background"),n=t.getBBox(),a=K0(i.padding),o=A({x:0,y:0,width:n.width+a[1]+a[3],height:n.height+a[0]+a[2]},i.style),l=this.addShape(t,{type:"rect",id:this.getElementId("background"),name:"legend-background",attrs:o});l.toBack()},r.prototype.drawTitle=function(t){var i=this.get("currentPoint"),n=this.get("title"),a=n.spacing,o=n.style,l=n.text,s=this.addShape(t,{type:"text",id:this.getElementId("title"),name:"legend-title",attrs:A({text:l,x:i.x,y:i.y},o)}),u=s.getBBox();this.set("currentPoint",{x:i.x,y:u.maxY+a})},r.prototype.resetDraw=function(){var t=this.get("background"),i={x:0,y:0};if(t){var n=K0(t.padding);i.x=n[3],i.y=n[0]}this.set("currentPoint",i)},r}(Hr),Jw={marker:{style:{inactiveFill:"#000",inactiveOpacity:.45,fill:"#000",opacity:1,size:12}},text:{style:{fill:"#ccc",fontSize:12}}},Hy={fill:Ht.textColor,fontSize:12,textAlign:"start",textBaseline:"middle",fontFamily:Ht.fontFamily,fontWeight:"normal",lineHeight:12},tC="navigation-arrow-right",eC="navigation-arrow-left",ZL={right:90*Math.PI/180,left:(360-90)*Math.PI/180,up:0,down:180*Math.PI/180},G5=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.currentPageIndex=1,t.totalPagesCnt=1,t.pageWidth=0,t.pageHeight=0,t.startX=0,t.startY=0,t.onNavigationBack=function(){var i=t.getElementByLocalId("item-group");if(t.currentPageIndex>1){t.currentPageIndex-=1,t.updateNavigation();var n=t.getCurrentNavigationMatrix();t.get("animate")?i.animate({matrix:n},100):i.attr({matrix:n})}},t.onNavigationAfter=function(){var i=t.getElementByLocalId("item-group");if(t.currentPageIndex<t.totalPagesCnt){t.currentPageIndex+=1,t.updateNavigation();var n=t.getCurrentNavigationMatrix();t.get("animate")?i.animate({matrix:n},100):i.attr({matrix:n})}},t}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{name:"legend",type:"category",itemSpacing:24,itemMarginBottom:8,maxItemWidth:null,itemWidth:null,itemHeight:null,itemName:{},itemValue:null,maxWidth:null,maxHeight:null,marker:{},radio:null,items:[],itemStates:{},itemBackground:{},pageNavigator:{},defaultCfg:{title:{spacing:5,style:{fill:Ht.textColor,fontSize:12,textAlign:"start",textBaseline:"top"}},background:{padding:5,style:{stroke:Ht.lineColor}},itemBackground:{style:{opacity:0,fill:"#fff"}},pageNavigator:Jw,itemName:{spacing:16,style:Hy},marker:{spacing:8,style:{r:6,symbol:"circle"}},itemValue:{alignRight:!1,formatter:null,style:Hy,spacing:6},itemStates:{active:{nameStyle:{opacity:.8}},unchecked:{nameStyle:{fill:Ht.uncheckedColor},markerStyle:{fill:Ht.uncheckedColor,stroke:Ht.uncheckedColor}},inactive:{nameStyle:{fill:Ht.uncheckedColor},markerStyle:{opacity:.2}}}}})},r.prototype.isList=function(){return!0},r.prototype.getItems=function(){return this.get("items")},r.prototype.setItems=function(t){this.update({items:t})},r.prototype.updateItem=function(t,i){Kt(t,i),this.clear(),this.render()},r.prototype.clearItems=function(){var t=this.getElementByLocalId("item-group");t&&t.clear()},r.prototype.setItemState=function(t,i,n){t[i]=n;var a=this.getElementByLocalId("item-"+t.id);if(a){var o=this.getItems(),l=o.indexOf(t),s=this.createOffScreenGroup(),u=this.drawItem(t,l,this.getItemHeight(),s);this.updateElements(u,a),this.clearUpdateStatus(a)}},r.prototype.hasState=function(t,i){return!!t[i]},r.prototype.getItemStates=function(t){var i=this.get("itemStates"),n=[];return P(i,function(a,o){t[o]&&n.push(o)}),n},r.prototype.clearItemsState=function(t){var i=this,n=this.getItemsByState(t);P(n,function(a){i.setItemState(a,t,!1)})},r.prototype.getItemsByState=function(t){var i=this,n=this.getItems();return jr(n,function(a){return i.hasState(a,t)})},r.prototype.drawLegendContent=function(t){this.processItems(),this.drawItems(t)},r.prototype.processItems=function(){var t=this.get("items");P(t,function(i){i.id||(i.id=i.name)})},r.prototype.drawItems=function(t){var i=this,n=this.addGroup(t,{id:this.getElementId("item-container-group"),name:"legend-item-container-group"}),a=this.addGroup(n,{id:this.getElementId("item-group"),name:"legend-item-group"}),o=this.getItemHeight(),l=this.get("itemWidth"),s=this.get("itemSpacing"),u=this.get("itemMarginBottom"),c=this.get("currentPoint"),f=c.x,h=c.y,v=this.get("layout"),d=this.get("items"),p=!1,x=0,m=this.get("maxWidth"),_=this.get("maxHeight");P(d,function(b,w){var S=i.drawItem(b,w,o,a),M=S.getBBox(),F=l||M.width;F>x&&(x=F),v==="horizontal"?(m&&m<c.x+F-f&&(p=!0,c.x=f,c.y+=o+u),i.moveElementTo(S,c),c.x+=F+s):(_&&_<c.y+o+u-h&&(p=!0,c.x+=x+s,c.y=h,x=0),i.moveElementTo(S,c),c.y+=o+u)}),p&&this.get("flipPage")&&(this.pageHeight=0,this.pageWidth=0,this.totalPagesCnt=1,this.startX=f,this.startY=h,this.adjustNavigation(t,a))},r.prototype.getItemHeight=function(){var t=this.get("itemHeight");if(!t){var i=(this.get("itemName")||{}).style;if(pt(i)){var n=this.getItems();n.forEach(function(a,o){var l=A(A({},Hy),i(a,o,n)).fontSize;t<l&&(t=l)})}else i&&(t=i.fontSize)}return t},r.prototype.drawMarker=function(t,i,n,a){var o=A(A(A({x:0,y:a/2},i.style),{symbol:I(n.marker,"symbol","circle")}),I(n.marker,"style",{})),l=this.addShape(t,{type:"marker",id:this.getElementId("item-"+n.id+"-marker"),name:"legend-item-marker",attrs:o}),s=l.getBBox();l.attr("x",s.width/2);var u=l.attr(),c=u.stroke,f=u.fill;return c&&l.set("isStroke",!0),f&&l.set("isFill",!0),l},r.prototype.drawItemText=function(t,i,n,a,o,l,s){var u=n.formatter,c=n.style,f=A(A({x:l,y:o/2,text:u?u(a[i],a,s):a[i]},Hy),pt(c)?c(a,s,this.getItems()):c);return this.addShape(t,{type:"text",id:this.getElementId("item-"+a.id+"-"+i),name:"legend-item-"+i,attrs:f})},r.prototype.drawRadio=function(t,i,n,a,o){var l,s,u=i.style||{},c=(l=u.r)!==null&&l!==void 0?l:a/2,f=c*3.6/8,h=[o+c,a/2-c],v=h[0],d=h[1],p=[v+c,d+c],x=p[0],m=p[1],_=[v,m+c],b=_[0],w=_[1],S=[o,d+c],M=S[0],F=S[1],O=n.showRadio,L=A(A({path:[["M",v,d],["A",c,c,0,0,1,x,m],["L",x-f,m],["L",x,m],["A",c,c,0,0,1,b,w],["L",b,w-f],["L",b,w],["A",c,c,0,0,1,M,F],["L",M+f,F],["L",M,F],["A",c,c,0,0,1,v,d],["L",v,d+f]],stroke:"#000000",fill:"#ffffff"},u),{opacity:O?(s=u==null?void 0:u.opacity)!==null&&s!==void 0?s:.45:0}),D=this.addShape(t,{type:"path",id:this.getElementId("item-"+n.id+"-radio"),name:"legend-item-radio",attrs:L});return D.set("tip",i.tip),D},r.prototype.drawItem=function(t,i,n,a){var o="item-"+t.id,l=this.addGroup(a,{name:"legend-item-container",id:this.getElementId("item-container-"+o),delegateObject:{item:t,index:i}}),s=this.addGroup(l,{name:"legend-item",id:this.getElementId(o),delegateObject:{item:t,index:i}}),u=this.get("marker"),c=this.get("itemName"),f=this.get("itemValue"),h=this.get("itemBackground"),v=this.get("radio"),d=this.getLimitItemWidth(),p=0;if(u){var x=this.drawMarker(s,u,t,n),m=u.spacing,_=I(t,["marker","spacing"]);Mt(_)&&(m=_),p=x.getBBox().maxX+m}if(c){var b=this.drawItemText(s,"name",c,t,n,p,i);d&&yd(!0,b,Ce(d-p,0,d)),p=b.getBBox().maxX+c.spacing}if(f){var w=this.drawItemText(s,"value",f,t,n,p,i);d&&(f.alignRight?(w.attr({textAlign:"right",x:d}),yd(!0,w,Ce(d-p,0,d),"head")):yd(!0,w,Ce(d-p,0,d))),p=w.getBBox().maxX+f.spacing}if(v&&this.drawRadio(s,v,t,n,p),h){var S=s.getBBox(),M=this.addShape(s,{type:"rect",name:"legend-item-background",id:this.getElementId(o+"-background"),attrs:A({x:0,y:0,width:S.width,height:n},h.style)});M.toBack()}return this.applyItemStates(t,s),s},r.prototype.adjustNavigation=function(t,i){var n=this,a=this.startX,o=this.startY,l=this.get("layout"),s=i.findAll(function(D){return D.get("name")==="legend-item"}),u=this.get("maxWidth"),c=this.get("maxHeight"),f=this.get("itemWidth"),h=this.get("itemSpacing"),v=this.getItemHeight(),d=ft({},Jw,this.get("pageNavigator")),p=this.drawNavigation(t,l,"00/00",d),x=p.getBBox(),m={x:a,y:o},_=1,b=0,w=0,S=0,M=this.get("itemMarginBottom");if(l==="horizontal"){var F=this.get("maxRow")||1,O=v+(F===1?0:M);this.pageHeight=O*F,P(s,function(D){var k=D.getBBox(),H=f||k.width;(b&&b<m.x+H+h||u<m.x+H+h+x.width)&&(_===1&&(b=m.x+h,n.pageWidth=b,n.moveElementTo(p,{x:u-h-x.width-x.minX,y:m.y+v/2-x.height/2-x.minY})),_+=1,m.x=a,m.y+=O),n.moveElementTo(D,m),D.getParent().setClip({type:"rect",attrs:{x:m.x,y:m.y,width:H+h,height:v}}),m.x+=H+h})}else{P(s,function(D){var k=D.getBBox();k.width>w&&(w=k.width)}),S=w,w+=h,u&&(w=Math.min(u,w),S=Math.min(u,S)),this.pageWidth=w,this.pageHeight=c-Math.max(x.height,v+M);var L=Math.floor(this.pageHeight/(v+M));P(s,function(D,k){k!==0&&k%L===0&&(_+=1,m.x+=w,m.y=o),n.moveElementTo(D,m),D.getParent().setClip({type:"rect",attrs:{x:m.x,y:m.y,width:w,height:v}}),m.y+=v+M}),this.totalPagesCnt=_,this.moveElementTo(p,{x:a+S/2-x.width/2-x.minX,y:c-x.height-x.minY})}this.pageHeight&&this.pageWidth&&i.getParent().setClip({type:"rect",attrs:{x:this.startX,y:this.startY,width:this.pageWidth,height:this.pageHeight}}),l==="horizontal"&&this.get("maxRow")?this.totalPagesCnt=Math.ceil(_/this.get("maxRow")):this.totalPagesCnt=_,this.currentPageIndex>this.totalPagesCnt&&(this.currentPageIndex=1),this.updateNavigation(p),i.attr("matrix",this.getCurrentNavigationMatrix())},r.prototype.drawNavigation=function(t,i,n,a){var o={x:0,y:0},l=this.addGroup(t,{id:this.getElementId("navigation-group"),name:"legend-navigation"}),s=I(a.marker,"style",{}),u=s.size,c=u===void 0?12:u,f=ue(s,["size"]),h=this.drawArrow(l,o,eC,i==="horizontal"?"up":"left",c,f);h.on("click",this.onNavigationBack);var v=h.getBBox();o.x+=v.width+2;var d=this.addShape(l,{type:"text",id:this.getElementId("navigation-text"),name:"navigation-text",attrs:A({x:o.x,y:o.y+c/2,text:n,textBaseline:"middle"},I(a.text,"style"))}),p=d.getBBox();o.x+=p.width+2;var x=this.drawArrow(l,o,tC,i==="horizontal"?"down":"right",c,f);return x.on("click",this.onNavigationAfter),l},r.prototype.updateNavigation=function(t){var i=ft({},Jw,this.get("pageNavigator")),n=i.marker.style,a=n.fill,o=n.opacity,l=n.inactiveFill,s=n.inactiveOpacity,u=this.currentPageIndex+"/"+this.totalPagesCnt,c=t?t.getChildren()[1]:this.getElementByLocalId("navigation-text"),f=t?t.findById(this.getElementId(eC)):this.getElementByLocalId(eC),h=t?t.findById(this.getElementId(tC)):this.getElementByLocalId(tC);c.attr("text",u),f.attr("opacity",this.currentPageIndex===1?s:o),f.attr("fill",this.currentPageIndex===1?l:a),f.attr("cursor",this.currentPageIndex===1?"not-allowed":"pointer"),h.attr("opacity",this.currentPageIndex===this.totalPagesCnt?s:o),h.attr("fill",this.currentPageIndex===this.totalPagesCnt?l:a),h.attr("cursor",this.currentPageIndex===this.totalPagesCnt?"not-allowed":"pointer");var v=f.getBBox().maxX+2;c.attr("x",v),v+=c.getBBox().width+2,this.updateArrowPath(h,{x:v,y:0})},r.prototype.drawArrow=function(t,i,n,a,o,l){var s=i.x,u=i.y,c=this.addShape(t,{type:"path",id:this.getElementId(n),name:n,attrs:A({size:o,direction:a,path:[["M",s+o/2,u],["L",s,u+o],["L",s+o,u+o],["Z"]],cursor:"pointer"},l)});return c.attr("matrix",qu({x:s+o/2,y:u+o/2},ZL[a])),c},r.prototype.updateArrowPath=function(t,i){var n=i.x,a=i.y,o=t.attr(),l=o.size,s=o.direction,u=qu({x:n+l/2,y:a+l/2},ZL[s]);t.attr("path",[["M",n+l/2,a],["L",n,a+l],["L",n+l,a+l],["Z"]]),t.attr("matrix",u)},r.prototype.getCurrentNavigationMatrix=function(){var t=this,i=t.currentPageIndex,n=t.pageWidth,a=t.pageHeight,o=this.get("layout"),l=o==="horizontal"?{x:0,y:a*(1-i)}:{x:n*(1-i),y:0};return GM(l)},r.prototype.applyItemStates=function(t,i){var n=this.getItemStates(t),a=n.length>0;if(a){var o=i.getChildren(),l=this.get("itemStates");P(o,function(s){var u=s.get("name"),c=u.split("-")[2],f=Yv(t,c,l);f&&(s.attr(f),c==="marker"&&!(s.get("isStroke")&&s.get("isFill"))&&(s.get("isStroke")&&s.attr("fill",null),s.get("isFill")&&s.attr("stroke",null)))})}},r.prototype.getLimitItemWidth=function(){var t=this.get("itemWidth"),i=this.get("maxItemWidth");return i?t&&(i=t<=i?t:i):t&&(i=t),i},r}(XM),ptt=1.4,QL=.4,z5=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{type:"continue",min:0,max:100,value:null,colors:[],track:{},rail:{},label:{},handler:{},slidable:!0,tip:null,step:null,maxWidth:null,maxHeight:null,defaultCfg:{label:{align:"rail",spacing:5,formatter:null,style:{fontSize:12,fill:Ht.textColor,textBaseline:"middle",fontFamily:Ht.fontFamily}},handler:{size:10,style:{fill:"#fff",stroke:"#333"}},track:{},rail:{type:"color",size:20,defaultLength:100,style:{fill:"#DCDEE2"}},title:{spacing:5,style:{fill:Ht.textColor,fontSize:12,textAlign:"start",textBaseline:"top"}}}})},r.prototype.isSlider=function(){return!0},r.prototype.getValue=function(){return this.getCurrentValue()},r.prototype.getRange=function(){return{min:this.get("min"),max:this.get("max")}},r.prototype.setRange=function(t,i){this.update({min:t,max:i})},r.prototype.setValue=function(t){var i=this.getValue();this.set("value",t);var n=this.get("group");this.resetTrackClip(),this.get("slidable")&&this.resetHandlers(n),this.delegateEmit("valuechanged",{originValue:i,value:t})},r.prototype.initEvent=function(){var t=this.get("group");this.bindSliderEvent(t),this.bindRailEvent(t),this.bindTrackEvent(t)},r.prototype.drawLegendContent=function(t){this.drawRail(t),this.drawLabels(t),this.fixedElements(t),this.resetTrack(t),this.resetTrackClip(t),this.get("slidable")&&this.resetHandlers(t)},r.prototype.bindSliderEvent=function(t){this.bindHandlersEvent(t)},r.prototype.bindHandlersEvent=function(t){var i=this;t.on("legend-handler-min:drag",function(n){var a=i.getValueByCanvasPoint(n.x,n.y),o=i.getCurrentValue(),l=o[1];l<a&&(l=a),i.setValue([a,l])}),t.on("legend-handler-max:drag",function(n){var a=i.getValueByCanvasPoint(n.x,n.y),o=i.getCurrentValue(),l=o[0];l>a&&(l=a),i.setValue([l,a])})},r.prototype.bindRailEvent=function(t){},r.prototype.bindTrackEvent=function(t){var i=this,n=null;t.on("legend-track:dragstart",function(a){n={x:a.x,y:a.y}}),t.on("legend-track:drag",function(a){if(!!n){var o=i.getValueByCanvasPoint(n.x,n.y),l=i.getValueByCanvasPoint(a.x,a.y),s=i.getCurrentValue(),u=s[1]-s[0],c=i.getRange(),f=l-o;f<0?s[0]+f>c.min?i.setValue([s[0]+f,s[1]+f]):i.setValue([c.min,c.min+u]):f>0&&(f>0&&s[1]+f<c.max?i.setValue([s[0]+f,s[1]+f]):i.setValue([c.max-u,c.max])),n={x:a.x,y:a.y}}}),t.on("legend-track:dragend",function(a){n=null})},r.prototype.drawLabels=function(t){this.drawLabel("min",t),this.drawLabel("max",t)},r.prototype.drawLabel=function(t,i){var n=this.get("label"),a=n.style,o=n.align,l=n.formatter,s=this.get(t),u=this.getLabelAlignAttrs(t,o),c="label-"+t;this.addShape(i,{type:"text",id:this.getElementId(c),name:"legend-label-"+t,attrs:A(A({x:0,y:0,text:pt(l)?l(s):s},a),u)})},r.prototype.getLabelAlignAttrs=function(t,i){var n=this.isVertical(),a="center",o="middle";return n?(a="start",i!=="rail"?t==="min"?o="top":o="bottom":o="top"):i!=="rail"?(o="top",t==="min"?a="start":a="end"):(a="start",o="middle"),{textAlign:a,textBaseline:o}},r.prototype.getRailPath=function(t,i,n,a){var o=this.get("rail"),l=o.size,s=o.defaultLength,u=o.type,c=this.isVertical(),f=s,h=n,v=a;h||(h=c?l:f),v||(v=c?f:l);var d=[];return u==="color"?(d.push(["M",t,i]),d.push(["L",t+h,i]),d.push(["L",t+h,i+v]),d.push(["L",t,i+v]),d.push(["Z"])):(d.push(["M",t+h,i]),d.push(["L",t+h,i+v]),d.push(["L",t,i+v]),d.push(["Z"])),d},r.prototype.drawRail=function(t){var i=this.get("rail"),n=i.style;this.addShape(t,{type:"path",id:this.getElementId("rail"),name:"legend-rail",attrs:A({path:this.getRailPath(0,0)},n)})},r.prototype.getTrackColor=function(t){var i=t.length;if(!i)return null;if(i===1)return t[0];var n;this.isVertical()?n="l(90)":n="l(0)";for(var a=0;a<i;a++){var o=a/(i-1);n+=" "+o+":"+t[a]}return n},r.prototype.getTrackPath=function(t){var i=this.getRailShape(t),n=i.attr("path");return di(n)},r.prototype.getClipTrackAttrs=function(t){var i=this.getCurrentValue(),n=i[0],a=i[1],o=this.getRailBBox(t),l=this.getPointByValue(n,t),s=this.getPointByValue(a,t),u=this.isVertical(),c,f,h,v;return u?(c=o.minX,f=l.y,h=o.width,v=s.y-l.y):(c=l.x,f=o.minY,h=s.x-l.x,v=o.height),{x:c,y:f,width:h,height:v}},r.prototype.getTrackAttrs=function(t){var i=this.get("track"),n=this.get("colors"),a=this.getTrackPath(t);return Kt({path:a,fill:this.getTrackColor(n)},i.style)},r.prototype.resetTrackClip=function(t){var i=t||this.get("group"),n=this.getElementId("track"),a=i.findById(n),o=a.getClip(),l=this.getClipTrackAttrs(t);o?o.attr(l):a.setClip({type:"rect",attrs:l})},r.prototype.resetTrack=function(t){var i=this.getElementId("track"),n=t.findById(i),a=this.getTrackAttrs(t);n?n.attr(a):this.addShape(t,{type:"path",id:i,draggable:this.get("slidable"),name:"legend-track",attrs:a})},r.prototype.getPointByValue=function(t,i){var n=this.getRange(),a=n.min,o=n.max,l=(t-a)/(o-a),s=this.getRailBBox(i),u=this.isVertical(),c={x:0,y:0};return u?(c.x=s.minX+s.width/2,c.y=Bu(s.minY,s.maxY,l)):(c.x=Bu(s.minX,s.maxX,l),c.y=s.minY+s.height/2),c},r.prototype.getRailShape=function(t){var i=t||this.get("group");return i.findById(this.getElementId("rail"))},r.prototype.getRailBBox=function(t){var i=this.getRailShape(t),n=i.getBBox();return n},r.prototype.getRailCanvasBBox=function(){var t=this.get("group"),i=t.findById(this.getElementId("rail")),n=i.getCanvasBBox();return n},r.prototype.isVertical=function(){return this.get("layout")==="vertical"},r.prototype.getValueByCanvasPoint=function(t,i){var n=this.getRange(),a=n.min,o=n.max,l=this.getRailCanvasBBox(),s=this.isVertical(),u=this.get("step"),c;s?c=(i-l.minY)/l.height:c=(t-l.minX)/l.width;var f=Bu(a,o,c);if(u){var h=Math.round((f-a)/u);f=a+h*u}return f>o&&(f=o),f<a&&(f=a),f},r.prototype.getCurrentValue=function(){var t=this.get("value");if(!t){var i=this.get("values");return i?[Math.max(Math.min.apply(Math,ye(i,[this.get("max")])),this.get("min")),Math.min(Math.max.apply(Math,ye(i,[this.get("min")])),this.get("max"))]:[this.get("min"),this.get("max")]}return t},r.prototype.resetHandlers=function(t){var i=this.getCurrentValue(),n=i[0],a=i[1];this.resetHandler(t,"min",n),this.resetHandler(t,"max",a)},r.prototype.getHandlerPath=function(t,i){var n=this.isVertical(),a=[],o=t.size,l=i.x,s=i.y,u=o*ptt,c=o/2,f=o/6;if(n){var h=l+u*QL;a.push(["M",l,s]),a.push(["L",h,s+c]),a.push(["L",l+u,s+c]),a.push(["L",l+u,s-c]),a.push(["L",h,s-c]),a.push(["Z"]),a.push(["M",h,s+f]),a.push(["L",l+u-2,s+f]),a.push(["M",h,s-f]),a.push(["L",l+u-2,s-f])}else{var v=s+u*QL;a.push(["M",l,s]),a.push(["L",l-c,v]),a.push(["L",l-c,s+u]),a.push(["L",l+c,s+u]),a.push(["L",l+c,v]),a.push(["Z"]),a.push(["M",l-f,v]),a.push(["L",l-f,s+u-2]),a.push(["M",l+f,v]),a.push(["L",l+f,s+u-2])}return a},r.prototype.resetHandler=function(t,i,n){var a=this.getPointByValue(n,t),o=this.get("handler"),l=this.getHandlerPath(o,a),s=this.getElementId("handler-"+i),u=t.findById(s),c=this.isVertical();u?u.attr("path",l):this.addShape(t,{type:"path",name:"legend-handler-"+i,draggable:!0,id:s,attrs:A(A({path:l},o.style),{cursor:c?"ns-resize":"ew-resize"})})},r.prototype.fixedElements=function(t){var i=t.findById(this.getElementId("rail")),n=t.findById(this.getElementId("label-min")),a=t.findById(this.getElementId("label-max")),o=this.getDrawPoint();this.isVertical()?this.fixedVertail(n,a,i,o):this.fixedHorizontal(n,a,i,o)},r.prototype.fitRailLength=function(t,i,n,a){var o=this.isVertical(),l=o?"height":"width",s=this.get("label"),u=s.align,c=s.spacing,f=this.get("max"+Os(l));if(f){var h=u==="rail"?n[l]+t[l]+i[l]+c*2:n[l],v=h-f;v>0&&this.changeRailLength(a,l,n[l]-v)}},r.prototype.changeRailLength=function(t,i,n){var a=t.getBBox(),o;i==="height"?o=this.getRailPath(a.x,a.y,a.width,n):o=this.getRailPath(a.x,a.y,n,a.height),t.attr("path",o)},r.prototype.changeRailPosition=function(t,i,n){var a=t.getBBox(),o=this.getRailPath(i,n,a.width,a.height);t.attr("path",o)},r.prototype.fixedHorizontal=function(t,i,n,a){var o=this.get("label"),l=o.align,s=o.spacing,u=n.getBBox(),c=t.getBBox(),f=i.getBBox(),h=u.height;this.fitRailLength(c,f,u,n),u=n.getBBox(),l==="rail"?(t.attr({x:a.x,y:a.y+h/2}),this.changeRailPosition(n,a.x+c.width+s,a.y),i.attr({x:a.x+c.width+u.width+s*2,y:a.y+h/2})):l==="top"?(t.attr({x:a.x,y:a.y}),i.attr({x:a.x+u.width,y:a.y}),this.changeRailPosition(n,a.x,a.y+c.height+s)):(this.changeRailPosition(n,a.x,a.y),t.attr({x:a.x,y:a.y+u.height+s}),i.attr({x:a.x+u.width,y:a.y+u.height+s}))},r.prototype.fixedVertail=function(t,i,n,a){var o=this.get("label"),l=o.align,s=o.spacing,u=n.getBBox(),c=t.getBBox(),f=i.getBBox();if(this.fitRailLength(c,f,u,n),u=n.getBBox(),l==="rail")t.attr({x:a.x,y:a.y}),this.changeRailPosition(n,a.x,a.y+c.height+s),i.attr({x:a.x,y:a.y+c.height+u.height+s*2});else if(l==="right")t.attr({x:a.x+u.width+s,y:a.y}),this.changeRailPosition(n,a.x,a.y),i.attr({x:a.x+u.width+s,y:a.y+u.height});else{var h=Math.max(c.width,f.width);t.attr({x:a.x,y:a.y}),this.changeRailPosition(n,a.x+h+s,a.y),i.attr({x:a.x,y:a.y+u.height})}},r}(XM),gtt=Object.freeze(Object.defineProperty({__proto__:null,Category:G5,Continuous:z5,Base:XM},Symbol.toStringTag,{value:"Module"})),Nf="g2-tooltip",Gf="g2-tooltip-title",Yd="g2-tooltip-list",x1="g2-tooltip-list-item",_1="g2-tooltip-marker",b1="g2-tooltip-value",V5="g2-tooltip-name",UM="g2-tooltip-crosshair-x",qM="g2-tooltip-crosshair-y",j5=Object.freeze(Object.defineProperty({__proto__:null,CONTAINER_CLASS:Nf,TITLE_CLASS:Gf,LIST_CLASS:Yd,LIST_ITEM_CLASS:x1,MARKER_CLASS:_1,VALUE_CLASS:b1,NAME_CLASS:V5,CROSSHAIR_X:UM,CROSSHAIR_Y:qM},Symbol.toStringTag,{value:"Module"})),Va,ytt=(Va={},Va[""+Nf]={position:"absolute",visibility:"visible",zIndex:8,transition:"visibility 0.2s cubic-bezier(0.23, 1, 0.32, 1), left 0.4s cubic-bezier(0.23, 1, 0.32, 1), top 0.4s cubic-bezier(0.23, 1, 0.32, 1)",backgroundColor:"rgba(255, 255, 255, 0.9)",boxShadow:"0px 0px 10px #aeaeae",borderRadius:"3px",color:"rgb(87, 87, 87)",fontSize:"12px",fontFamily:Ht.fontFamily,lineHeight:"20px",padding:"10px 10px 6px 10px"},Va[""+Gf]={marginBottom:"4px"},Va[""+Yd]={margin:"0px",listStyleType:"none",padding:"0px"},Va[""+x1]={listStyleType:"none",marginBottom:"4px"},Va[""+_1]={width:"8px",height:"8px",borderRadius:"50%",display:"inline-block",marginRight:"8px"},Va[""+b1]={display:"inline-block",float:"right",marginLeft:"30px"},Va[""+UM]={position:"absolute",width:"1px",backgroundColor:"rgba(0, 0, 0, 0.25)"},Va[""+qM]={position:"absolute",height:"1px",backgroundColor:"rgba(0, 0, 0, 0.25)"},Va);function mtt(e,r,t,i,n){var a={left:e<n.x,right:e+t>n.x+n.width,top:r<n.y,bottom:r+i>n.y+n.height};return a}function xtt(e,r,t,i,n,a){var o=e,l=r;switch(a){case"left":o=e-i-t,l=r-n/2;break;case"right":o=e+t,l=r-n/2;break;case"top":o=e-i/2,l=r-n-t;break;case"bottom":o=e-i/2,l=r+t;break;default:o=e+t,l=r-n-t;break}return{x:o,y:l}}function _tt(e,r,t,i,n,a,o){var l=xtt(e,r,t,i,n,a);if(o){var s=mtt(l.x,l.y,i,n,o);a==="auto"?(s.right&&(l.x=Math.max(0,e-i-t)),s.top&&(l.y=Math.max(0,r-n-t))):a==="top"||a==="bottom"?(s.left&&(l.x=o.x),s.right&&(l.x=o.x+o.width-i),a==="top"&&s.top&&(l.y=r+t),a==="bottom"&&s.bottom&&(l.y=r-n-t)):(s.top&&(l.y=o.y),s.bottom&&(l.y=o.y+o.height-n),a==="left"&&s.left&&(l.x=e+t),a==="right"&&s.right&&(l.x=e-i-t))}return l}function btt(e,r){var t=!1;return P(r,function(i){if(po(e,i))return t=!0,!1}),t}var H5=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{name:"tooltip",type:"html",x:0,y:0,items:[],customContent:null,containerTpl:'<div class="'+Nf+'"><div class="'+Gf+'"></div><ul class="'+Yd+'"></ul></div>',itemTpl:'<li class="'+x1+`" data-index={index}>
|
|
<span class="`+_1+`" style="background:{color}"></span>
|
|
<span class="`+V5+`">{name}</span>:
|
|
<span class="`+b1+`">{value}</span>
|
|
</li>`,xCrosshairTpl:'<div class="'+UM+'"></div>',yCrosshairTpl:'<div class="'+qM+'"></div>',title:null,showTitle:!0,region:null,crosshairsRegion:null,containerClassName:Nf,crosshairs:null,offset:10,position:"right",domStyles:null,defaultStyles:ytt})},r.prototype.render=function(){this.get("customContent")?this.renderCustomContent():(this.resetTitle(),this.renderItems()),this.resetPosition()},r.prototype.clear=function(){this.clearCrosshairs(),this.setTitle(""),this.clearItemDoms()},r.prototype.show=function(){var t=this.getContainer();!t||this.destroyed||(this.set("visible",!0),qr(t,{visibility:"visible"}),this.setCrossHairsVisible(!0))},r.prototype.hide=function(){var t=this.getContainer();!t||this.destroyed||(this.set("visible",!1),qr(t,{visibility:"hidden"}),this.setCrossHairsVisible(!1))},r.prototype.getLocation=function(){return{x:this.get("x"),y:this.get("y")}},r.prototype.setLocation=function(t){this.set("x",t.x),this.set("y",t.y),this.resetPosition()},r.prototype.setCrossHairsVisible=function(t){var i=t?"":"none",n=this.get("xCrosshairDom"),a=this.get("yCrosshairDom");n&&qr(n,{display:i}),a&&qr(a,{display:i})},r.prototype.initContainer=function(){if(e.prototype.initContainer.call(this),this.get("customContent")){this.get("container")&&this.get("container").remove();var t=this.getHtmlContentNode();this.get("parent").appendChild(t),this.set("container",t),this.resetStyles(),this.applyStyles()}},r.prototype.updateInner=function(t){this.get("customContent")?this.renderCustomContent():(btt(t,["title","showTitle"])&&this.resetTitle(),po(t,"items")&&this.renderItems()),e.prototype.updateInner.call(this,t)},r.prototype.initDom=function(){this.cacheDoms()},r.prototype.removeDom=function(){e.prototype.removeDom.call(this),this.clearCrosshairs()},r.prototype.resetPosition=function(){var t=this.get("x"),i=this.get("y"),n=this.get("offset"),a=this.getOffset(),o=a.offsetX,l=a.offsetY,s=this.get("position"),u=this.get("region"),c=this.getContainer(),f=this.getBBox(),h=f.width,v=f.height,d;u&&(d=Vd(u));var p=_tt(t,i,n,h,v,s,d);qr(c,{left:Ni(p.x+o),top:Ni(p.y+l)}),this.resetCrosshairs()},r.prototype.renderCustomContent=function(){var t=this.getHtmlContentNode(),i=this.get("parent"),n=this.get("container");n&&n.parentNode===i?i.replaceChild(t,n):i.appendChild(t),this.set("container",t),this.resetStyles(),this.applyStyles()},r.prototype.getHtmlContentNode=function(){var t,i=this.get("customContent");if(i){var n=i(this.get("title"),this.get("items"));t1(n)?t=n:t=Zo(n)}return t},r.prototype.cacheDoms=function(){var t=this.getContainer(),i=t.getElementsByClassName(Gf)[0],n=t.getElementsByClassName(Yd)[0];this.set("titleDom",i),this.set("listDom",n)},r.prototype.resetTitle=function(){var t=this.get("title"),i=this.get("showTitle");i&&t?this.setTitle(t):this.setTitle("")},r.prototype.setTitle=function(t){var i=this.get("titleDom");i&&(i.innerText=t)},r.prototype.resetCrosshairs=function(){var t=this.get("crosshairsRegion"),i=this.get("crosshairs");if(!t||!i)this.clearCrosshairs();else{var n=Vd(t),a=this.get("xCrosshairDom"),o=this.get("yCrosshairDom");i==="x"?(this.resetCrosshair("x",n),o&&(o.remove(),this.set("yCrosshairDom",null))):i==="y"?(this.resetCrosshair("y",n),a&&(a.remove(),this.set("xCrosshairDom",null))):(this.resetCrosshair("x",n),this.resetCrosshair("y",n)),this.setCrossHairsVisible(this.get("visible"))}},r.prototype.resetCrosshair=function(t,i){var n=this.checkCrosshair(t),a=this.get(t);t==="x"?qr(n,{left:Ni(a),top:Ni(i.y),height:Ni(i.height)}):qr(n,{top:Ni(a),left:Ni(i.x),width:Ni(i.width)})},r.prototype.checkCrosshair=function(t){var i=t+"CrosshairDom",n=t+"CrosshairTpl",a="CROSSHAIR_"+t.toUpperCase(),o=j5[a],l=this.get(i),s=this.get("parent");return l||(l=Zo(this.get(n)),this.applyStyle(o,l),s.appendChild(l),this.set(i,l)),l},r.prototype.renderItems=function(){this.clearItemDoms();var t=this.get("items"),i=this.get("itemTpl"),n=this.get("listDom");n&&(P(t,function(a){var o=Qo.toCSSGradient(a.color),l=A(A({},a),{color:o}),s=fM(i,l),u=Zo(s);n.appendChild(u)}),this.applyChildrenStyles(n,this.get("domStyles")))},r.prototype.clearItemDoms=function(){this.get("listDom")&&zM(this.get("listDom"))},r.prototype.clearCrosshairs=function(){var t=this.get("xCrosshairDom"),i=this.get("yCrosshairDom");t&&t.remove(),i&&i.remove(),this.set("xCrosshairDom",null),this.set("yCrosshairDom",null)},r}(m1),wtt=Object.freeze(Object.defineProperty({__proto__:null,Html:H5},Symbol.toStringTag,{value:"Module"})),Ctt={opacity:0},Stt={stroke:"#C5C5C5",strokeOpacity:.85},Att={fill:"#CACED4",opacity:.85};function Ttt(e){return je(e,function(r,t){var i=t===0?"M":"L",n=r[0],a=r[1];return[i,n,a]})}function Y5(e){return Ttt(e)}function Mtt(e){if(e.length<=2)return Y5(e);var r=[];P(e,function(o){Ge(o,r.slice(r.length-2))||r.push(o[0],o[1])});var t=FV(r,!1),i=Wi(e),n=i[0],a=i[1];return t.unshift(["M",n,a]),t}function Ett(e,r,t,i){i===void 0&&(i=!0);var n=new Ah({values:e}),a=new Pp({values:je(e,function(l,s){return s})}),o=je(e,function(l,s){return[a.scale(s)*r,t-n.scale(l)*t]});return i?Mtt(o):Y5(o)}function Ftt(e,r){var t=new Ah({values:e}),i=t.max<0?t.max:Math.max(0,t.min);return r-t.scale(i)*r}function Ott(e,r,t,i){var n=ye(e),a=Ftt(i,t);return n.push(["L",r,a]),n.push(["L",0,a]),n.push(["Z"]),n}var Ptt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{name:"trend",x:0,y:0,width:200,height:16,smooth:!0,isArea:!1,data:[],backgroundStyle:Ctt,lineStyle:Stt,areaStyle:Att})},r.prototype.renderInner=function(t){var i=this.cfg,n=i.width,a=i.height,o=i.data,l=i.smooth,s=i.isArea,u=i.backgroundStyle,c=i.lineStyle,f=i.areaStyle;this.addShape(t,{id:this.getElementId("background"),type:"rect",attrs:A({x:0,y:0,width:n,height:a},u)});var h=Ett(o,n,a,l);if(this.addShape(t,{id:this.getElementId("line"),type:"path",attrs:A({path:h},c)}),s){var v=Ott(h,n,a,o);this.addShape(t,{id:this.getElementId("area"),type:"path",attrs:A({path:v},f)})}},r.prototype.applyOffset=function(){var t=this.cfg,i=t.x,n=t.y;this.moveElementTo(this.get("group"),{x:i,y:n})},r}(Hr),W5={fill:"#F7F7F7",stroke:"#BFBFBF",radius:2,opacity:1,cursor:"ew-resize",highLightFill:"#FFF"},KL=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{name:"handler",x:0,y:0,width:10,height:24,style:W5})},r.prototype.renderInner=function(t){var i=this.cfg,n=i.width,a=i.height,o=i.style,l=o.fill,s=o.stroke,u=o.radius,c=o.opacity,f=o.cursor;this.addShape(t,{type:"rect",id:this.getElementId("background"),attrs:{x:0,y:0,width:n,height:a,fill:l,stroke:s,radius:u,opacity:c,cursor:f}});var h=1/3*n,v=2/3*n,d=1/4*a,p=3/4*a;this.addShape(t,{id:this.getElementId("line-left"),type:"line",attrs:{x1:h,y1:d,x2:h,y2:p,stroke:s,cursor:f}}),this.addShape(t,{id:this.getElementId("line-right"),type:"line",attrs:{x1:v,y1:d,x2:v,y2:p,stroke:s,cursor:f}})},r.prototype.applyOffset=function(){this.moveElementTo(this.get("group"),{x:this.get("x"),y:this.get("y")})},r.prototype.initEvent=function(){this.bindEvents()},r.prototype.bindEvents=function(){var t=this;this.get("group").on("mouseenter",function(){var i=t.get("style").highLightFill;t.getElementByLocalId("background").attr("fill",i),t.draw()}),this.get("group").on("mouseleave",function(){var i=t.get("style").fill;t.getElementByLocalId("background").attr("fill",i),t.draw()})},r.prototype.draw=function(){var t=this.get("container").get("canvas");t&&t.draw()},r}(Hr),Itt={fill:"#416180",opacity:.05},Ltt={fill:"#5B8FF9",opacity:.15,cursor:"move"},y0=10,Dtt={width:y0,height:24},$tt={textBaseline:"middle",fill:"#000",opacity:.45},ktt="sliderchange",X5=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.onMouseDown=function(i){return function(n){t.currentTarget=i;var a=n.originalEvent;a.stopPropagation(),a.preventDefault(),t.prevX=I(a,"touches.0.pageX",a.pageX),t.prevY=I(a,"touches.0.pageY",a.pageY);var o=t.getContainerDOM();o.addEventListener("mousemove",t.onMouseMove),o.addEventListener("mouseup",t.onMouseUp),o.addEventListener("mouseleave",t.onMouseUp),o.addEventListener("touchmove",t.onMouseMove),o.addEventListener("touchend",t.onMouseUp),o.addEventListener("touchcancel",t.onMouseUp)}},t.onMouseMove=function(i){var n=t.cfg.width,a=[t.get("start"),t.get("end")];i.stopPropagation(),i.preventDefault();var o=I(i,"touches.0.pageX",i.pageX),l=I(i,"touches.0.pageY",i.pageY),s=o-t.prevX,u=t.adjustOffsetRange(s/n);t.updateStartEnd(u),t.updateUI(t.getElementByLocalId("foreground"),t.getElementByLocalId("minText"),t.getElementByLocalId("maxText")),t.prevX=o,t.prevY=l,t.draw(),t.emit(ktt,[t.get("start"),t.get("end")].sort()),t.delegateEmit("valuechanged",{originValue:a,value:[t.get("start"),t.get("end")]})},t.onMouseUp=function(){t.currentTarget&&(t.currentTarget=void 0);var i=t.getContainerDOM();i&&(i.removeEventListener("mousemove",t.onMouseMove),i.removeEventListener("mouseup",t.onMouseUp),i.removeEventListener("mouseleave",t.onMouseUp),i.removeEventListener("touchmove",t.onMouseMove),i.removeEventListener("touchend",t.onMouseUp),i.removeEventListener("touchcancel",t.onMouseUp))},t}return r.prototype.setRange=function(t,i){this.set("minLimit",t),this.set("maxLimit",i);var n=this.get("start"),a=this.get("end"),o=Ce(n,t,i),l=Ce(a,t,i);!this.get("isInit")&&(n!==o||a!==l)&&this.setValue([o,l])},r.prototype.getRange=function(){return{min:this.get("minLimit")||0,max:this.get("maxLimit")||1}},r.prototype.setValue=function(t){var i=this.getRange();if(it(t)&&t.length===2){var n=[this.get("start"),this.get("end")];this.update({start:Ce(t[0],i.min,i.max),end:Ce(t[1],i.min,i.max)}),this.get("updateAutoRender")||this.render(),this.delegateEmit("valuechanged",{originValue:n,value:t})}},r.prototype.getValue=function(){return[this.get("start"),this.get("end")]},r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{name:"slider",x:0,y:0,width:100,height:16,backgroundStyle:{},foregroundStyle:{},handlerStyle:{},textStyle:{},defaultCfg:{backgroundStyle:Itt,foregroundStyle:Ltt,handlerStyle:Dtt,textStyle:$tt}})},r.prototype.update=function(t){var i=t.start,n=t.end,a=A({},t);K(i)||(a.start=Ce(i,0,1)),K(n)||(a.end=Ce(n,0,1)),e.prototype.update.call(this,a),this.minHandler=this.getChildComponentById(this.getElementId("minHandler")),this.maxHandler=this.getChildComponentById(this.getElementId("maxHandler")),this.trend=this.getChildComponentById(this.getElementId("trend"))},r.prototype.init=function(){this.set("start",Ce(this.get("start"),0,1)),this.set("end",Ce(this.get("end"),0,1)),e.prototype.init.call(this)},r.prototype.render=function(){e.prototype.render.call(this),this.updateUI(this.getElementByLocalId("foreground"),this.getElementByLocalId("minText"),this.getElementByLocalId("maxText"))},r.prototype.renderInner=function(t){var i=this.cfg;i.start,i.end;var n=i.width,a=i.height,o=i.trendCfg,l=o===void 0?{}:o,s=i.minText,u=i.maxText,c=i.backgroundStyle,f=c===void 0?{}:c,h=i.foregroundStyle,v=h===void 0?{}:h,d=i.textStyle,p=d===void 0?{}:d,x=ft({},W5,this.cfg.handlerStyle);yr(I(l,"data"))&&(this.trend=this.addComponent(t,A({component:Ptt,id:this.getElementId("trend"),x:0,y:0,width:n,height:a},l))),this.addShape(t,{id:this.getElementId("background"),type:"rect",attrs:A({x:0,y:0,width:n,height:a},f)}),this.addShape(t,{id:this.getElementId("minText"),type:"text",attrs:A({y:a/2,textAlign:"right",text:s,silent:!1},p)}),this.addShape(t,{id:this.getElementId("maxText"),type:"text",attrs:A({y:a/2,textAlign:"left",text:u,silent:!1},p)}),this.addShape(t,{id:this.getElementId("foreground"),name:"foreground",type:"rect",attrs:A({y:0,height:a},v)});var m=I(x,"width",y0),_=I(x,"height",24);this.minHandler=this.addComponent(t,{component:KL,id:this.getElementId("minHandler"),name:"handler-min",x:0,y:(a-_)/2,width:m,height:_,cursor:"ew-resize",style:x}),this.maxHandler=this.addComponent(t,{component:KL,id:this.getElementId("maxHandler"),name:"handler-max",x:0,y:(a-_)/2,width:m,height:_,cursor:"ew-resize",style:x})},r.prototype.applyOffset=function(){this.moveElementTo(this.get("group"),{x:this.get("x"),y:this.get("y")})},r.prototype.initEvent=function(){this.bindEvents()},r.prototype.updateUI=function(t,i,n){var a=this.cfg,o=a.start,l=a.end,s=a.width,u=a.minText,c=a.maxText,f=a.handlerStyle,h=a.height,v=o*s,d=l*s;this.trend&&(this.trend.update({width:s,height:h}),this.get("updateAutoRender")||this.trend.render()),t.attr("x",v),t.attr("width",d-v);var p=I(f,"width",y0);i.attr("text",u),n.attr("text",c);var x=this._dodgeText([v,d],i,n),m=x[0],_=x[1];this.minHandler&&(this.minHandler.update({x:v-p/2}),this.get("updateAutoRender")||this.minHandler.render()),P(m,function(b,w){return i.attr(w,b)}),this.maxHandler&&(this.maxHandler.update({x:d-p/2}),this.get("updateAutoRender")||this.maxHandler.render()),P(_,function(b,w){return n.attr(w,b)})},r.prototype.bindEvents=function(){var t=this.get("group");t.on("handler-min:mousedown",this.onMouseDown("minHandler")),t.on("handler-min:touchstart",this.onMouseDown("minHandler")),t.on("handler-max:mousedown",this.onMouseDown("maxHandler")),t.on("handler-max:touchstart",this.onMouseDown("maxHandler"));var i=t.findById(this.getElementId("foreground"));i.on("mousedown",this.onMouseDown("foreground")),i.on("touchstart",this.onMouseDown("foreground"))},r.prototype.adjustOffsetRange=function(t){var i=this.cfg,n=i.start,a=i.end;switch(this.currentTarget){case"minHandler":{var o=0-n,l=1-n;return Math.min(l,Math.max(o,t))}case"maxHandler":{var o=0-a,l=1-a;return Math.min(l,Math.max(o,t))}case"foreground":{var o=0-n,l=1-a;return Math.min(l,Math.max(o,t))}}},r.prototype.updateStartEnd=function(t){var i=this.cfg,n=i.start,a=i.end;switch(this.currentTarget){case"minHandler":n+=t;break;case"maxHandler":a+=t;break;case"foreground":n+=t,a+=t;break}this.set("start",n),this.set("end",a)},r.prototype._dodgeText=function(t,i,n){var a,o,l=this.cfg,s=l.handlerStyle,u=l.width,c=2,f=I(s,"width",y0),h=t[0],v=t[1],d=!1;h>v&&(a=[v,h],h=a[0],v=a[1],o=[n,i],i=o[0],n=o[1],d=!0);var p=i.getBBox(),x=n.getBBox(),m=p.width>h-c?{x:h+f/2+c,textAlign:"left"}:{x:h-f/2-c,textAlign:"right"},_=x.width>u-v-c?{x:v-f/2-c,textAlign:"right"}:{x:v+f/2+c,textAlign:"left"};return d?[_,m]:[m,_]},r.prototype.draw=function(){var t=this.get("container"),i=t&&t.get("canvas");i&&i.draw()},r.prototype.getContainerDOM=function(){var t=this.get("container"),i=t&&t.get("canvas");return i&&i.get("container")},r}(Hr),Rtt={trackColor:"rgba(0,0,0,0)",thumbColor:"rgba(0,0,0,0.15)",size:8,lineCap:"round"},rC={default:Rtt,hover:{thumbColor:"rgba(0,0,0,0.2)"}},U5=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.clearEvents=Wo,t.onStartEvent=function(i){return function(n){t.isMobile=i,n.originalEvent.preventDefault();var a=i?I(n.originalEvent,"touches.0.clientX"):n.clientX,o=i?I(n.originalEvent,"touches.0.clientY"):n.clientY;t.startPos=t.cfg.isHorizontal?a:o,t.bindLaterEvent()}},t.bindLaterEvent=function(){var i=t.getContainerDOM(),n=[];t.isMobile?n=[hu(i,"touchmove",t.onMouseMove),hu(i,"touchend",t.onMouseUp),hu(i,"touchcancel",t.onMouseUp)]:n=[hu(i,"mousemove",t.onMouseMove),hu(i,"mouseup",t.onMouseUp),hu(i,"mouseleave",t.onMouseUp)],t.clearEvents=function(){n.forEach(function(a){a.remove()})}},t.onMouseMove=function(i){var n=t.cfg,a=n.isHorizontal,o=n.thumbOffset;i.preventDefault();var l=t.isMobile?I(i,"touches.0.clientX"):i.clientX,s=t.isMobile?I(i,"touches.0.clientY"):i.clientY,u=a?l:s,c=u-t.startPos;t.startPos=u,t.updateThumbOffset(o+c)},t.onMouseUp=function(i){i.preventDefault(),t.clearEvents()},t.onTrackClick=function(i){var n=t.cfg,a=n.isHorizontal,o=n.x,l=n.y,s=n.thumbLen,u=t.getContainerDOM(),c=u.getBoundingClientRect(),f=i.clientX,h=i.clientY,v=a?f-c.left-o-s/2:h-c.top-l-s/2,d=t.validateRange(v);t.updateThumbOffset(d)},t.onThumbMouseOver=function(){var i=t.cfg.theme.hover.thumbColor;t.getElementByLocalId("thumb").attr("stroke",i),t.draw()},t.onThumbMouseOut=function(){var i=t.cfg.theme.default.thumbColor;t.getElementByLocalId("thumb").attr("stroke",i),t.draw()},t}return r.prototype.setRange=function(t,i){this.set("minLimit",t),this.set("maxLimit",i);var n=this.getValue(),a=Ce(n,t,i);n!==a&&!this.get("isInit")&&this.setValue(a)},r.prototype.getRange=function(){var t=this.get("minLimit")||0,i=this.get("maxLimit")||1;return{min:t,max:i}},r.prototype.setValue=function(t){var i=this.getRange(),n=this.getValue();this.update({thumbOffset:(this.get("trackLen")-this.get("thumbLen"))*Ce(t,i.min,i.max)}),this.delegateEmit("valuechange",{originalValue:n,value:this.getValue()})},r.prototype.getValue=function(){return Ce(this.get("thumbOffset")/(this.get("trackLen")-this.get("thumbLen")),0,1)},r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return A(A({},t),{name:"scrollbar",isHorizontal:!0,minThumbLen:20,thumbOffset:0,theme:rC})},r.prototype.renderInner=function(t){this.renderTrackShape(t),this.renderThumbShape(t)},r.prototype.applyOffset=function(){this.moveElementTo(this.get("group"),{x:this.get("x"),y:this.get("y")})},r.prototype.initEvent=function(){this.bindEvents()},r.prototype.renderTrackShape=function(t){var i=this.cfg,n=i.trackLen,a=i.theme,o=a===void 0?{default:{}}:a,l=ft({},rC,o).default,s=l.lineCap,u=l.trackColor,c=l.size,f=I(this.cfg,"size",c),h=this.get("isHorizontal")?{x1:0+f/2,y1:f/2,x2:n-f/2,y2:f/2,lineWidth:f,stroke:u,lineCap:s}:{x1:f/2,y1:0+f/2,x2:f/2,y2:n-f/2,lineWidth:f,stroke:u,lineCap:s};return this.addShape(t,{id:this.getElementId("track"),name:"track",type:"line",attrs:h})},r.prototype.renderThumbShape=function(t){var i=this.cfg,n=i.thumbOffset,a=i.thumbLen,o=i.theme,l=ft({},rC,o).default,s=l.size,u=l.lineCap,c=l.thumbColor,f=I(this.cfg,"size",s),h=this.get("isHorizontal")?{x1:n+f/2,y1:f/2,x2:n+a-f/2,y2:f/2,lineWidth:f,stroke:c,lineCap:u,cursor:"default"}:{x1:f/2,y1:n+f/2,x2:f/2,y2:n+a-f/2,lineWidth:f,stroke:c,lineCap:u,cursor:"default"};return this.addShape(t,{id:this.getElementId("thumb"),name:"thumb",type:"line",attrs:h})},r.prototype.bindEvents=function(){var t=this.get("group");t.on("mousedown",this.onStartEvent(!1)),t.on("mouseup",this.onMouseUp),t.on("touchstart",this.onStartEvent(!0)),t.on("touchend",this.onMouseUp);var i=t.findById(this.getElementId("track"));i.on("click",this.onTrackClick);var n=t.findById(this.getElementId("thumb"));n.on("mouseover",this.onThumbMouseOver),n.on("mouseout",this.onThumbMouseOut)},r.prototype.getContainerDOM=function(){var t=this.get("container"),i=t&&t.get("canvas");return i&&i.get("container")},r.prototype.validateRange=function(t){var i=this.cfg,n=i.thumbLen,a=i.trackLen,o=t;return t+n>a?o=a-n:t+n<n&&(o=0),o},r.prototype.draw=function(){var t=this.get("container"),i=t&&t.get("canvas");i&&i.draw()},r.prototype.updateThumbOffset=function(t){var i=this.cfg,n=i.thumbOffset,a=i.isHorizontal,o=i.thumbLen,l=i.size,s=this.validateRange(t);if(s!==n){var u=this.getElementByLocalId("thumb");a?u.attr({x1:s+l/2,x2:s+o-l/2}):u.attr({y1:s+l/2,y2:s+o-l/2}),this.emitOffsetChange(s)}},r.prototype.emitOffsetChange=function(t){var i=this.cfg,n=i.thumbOffset,a=i.trackLen,o=i.thumbLen;this.cfg.thumbOffset=t,this.emit("scrollchange",{thumbOffset:t,ratio:Ce(t/(a-o),0,1)}),this.delegateEmit("valuechange",{originalValue:n,value:t})},r}(Hr),Btt=Object.freeze(Object.defineProperty({__proto__:null,Axis:utt,Annotation:M5,Grid:dtt,Legend:gtt,Tooltip:wtt,Crosshair:BA,TOOLTIP_CSS_CONST:j5,Component:VM,GroupComponent:Hr,HtmlComponent:m1,Slider:X5,Scrollbar:U5,propagationDelegate:NM},Symbol.toStringTag,{value:"Module"})),w1=br(Btt);(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Scrollbar=e.Slider=e.HtmlTooltip=e.ContinuousLegend=e.CategoryLegend=e.CircleGrid=e.LineGrid=e.CircleAxis=e.LineAxis=e.Annotation=e.Crosshair=e.Component=e.GroupComponent=e.HtmlComponent=e.Scale=e.registerScale=e.getScale=e.Coordinate=e.registerCoordinate=e.getCoordinate=e.Color=e.Attribute=e.getAttribute=e.Adjust=e.getAdjust=e.registerAdjust=e.AbstractShape=e.AbstractGroup=e.Event=void 0;var r=ii;Object.defineProperty(e,"Event",{enumerable:!0,get:function(){return r.Event}}),Object.defineProperty(e,"AbstractGroup",{enumerable:!0,get:function(){return r.AbstractGroup}}),Object.defineProperty(e,"AbstractShape",{enumerable:!0,get:function(){return r.AbstractShape}});var t=zV;Object.defineProperty(e,"registerAdjust",{enumerable:!0,get:function(){return t.registerAdjust}}),Object.defineProperty(e,"getAdjust",{enumerable:!0,get:function(){return t.getAdjust}}),Object.defineProperty(e,"Adjust",{enumerable:!0,get:function(){return t.Adjust}});var i=LA;Object.defineProperty(e,"getAttribute",{enumerable:!0,get:function(){return i.getAttribute}}),Object.defineProperty(e,"Attribute",{enumerable:!0,get:function(){return i.Attribute}});var n=LA;Object.defineProperty(e,"Color",{enumerable:!0,get:function(){return n.Color}});var a=xJ;Object.defineProperty(e,"getCoordinate",{enumerable:!0,get:function(){return a.getCoordinate}}),Object.defineProperty(e,"registerCoordinate",{enumerable:!0,get:function(){return a.registerCoordinate}}),Object.defineProperty(e,"Coordinate",{enumerable:!0,get:function(){return a.Coordinate}});var o=_J;Object.defineProperty(e,"getScale",{enumerable:!0,get:function(){return o.getScale}}),Object.defineProperty(e,"registerScale",{enumerable:!0,get:function(){return o.registerScale}}),Object.defineProperty(e,"Scale",{enumerable:!0,get:function(){return o.Scale}});var l=w1;Object.defineProperty(e,"Annotation",{enumerable:!0,get:function(){return l.Annotation}}),Object.defineProperty(e,"Component",{enumerable:!0,get:function(){return l.Component}}),Object.defineProperty(e,"Crosshair",{enumerable:!0,get:function(){return l.Crosshair}}),Object.defineProperty(e,"GroupComponent",{enumerable:!0,get:function(){return l.GroupComponent}}),Object.defineProperty(e,"HtmlComponent",{enumerable:!0,get:function(){return l.HtmlComponent}}),Object.defineProperty(e,"Slider",{enumerable:!0,get:function(){return l.Slider}}),Object.defineProperty(e,"Scrollbar",{enumerable:!0,get:function(){return l.Scrollbar}});var s=l.Axis.Line,u=l.Axis.Circle;e.LineAxis=s,e.CircleAxis=u;var c=l.Grid.Line,f=l.Grid.Circle;e.LineGrid=c,e.CircleGrid=f;var h=l.Legend.Category,v=l.Legend.Continuous;e.CategoryLegend=h,e.ContinuousLegend=v;var d=l.Tooltip.Html;e.HtmlTooltip=d})(Qn);var cl={},Zu={};Object.defineProperty(Zu,"__esModule",{value:!0});Zu.registerAnimation=Zu.getAnimation=void 0;var q5={};function Ntt(e){return q5[e.toLowerCase()]}Zu.getAnimation=Ntt;function Gtt(e,r){q5[e.toLowerCase()]=r}Zu.registerAnimation=Gtt;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.doGroupAppearAnimate=e.doAnimate=e.getDefaultAnimateCfg=e.DEFAULT_ANIMATE_CFG=void 0;var r=V,t=Y,i=Jt,n=Zu;e.DEFAULT_ANIMATE_CFG={appear:{duration:450,easing:"easeQuadOut"},update:{duration:400,easing:"easeQuadInOut"},enter:{duration:400,easing:"easeQuadInOut"},leave:{duration:350,easing:"easeQuadIn"}};var a={interval:function(f){return{enter:{animation:f.isRect?f.isTransposed?"scale-in-x":"scale-in-y":"fade-in"},update:{animation:f.isPolar&&f.isTransposed?"sector-path-update":null},leave:{animation:"fade-out"}}},line:{enter:{animation:"fade-in"},leave:{animation:"fade-out"}},path:{enter:{animation:"fade-in"},leave:{animation:"fade-out"}},point:{appear:{animation:"zoom-in"},enter:{animation:"zoom-in"},leave:{animation:"zoom-out"}},area:{enter:{animation:"fade-in"},leave:{animation:"fade-out"}},polygon:{enter:{animation:"fade-in"},leave:{animation:"fade-out"}},schema:{enter:{animation:"fade-in"},leave:{animation:"fade-out"}},edge:{enter:{animation:"fade-in"},leave:{animation:"fade-out"}},label:{appear:{animation:"fade-in",delay:450},enter:{animation:"fade-in"},update:{animation:"position-update"},leave:{animation:"fade-out"}}},o={line:function(){return{animation:"wave-in"}},area:function(){return{animation:"wave-in"}},path:function(){return{animation:"fade-in"}},interval:function(f){var h;return f.isRect?h=f.isTransposed?"grow-in-x":"grow-in-y":(h="grow-in-xy",f.isPolar&&f.isTransposed&&(h="wave-in")),{animation:h}},schema:function(f){var h;return f.isRect?h=f.isTransposed?"grow-in-x":"grow-in-y":h="grow-in-xy",{animation:h}},polygon:function(){return{animation:"fade-in",duration:500}},edge:function(){return{animation:"fade-in"}}};function l(f,h){return{delay:(0,t.isFunction)(f.delay)?f.delay(h):f.delay,easing:(0,t.isFunction)(f.easing)?f.easing(h):f.easing,duration:(0,t.isFunction)(f.duration)?f.duration(h):f.duration,callback:f.callback,repeat:f.repeat}}function s(f,h,v){var d=a[f];return d&&((0,t.isFunction)(d)&&(d=d(h)),d=(0,t.deepMix)({},e.DEFAULT_ANIMATE_CFG,d),v)?d[v]:d}e.getDefaultAnimateCfg=s;function u(f,h,v){var d=(0,t.get)(f.get("origin"),"data",i.FIELD_ORIGIN),p=h.animation,x=l(h,d);if(p){var m=(0,n.getAnimation)(p);m&&m(f,x,v)}else f.animate(v.toAttrs,x)}e.doAnimate=u;function c(f,h,v,d,p){if(o[v]){var x=o[v](d),m=(0,n.getAnimation)((0,t.get)(x,"animation",""));if(m){var _=(0,r.__assign)((0,r.__assign)((0,r.__assign)({},e.DEFAULT_ANIMATE_CFG.appear),x),h);f.stopAnimate(),m(f,_,{coordinate:d,minYPoint:p,toAttrs:null})}}}e.doGroupAppearAnimate=c})(cl);var be={},Se={};Object.defineProperty(Se,"__esModule",{value:!0});Se.getReplaceAttrs=Se.getPolygonCentroid=Se.getAngle=Se.getArcPath=Se.getSectorPath=Se.polarToCartesian=void 0;var vs=Y;function ztt(e){if((0,vs.isEmpty)(e))return null;var r=e[0].x,t=e[0].x,i=e[0].y,n=e[0].y;return(0,vs.each)(e,function(a){r=r>a.x?a.x:r,t=t<a.x?a.x:t,i=i>a.y?a.y:i,n=n<a.y?a.y:n}),{minX:r,maxX:t,minY:i,maxY:n,centerX:(r+t)/2,centerY:(i+n)/2}}function JL(e){return Array.from(new Set(e)).length===1}function tD(e){return((0,vs.min)(e)+(0,vs.max)(e))/2}function Ka(e,r,t,i){return{x:e+t*Math.cos(i),y:r+t*Math.sin(i)}}Se.polarToCartesian=Ka;function Vtt(e,r,t,i,n,a){a===void 0&&(a=0);var o=Ka(e,r,t,i),l=Ka(e,r,t,n),s=Ka(e,r,a,i),u=Ka(e,r,a,n);if(n-i===Math.PI*2){var c=Ka(e,r,t,i+Math.PI),f=Ka(e,r,a,i+Math.PI),h=[["M",o.x,o.y],["A",t,t,0,1,1,c.x,c.y],["A",t,t,0,1,1,l.x,l.y],["M",s.x,s.y]];return a&&(h.push(["A",a,a,0,1,0,f.x,f.y]),h.push(["A",a,a,0,1,0,u.x,u.y])),h.push(["M",o.x,o.y]),h.push(["Z"]),h}var v=n-i<=Math.PI?0:1,d=[["M",o.x,o.y],["A",t,t,0,v,1,l.x,l.y],["L",u.x,u.y]];return a&&d.push(["A",a,a,0,v,0,s.x,s.y]),d.push(["L",o.x,o.y]),d.push(["Z"]),d}Se.getSectorPath=Vtt;function jtt(e,r,t,i,n){var a=Ka(e,r,t,i),o=Ka(e,r,t,n);if((0,vs.isNumberEqual)(n-i,Math.PI*2)){var l=Ka(e,r,t,i+Math.PI);return[["M",a.x,a.y],["A",t,t,0,1,1,l.x,l.y],["A",t,t,0,1,1,a.x,a.y],["A",t,t,0,1,0,l.x,l.y],["A",t,t,0,1,0,a.x,a.y],["Z"]]}var s=n-i<=Math.PI?0:1;return[["M",a.x,a.y],["A",t,t,0,s,1,o.x,o.y]]}Se.getArcPath=jtt;function Htt(e,r){var t=e.points,i=ztt(t),n,a,o=r.startAngle,l=r.endAngle,s=l-o;return r.isTransposed?(n=i.maxY*s,a=i.minY*s):(n=i.maxX*s,a=i.minX*s),n+=o,a+=o,{startAngle:a,endAngle:n}}Se.getAngle=Htt;function Ytt(e,r){if((0,vs.isNumber)(e)&&(0,vs.isNumber)(r))return[e,r];if(e=e,r=r,JL(e)||JL(r))return[tD(e),tD(r)];for(var t=-1,i=0,n=0,a,o=e.length-1,l,s=0;++t<e.length;)a=o,o=t,s+=l=e[a]*r[o]-e[o]*r[a],i+=(e[a]+e[o])*l,n+=(r[a]+r[o])*l;return s*=3,[i/s,n/s]}Se.getPolygonCentroid=Ytt;function Wtt(e,r){var t=e.attr(),i=r.attr();return(0,vs.each)(t,function(n,a){i[a]===void 0&&(i[a]=void 0)}),i}Se.getReplaceAttrs=Wtt;var mr={};Object.defineProperty(mr,"__esModule",{value:!0});mr.uniq=mr.omit=mr.padEnd=mr.isBetween=void 0;var eD=Y;function Xtt(e,r,t){var i=Math.min(r,t),n=Math.max(r,t);return e>=i&&e<=n}mr.isBetween=Xtt;function Utt(e,r,t){if((0,eD.isString)(e))return e.padEnd(r,t);if((0,eD.isArray)(e)){var i=e.length;if(i<r)for(var n=r-i,a=0;a<n;a++)e.push(t)}return e}mr.padEnd=Utt;function qtt(e,r){return typeof e=="object"&&r.forEach(function(t){delete e[t]}),e}mr.omit=qtt;function Ztt(e,r,t){r===void 0&&(r=[]),t===void 0&&(t=new Map);for(var i=0,n=e;i<n.length;i++){var a=n[i];t.has(a)||(r.push(a),t.set(a,!0))}return r}mr.uniq=Ztt;var ti={};Object.defineProperty(ti,"__esModule",{value:!0});ti.toPoints=ti.getRegionBBox=ti.BBox=void 0;var rD=Y,$n=Jt,Z5=function(){function e(r,t,i,n){r===void 0&&(r=0),t===void 0&&(t=0),i===void 0&&(i=0),n===void 0&&(n=0),this.x=r,this.y=t,this.height=n,this.width=i}return e.fromRange=function(r,t,i,n){return new e(r,t,i-r,n-t)},e.fromObject=function(r){return new e(r.minX,r.minY,r.width,r.height)},Object.defineProperty(e.prototype,"minX",{get:function(){return this.x},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"maxX",{get:function(){return this.x+this.width},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"minY",{get:function(){return this.y},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"maxY",{get:function(){return this.y+this.height},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tl",{get:function(){return{x:this.x,y:this.y}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tr",{get:function(){return{x:this.maxX,y:this.y}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"bl",{get:function(){return{x:this.x,y:this.maxY}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"br",{get:function(){return{x:this.maxX,y:this.maxY}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"top",{get:function(){return{x:this.x+this.width/2,y:this.minY}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"right",{get:function(){return{x:this.maxX,y:this.y+this.height/2}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"bottom",{get:function(){return{x:this.x+this.width/2,y:this.maxY}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"left",{get:function(){return{x:this.minX,y:this.y+this.height/2}},enumerable:!1,configurable:!0}),e.prototype.isEqual=function(r){return this.x===r.x&&this.y===r.y&&this.width===r.width&&this.height===r.height},e.prototype.contains=function(r){return r.minX>=this.minX&&r.maxX<=this.maxX&&r.minY>=this.minY&&r.maxY<=this.maxY},e.prototype.clone=function(){return new e(this.x,this.y,this.width,this.height)},e.prototype.add=function(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];var i=this.clone();return(0,rD.each)(r,function(n){i.x=Math.min(n.x,i.x),i.y=Math.min(n.y,i.y),i.width=Math.max(n.maxX,i.maxX)-i.x,i.height=Math.max(n.maxY,i.maxY)-i.y}),i},e.prototype.merge=function(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];var i=this.clone();return(0,rD.each)(r,function(n){i.x=Math.max(n.x,i.x),i.y=Math.max(n.y,i.y),i.width=Math.min(n.maxX,i.maxX)-i.x,i.height=Math.min(n.maxY,i.maxY)-i.y}),i},e.prototype.cut=function(r,t){var i=r.width,n=r.height;switch(t){case $n.DIRECTION.TOP:case $n.DIRECTION.TOP_LEFT:case $n.DIRECTION.TOP_RIGHT:return e.fromRange(this.minX,this.minY+n,this.maxX,this.maxY);case $n.DIRECTION.RIGHT:case $n.DIRECTION.RIGHT_TOP:case $n.DIRECTION.RIGHT_BOTTOM:return e.fromRange(this.minX,this.minY,this.maxX-i,this.maxY);case $n.DIRECTION.BOTTOM:case $n.DIRECTION.BOTTOM_LEFT:case $n.DIRECTION.BOTTOM_RIGHT:return e.fromRange(this.minX,this.minY,this.maxX,this.maxY-n);case $n.DIRECTION.LEFT:case $n.DIRECTION.LEFT_TOP:case $n.DIRECTION.LEFT_BOTTOM:return e.fromRange(this.minX+i,this.minY,this.maxX,this.maxY);default:return this}},e.prototype.shrink=function(r){var t=r[0],i=r[1],n=r[2],a=r[3];return new e(this.x+a,this.y+t,this.width-a-i,this.height-t-n)},e.prototype.expand=function(r){var t=r[0],i=r[1],n=r[2],a=r[3];return new e(this.x-a,this.y-t,this.width+a+i,this.height+t+n)},e.prototype.exceed=function(r){return[Math.max(-this.minY+r.minY,0),Math.max(this.maxX-r.maxX,0),Math.max(this.maxY-r.maxY,0),Math.max(-this.minX+r.minX,0)]},e.prototype.collide=function(r){return this.minX<r.maxX&&this.maxX>r.minX&&this.minY<r.maxY&&this.maxY>r.minY},e.prototype.size=function(){return this.width*this.height},e.prototype.isPointIn=function(r){return r.x>=this.minX&&r.x<=this.maxX&&r.y>=this.minY&&r.y<=this.maxY},e}();ti.BBox=Z5;var Qtt=function(e,r){var t=r.start,i=r.end;return new Z5(e.x+e.width*t.x,e.y+e.height*t.y,e.width*Math.abs(i.x-t.x),e.height*Math.abs(i.y-t.y))};ti.getRegionBBox=Qtt;function Ktt(e){return[[e.minX,e.minY],[e.maxX,e.minY],[e.maxX,e.maxY],[e.minX,e.maxY]]}ti.toPoints=Ktt;Object.defineProperty(be,"__esModule",{value:!0});be.getCoordinateBBox=be.getCoordinateClipCfg=be.getAngleByPoint=be.isPointInCoordinate=be.getDistanceToCenter=be.isFullCircle=be.getXDimensionLength=void 0;var iC=Se,Yy=mr,Jtt=ti;function tet(e){if(e.isPolar&&!e.isTransposed)return(e.endAngle-e.startAngle)*e.getRadius();var r=e.convert({x:0,y:0}),t=e.convert({x:1,y:0});return Math.sqrt(Math.pow(t.x-r.x,2)+Math.pow(t.y-r.y,2))}be.getXDimensionLength=tet;function eet(e){if(e.isPolar){var r=e.startAngle,t=e.endAngle;return t-r===Math.PI*2}return!1}be.isFullCircle=eet;function ret(e,r){var t=e.getCenter();return Math.sqrt(Math.pow(r.x-t.x,2)+Math.pow(r.y-t.y,2))}be.getDistanceToCenter=ret;function iet(e,r){var t=!1;if(e)if(e.type==="theta"){var i=e.start,n=e.end;t=(0,Yy.isBetween)(r.x,i.x,n.x)&&(0,Yy.isBetween)(r.y,i.y,n.y)}else{var a=e.invert(r);t=(0,Yy.isBetween)(a.x,0,1)&&(0,Yy.isBetween)(a.y,0,1)}return t}be.isPointInCoordinate=iet;function net(e,r){var t=e.getCenter();return Math.atan2(r.y-t.y,r.x-t.x)}be.getAngleByPoint=net;function aet(e,r){r===void 0&&(r=0);var t=e.start,i=e.end,n=e.getWidth(),a=e.getHeight();if(e.isPolar){var o=e.startAngle,l=e.endAngle,s=e.getCenter(),u=e.getRadius();return{type:"path",startState:{path:(0,iC.getSectorPath)(s.x,s.y,u+r,o,o)},endState:function(f){var h=(l-o)*f+o,v=(0,iC.getSectorPath)(s.x,s.y,u+r,o,h);return{path:v}},attrs:{path:(0,iC.getSectorPath)(s.x,s.y,u+r,o,l)}}}var c;return e.isTransposed?c={height:a+r*2}:c={width:n+r*2},{type:"rect",startState:{x:t.x-r,y:i.y-r,width:e.isTransposed?n+r*2:0,height:e.isTransposed?0:a+r*2},endState:c,attrs:{x:t.x-r,y:i.y-r,width:n+r*2,height:a+r*2}}}be.getCoordinateClipCfg=aet;function oet(e,r){r===void 0&&(r=0);var t=e.start,i=e.end,n=e.getWidth(),a=e.getHeight(),o=Math.min(t.x,i.x),l=Math.min(t.y,i.y);return Jtt.BBox.fromRange(o-r,l-r,o+n+r,l+a+r)}be.getCoordinateBBox=oet;var C1={},zf={};Object.defineProperty(zf,"__esModule",{value:!0});zf.getMean=zf.getMedian=void 0;var set=V,iD=Y;function uet(e){var r=(0,set.__spreadArray)([],e,!0);r.sort(function(i,n){return i-n});var t=r.length;return t===0?0:t%2===1?r[(t-1)/2]:(r[t/2]+r[t/2-1])/2}zf.getMedian=uet;function cet(e){var r=(0,iD.reduce)(e,function(t,i){return t+=isNaN(i)||!(0,iD.isNumber)(i)?0:i},0);return e.length===0?0:r/e.length}zf.getMean=cet;Object.defineProperty(C1,"__esModule",{value:!0});C1.getNormalizedValue=void 0;var nC=zf;function fet(e,r){if(!r)return null;var t;switch(e){case"start":return 0;case"center":return .5;case"end":return 1;case"median":{t=r.isCategory?(0,nC.getMedian)(r.values.map(function(i,n){return n})):(0,nC.getMedian)(r.values);break}case"mean":{t=r.isCategory?(r.values.length-1)/2:(0,nC.getMean)(r.values);break}case"min":t=r.isCategory?0:r[e];break;case"max":t=r.isCategory?r.values.length-1:r[e];break;default:t=e;break}return r.scale(t)}C1.getNormalizedValue=fet;var mo={};Object.defineProperty(mo,"__esModule",{value:!0});mo.Controller=void 0;var het=Y,vet=function(){function e(r){this.visible=!0,this.components=[],this.view=r}return e.prototype.clear=function(r){(0,het.each)(this.components,function(t){t.component.destroy()}),this.components=[]},e.prototype.destroy=function(){this.clear()},e.prototype.getComponents=function(){return this.components},e.prototype.changeVisible=function(r){this.visible!==r&&(this.components.forEach(function(t){r?t.component.show():t.component.hide()}),this.visible=r)},e}();mo.Controller=vet;Object.defineProperty(IM,"__esModule",{value:!0});var Vt=V,xe=Y,det=Qn,pet=cl,Tl=Jt,aC=be,get=mr,Wy=C1,yet=mo,Xy=["regionFilter","shape"],met=function(e){(0,Vt.__extends)(r,e);function r(t){var i=e.call(this,t)||this;return i.cache=new Map,i.foregroundContainer=i.view.getLayer(Tl.LAYER.FORE).addGroup(),i.backgroundContainer=i.view.getLayer(Tl.LAYER.BG).addGroup(),i.option=[],i}return Object.defineProperty(r.prototype,"name",{get:function(){return"annotation"},enumerable:!1,configurable:!0}),r.prototype.init=function(){},r.prototype.layout=function(){this.update()},r.prototype.render=function(){},r.prototype.update=function(){var t=this;this.onAfterRender(function(){var n=new Map;(0,xe.each)(t.option,function(a){if((0,xe.includes)(Xy,a.type)){var o=t.updateOrCreate(a);o&&n.set(t.getCacheKey(a),o)}}),t.cache=t.syncCache(n)});var i=new Map;(0,xe.each)(this.option,function(n){if(!(0,xe.includes)(Xy,n.type)){var a=t.updateOrCreate(n);a&&i.set(t.getCacheKey(n),a)}}),this.cache=this.syncCache(i)},r.prototype.clear=function(t){t===void 0&&(t=!1),e.prototype.clear.call(this),this.clearComponents(),this.foregroundContainer.clear(),this.backgroundContainer.clear(),t&&(this.option=[])},r.prototype.destroy=function(){this.clear(!0),this.foregroundContainer.remove(!0),this.backgroundContainer.remove(!0)},r.prototype.getComponents=function(){var t=[];return this.cache.forEach(function(i){t.push(i)}),t},r.prototype.clearComponents=function(){this.getComponents().forEach(function(t){t.component.destroy()}),this.cache.clear()},r.prototype.onAfterRender=function(t){this.view.getOptions().animate?this.view.geometries.forEach(function(i){i.animateOption&&i.once(Tl.GEOMETRY_LIFE_CIRCLE.AFTER_DRAW_ANIMATE,function(){t()})}):this.view.getRootView().once(Tl.VIEW_LIFE_CIRCLE.AFTER_RENDER,function(){t()})},r.prototype.createAnnotation=function(t){var i=t.type,n=det.Annotation[(0,xe.upperFirst)(i)];if(n){var a=this.getAnnotationTheme(i),o=this.getAnnotationCfg(i,t,a),l=new n(o);return{component:l,layer:this.isTop(o)?Tl.LAYER.FORE:Tl.LAYER.BG,direction:Tl.DIRECTION.NONE,type:Tl.COMPONENT_TYPE.ANNOTATION,extra:t}}},r.prototype.annotation=function(t){this.option.push(t)},r.prototype.arc=function(t){return this.annotation((0,Vt.__assign)({type:"arc"},t)),this},r.prototype.image=function(t){return this.annotation((0,Vt.__assign)({type:"image"},t)),this},r.prototype.line=function(t){return this.annotation((0,Vt.__assign)({type:"line"},t)),this},r.prototype.region=function(t){return this.annotation((0,Vt.__assign)({type:"region"},t)),this},r.prototype.text=function(t){return this.annotation((0,Vt.__assign)({type:"text"},t)),this},r.prototype.dataMarker=function(t){return this.annotation((0,Vt.__assign)({type:"dataMarker"},t)),this},r.prototype.dataRegion=function(t){this.annotation((0,Vt.__assign)({type:"dataRegion"},t))},r.prototype.regionFilter=function(t){this.annotation((0,Vt.__assign)({type:"regionFilter"},t))},r.prototype.shape=function(t){this.annotation((0,Vt.__assign)({type:"shape"},t))},r.prototype.html=function(t){this.annotation((0,Vt.__assign)({type:"html"},t))},r.prototype.parsePosition=function(t){var i=this.view.getXScale(),n=this.view.getScalesByDim("y"),a=(0,xe.isFunction)(t)?t.call(null,i,n):t,o=0,l=0;if((0,xe.isArray)(a)){var s=a[0],u=a[1];if((0,xe.isString)(s)&&s.indexOf("%")!==-1&&!isNaN(s.slice(0,-1)))return this.parsePercentPosition(a);o=(0,Wy.getNormalizedValue)(s,i),l=(0,Wy.getNormalizedValue)(u,Object.values(n)[0])}else if(!(0,xe.isNil)(a))for(var c=0,f=(0,xe.keys)(a);c<f.length;c++){var h=f[c],v=a[h];h===i.field&&(o=(0,Wy.getNormalizedValue)(v,i)),n[h]&&(l=(0,Wy.getNormalizedValue)(v,n[h]))}return this.view.getCoordinate().convert({x:o,y:l})},r.prototype.getRegionPoints=function(t,i){var n=this,a=this.view.getXScale(),o=this.view.getScalesByDim("y"),l=Object.values(o)[0],s=a.field,u=this.view.getData(),c=(0,xe.isArray)(t)?t[0]:t[s],f=(0,xe.isArray)(i)?i[0]:i[s],h=[],v;return(0,xe.each)(u,function(d,p){if(d[s]===c&&(v=p),p>=v){var x=n.parsePosition([d[s],d[l.field]]);x&&h.push(x)}if(d[s]===f)return!1}),h},r.prototype.parsePercentPosition=function(t){var i=parseFloat(t[0])/100,n=parseFloat(t[1])/100,a=this.view.getCoordinate(),o=a.start,l=a.end,s={x:Math.min(o.x,l.x),y:Math.min(o.y,l.y)},u=a.getWidth()*i+s.x,c=a.getHeight()*n+s.y;return{x:u,y:c}},r.prototype.getCoordinateBBox=function(){var t=this.view.getCoordinate(),i=t.start,n=t.end,a=t.getWidth(),o=t.getHeight(),l={x:Math.min(i.x,n.x),y:Math.min(i.y,n.y)};return{x:l.x,y:l.y,minX:l.x,minY:l.y,maxX:l.x+a,maxY:l.y+o,width:a,height:o}},r.prototype.getAnnotationCfg=function(t,i,n){var a=this,o=this.view.getCoordinate(),l=this.view.getCanvas(),s={};if((0,xe.isNil)(i))return null;if(t==="arc"){var u=i,c=u.start,f=u.end,h=(0,Vt.__rest)(u,["start","end"]),v=this.parsePosition(c),d=this.parsePosition(f),p=(0,aC.getAngleByPoint)(o,v),x=(0,aC.getAngleByPoint)(o,d);p>x&&(x=Math.PI*2+x),s=(0,Vt.__assign)((0,Vt.__assign)({},h),{center:o.getCenter(),radius:(0,aC.getDistanceToCenter)(o,v),startAngle:p,endAngle:x})}else if(t==="image"){var m=i,c=m.start,f=m.end,h=(0,Vt.__rest)(m,["start","end"]);s=(0,Vt.__assign)((0,Vt.__assign)({},h),{start:this.parsePosition(c),end:this.parsePosition(f),src:i.src})}else if(t==="line"){var _=i,c=_.start,f=_.end,h=(0,Vt.__rest)(_,["start","end"]);s=(0,Vt.__assign)((0,Vt.__assign)({},h),{start:this.parsePosition(c),end:this.parsePosition(f),text:(0,xe.get)(i,"text",null)})}else if(t==="region"){var b=i,c=b.start,f=b.end,h=(0,Vt.__rest)(b,["start","end"]);s=(0,Vt.__assign)((0,Vt.__assign)({},h),{start:this.parsePosition(c),end:this.parsePosition(f)})}else if(t==="text"){var w=this.view.getData(),S=i,M=S.position,F=S.content,h=(0,Vt.__rest)(S,["position","content"]),O=F;(0,xe.isFunction)(F)&&(O=F(w)),s=(0,Vt.__assign)((0,Vt.__assign)((0,Vt.__assign)({},this.parsePosition(M)),h),{content:O})}else if(t==="dataMarker"){var L=i,M=L.position,D=L.point,k=L.line,H=L.text,B=L.autoAdjust,j=L.direction,h=(0,Vt.__rest)(L,["position","point","line","text","autoAdjust","direction"]);s=(0,Vt.__assign)((0,Vt.__assign)((0,Vt.__assign)({},h),this.parsePosition(M)),{coordinateBBox:this.getCoordinateBBox(),point:D,line:k,text:H,autoAdjust:B,direction:j})}else if(t==="dataRegion"){var U=i,c=U.start,f=U.end,R=U.region,H=U.text,G=U.lineLength,h=(0,Vt.__rest)(U,["start","end","region","text","lineLength"]);s=(0,Vt.__assign)((0,Vt.__assign)({},h),{points:this.getRegionPoints(c,f),region:R,text:H,lineLength:G})}else if(t==="regionFilter"){var N=i,c=N.start,f=N.end,W=N.apply,q=N.color,h=(0,Vt.__rest)(N,["start","end","apply","color"]),tt=this.view.geometries,ot=[],st=function(Nt){!Nt||(Nt.isGroup()?Nt.getChildren().forEach(function(pe){return st(pe)}):ot.push(Nt))};(0,xe.each)(tt,function(Nt){W?(0,xe.contains)(W,Nt.type)&&(0,xe.each)(Nt.elements,function(pe){st(pe.shape)}):(0,xe.each)(Nt.elements,function(pe){st(pe.shape)})}),s=(0,Vt.__assign)((0,Vt.__assign)({},h),{color:q,shapes:ot,start:this.parsePosition(c),end:this.parsePosition(f)})}else if(t==="shape"){var Z=i,et=Z.render,lt=(0,Vt.__rest)(Z,["render"]),dt=function(_t){if((0,xe.isFunction)(i.render))return et(_t,a.view,{parsePosition:a.parsePosition.bind(a)})};s=(0,Vt.__assign)((0,Vt.__assign)({},lt),{render:dt})}else if(t==="html"){var ht=i,wt=ht.html,M=ht.position,lt=(0,Vt.__rest)(ht,["html","position"]),gt=function(qt){return(0,xe.isFunction)(wt)?wt(qt,a.view):wt};s=(0,Vt.__assign)((0,Vt.__assign)((0,Vt.__assign)({},lt),this.parsePosition(M)),{parent:l.get("el").parentNode,html:gt})}var vt=(0,xe.deepMix)({},n,(0,Vt.__assign)((0,Vt.__assign)({},s),{top:i.top,style:i.style,offsetX:i.offsetX,offsetY:i.offsetY}));return t!=="html"&&(vt.container=this.getComponentContainer(vt)),vt.animate=this.view.getOptions().animate&&vt.animate&&(0,xe.get)(i,"animate",vt.animate),vt.animateOption=(0,xe.deepMix)({},pet.DEFAULT_ANIMATE_CFG,vt.animateOption,i.animateOption),vt},r.prototype.isTop=function(t){return(0,xe.get)(t,"top",!0)},r.prototype.getComponentContainer=function(t){return this.isTop(t)?this.foregroundContainer:this.backgroundContainer},r.prototype.getAnnotationTheme=function(t){return(0,xe.get)(this.view.getTheme(),["components","annotation",t],{})},r.prototype.updateOrCreate=function(t){var i=this.cache.get(this.getCacheKey(t));if(i){var n=t.type,a=this.getAnnotationTheme(n),o=this.getAnnotationCfg(n,t,a);(0,get.omit)(o,["container"]),i.component.update(o),(0,xe.includes)(Xy,t.type)&&i.component.render()}else i=this.createAnnotation(t),i&&(i.component.init(),(0,xe.includes)(Xy,t.type)&&i.component.render());return i},r.prototype.syncCache=function(t){var i=this,n=new Map(this.cache);return t.forEach(function(a,o){n.set(o,a)}),n.forEach(function(a,o){(0,xe.find)(i.option,function(l){return o===i.getCacheKey(l)})||(a.component.destroy(),n.delete(o))}),n},r.prototype.getCacheKey=function(t){return t},r}(yet.Controller),xet=IM.default=met,NA=globalThis&&globalThis.__assign||function(){return NA=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},NA.apply(this,arguments)},Ps=Pt.createContext(null);Ps.displayName="ChartViewContext";var _et=Ps.Consumer;function bet(e){return function(r){return Pt.createElement(_et,null,function(t){return Pt.createElement(e,NA({chartView:t},r))})}}var Dp={},Mh={},Cn={},Pi={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.isSamePoint=e.mergeRegion=e.intersectRect=e.inBox=e.distance=e.getPixelRatio=void 0;function r(){return window?window.devicePixelRatio:1}e.getPixelRatio=r;function t(s,u,c,f){var h=s-c,v=u-f;return Math.sqrt(h*h+v*v)}e.distance=t;function i(s,u,c,f,h,v){return h>=s&&h<=s+c&&v>=u&&v<=u+f}e.inBox=i;function n(s,u){return!(u.minX>s.maxX||u.maxX<s.minX||u.minY>s.maxY||u.maxY<s.minY)}e.intersectRect=n;function a(s,u){return!s||!u?s||u:{minX:Math.min(s.minX,u.minX),minY:Math.min(s.minY,u.minY),maxX:Math.max(s.maxX,u.maxX),maxY:Math.max(s.maxY,u.maxY)}}e.mergeRegion=a;function o(s,u){return s[0]===u[0]&&s[1]===u[1]}e.isSamePoint=o;var l=Y;Object.defineProperty(e,"isNil",{enumerable:!0,get:function(){return l.isNil}}),Object.defineProperty(e,"isString",{enumerable:!0,get:function(){return l.isString}}),Object.defineProperty(e,"isFunction",{enumerable:!0,get:function(){return l.isFunction}}),Object.defineProperty(e,"isArray",{enumerable:!0,get:function(){return l.isArray}}),Object.defineProperty(e,"each",{enumerable:!0,get:function(){return l.each}}),Object.defineProperty(e,"toRadian",{enumerable:!0,get:function(){return l.toRadian}}),Object.defineProperty(e,"mod",{enumerable:!0,get:function(){return l.mod}}),Object.defineProperty(e,"isNumberEqual",{enumerable:!0,get:function(){return l.isNumberEqual}}),Object.defineProperty(e,"requestAnimationFrame",{enumerable:!0,get:function(){return l.requestAnimationFrame}}),Object.defineProperty(e,"clearAnimationFrame",{enumerable:!0,get:function(){return l.clearAnimationFrame}})})(Pi);var Ne={},hn={};Object.defineProperty(hn,"__esModule",{value:!0});hn.parseRadius=hn.parseStyle=hn.parsePattern=hn.parseRadialGradient=hn.parseLineGradient=void 0;var ZM=Pi,wet=/^l\s*\(\s*([\d.]+)\s*\)\s*(.*)/i,Cet=/^r\s*\(\s*([\d.]+)\s*,\s*([\d.]+)\s*,\s*([\d.]+)\s*\)\s*(.*)/i,Aet=/^p\s*\(\s*([axyn])\s*\)\s*(.*)/i,Q5=/[\d.]+:(#[^\s]+|[^\)]+\))/gi;function K5(e,r){var t=e.match(Q5);ZM.each(t,function(i){var n=i.split(":");r.addColorStop(n[0],n[1])})}function J5(e,r,t){var i=wet.exec(t),n=parseFloat(i[1])%360*(Math.PI/180),a=i[2],o=r.getBBox(),l,s;n>=0&&n<1/2*Math.PI?(l={x:o.minX,y:o.minY},s={x:o.maxX,y:o.maxY}):1/2*Math.PI<=n&&n<Math.PI?(l={x:o.maxX,y:o.minY},s={x:o.minX,y:o.maxY}):Math.PI<=n&&n<3/2*Math.PI?(l={x:o.maxX,y:o.maxY},s={x:o.minX,y:o.minY}):(l={x:o.minX,y:o.maxY},s={x:o.maxX,y:o.minY});var u=Math.tan(n),c=u*u,f=(s.x-l.x+u*(s.y-l.y))/(c+1)+l.x,h=u*(s.x-l.x+u*(s.y-l.y))/(c+1)+l.y,v=e.createLinearGradient(l.x,l.y,f,h);return K5(a,v),v}hn.parseLineGradient=J5;function t3(e,r,t){var i=Cet.exec(t),n=parseFloat(i[1]),a=parseFloat(i[2]),o=parseFloat(i[3]),l=i[4];if(o===0){var s=l.match(Q5);return s[s.length-1].split(":")[1]}var u=r.getBBox(),c=u.maxX-u.minX,f=u.maxY-u.minY,h=Math.sqrt(c*c+f*f)/2,v=e.createRadialGradient(u.minX+c*n,u.minY+f*a,0,u.minX+c/2,u.minY+f/2,o*h);return K5(l,v),v}hn.parseRadialGradient=t3;function e3(e,r,t){if(r.get("patternSource")&&r.get("patternSource")===t)return r.get("pattern");var i,n,a=Aet.exec(t),o=a[1],l=a[2];function s(){i=e.createPattern(n,o),r.set("pattern",i),r.set("patternSource",t)}switch(o){case"a":o="repeat";break;case"x":o="repeat-x";break;case"y":o="repeat-y";break;case"n":o="no-repeat";break;default:o="no-repeat"}return n=new Image,l.match(/^data:/i)||(n.crossOrigin="Anonymous"),n.src=l,n.complete?s():(n.onload=s,n.src=n.src),i}hn.parsePattern=e3;function Tet(e,r,t){var i=r.getBBox();if(isNaN(i.x)||isNaN(i.y)||isNaN(i.width)||isNaN(i.height))return t;if(ZM.isString(t)){if(t[1]==="("||t[2]==="("){if(t[0]==="l")return J5(e,r,t);if(t[0]==="r")return t3(e,r,t);if(t[0]==="p")return e3(e,r,t)}return t}if(t instanceof CanvasPattern)return t}hn.parseStyle=Tet;function Met(e){var r=0,t=0,i=0,n=0;return ZM.isArray(e)?e.length===1?r=t=i=n=e[0]:e.length===2?(r=i=e[0],t=n=e[1]):e.length===3?(r=e[0],t=n=e[1],i=e[2]):(r=e[0],t=e[1],i=e[2],n=e[3]):r=t=i=n=e,[r,t,i,n]}hn.parseRadius=Met;var S1={};Object.defineProperty(S1,"__esModule",{value:!0});var Uy=Pi;function qy(e){return Math.sqrt(e[0]*e[0]+e[1]*e[1])}function GA(e,r){return qy(e)*qy(r)?(e[0]*r[0]+e[1]*r[1])/(qy(e)*qy(r)):1}function nD(e,r){return(e[0]*r[1]<e[1]*r[0]?-1:1)*Math.acos(GA(e,r))}function Eet(e,r){var t=r[1],i=r[2],n=Uy.mod(Uy.toRadian(r[3]),Math.PI*2),a=r[4],o=r[5],l=e[0],s=e[1],u=r[6],c=r[7],f=Math.cos(n)*(l-u)/2+Math.sin(n)*(s-c)/2,h=-1*Math.sin(n)*(l-u)/2+Math.cos(n)*(s-c)/2,v=f*f/(t*t)+h*h/(i*i);v>1&&(t*=Math.sqrt(v),i*=Math.sqrt(v));var d=t*t*(h*h)+i*i*(f*f),p=d?Math.sqrt((t*t*(i*i)-d)/d):1;a===o&&(p*=-1),isNaN(p)&&(p=0);var x=i?p*t*h/i:0,m=t?p*-i*f/t:0,_=(l+u)/2+Math.cos(n)*x-Math.sin(n)*m,b=(s+c)/2+Math.sin(n)*x+Math.cos(n)*m,w=[(f-x)/t,(h-m)/i],S=[(-1*f-x)/t,(-1*h-m)/i],M=nD([1,0],w),F=nD(w,S);return GA(w,S)<=-1&&(F=Math.PI),GA(w,S)>=1&&(F=0),o===0&&F>0&&(F=F-2*Math.PI),o===1&&F<0&&(F=F+2*Math.PI),{cx:_,cy:b,rx:Uy.isSamePoint(e,[u,c])?0:t,ry:Uy.isSamePoint(e,[u,c])?0:i,startAngle:M,endAngle:M+F,xRotation:n,arcFlag:a,sweepFlag:o}}S1.default=Eet;var Ca={};Object.defineProperty(Ca,"__esModule",{value:!0});Ca.addEndArrow=Ca.addStartArrow=Ca.getShortenOffset=void 0;var oC=V,r3=Mh,tx=Math.sin,ex=Math.cos,QM=Math.atan2,Zy=Math.PI;function i3(e,r,t,i,n,a,o){var l=r.stroke,s=r.lineWidth,u=t-n,c=i-a,f=QM(c,u),h=new r3.Path({type:"path",canvas:e.get("canvas"),isArrowShape:!0,attrs:{path:"M"+10*ex(Zy/6)+","+10*tx(Zy/6)+" L0,0 L"+10*ex(Zy/6)+",-"+10*tx(Zy/6),stroke:l,lineWidth:s}});h.translate(n,a),h.rotateAtPoint(n,a,f),e.set(o?"startArrowShape":"endArrowShape",h)}function n3(e,r,t,i,n,a,o){var l=r.startArrow,s=r.endArrow,u=r.stroke,c=r.lineWidth,f=o?l:s,h=f.d,v=f.fill,d=f.stroke,p=f.lineWidth,x=oC.__rest(f,["d","fill","stroke","lineWidth"]),m=t-n,_=i-a,b=QM(_,m);h&&(n=n-ex(b)*h,a=a-tx(b)*h);var w=new r3.Path({type:"path",canvas:e.get("canvas"),isArrowShape:!0,attrs:oC.__assign(oC.__assign({},x),{stroke:d||u,lineWidth:p||c,fill:v})});w.translate(n,a),w.rotateAtPoint(n,a,b),e.set(o?"startArrowShape":"endArrowShape",w)}function Fet(e,r,t,i,n){var a=QM(i-r,t-e);return{dx:ex(a)*n,dy:tx(a)*n}}Ca.getShortenOffset=Fet;function Oet(e,r,t,i,n,a){typeof r.startArrow=="object"?n3(e,r,t,i,n,a,!0):r.startArrow?i3(e,r,t,i,n,a,!0):e.set("startArrowShape",null)}Ca.addStartArrow=Oet;function Pet(e,r,t,i,n,a){typeof r.endArrow=="object"?n3(e,r,t,i,n,a,!1):r.endArrow?i3(e,r,t,i,n,a,!1):e.set("startArrowShape",null)}Ca.addEndArrow=Pet;Object.defineProperty(Ne,"__esModule",{value:!0});Ne.mergeView=Ne.getMergedRegion=Ne.getRefreshRegion=Ne.refreshElement=Ne.drawPath=Ne.clearChanged=Ne.checkChildrenRefresh=Ne.checkRefresh=Ne.drawChildren=Ne.applyAttrsToContext=void 0;var _u=Y,Iet=hn,aD=S1,KM=Pi,lC=Ca,oD={fill:"fillStyle",stroke:"strokeStyle",opacity:"globalAlpha"};function Let(e,r){var t=r.attr();for(var i in t){var n=t[i],a=oD[i]?oD[i]:i;a==="matrix"&&n?e.transform(n[0],n[1],n[3],n[4],n[6],n[7]):a==="lineDash"&&e.setLineDash?_u.isArray(n)&&e.setLineDash(n):(a==="strokeStyle"||a==="fillStyle"?n=Iet.parseStyle(e,r,n):a==="globalAlpha"&&(n=n*e.globalAlpha),e[a]=n)}}Ne.applyAttrsToContext=Let;function Det(e,r,t){for(var i=0;i<r.length;i++){var n=r[i];n.cfg.visible?n.draw(e,t):n.skipDraw()}}Ne.drawChildren=Det;function $et(e,r,t){var i=e.get("refreshElements");_u.each(i,function(n){if(n!==e)for(var a=n.cfg.parent;a&&a!==e&&!a.cfg.refresh;)a.cfg.refresh=!0,a=a.cfg.parent}),i[0]===e?JM(r):rx(r,t)}Ne.checkRefresh=$et;function rx(e,r){for(var t=0;t<e.length;t++){var i=e[t];if(i.cfg.visible)if(i.cfg.hasChanged)i.cfg.refresh=!0,i.isGroup()&&JM(i.cfg.children);else if(i.cfg.refresh)i.isGroup()&&rx(i.cfg.children,r);else{var n=ket(i,r);i.cfg.refresh=n,n&&i.isGroup()&&rx(i.cfg.children,r)}}}Ne.checkChildrenRefresh=rx;function a3(e){for(var r=0;r<e.length;r++){var t=e[r];t.cfg.hasChanged=!1,t.isGroup()&&!t.destroyed&&a3(t.cfg.children)}}Ne.clearChanged=a3;function JM(e,r){for(var t=0;t<e.length;t++){var i=e[t];i.cfg.refresh=!0,i.isGroup()&&JM(i.get("children"))}}function ket(e,r){var t=e.cfg.cacheCanvasBBox,i=e.cfg.isInView&&t&&KM.intersectRect(t,r);return i}function Ret(e,r,t,i){var n=t.path,a=t.startArrow,o=t.endArrow;if(!!n){var l=[0,0],s=[0,0],u={dx:0,dy:0};r.beginPath();for(var c=0;c<n.length;c++){var f=n[c],h=f[0];if(c===0&&a&&a.d){var v=e.getStartTangent();u=lC.getShortenOffset(v[0][0],v[0][1],v[1][0],v[1][1],a.d)}else if(c===n.length-2&&n[c+1][0]==="Z"&&o&&o.d){var d=n[c+1];if(d[0]==="Z"){var v=e.getEndTangent();u=lC.getShortenOffset(v[0][0],v[0][1],v[1][0],v[1][1],o.d)}}else if(c===n.length-1&&o&&o.d&&n[0]!=="Z"){var v=e.getEndTangent();u=lC.getShortenOffset(v[0][0],v[0][1],v[1][0],v[1][1],o.d)}var p=u.dx,x=u.dy;switch(h){case"M":r.moveTo(f[1]-p,f[2]-x),s=[f[1],f[2]];break;case"L":r.lineTo(f[1]-p,f[2]-x);break;case"Q":r.quadraticCurveTo(f[1],f[2],f[3]-p,f[4]-x);break;case"C":r.bezierCurveTo(f[1],f[2],f[3],f[4],f[5]-p,f[6]-x);break;case"A":{var m=void 0;i?(m=i[c],m||(m=aD.default(l,f),i[c]=m)):m=aD.default(l,f);var _=m.cx,b=m.cy,w=m.rx,S=m.ry,M=m.startAngle,F=m.endAngle,O=m.xRotation,L=m.sweepFlag;if(r.ellipse)r.ellipse(_,b,w,S,O,M,F,1-L);else{var D=w>S?w:S,k=w>S?1:w/S,H=w>S?S/w:1;r.translate(_,b),r.rotate(O),r.scale(k,H),r.arc(0,0,D,M,F,1-L),r.scale(1/k,1/H),r.rotate(-O),r.translate(-_,-b)}break}case"Z":r.closePath();break}if(h==="Z")l=s;else{var B=f.length;l=[f[B-2],f[B-1]]}}}}Ne.drawPath=Ret;function Bet(e,r){var t=e.get("canvas");t&&(r==="remove"&&(e._cacheCanvasBBox=e.get("cacheCanvasBBox")),e.get("hasChanged")||(e.set("hasChanged",!0),e.cfg.parent&&e.cfg.parent.get("hasChanged")||(t.refreshElement(e,r,t),t.get("autoDraw")&&t.draw())))}Ne.refreshElement=Bet;function o3(e){var r;if(e.destroyed)r=e._cacheCanvasBBox;else{var t=e.get("cacheCanvasBBox"),i=t&&!!(t.width&&t.height),n=e.getCanvasBBox(),a=n&&!!(n.width&&n.height);i&&a?r=KM.mergeRegion(t,n):i?r=t:a&&(r=n)}return r}Ne.getRefreshRegion=o3;function Net(e){if(!e.length)return null;var r=[],t=[],i=[],n=[];return _u.each(e,function(a){var o=o3(a);o&&(r.push(o.minX),t.push(o.minY),i.push(o.maxX),n.push(o.maxY))}),{minX:_u.min(r),minY:_u.min(t),maxX:_u.max(i),maxY:_u.max(n)}}Ne.getMergedRegion=Net;function Get(e,r){return!e||!r||!KM.intersectRect(e,r)?null:{minX:Math.max(e.minX,r.minX),minY:Math.max(e.minY,r.minY),maxX:Math.min(e.maxX,r.maxX),maxY:Math.min(e.maxY,r.maxY)}}Ne.mergeView=Get;var $p={};Object.defineProperty($p,"__esModule",{value:!0});var zet=V,Vet=ii,jet=Mh,Qy=Ne,dv=Y,Het=Pi,Yet=function(e){zet.__extends(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.onCanvasChange=function(t){Qy.refreshElement(this,t)},r.prototype.getShapeBase=function(){return jet},r.prototype.getGroupBase=function(){return r},r.prototype._applyClip=function(t,i){i&&(t.save(),Qy.applyAttrsToContext(t,i),i.createPath(t),t.restore(),t.clip(),i._afterDraw())},r.prototype.cacheCanvasBBox=function(){var t=this.cfg.children,i=[],n=[];dv.each(t,function(h){var v=h.cfg.cacheCanvasBBox;v&&h.cfg.isInView&&(i.push(v.minX,v.maxX),n.push(v.minY,v.maxY))});var a=null;if(i.length){var o=dv.min(i),l=dv.max(i),s=dv.min(n),u=dv.max(n);a={minX:o,minY:s,x:o,y:s,maxX:l,maxY:u,width:l-o,height:u-s};var c=this.cfg.canvas;if(c){var f=c.getViewRange();this.set("isInView",Het.intersectRect(a,f))}}else this.set("isInView",!1);this.set("cacheCanvasBBox",a)},r.prototype.draw=function(t,i){var n=this.cfg.children,a=i?this.cfg.refresh:!0;n.length&&a&&(t.save(),Qy.applyAttrsToContext(t,this),this._applyClip(t,this.getClip()),Qy.drawChildren(t,n,i),t.restore(),this.cacheCanvasBBox()),this.cfg.refresh=null,this.set("hasChanged",!1)},r.prototype.skipDraw=function(){this.set("cacheCanvasBBox",null),this.set("hasChanged",!1)},r}(Vet.AbstractGroup);$p.default=Yet;Object.defineProperty(Cn,"__esModule",{value:!0});var sC=V,Wet=ii,Ky=Pi,uC=Ne,Xet=ii,Uet=Mh,qet=$p,Zet=function(e){sC.__extends(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return sC.__assign(sC.__assign({},t),{lineWidth:1,lineAppendWidth:0,strokeOpacity:1,fillOpacity:1})},r.prototype.getShapeBase=function(){return Uet},r.prototype.getGroupBase=function(){return qet.default},r.prototype.onCanvasChange=function(t){uC.refreshElement(this,t)},r.prototype.calculateBBox=function(){var t=this.get("type"),i=this.getHitLineWidth(),n=Xet.getBBoxMethod(t),a=n(this),o=i/2,l=a.x-o,s=a.y-o,u=a.x+a.width+o,c=a.y+a.height+o;return{x:l,minX:l,y:s,minY:s,width:a.width+i,height:a.height+i,maxX:u,maxY:c}},r.prototype.isFill=function(){return!!this.attrs.fill||this.isClipShape()},r.prototype.isStroke=function(){return!!this.attrs.stroke},r.prototype._applyClip=function(t,i){i&&(t.save(),uC.applyAttrsToContext(t,i),i.createPath(t),t.restore(),t.clip(),i._afterDraw())},r.prototype.draw=function(t,i){var n=this.cfg.clipShape;if(i){if(this.cfg.refresh===!1){this.set("hasChanged",!1);return}var a=this.getCanvasBBox();if(!Ky.intersectRect(i,a)){this.set("hasChanged",!1),this.cfg.isInView&&this._afterDraw();return}}t.save(),uC.applyAttrsToContext(t,this),this._applyClip(t,n),this.drawPath(t),t.restore(),this._afterDraw()},r.prototype.getCanvasViewBox=function(){var t=this.cfg.canvas;return t?t.getViewRange():null},r.prototype.cacheCanvasBBox=function(){var t=this.getCanvasViewBox();if(t){var i=this.getCanvasBBox(),n=Ky.intersectRect(i,t);this.set("isInView",n),n?this.set("cacheCanvasBBox",i):this.set("cacheCanvasBBox",null)}},r.prototype._afterDraw=function(){this.cacheCanvasBBox(),this.set("hasChanged",!1),this.set("refresh",null)},r.prototype.skipDraw=function(){this.set("cacheCanvasBBox",null),this.set("isInView",null),this.set("hasChanged",!1)},r.prototype.drawPath=function(t){this.createPath(t),this.strokeAndFill(t),this.afterDrawPath(t)},r.prototype.fill=function(t){t.fill()},r.prototype.stroke=function(t){t.stroke()},r.prototype.strokeAndFill=function(t){var i=this.attrs,n=i.lineWidth,a=i.opacity,o=i.strokeOpacity,l=i.fillOpacity;this.isFill()&&(!Ky.isNil(l)&&l!==1?(t.globalAlpha=l,this.fill(t),t.globalAlpha=a):this.fill(t)),this.isStroke()&&n>0&&(!Ky.isNil(o)&&o!==1&&(t.globalAlpha=o),this.stroke(t)),this.afterDrawPath(t)},r.prototype.createPath=function(t){},r.prototype.afterDrawPath=function(t){},r.prototype.isInShape=function(t,i){var n=this.isStroke(),a=this.isFill(),o=this.getHitLineWidth();return this.isInStrokeOrPath(t,i,n,a,o)},r.prototype.isInStrokeOrPath=function(t,i,n,a,o){return!1},r.prototype.getHitLineWidth=function(){if(!this.isStroke())return 0;var t=this.attrs;return t.lineWidth+t.lineAppendWidth},r}(Wet.AbstractShape);Cn.default=Zet;var tE={};Object.defineProperty(tE,"__esModule",{value:!0});var cC=V,Qet=Cn,Ket=Pi,Jet=function(e){cC.__extends(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return cC.__assign(cC.__assign({},t),{x:0,y:0,r:0})},r.prototype.isInStrokeOrPath=function(t,i,n,a,o){var l=this.attr(),s=l.x,u=l.y,c=l.r,f=o/2,h=Ket.distance(s,u,t,i);return a&&n?h<=c+f:a?h<=c:n?h>=c-f&&h<=c+f:!1},r.prototype.createPath=function(t){var i=this.attr(),n=i.x,a=i.y,o=i.r;t.beginPath(),t.arc(n,a,o,0,Math.PI*2,!1),t.closePath()},r}(Qet.default);tE.default=Jet;var eE={};Object.defineProperty(eE,"__esModule",{value:!0});var fC=V,trt=Cn;function Jy(e,r,t,i){return e/(t*t)+r/(i*i)}var ert=function(e){fC.__extends(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return fC.__assign(fC.__assign({},t),{x:0,y:0,rx:0,ry:0})},r.prototype.isInStrokeOrPath=function(t,i,n,a,o){var l=this.attr(),s=o/2,u=l.x,c=l.y,f=l.rx,h=l.ry,v=(t-u)*(t-u),d=(i-c)*(i-c);return a&&n?Jy(v,d,f+s,h+s)<=1:a?Jy(v,d,f,h)<=1:n?Jy(v,d,f-s,h-s)>=1&&Jy(v,d,f+s,h+s)<=1:!1},r.prototype.createPath=function(t){var i=this.attr(),n=i.x,a=i.y,o=i.rx,l=i.ry;if(t.beginPath(),t.ellipse)t.ellipse(n,a,o,l,0,0,Math.PI*2,!1);else{var s=o>l?o:l,u=o>l?1:o/l,c=o>l?l/o:1;t.save(),t.translate(n,a),t.scale(u,c),t.arc(0,0,s,0,Math.PI*2),t.restore(),t.closePath()}},r}(trt.default);eE.default=ert;var rE={};Object.defineProperty(rE,"__esModule",{value:!0});var hC=V,rrt=Cn,Kc=Pi;function lD(e){return e instanceof HTMLElement&&Kc.isString(e.nodeName)&&e.nodeName.toUpperCase()==="CANVAS"}var irt=function(e){hC.__extends(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return hC.__assign(hC.__assign({},t),{x:0,y:0,width:0,height:0})},r.prototype.initAttrs=function(t){this._setImage(t.img)},r.prototype.isStroke=function(){return!1},r.prototype.isOnlyHitBox=function(){return!0},r.prototype._afterLoading=function(){if(this.get("toDraw")===!0){var t=this.get("canvas");t?t.draw():this.createPath(this.get("context"))}},r.prototype._setImage=function(t){var i=this,n=this.attrs;if(Kc.isString(t)){var a=new Image;a.onload=function(){if(i.destroyed)return!1;i.attr("img",a),i.set("loading",!1),i._afterLoading();var o=i.get("callback");o&&o.call(i)},a.crossOrigin="Anonymous",a.src=t,this.set("loading",!0)}else t instanceof Image?(n.width||(n.width=t.width),n.height||(n.height=t.height)):lD(t)&&(n.width||(n.width=Number(t.getAttribute("width"))),n.height||(n.height,Number(t.getAttribute("height"))))},r.prototype.onAttrChange=function(t,i,n){e.prototype.onAttrChange.call(this,t,i,n),t==="img"&&this._setImage(i)},r.prototype.createPath=function(t){if(this.get("loading")){this.set("toDraw",!0),this.set("context",t);return}var i=this.attr(),n=i.x,a=i.y,o=i.width,l=i.height,s=i.sx,u=i.sy,c=i.swidth,f=i.sheight,h=i.img;(h instanceof Image||lD(h))&&(!Kc.isNil(s)&&!Kc.isNil(u)&&!Kc.isNil(c)&&!Kc.isNil(f)?t.drawImage(h,s,u,c,f,n,a,o,l):t.drawImage(h,n,a,o,l))},r}(rrt.default);rE.default=irt;var iE={},xo=br(QZ),Eh={};Object.defineProperty(Eh,"__esModule",{value:!0});var nrt=xo;function art(e,r,t,i,n,a,o){var l=Math.min(e,t),s=Math.max(e,t),u=Math.min(r,i),c=Math.max(r,i),f=n/2;return a>=l-f&&a<=s+f&&o>=u-f&&o<=c+f?nrt.Line.pointToLine(e,r,t,i,a,o)<=n/2:!1}Eh.default=art;Object.defineProperty(iE,"__esModule",{value:!0});var vC=V,sD=xo,ort=Cn,lrt=Eh,tm=Ca,srt=function(e){vC.__extends(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return vC.__assign(vC.__assign({},t),{x1:0,y1:0,x2:0,y2:0,startArrow:!1,endArrow:!1})},r.prototype.initAttrs=function(t){this.setArrow()},r.prototype.onAttrChange=function(t,i,n){e.prototype.onAttrChange.call(this,t,i,n),this.setArrow()},r.prototype.setArrow=function(){var t=this.attr(),i=t.x1,n=t.y1,a=t.x2,o=t.y2,l=t.startArrow,s=t.endArrow;l&&tm.addStartArrow(this,t,a,o,i,n),s&&tm.addEndArrow(this,t,i,n,a,o)},r.prototype.isInStrokeOrPath=function(t,i,n,a,o){if(!n||!o)return!1;var l=this.attr(),s=l.x1,u=l.y1,c=l.x2,f=l.y2;return lrt.default(s,u,c,f,o,t,i)},r.prototype.createPath=function(t){var i=this.attr(),n=i.x1,a=i.y1,o=i.x2,l=i.y2,s=i.startArrow,u=i.endArrow,c={dx:0,dy:0},f={dx:0,dy:0};s&&s.d&&(c=tm.getShortenOffset(n,a,o,l,i.startArrow.d)),u&&u.d&&(f=tm.getShortenOffset(n,a,o,l,i.endArrow.d)),t.beginPath(),t.moveTo(n+c.dx,a+c.dy),t.lineTo(o-f.dx,l-f.dy)},r.prototype.afterDrawPath=function(t){var i=this.get("startArrowShape"),n=this.get("endArrowShape");i&&i.draw(t),n&&n.draw(t)},r.prototype.getTotalLength=function(){var t=this.attr(),i=t.x1,n=t.y1,a=t.x2,o=t.y2;return sD.Line.length(i,n,a,o)},r.prototype.getPoint=function(t){var i=this.attr(),n=i.x1,a=i.y1,o=i.x2,l=i.y2;return sD.Line.pointAt(n,a,o,l,t)},r}(ort.default);iE.default=srt;var nE={},A1=br(kQ);Object.defineProperty(nE,"__esModule",{value:!0});var urt=V,crt=Y,frt=A1,hrt=Cn,vrt=Pi,drt=Ne,prt={circle:function(e,r,t){return[["M",e-t,r],["A",t,t,0,1,0,e+t,r],["A",t,t,0,1,0,e-t,r]]},square:function(e,r,t){return[["M",e-t,r-t],["L",e+t,r-t],["L",e+t,r+t],["L",e-t,r+t],["Z"]]},diamond:function(e,r,t){return[["M",e-t,r],["L",e,r-t],["L",e+t,r],["L",e,r+t],["Z"]]},triangle:function(e,r,t){var i=t*Math.sin(.3333333333333333*Math.PI);return[["M",e-t,r+i],["L",e,r-i],["L",e+t,r+i],["Z"]]},"triangle-down":function(e,r,t){var i=t*Math.sin(.3333333333333333*Math.PI);return[["M",e-t,r-i],["L",e+t,r-i],["L",e,r+i],["Z"]]}},grt=function(e){urt.__extends(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.initAttrs=function(t){this._resetParamsCache()},r.prototype._resetParamsCache=function(){this.set("paramsCache",{})},r.prototype.onAttrChange=function(t,i,n){e.prototype.onAttrChange.call(this,t,i,n),["symbol","x","y","r","radius"].indexOf(t)!==-1&&this._resetParamsCache()},r.prototype.isOnlyHitBox=function(){return!0},r.prototype._getR=function(t){return crt.isNil(t.r)?t.radius:t.r},r.prototype._getPath=function(){var t=this.attr(),i=t.x,n=t.y,a=t.symbol||"circle",o=this._getR(t),l,s;if(vrt.isFunction(a))l=a,s=l(i,n,o),s=frt.path2Absolute(s);else{if(l=r.Symbols[a],!l)return console.warn(a+" marker is not supported."),null;s=l(i,n,o)}return s},r.prototype.createPath=function(t){var i=this._getPath(),n=this.get("paramsCache");drt.drawPath(this,t,{path:i},n)},r.Symbols=prt,r}(hrt.default);nE.default=grt;var aE={},T1={};Object.defineProperty(T1,"__esModule",{value:!0});var yrt=ii;function mrt(e,r,t){var i=yrt.getOffScreenContext();return e.createPath(i),i.isPointInPath(r,t)}T1.default=mrt;var M1={};Object.defineProperty(M1,"__esModule",{value:!0});var xrt=1e-6;function dC(e){return Math.abs(e)<xrt?0:e<0?-1:1}function _rt(e,r,t){return(t[0]-e[0])*(r[1]-e[1])===(r[0]-e[0])*(t[1]-e[1])&&Math.min(e[0],r[0])<=t[0]&&t[0]<=Math.max(e[0],r[0])&&Math.min(e[1],r[1])<=t[1]&&t[1]<=Math.max(e[1],r[1])}function brt(e,r,t){var i=!1,n=e.length;if(n<=2)return!1;for(var a=0;a<n;a++){var o=e[a],l=e[(a+1)%n];if(_rt(o,l,[r,t]))return!0;dC(o[1]-t)>0!=dC(l[1]-t)>0&&dC(r-(t-o[1])*(o[0]-l[0])/(o[1]-l[1])-o[0])<0&&(i=!i)}return i}M1.default=brt;var oE={},ta=br(_q),wrt=br(Hz),E1={};Object.defineProperty(E1,"__esModule",{value:!0});var Crt=Pi;function Srt(e,r,t,i,n,a,o,l){var s=(Math.atan2(l-r,o-e)+Math.PI*2)%(Math.PI*2);if(s<i||s>n)return!1;var u={x:e+t*Math.cos(s),y:r+t*Math.sin(s)};return Crt.distance(u.x,u.y,o,l)<=a/2}E1.default=Srt;Object.defineProperty(oE,"__esModule",{value:!0});var Art=V,Trt=ii,Mrt=xo,Ert=xo,Frt=ta,Ort=wrt,Prt=Pi,Irt=Eh,Lrt=E1,Drt=Frt.ext.transform;function $rt(e){for(var r=!1,t=e.length,i=0;i<t;i++){var n=e[i],a=n[0];if(a==="C"||a==="A"||a==="Q"){r=!0;break}}return r}function krt(e,r,t,i,n){for(var a=!1,o=r/2,l=0;l<e.length;l++){var s=e[l],u=s.currentPoint,c=s.params,f=s.prePoint,h=s.box;if(!(h&&!Prt.inBox(h.x-o,h.y-o,h.width+r,h.height+r,t,i))){switch(s.command){case"L":case"Z":a=Irt.default(f[0],f[1],u[0],u[1],r,t,i);break;case"Q":var v=Mrt.Quad.pointDistance(f[0],f[1],c[1],c[2],c[3],c[4],t,i);a=v<=r/2;break;case"C":var d=Ert.Cubic.pointDistance(f[0],f[1],c[1],c[2],c[3],c[4],c[5],c[6],t,i,n);a=d<=r/2;break;case"A":var p=s.arcParams,x=p.cx,m=p.cy,_=p.rx,b=p.ry,w=p.startAngle,S=p.endAngle,M=p.xRotation,F=[t,i,1],O=_>b?_:b,L=_>b?1:_/b,D=_>b?b/_:1,k=Drt(null,[["t",-x,-m],["r",-M],["s",1/L,1/D]]);Ort.transformMat3(F,F,k),a=Lrt.default(0,0,O,w,S,r,F[0],F[1]);break}if(a)break}}return a}function Rrt(e){for(var r=e.length,t=[],i=[],n=[],a=0;a<r;a++){var o=e[a],l=o[0];l==="M"?(n.length&&(i.push(n),n=[]),n.push([o[1],o[2]])):l==="Z"?n.length&&(t.push(n),n=[]):n.push([o[1],o[2]])}return n.length>0&&i.push(n),{polygons:t,polylines:i}}oE.default=Art.__assign({hasArc:$rt,extractPolygons:Rrt,isPointInStroke:krt},Trt.PathUtil);Object.defineProperty(aE,"__esModule",{value:!0});var pC=V,gC=xo,Ic=Y,Brt=Cn,uD=A1,Nrt=Ne,Grt=T1,zrt=M1,em=oE,cD=Ca;function fD(e,r,t){for(var i=!1,n=0;n<e.length;n++){var a=e[n];if(i=zrt.default(a,r,t),i)break}return i}var Vrt=function(e){pC.__extends(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return pC.__assign(pC.__assign({},t),{startArrow:!1,endArrow:!1})},r.prototype.initAttrs=function(t){this._setPathArr(t.path),this.setArrow()},r.prototype.onAttrChange=function(t,i,n){e.prototype.onAttrChange.call(this,t,i,n),t==="path"&&this._setPathArr(i),this.setArrow()},r.prototype._setPathArr=function(t){this.attrs.path=uD.path2Absolute(t);var i=em.default.hasArc(t);this.set("hasArc",i),this.set("paramsCache",{}),this.set("segments",null),this.set("curve",null),this.set("tCache",null),this.set("totalLength",null)},r.prototype.getSegments=function(){var t=this.get("segements");return t||(t=uD.path2Segments(this.attr("path")),this.set("segments",t)),t},r.prototype.setArrow=function(){var t=this.attr(),i=t.startArrow,n=t.endArrow;if(i){var a=this.getStartTangent();cD.addStartArrow(this,t,a[0][0],a[0][1],a[1][0],a[1][1])}if(n){var a=this.getEndTangent();cD.addEndArrow(this,t,a[0][0],a[0][1],a[1][0],a[1][1])}},r.prototype.isInStrokeOrPath=function(t,i,n,a,o){var l=this.getSegments(),s=this.get("hasArc"),u=!1;if(n){var c=this.getTotalLength();u=em.default.isPointInStroke(l,o,t,i,c)}if(!u&&a)if(s)u=Grt.default(this,t,i);else{var f=this.attr("path"),h=em.default.extractPolygons(f);u=fD(h.polygons,t,i)||fD(h.polylines,t,i)}return u},r.prototype.createPath=function(t){var i=this.attr(),n=this.get("paramsCache");Nrt.drawPath(this,t,i,n)},r.prototype.afterDrawPath=function(t){var i=this.get("startArrowShape"),n=this.get("endArrowShape");i&&i.draw(t),n&&n.draw(t)},r.prototype.getTotalLength=function(){var t=this.get("totalLength");return Ic.isNil(t)?(this._calculateCurve(),this._setTcache(),this.get("totalLength")):t},r.prototype.getPoint=function(t){var i=this.get("tCache");i||(this._calculateCurve(),this._setTcache(),i=this.get("tCache"));var n,a,o=this.get("curve");if(!i||i.length===0)return o?{x:o[0][1],y:o[0][2]}:null;Ic.each(i,function(c,f){t>=c[0]&&t<=c[1]&&(n=(t-c[0])/(c[1]-c[0]),a=f)});var l=o[a];if(Ic.isNil(l)||Ic.isNil(a))return null;var s=l.length,u=o[a+1];return gC.Cubic.pointAt(l[s-2],l[s-1],u[1],u[2],u[3],u[4],u[5],u[6],n)},r.prototype._calculateCurve=function(){var t=this.attr().path;this.set("curve",em.default.pathToCurve(t))},r.prototype._setTcache=function(){var t=0,i=0,n=[],a,o,l,s,u=this.get("curve");if(!!u){if(Ic.each(u,function(c,f){l=u[f+1],s=c.length,l&&(t+=gC.Cubic.length(c[s-2],c[s-1],l[1],l[2],l[3],l[4],l[5],l[6])||0)}),this.set("totalLength",t),t===0){this.set("tCache",[]);return}Ic.each(u,function(c,f){l=u[f+1],s=c.length,l&&(a=[],a[0]=i/t,o=gC.Cubic.length(c[s-2],c[s-1],l[1],l[2],l[3],l[4],l[5],l[6]),i+=o||0,a[1]=i/t,n.push(a))}),this.set("tCache",n)}},r.prototype.getStartTangent=function(){var t=this.getSegments(),i;if(t.length>1){var n=t[0].currentPoint,a=t[1].currentPoint,o=t[1].startTangent;i=[],o?(i.push([n[0]-o[0],n[1]-o[1]]),i.push([n[0],n[1]])):(i.push([a[0],a[1]]),i.push([n[0],n[1]]))}return i},r.prototype.getEndTangent=function(){var t=this.getSegments(),i=t.length,n;if(i>1){var a=t[i-2].currentPoint,o=t[i-1].currentPoint,l=t[i-1].endTangent;n=[],l?(n.push([o[0]-l[0],o[1]-l[1]]),n.push([o[0],o[1]])):(n.push([a[0],a[1]]),n.push([o[0],o[1]]))}return n},r}(Brt.default);aE.default=Vrt;var lE={},F1={};Object.defineProperty(F1,"__esModule",{value:!0});var hD=Eh;function jrt(e,r,t,i,n){var a=e.length;if(a<2)return!1;for(var o=0;o<a-1;o++){var l=e[o][0],s=e[o][1],u=e[o+1][0],c=e[o+1][1];if(hD.default(l,s,u,c,r,t,i))return!0}if(n){var f=e[0],h=e[a-1];if(hD.default(f[0],f[1],h[0],h[1],r,t,i))return!0}return!1}F1.default=jrt;Object.defineProperty(lE,"__esModule",{value:!0});var Hrt=V,Yrt=Cn,Wrt=F1,Xrt=M1,Urt=function(e){Hrt.__extends(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.isInStrokeOrPath=function(t,i,n,a,o){var l=this.attr().points,s=!1;return n&&(s=Wrt.default(l,o,t,i,!0)),!s&&a&&(s=Xrt.default(l,t,i)),s},r.prototype.createPath=function(t){var i=this.attr(),n=i.points;if(!(n.length<2)){t.beginPath();for(var a=0;a<n.length;a++){var o=n[a];a===0?t.moveTo(o[0],o[1]):t.lineTo(o[0],o[1])}t.closePath()}},r}(Yrt.default);lE.default=Urt;var sE={};Object.defineProperty(sE,"__esModule",{value:!0});var yC=V,vD=xo,qrt=xo,mC=Y,Zrt=Cn,Qrt=F1,rm=Ca,Krt=function(e){yC.__extends(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return yC.__assign(yC.__assign({},t),{startArrow:!1,endArrow:!1})},r.prototype.initAttrs=function(t){this.setArrow()},r.prototype.onAttrChange=function(t,i,n){e.prototype.onAttrChange.call(this,t,i,n),this.setArrow(),["points"].indexOf(t)!==-1&&this._resetCache()},r.prototype._resetCache=function(){this.set("totalLength",null),this.set("tCache",null)},r.prototype.setArrow=function(){var t=this.attr(),i=this.attrs,n=i.points,a=i.startArrow,o=i.endArrow,l=n.length,s=n[0][0],u=n[0][1],c=n[l-1][0],f=n[l-1][1];a&&rm.addStartArrow(this,t,n[1][0],n[1][1],s,u),o&&rm.addEndArrow(this,t,n[l-2][0],n[l-2][1],c,f)},r.prototype.isFill=function(){return!1},r.prototype.isInStrokeOrPath=function(t,i,n,a,o){if(!n||!o)return!1;var l=this.attr().points;return Qrt.default(l,o,t,i,!1)},r.prototype.isStroke=function(){return!0},r.prototype.createPath=function(t){var i=this.attr(),n=i.points,a=i.startArrow,o=i.endArrow,l=n.length;if(!(n.length<2)){var s=n[0][0],u=n[0][1],c=n[l-1][0],f=n[l-1][1];if(a&&a.d){var h=rm.getShortenOffset(s,u,n[1][0],n[1][1],a.d);s+=h.dx,u+=h.dy}if(o&&o.d){var h=rm.getShortenOffset(n[l-2][0],n[l-2][1],c,f,o.d);c-=h.dx,f-=h.dy}t.beginPath(),t.moveTo(s,u);for(var v=0;v<l-1;v++){var d=n[v];t.lineTo(d[0],d[1])}t.lineTo(c,f)}},r.prototype.afterDrawPath=function(t){var i=this.get("startArrowShape"),n=this.get("endArrowShape");i&&i.draw(t),n&&n.draw(t)},r.prototype.getTotalLength=function(){var t=this.attr().points,i=this.get("totalLength");return mC.isNil(i)?(this.set("totalLength",qrt.Polyline.length(t)),this.get("totalLength")):i},r.prototype.getPoint=function(t){var i=this.attr().points,n=this.get("tCache");n||(this._setTcache(),n=this.get("tCache"));var a,o;return mC.each(n,function(l,s){t>=l[0]&&t<=l[1]&&(a=(t-l[0])/(l[1]-l[0]),o=s)}),vD.Line.pointAt(i[o][0],i[o][1],i[o+1][0],i[o+1][1],a)},r.prototype._setTcache=function(){var t=this.attr().points;if(!(!t||t.length===0)){var i=this.getTotalLength();if(!(i<=0)){var n=0,a=[],o,l;mC.each(t,function(s,u){t[u+1]&&(o=[],o[0]=n/i,l=vD.Line.length(s[0],s[1],t[u+1][0],t[u+1][1]),n+=l,o[1]=n/i,a.push(o))}),this.set("tCache",a)}}},r.prototype.getStartTangent=function(){var t=this.attr().points,i=[];return i.push([t[1][0],t[1][1]]),i.push([t[0][0],t[0][1]]),i},r.prototype.getEndTangent=function(){var t=this.attr().points,i=t.length-1,n=[];return n.push([t[i-1][0],t[i-1][1]]),n.push([t[i][0],t[i][1]]),n},r}(Zrt.default);sE.default=Krt;var uE={},cE={};Object.defineProperty(cE,"__esModule",{value:!0});var im=Pi;function Jrt(e,r,t,i,n,a,o){var l=n/2;return im.inBox(e-l,r-l,t,n,a,o)||im.inBox(e+t-l,r-l,n,i,a,o)||im.inBox(e+l,r+i-l,t,n,a,o)||im.inBox(e-l,r+l,n,i,a,o)}cE.default=Jrt;var fE={};Object.defineProperty(fE,"__esModule",{value:!0});var nm=Eh,am=E1;function tit(e,r,t,i,n,a,o,l){return nm.default(e+n,r,e+t-n,r,a,o,l)||nm.default(e+t,r+n,e+t,r+i-n,a,o,l)||nm.default(e+t-n,r+i,e+n,r+i,a,o,l)||nm.default(e,r+i-n,e,r+n,a,o,l)||am.default(e+t-n,r+n,n,1.5*Math.PI,2*Math.PI,a,o,l)||am.default(e+t-n,r+i-n,n,0,.5*Math.PI,a,o,l)||am.default(e+n,r+i-n,n,.5*Math.PI,Math.PI,a,o,l)||am.default(e+n,r+n,n,Math.PI,1.5*Math.PI,a,o,l)}fE.default=tit;Object.defineProperty(uE,"__esModule",{value:!0});var xC=V,eit=Cn,rit=hn,dD=Pi,iit=cE,nit=fE,ait=T1,oit=function(e){xC.__extends(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return xC.__assign(xC.__assign({},t),{x:0,y:0,width:0,height:0,radius:0})},r.prototype.isInStrokeOrPath=function(t,i,n,a,o){var l=this.attr(),s=l.x,u=l.y,c=l.width,f=l.height,h=l.radius;if(h){var d=!1;return n&&(d=nit.default(s,u,c,f,h,o,t,i)),!d&&a&&(d=ait.default(this,t,i)),d}else{var v=o/2;if(a&&n)return dD.inBox(s-v,u-v,c+v,f+v,t,i);if(a)return dD.inBox(s,u,c,f,t,i);if(n)return iit.default(s,u,c,f,o,t,i)}},r.prototype.createPath=function(t){var i=this.attr(),n=i.x,a=i.y,o=i.width,l=i.height,s=i.radius;if(t.beginPath(),s===0)t.rect(n,a,o,l);else{var u=rit.parseRadius(s),c=u[0],f=u[1],h=u[2],v=u[3];t.moveTo(n+c,a),t.lineTo(n+o-f,a),f!==0&&t.arc(n+o-f,a+f,f,-Math.PI/2,0),t.lineTo(n+o,a+l-h),h!==0&&t.arc(n+o-h,a+l-h,h,0,Math.PI/2),t.lineTo(n+v,a+l),v!==0&&t.arc(n+v,a+l-v,v,Math.PI/2,Math.PI),t.lineTo(n,a+c),c!==0&&t.arc(n+c,a+c,c,Math.PI,Math.PI*1.5),t.closePath()}},r}(eit.default);uE.default=oit;var hE={};Object.defineProperty(hE,"__esModule",{value:!0});var _C=V,lit=Cn,Lc=Pi,pD=ii,sit=function(e){_C.__extends(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return _C.__assign(_C.__assign({},t),{x:0,y:0,text:null,fontSize:12,fontFamily:"sans-serif",fontStyle:"normal",fontWeight:"normal",fontVariant:"normal",textAlign:"start",textBaseline:"bottom"})},r.prototype.isOnlyHitBox=function(){return!0},r.prototype.initAttrs=function(t){this._assembleFont(),t.text&&this._setText(t.text)},r.prototype._assembleFont=function(){var t=this.attrs;t.font=pD.assembleFont(t)},r.prototype._setText=function(t){var i=null;Lc.isString(t)&&t.indexOf(`
|
|
`)!==-1&&(i=t.split(`
|
|
`)),this.set("textArr",i)},r.prototype.onAttrChange=function(t,i,n){e.prototype.onAttrChange.call(this,t,i,n),t.startsWith("font")&&this._assembleFont(),t==="text"&&this._setText(i)},r.prototype._getSpaceingY=function(){var t=this.attrs,i=t.lineHeight,n=t.fontSize*1;return i?i-n:n*.14},r.prototype._drawTextArr=function(t,i,n){var a=this.attrs,o=a.textBaseline,l=a.x,s=a.y,u=a.fontSize*1,c=this._getSpaceingY(),f=pD.getTextHeight(a.text,a.fontSize,a.lineHeight),h;Lc.each(i,function(v,d){h=s+d*(c+u)-f+u,o==="middle"&&(h+=f-u-(f-u)/2),o==="top"&&(h+=f-u),Lc.isNil(v)||(n?t.fillText(v,l,h):t.strokeText(v,l,h))})},r.prototype._drawText=function(t,i){var n=this.attr(),a=n.x,o=n.y,l=this.get("textArr");if(l)this._drawTextArr(t,l,i);else{var s=n.text;Lc.isNil(s)||(i?t.fillText(s,a,o):t.strokeText(s,a,o))}},r.prototype.strokeAndFill=function(t){var i=this.attrs,n=i.lineWidth,a=i.opacity,o=i.strokeOpacity,l=i.fillOpacity;this.isStroke()&&n>0&&(!Lc.isNil(o)&&o!==1&&(t.globalAlpha=a),this.stroke(t)),this.isFill()&&(!Lc.isNil(l)&&l!==1?(t.globalAlpha=l,this.fill(t),t.globalAlpha=a):this.fill(t)),this.afterDrawPath(t)},r.prototype.fill=function(t){this._drawText(t,!0)},r.prototype.stroke=function(t){this._drawText(t,!1)},r}(lit.default);hE.default=sit;(function(e){Object.defineProperty(e,"__esModule",{value:!0});var r=Cn;Object.defineProperty(e,"Base",{enumerable:!0,get:function(){return r.default}});var t=tE;Object.defineProperty(e,"Circle",{enumerable:!0,get:function(){return t.default}});var i=eE;Object.defineProperty(e,"Ellipse",{enumerable:!0,get:function(){return i.default}});var n=rE;Object.defineProperty(e,"Image",{enumerable:!0,get:function(){return n.default}});var a=iE;Object.defineProperty(e,"Line",{enumerable:!0,get:function(){return a.default}});var o=nE;Object.defineProperty(e,"Marker",{enumerable:!0,get:function(){return o.default}});var l=aE;Object.defineProperty(e,"Path",{enumerable:!0,get:function(){return l.default}});var s=lE;Object.defineProperty(e,"Polygon",{enumerable:!0,get:function(){return s.default}});var u=sE;Object.defineProperty(e,"Polyline",{enumerable:!0,get:function(){return u.default}});var c=uE;Object.defineProperty(e,"Rect",{enumerable:!0,get:function(){return c.default}});var f=hE;Object.defineProperty(e,"Text",{enumerable:!0,get:function(){return f.default}})})(Mh);var vE={},O1={};Object.defineProperty(O1,"__esModule",{value:!0});O1.getShape=void 0;var zA=ii;function uit(e,r){if(r){var t=zA.invert(r);return zA.multiplyVec2(t,e)}return e}function l3(e,r,t){var i=e.getTotalMatrix();if(i){var n=uit([r,t,1],i),a=n[0],o=n[1];return[a,o]}return[r,t]}function gD(e,r,t){if(e.isCanvas&&e.isCanvas())return!0;if(!zA.isAllowCapture(e)||e.cfg.isInView===!1)return!1;if(e.cfg.clipShape){var i=l3(e,r,t),n=i[0],a=i[1];if(e.isClipped(n,a))return!1}var o=e.cfg.cacheCanvasBBox||e.getCanvasBBox();return r>=o.minX&&r<=o.maxX&&t>=o.minY&&t<=o.maxY}function s3(e,r,t){if(!gD(e,r,t))return null;for(var i=null,n=e.getChildren(),a=n.length,o=a-1;o>=0;o--){var l=n[o];if(l.isGroup())i=s3(l,r,t);else if(gD(l,r,t)){var s=l,u=l3(l,r,t),c=u[0],f=u[1];s.isInShape(c,f)&&(i=l)}if(i)break}return i}O1.getShape=s3;Object.defineProperty(vE,"__esModule",{value:!0});var cit=V,fit=ii,hit=O1,vit=Mh,dit=$p,om=Pi,Ml=Ne,pit=function(e){cit.__extends(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return t.renderer="canvas",t.autoDraw=!0,t.localRefresh=!0,t.refreshElements=[],t.clipView=!0,t.quickHit=!1,t},r.prototype.onCanvasChange=function(t){(t==="attr"||t==="sort"||t==="changeSize")&&(this.set("refreshElements",[this]),this.draw())},r.prototype.getShapeBase=function(){return vit},r.prototype.getGroupBase=function(){return dit.default},r.prototype.getPixelRatio=function(){var t=this.get("pixelRatio")||om.getPixelRatio();return t>=1?Math.ceil(t):1},r.prototype.getViewRange=function(){return{minX:0,minY:0,maxX:this.cfg.width,maxY:this.cfg.height}},r.prototype.createDom=function(){var t=document.createElement("canvas"),i=t.getContext("2d");return this.set("context",i),t},r.prototype.setDOMSize=function(t,i){e.prototype.setDOMSize.call(this,t,i);var n=this.get("context"),a=this.get("el"),o=this.getPixelRatio();a.width=o*t,a.height=o*i,o>1&&n.scale(o,o)},r.prototype.clear=function(){e.prototype.clear.call(this),this._clearFrame();var t=this.get("context"),i=this.get("el");t.clearRect(0,0,i.width,i.height)},r.prototype.getShape=function(t,i){var n;return this.get("quickHit")?n=hit.getShape(this,t,i):n=e.prototype.getShape.call(this,t,i,null),n},r.prototype._getRefreshRegion=function(){var t=this.get("refreshElements"),i=this.getViewRange(),n;if(t.length&&t[0]===this)n=i;else if(n=Ml.getMergedRegion(t),n){n.minX=Math.floor(n.minX),n.minY=Math.floor(n.minY),n.maxX=Math.ceil(n.maxX),n.maxY=Math.ceil(n.maxY),n.maxY+=1;var a=this.get("clipView");a&&(n=Ml.mergeView(n,i))}return n},r.prototype.refreshElement=function(t){var i=this.get("refreshElements");i.push(t)},r.prototype._clearFrame=function(){var t=this.get("drawFrame");t&&(om.clearAnimationFrame(t),this.set("drawFrame",null),this.set("refreshElements",[]))},r.prototype.draw=function(){var t=this.get("drawFrame");this.get("autoDraw")&&t||this._startDraw()},r.prototype._drawAll=function(){var t=this.get("context"),i=this.get("el"),n=this.getChildren();t.clearRect(0,0,i.width,i.height),Ml.applyAttrsToContext(t,this),Ml.drawChildren(t,n),this.set("refreshElements",[])},r.prototype._drawRegion=function(){var t=this.get("context"),i=this.get("refreshElements"),n=this.getChildren(),a=this._getRefreshRegion();a?(t.clearRect(a.minX,a.minY,a.maxX-a.minX,a.maxY-a.minY),t.save(),t.beginPath(),t.rect(a.minX,a.minY,a.maxX-a.minX,a.maxY-a.minY),t.clip(),Ml.applyAttrsToContext(t,this),Ml.checkRefresh(this,n,a),Ml.drawChildren(t,n,a),t.restore()):i.length&&Ml.clearChanged(i),om.each(i,function(o){o.get("hasChanged")&&o.set("hasChanged",!1)}),this.set("refreshElements",[])},r.prototype._startDraw=function(){var t=this,i=this.get("drawFrame");i||(i=om.requestAnimationFrame(function(){t.get("localRefresh")?t._drawRegion():t._drawAll(),t.set("drawFrame",null)}),this.set("drawFrame",i))},r.prototype.skipDraw=function(){},r.prototype.removeDom=function(){var t=this.get("el");t.width=0,t.height=0,t.parentNode.removeChild(t)},r}(fit.AbstractCanvas);vE.default=pit;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.version=e.Shape=void 0;var r=V,t=Mh;e.Shape=t,r.__exportStar(ii,e);var i=vE;Object.defineProperty(e,"Canvas",{enumerable:!0,get:function(){return i.default}});var n=$p;Object.defineProperty(e,"Group",{enumerable:!0,get:function(){return n.default}});var a=S1;Object.defineProperty(e,"getArcParams",{enumerable:!0,get:function(){return a.default}}),e.version="0.5.12"})(Dp);var git=aM(Dp),yit=jG({__proto__:null,default:git},[Dp]),dE={},kp={},Zi={},Wn={},xr={},ur={};Object.defineProperty(ur,"__esModule",{value:!0});ur.EVENTS=ur.SVG_ATTR_MAP=ur.SHAPE_TO_TAGS=void 0;ur.SHAPE_TO_TAGS={rect:"path",circle:"circle",line:"line",path:"path",marker:"path",text:"text",polyline:"polyline",polygon:"polygon",image:"image",ellipse:"ellipse",dom:"foreignObject"};ur.SVG_ATTR_MAP={opacity:"opacity",fillStyle:"fill",fill:"fill",fillOpacity:"fill-opacity",strokeStyle:"stroke",strokeOpacity:"stroke-opacity",stroke:"stroke",x:"x",y:"y",r:"r",rx:"rx",ry:"ry",width:"width",height:"height",x1:"x1",x2:"x2",y1:"y1",y2:"y2",lineCap:"stroke-linecap",lineJoin:"stroke-linejoin",lineWidth:"stroke-width",lineDash:"stroke-dasharray",lineDashOffset:"stroke-dashoffset",miterLimit:"stroke-miterlimit",font:"font",fontSize:"font-size",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",fontFamily:"font-family",startArrow:"marker-start",endArrow:"marker-end",path:"d",class:"class",id:"id",style:"style",preserveAspectRatio:"preserveAspectRatio"};ur.EVENTS=["click","mousedown","mouseup","dblclick","contextmenu","mouseenter","mouseleave","mouseover","mouseout","mousemove","wheel"];Object.defineProperty(xr,"__esModule",{value:!0});xr.moveTo=xr.sortDom=xr.createDom=xr.createSVGElement=void 0;var mit=Y,xit=ur;function u3(e){return document.createElementNS("http://www.w3.org/2000/svg",e)}xr.createSVGElement=u3;function _it(e){var r=xit.SHAPE_TO_TAGS[e.type],t=e.getParent();if(!r)throw new Error("the type "+e.type+" is not supported by svg");var i=u3(r);if(e.get("id")&&(i.id=e.get("id")),e.set("el",i),e.set("attrs",{}),t){var n=t.get("el");n||(n=t.createDom(),t.set("el",n)),n.appendChild(i)}return i}xr.createDom=_it;function bit(e,r){var t=e.get("el"),i=mit.toArray(t.children).sort(r),n=document.createDocumentFragment();i.forEach(function(a){n.appendChild(a)}),t.appendChild(n)}xr.sortDom=bit;function wit(e,r){var t=e.parentNode,i=Array.from(t.childNodes).filter(function(l){return l.nodeType===1&&l.nodeName.toLowerCase()!=="defs"}),n=i[r],a=i.indexOf(e);if(n){if(a>r)t.insertBefore(e,n);else if(a<r){var o=i[r+1];o?t.insertBefore(e,o):t.appendChild(e)}}else t.appendChild(e)}xr.moveTo=wit;Object.defineProperty(Wn,"__esModule",{value:!0});Wn.setClip=Wn.setTransform=Wn.setShadow=void 0;var Cit=xr;function Sit(e,r){var t=e.cfg.el,i=e.attr(),n={dx:i.shadowOffsetX,dy:i.shadowOffsetY,blur:i.shadowBlur,color:i.shadowColor};if(!n.dx&&!n.dy&&!n.blur&&!n.color)t.removeAttribute("filter");else{var a=r.find("filter",n);a||(a=r.addShadow(n)),t.setAttribute("filter","url(#"+a+")")}}Wn.setShadow=Sit;function Ait(e){var r=e.attr().matrix;if(r){for(var t=e.cfg.el,i=[],n=0;n<9;n+=3)i.push(r[n]+","+r[n+1]);i=i.join(","),i.indexOf("NaN")===-1?t.setAttribute("transform","matrix("+i+")"):console.warn("invalid matrix:",r)}}Wn.setTransform=Ait;function Tit(e,r){var t=e.getClip(),i=e.get("el");if(!t)i.removeAttribute("clip-path");else if(t&&!i.hasAttribute("clip-path")){Cit.createDom(t),t.createPath(r);var n=r.addClip(t);i.setAttribute("clip-path","url(#"+n+")")}}Wn.setClip=Tit;var ds={};Object.defineProperty(ds,"__esModule",{value:!0});ds.refreshElement=ds.drawChildren=void 0;var yD=Wn,mD=xr;function Mit(e,r){r.forEach(function(t){t.draw(e)})}ds.drawChildren=Mit;function Eit(e,r){var t=e.get("canvas");if(t&&t.get("autoDraw")){var i=t.get("context"),n=e.getParent(),a=n?n.getChildren():[t],o=e.get("el");if(r==="remove"){var l=e.get("isClipShape");if(l){var s=o&&o.parentNode,u=s&&s.parentNode;s&&u&&u.removeChild(s)}else o&&o.parentNode&&o.parentNode.removeChild(o)}else if(r==="show")o.setAttribute("visibility","visible");else if(r==="hide")o.setAttribute("visibility","hidden");else if(r==="zIndex")mD.moveTo(o,a.indexOf(e));else if(r==="sort"){var c=e.get("children");c&&c.length&&mD.sortDom(e,function(f,h){return c.indexOf(f)-c.indexOf(h)?1:0})}else r==="clear"?o&&(o.innerHTML=""):r==="matrix"?yD.setTransform(e):r==="clip"?yD.setClip(e,i):r==="attr"||r==="add"&&e.draw(i)}}ds.refreshElement=Eit;var Rp={};Object.defineProperty(Rp,"__esModule",{value:!0});var Fit=V,Oit=ii,Pit=Y,Iit=kp,xD=ds,_D=Wn,bD=ur,Lit=xr,Dit=function(e){Fit.__extends(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.isEntityGroup=function(){return!0},r.prototype.createDom=function(){var t=Lit.createSVGElement("g");this.set("el",t);var i=this.getParent();if(i){var n=i.get("el");n||(n=i.createDom(),i.set("el",n)),n.appendChild(t)}return t},r.prototype.afterAttrsChange=function(t){e.prototype.afterAttrsChange.call(this,t);var i=this.get("canvas");if(i&&i.get("autoDraw")){var n=i.get("context");this.createPath(n,t)}},r.prototype.onCanvasChange=function(t){xD.refreshElement(this,t)},r.prototype.getShapeBase=function(){return Iit},r.prototype.getGroupBase=function(){return r},r.prototype.draw=function(t){var i=this.getChildren(),n=this.get("el");this.get("destroyed")?n&&n.parentNode.removeChild(n):(n||this.createDom(),_D.setClip(this,t),this.createPath(t),i.length&&xD.drawChildren(t,i))},r.prototype.createPath=function(t,i){var n=this.attr(),a=this.get("el");Pit.each(i||n,function(o,l){bD.SVG_ATTR_MAP[l]&&a.setAttribute(bD.SVG_ATTR_MAP[l],o)}),_D.setTransform(this)},r}(Oit.AbstractGroup);Rp.default=Dit;Object.defineProperty(Zi,"__esModule",{value:!0});var bC=V,$it=ii,wC=Wn,kit=xr,Rit=ds,eu=ur,Bit=kp,Nit=Rp,Git=ii,zit=function(e){bC.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="svg",t.canFill=!1,t.canStroke=!1,t}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return bC.__assign(bC.__assign({},t),{lineWidth:1,lineAppendWidth:0,strokeOpacity:1,fillOpacity:1})},r.prototype.afterAttrsChange=function(t){e.prototype.afterAttrsChange.call(this,t);var i=this.get("canvas");if(i&&i.get("autoDraw")){var n=i.get("context");this.draw(n,t)}},r.prototype.getShapeBase=function(){return Bit},r.prototype.getGroupBase=function(){return Nit.default},r.prototype.onCanvasChange=function(t){Rit.refreshElement(this,t)},r.prototype.calculateBBox=function(){var t=this.get("el"),i=null;if(t)i=t.getBBox();else{var n=Git.getBBoxMethod(this.get("type"));n&&(i=n(this))}if(i){var a=i.x,o=i.y,l=i.width,s=i.height,u=this.getHitLineWidth(),c=u/2,f=a-c,h=o-c,v=a+l+c,d=o+s+c;return{x:f,y:h,minX:f,minY:h,maxX:v,maxY:d,width:l+u,height:s+u}}return{x:0,y:0,minX:0,minY:0,maxX:0,maxY:0,width:0,height:0}},r.prototype.isFill=function(){var t=this.attr(),i=t.fill,n=t.fillStyle;return(i||n||this.isClipShape())&&this.canFill},r.prototype.isStroke=function(){var t=this.attr(),i=t.stroke,n=t.strokeStyle;return(i||n)&&this.canStroke},r.prototype.draw=function(t,i){var n=this.get("el");this.get("destroyed")?n&&n.parentNode.removeChild(n):(n||kit.createDom(this),wC.setClip(this,t),this.createPath(t,i),this.shadow(t,i),this.strokeAndFill(t,i),this.transform(i))},r.prototype.createPath=function(t,i){},r.prototype.strokeAndFill=function(t,i){var n=i||this.attr(),a=n.fill,o=n.fillStyle,l=n.stroke,s=n.strokeStyle,u=n.fillOpacity,c=n.strokeOpacity,f=n.lineWidth,h=this.get("el");this.canFill&&(i?"fill"in n?this._setColor(t,"fill",a):"fillStyle"in n&&this._setColor(t,"fill",o):this._setColor(t,"fill",a||o),u&&h.setAttribute(eu.SVG_ATTR_MAP.fillOpacity,u)),this.canStroke&&f>0&&(i?"stroke"in n?this._setColor(t,"stroke",l):"strokeStyle"in n&&this._setColor(t,"stroke",s):this._setColor(t,"stroke",l||s),c&&h.setAttribute(eu.SVG_ATTR_MAP.strokeOpacity,c),f&&h.setAttribute(eu.SVG_ATTR_MAP.lineWidth,f))},r.prototype._setColor=function(t,i,n){var a=this.get("el");if(!n){a.setAttribute(eu.SVG_ATTR_MAP[i],"none");return}if(n=n.trim(),/^[r,R,L,l]{1}[\s]*\(/.test(n)){var o=t.find("gradient",n);o||(o=t.addGradient(n)),a.setAttribute(eu.SVG_ATTR_MAP[i],"url(#"+o+")")}else if(/^[p,P]{1}[\s]*\(/.test(n)){var o=t.find("pattern",n);o||(o=t.addPattern(n)),a.setAttribute(eu.SVG_ATTR_MAP[i],"url(#"+o+")")}else a.setAttribute(eu.SVG_ATTR_MAP[i],n)},r.prototype.shadow=function(t,i){var n=this.attr(),a=i||n,o=a.shadowOffsetX,l=a.shadowOffsetY,s=a.shadowBlur,u=a.shadowColor;(o||l||s||u)&&wC.setShadow(this,t)},r.prototype.transform=function(t){var i=this.attr(),n=(t||i).matrix;n&&wC.setTransform(this)},r.prototype.isInShape=function(t,i){return this.isPointInPath(t,i)},r.prototype.isPointInPath=function(t,i){var n=this.get("el"),a=this.get("canvas"),o=a.get("el").getBoundingClientRect(),l=t+o.left,s=i+o.top,u=document.elementFromPoint(l,s);return!!(u&&u.isEqualNode(n))},r.prototype.getHitLineWidth=function(){var t=this.attrs,i=t.lineWidth,n=t.lineAppendWidth;return this.isStroke()?i+n:0},r}($it.AbstractShape);Zi.default=zit;var pE={};Object.defineProperty(pE,"__esModule",{value:!0});var CC=V,Vit=Y,wD=ur,jit=Zi,Hit=function(e){CC.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="circle",t.canFill=!0,t.canStroke=!0,t}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return CC.__assign(CC.__assign({},t),{x:0,y:0,r:0})},r.prototype.createPath=function(t,i){var n=this.attr(),a=this.get("el");Vit.each(i||n,function(o,l){l==="x"||l==="y"?a.setAttribute("c"+l,o):wD.SVG_ATTR_MAP[l]&&a.setAttribute(wD.SVG_ATTR_MAP[l],o)})},r}(jit.default);pE.default=Hit;var gE={};Object.defineProperty(gE,"__esModule",{value:!0});var Yit=V,Wit=Y,CD=ur,Xit=Zi,Uit=function(e){Yit.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="dom",t.canFill=!1,t.canStroke=!1,t}return r.prototype.createPath=function(t,i){var n=this.attr(),a=this.get("el");if(Wit.each(i||n,function(u,c){CD.SVG_ATTR_MAP[c]&&a.setAttribute(CD.SVG_ATTR_MAP[c],u)}),typeof n.html=="function"){var o=n.html.call(this,n);if(o instanceof Element||o instanceof HTMLDocument){for(var l=a.childNodes,s=l.length-1;s>=0;s--)a.removeChild(l[s]);a.appendChild(o)}else a.innerHTML=o}else a.innerHTML=n.html},r}(Xit.default);gE.default=Uit;var yE={};Object.defineProperty(yE,"__esModule",{value:!0});var SC=V,qit=Y,SD=ur,Zit=Zi,Qit=function(e){SC.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="ellipse",t.canFill=!0,t.canStroke=!0,t}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return SC.__assign(SC.__assign({},t),{x:0,y:0,rx:0,ry:0})},r.prototype.createPath=function(t,i){var n=this.attr(),a=this.get("el");qit.each(i||n,function(o,l){l==="x"||l==="y"?a.setAttribute("c"+l,o):SD.SVG_ATTR_MAP[l]&&a.setAttribute(SD.SVG_ATTR_MAP[l],o)})},r}(Zit.default);yE.default=Qit;var mE={};Object.defineProperty(mE,"__esModule",{value:!0});var AC=V,TC=Y,AD=ur,Kit=Zi,Jit=function(e){AC.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="image",t.canFill=!1,t.canStroke=!1,t}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return AC.__assign(AC.__assign({},t),{x:0,y:0,width:0,height:0})},r.prototype.createPath=function(t,i){var n=this,a=this.attr(),o=this.get("el");TC.each(i||a,function(l,s){s==="img"?n._setImage(a.img):AD.SVG_ATTR_MAP[s]&&o.setAttribute(AD.SVG_ATTR_MAP[s],l)})},r.prototype.setAttr=function(t,i){this.attrs[t]=i,t==="img"&&this._setImage(i)},r.prototype._setImage=function(t){var i=this.attr(),n=this.get("el");if(TC.isString(t))n.setAttribute("href",t);else if(t instanceof window.Image)i.width||(n.setAttribute("width",t.width),this.attr("width",t.width)),i.height||(n.setAttribute("height",t.height),this.attr("height",t.height)),n.setAttribute("href",t.src);else if(t instanceof HTMLElement&&TC.isString(t.nodeName)&&t.nodeName.toUpperCase()==="CANVAS")n.setAttribute("href",t.toDataURL());else if(t instanceof ImageData){var a=document.createElement("canvas");a.setAttribute("width",""+t.width),a.setAttribute("height",""+t.height),a.getContext("2d").putImageData(t,0,0),i.width||(n.setAttribute("width",""+t.width),this.attr("width",t.width)),i.height||(n.setAttribute("height",""+t.height),this.attr("height",t.height)),n.setAttribute("href",a.toDataURL())}},r}(Kit.default);mE.default=Jit;var xE={};Object.defineProperty(xE,"__esModule",{value:!0});var MC=V,TD=xo,MD=Y,Dc=ur,tnt=Zi,ent=function(e){MC.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="line",t.canFill=!1,t.canStroke=!0,t}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return MC.__assign(MC.__assign({},t),{x1:0,y1:0,x2:0,y2:0,startArrow:!1,endArrow:!1})},r.prototype.createPath=function(t,i){var n=this.attr(),a=this.get("el");MD.each(i||n,function(o,l){if(l==="startArrow"||l==="endArrow")if(o){var s=MD.isObject(o)?t.addArrow(n,Dc.SVG_ATTR_MAP[l]):t.getDefaultArrow(n,Dc.SVG_ATTR_MAP[l]);a.setAttribute(Dc.SVG_ATTR_MAP[l],"url(#"+s+")")}else a.removeAttribute(Dc.SVG_ATTR_MAP[l]);else Dc.SVG_ATTR_MAP[l]&&a.setAttribute(Dc.SVG_ATTR_MAP[l],o)})},r.prototype.getTotalLength=function(){var t=this.attr(),i=t.x1,n=t.y1,a=t.x2,o=t.y2;return TD.Line.length(i,n,a,o)},r.prototype.getPoint=function(t){var i=this.attr(),n=i.x1,a=i.y1,o=i.x2,l=i.y2;return TD.Line.pointAt(n,a,o,l,t)},r}(tnt.default);xE.default=ent;var _E={},bE={};Object.defineProperty(bE,"__esModule",{value:!0});var lm={circle:function(e,r,t){return[["M",e,r],["m",-t,0],["a",t,t,0,1,0,t*2,0],["a",t,t,0,1,0,-t*2,0]]},square:function(e,r,t){return[["M",e-t,r-t],["L",e+t,r-t],["L",e+t,r+t],["L",e-t,r+t],["Z"]]},diamond:function(e,r,t){return[["M",e-t,r],["L",e,r-t],["L",e+t,r],["L",e,r+t],["Z"]]},triangle:function(e,r,t){var i=t*Math.sin(.3333333333333333*Math.PI);return[["M",e-t,r+i],["L",e,r-i],["L",e+t,r+i],["z"]]},triangleDown:function(e,r,t){var i=t*Math.sin(.3333333333333333*Math.PI);return[["M",e-t,r-i],["L",e+t,r-i],["L",e,r+i],["Z"]]}};bE.default={get:function(e){return lm[e]},register:function(e,r){lm[e]=r},remove:function(e){delete lm[e]},getAll:function(){return lm}};Object.defineProperty(_E,"__esModule",{value:!0});var rnt=V,ED=Y,int=Zi,FD=bE,nnt=function(e){rnt.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="marker",t.canFill=!0,t.canStroke=!0,t}return r.prototype.createPath=function(t){var i=this.get("el");i.setAttribute("d",this._assembleMarker())},r.prototype._assembleMarker=function(){var t=this._getPath();return ED.isArray(t)?t.map(function(i){return i.join(" ")}).join(""):t},r.prototype._getPath=function(){var t=this.attr(),i=t.x,n=t.y,a=t.r||t.radius,o=t.symbol||"circle",l;return ED.isFunction(o)?l=o:l=FD.default.get(o),l?l(i,n,a):(console.warn(l+" symbol is not exist."),null)},r.symbolsFactory=FD.default,r}(int.default);_E.default=nnt;var wE={};Object.defineProperty(wE,"__esModule",{value:!0});var EC=V,FC=Y,$c=ur,ant=Zi,ont=function(e){EC.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="path",t.canFill=!0,t.canStroke=!0,t}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return EC.__assign(EC.__assign({},t),{startArrow:!1,endArrow:!1})},r.prototype.createPath=function(t,i){var n=this,a=this.attr(),o=this.get("el");FC.each(i||a,function(l,s){if(s==="path"&&FC.isArray(l))o.setAttribute("d",n._formatPath(l));else if(s==="startArrow"||s==="endArrow")if(l){var u=FC.isObject(l)?t.addArrow(a,$c.SVG_ATTR_MAP[s]):t.getDefaultArrow(a,$c.SVG_ATTR_MAP[s]);o.setAttribute($c.SVG_ATTR_MAP[s],"url(#"+u+")")}else o.removeAttribute($c.SVG_ATTR_MAP[s]);else $c.SVG_ATTR_MAP[s]&&o.setAttribute($c.SVG_ATTR_MAP[s],l)})},r.prototype._formatPath=function(t){var i=t.map(function(n){return n.join(" ")}).join("");return~i.indexOf("NaN")?"":i},r.prototype.getTotalLength=function(){var t=this.get("el");return t?t.getTotalLength():null},r.prototype.getPoint=function(t){var i=this.get("el"),n=this.getTotalLength();if(n===0)return null;var a=i?i.getPointAtLength(t*n):null;return a?{x:a.x,y:a.y}:null},r}(ant.default);wE.default=ont;var CE={};Object.defineProperty(CE,"__esModule",{value:!0});var lnt=V,OD=Y,PD=ur,snt=Zi,unt=function(e){lnt.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="polygon",t.canFill=!0,t.canStroke=!0,t}return r.prototype.createPath=function(t,i){var n=this.attr(),a=this.get("el");OD.each(i||n,function(o,l){l==="points"&&OD.isArray(o)&&o.length>=2?a.setAttribute("points",o.map(function(s){return s[0]+","+s[1]}).join(" ")):PD.SVG_ATTR_MAP[l]&&a.setAttribute(PD.SVG_ATTR_MAP[l],o)})},r}(snt.default);CE.default=unt;var SE={};Object.defineProperty(SE,"__esModule",{value:!0});var OC=V,cnt=xo,ID=xo,pv=Y,LD=ur,fnt=Zi,hnt=function(e){OC.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="polyline",t.canFill=!0,t.canStroke=!0,t}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return OC.__assign(OC.__assign({},t),{startArrow:!1,endArrow:!1})},r.prototype.onAttrChange=function(t,i,n){e.prototype.onAttrChange.call(this,t,i,n),["points"].indexOf(t)!==-1&&this._resetCache()},r.prototype._resetCache=function(){this.set("totalLength",null),this.set("tCache",null)},r.prototype.createPath=function(t,i){var n=this.attr(),a=this.get("el");pv.each(i||n,function(o,l){l==="points"&&pv.isArray(o)&&o.length>=2?a.setAttribute("points",o.map(function(s){return s[0]+","+s[1]}).join(" ")):LD.SVG_ATTR_MAP[l]&&a.setAttribute(LD.SVG_ATTR_MAP[l],o)})},r.prototype.getTotalLength=function(){var t=this.attr().points,i=this.get("totalLength");return pv.isNil(i)?(this.set("totalLength",cnt.Polyline.length(t)),this.get("totalLength")):i},r.prototype.getPoint=function(t){var i=this.attr().points,n=this.get("tCache");n||(this._setTcache(),n=this.get("tCache"));var a,o;return pv.each(n,function(l,s){t>=l[0]&&t<=l[1]&&(a=(t-l[0])/(l[1]-l[0]),o=s)}),ID.Line.pointAt(i[o][0],i[o][1],i[o+1][0],i[o+1][1],a)},r.prototype._setTcache=function(){var t=this.attr().points;if(!(!t||t.length===0)){var i=this.getTotalLength();if(!(i<=0)){var n=0,a=[],o,l;pv.each(t,function(s,u){t[u+1]&&(o=[],o[0]=n/i,l=ID.Line.length(s[0],s[1],t[u+1][0],t[u+1][1]),n+=l,o[1]=n/i,a.push(o))}),this.set("tCache",a)}}},r.prototype.getStartTangent=function(){var t=this.attr().points,i=[];return i.push([t[1][0],t[1][1]]),i.push([t[0][0],t[0][1]]),i},r.prototype.getEndTangent=function(){var t=this.attr().points,i=t.length-1,n=[];return n.push([t[i-1][0],t[i-1][1]]),n.push([t[i][0],t[i][1]]),n},r}(fnt.default);SE.default=hnt;var AE={},Vf={};Object.defineProperty(Vf,"__esModule",{value:!0});Vf.parsePath=Vf.parseRadius=void 0;var Wv=Y,vnt=/[MLHVQTCSAZ]([^MLHVQTCSAZ]*)/gi,dnt=/[^\s,]+/gi;function pnt(e){var r=0,t=0,i=0,n=0;return Wv.isArray(e)?e.length===1?r=t=i=n=e[0]:e.length===2?(r=i=e[0],t=n=e[1]):e.length===3?(r=e[0],t=n=e[1],i=e[2]):(r=e[0],t=e[1],i=e[2],n=e[3]):r=t=i=n=e,{r1:r,r2:t,r3:i,r4:n}}Vf.parseRadius=pnt;function gnt(e){if(e=e||[],Wv.isArray(e))return e;if(Wv.isString(e))return e=e.match(vnt),Wv.each(e,function(r,t){if(r=r.match(dnt),r[0].length>1){var i=r[0].charAt(0);r.splice(1,0,r[0].substr(1)),r[0]=i}Wv.each(r,function(n,a){isNaN(n)||(r[a]=+n)}),e[t]=r}),e}Vf.parsePath=gnt;Object.defineProperty(AE,"__esModule",{value:!0});var PC=V,DD=Y,ynt=Zi,$D=ur,mnt=Vf,xnt=function(e){PC.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="rect",t.canFill=!0,t.canStroke=!0,t}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return PC.__assign(PC.__assign({},t),{x:0,y:0,width:0,height:0,radius:0})},r.prototype.createPath=function(t,i){var n=this,a=this.attr(),o=this.get("el"),l=!1,s=["x","y","width","height","radius"];DD.each(i||a,function(u,c){s.indexOf(c)!==-1&&!l?(o.setAttribute("d",n._assembleRect(a)),l=!0):s.indexOf(c)===-1&&$D.SVG_ATTR_MAP[c]&&o.setAttribute($D.SVG_ATTR_MAP[c],u)})},r.prototype._assembleRect=function(t){var i=t.x,n=t.y,a=t.width,o=t.height,l=t.radius;if(!l)return"M "+i+","+n+" l "+a+",0 l 0,"+o+" l"+-a+" 0 z";var s=mnt.parseRadius(l);DD.isArray(l)?l.length===1?s.r1=s.r2=s.r3=s.r4=l[0]:l.length===2?(s.r1=s.r3=l[0],s.r2=s.r4=l[1]):l.length===3?(s.r1=l[0],s.r2=s.r4=l[1],s.r3=l[2]):(s.r1=l[0],s.r2=l[1],s.r3=l[2],s.r4=l[3]):s.r1=s.r2=s.r3=s.r4=l;var u=[["M "+(i+s.r1)+","+n],["l "+(a-s.r1-s.r2)+",0"],["a "+s.r2+","+s.r2+",0,0,1,"+s.r2+","+s.r2],["l 0,"+(o-s.r2-s.r3)],["a "+s.r3+","+s.r3+",0,0,1,"+-s.r3+","+s.r3],["l "+(s.r3+s.r4-a)+",0"],["a "+s.r4+","+s.r4+",0,0,1,"+-s.r4+","+-s.r4],["l 0,"+(s.r4+s.r1-o)],["a "+s.r1+","+s.r1+",0,0,1,"+s.r1+","+-s.r1],["z"]];return u.join(" ")},r}(ynt.default);AE.default=xnt;var TE={},_nt=br(P9);Object.defineProperty(TE,"__esModule",{value:!0});var IC=V,kD=Y,bnt=_nt,wnt=Wn,RD=ur,Cnt=Zi,BD=.3,Snt={top:"before-edge",middle:"central",bottom:"after-edge",alphabetic:"baseline",hanging:"hanging"},Ant={top:"text-before-edge",middle:"central",bottom:"text-after-edge",alphabetic:"alphabetic",hanging:"hanging"},Tnt={left:"left",start:"left",center:"middle",right:"end",end:"end"},Mnt=function(e){IC.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="text",t.canFill=!0,t.canStroke=!0,t}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return IC.__assign(IC.__assign({},t),{x:0,y:0,text:null,fontSize:12,fontFamily:"sans-serif",fontStyle:"normal",fontWeight:"normal",fontVariant:"normal",textAlign:"start",textBaseline:"bottom"})},r.prototype.createPath=function(t,i){var n=this,a=this.attr(),o=this.get("el");this._setFont(),kD.each(i||a,function(l,s){s==="text"?n._setText(""+l):s==="matrix"&&l?wnt.setTransform(n):RD.SVG_ATTR_MAP[s]&&o.setAttribute(RD.SVG_ATTR_MAP[s],l)}),o.setAttribute("paint-order","stroke"),o.setAttribute("style","stroke-linecap:butt; stroke-linejoin:miter;")},r.prototype._setFont=function(){var t=this.get("el"),i=this.attr(),n=i.textBaseline,a=i.textAlign,o=bnt.detect();o&&o.name==="firefox"?t.setAttribute("dominant-baseline",Ant[n]||"alphabetic"):t.setAttribute("alignment-baseline",Snt[n]||"baseline"),t.setAttribute("text-anchor",Tnt[a]||"left")},r.prototype._setText=function(t){var i=this.get("el"),n=this.attr(),a=n.x,o=n.textBaseline,l=o===void 0?"bottom":o;if(!t)i.innerHTML="";else if(~t.indexOf(`
|
|
`)){var s=t.split(`
|
|
`),u=s.length-1,c="";kD.each(s,function(f,h){h===0?l==="alphabetic"?c+='<tspan x="'+a+'" dy="'+-u+'em">'+f+"</tspan>":l==="top"?c+='<tspan x="'+a+'" dy="0.9em">'+f+"</tspan>":l==="middle"?c+='<tspan x="'+a+'" dy="'+-(u-1)/2+'em">'+f+"</tspan>":l==="bottom"?c+='<tspan x="'+a+'" dy="-'+(u+BD)+'em">'+f+"</tspan>":l==="hanging"&&(c+='<tspan x="'+a+'" dy="'+(-(u-1)-BD)+'em">'+f+"</tspan>"):c+='<tspan x="'+a+'" dy="1em">'+f+"</tspan>"}),i.innerHTML=c}else i.innerHTML=t},r}(Cnt.default);TE.default=Mnt;(function(e){Object.defineProperty(e,"__esModule",{value:!0});var r=Zi;Object.defineProperty(e,"Base",{enumerable:!0,get:function(){return r.default}});var t=pE;Object.defineProperty(e,"Circle",{enumerable:!0,get:function(){return t.default}});var i=gE;Object.defineProperty(e,"Dom",{enumerable:!0,get:function(){return i.default}});var n=yE;Object.defineProperty(e,"Ellipse",{enumerable:!0,get:function(){return n.default}});var a=mE;Object.defineProperty(e,"Image",{enumerable:!0,get:function(){return a.default}});var o=xE;Object.defineProperty(e,"Line",{enumerable:!0,get:function(){return o.default}});var l=_E;Object.defineProperty(e,"Marker",{enumerable:!0,get:function(){return l.default}});var s=wE;Object.defineProperty(e,"Path",{enumerable:!0,get:function(){return s.default}});var u=CE;Object.defineProperty(e,"Polygon",{enumerable:!0,get:function(){return u.default}});var c=SE;Object.defineProperty(e,"Polyline",{enumerable:!0,get:function(){return c.default}});var f=AE;Object.defineProperty(e,"Rect",{enumerable:!0,get:function(){return f.default}});var h=TE;Object.defineProperty(e,"Text",{enumerable:!0,get:function(){return h.default}})})(kp);var ME={},EE={},FE={};Object.defineProperty(FE,"__esModule",{value:!0});var ix=Y,ND=xr,Ent=/^l\s*\(\s*([\d.]+)\s*\)\s*(.*)/i,Fnt=/^r\s*\(\s*([\d.]+)\s*,\s*([\d.]+)\s*,\s*([\d.]+)\s*\)\s*(.*)/i,Ont=/[\d.]+:(#[^\s]+|[^)]+\))/gi;function c3(e){var r=e.match(Ont);if(!r)return"";var t="";return r.sort(function(i,n){return i=i.split(":"),n=n.split(":"),Number(i[0])-Number(n[0])}),ix.each(r,function(i){i=i.split(":"),t+='<stop offset="'+i[0]+'" stop-color="'+i[1]+'"></stop>'}),t}function Pnt(e,r){var t=Ent.exec(e),i=ix.mod(ix.toRadian(parseFloat(t[1])),Math.PI*2),n=t[2],a,o;i>=0&&i<.5*Math.PI?(a={x:0,y:0},o={x:1,y:1}):.5*Math.PI<=i&&i<Math.PI?(a={x:1,y:0},o={x:0,y:1}):Math.PI<=i&&i<1.5*Math.PI?(a={x:1,y:1},o={x:0,y:0}):(a={x:0,y:1},o={x:1,y:0});var l=Math.tan(i),s=l*l,u=(o.x-a.x+l*(o.y-a.y))/(s+1)+a.x,c=l*(o.x-a.x+l*(o.y-a.y))/(s+1)+a.y;r.setAttribute("x1",a.x),r.setAttribute("y1",a.y),r.setAttribute("x2",u),r.setAttribute("y2",c),r.innerHTML=c3(n)}function Int(e,r){var t=Fnt.exec(e),i=parseFloat(t[1]),n=parseFloat(t[2]),a=parseFloat(t[3]),o=t[4];r.setAttribute("cx",i),r.setAttribute("cy",n),r.setAttribute("r",a),r.innerHTML=c3(o)}var Lnt=function(){function e(r){this.cfg={};var t=null,i=ix.uniqueId("gradient_");return r.toLowerCase()[0]==="l"?(t=ND.createSVGElement("linearGradient"),Pnt(r,t)):(t=ND.createSVGElement("radialGradient"),Int(r,t)),t.setAttribute("id",i),this.el=t,this.id=i,this.cfg=r,this}return e.prototype.match=function(r,t){return this.cfg===t},e}();FE.default=Lnt;var OE={};Object.defineProperty(OE,"__esModule",{value:!0});var LC=Y,Dnt=xr,$nt={shadowColor:"color",shadowOpacity:"opacity",shadowBlur:"blur",shadowOffsetX:"dx",shadowOffsetY:"dy"},knt={x:"-40%",y:"-40%",width:"200%",height:"200%"},Rnt=function(){function e(r){this.type="filter",this.cfg={},this.type="filter";var t=Dnt.createSVGElement("filter");return LC.each(knt,function(i,n){t.setAttribute(n,i)}),this.el=t,this.id=LC.uniqueId("filter_"),this.el.id=this.id,this.cfg=r,this._parseShadow(r,t),this}return e.prototype.match=function(r,t){if(this.type!==r)return!1;var i=!0,n=this.cfg;return LC.each(Object.keys(n),function(a){if(n[a]!==t[a])return i=!1,!1}),i},e.prototype.update=function(r,t){var i=this.cfg;return i[$nt[r]]=t,this._parseShadow(i,this.el),this},e.prototype._parseShadow=function(r,t){var i=`<feDropShadow
|
|
dx="`+(r.dx||0)+`"
|
|
dy="`+(r.dy||0)+`"
|
|
stdDeviation="`+(r.blur?r.blur/10:0)+`"
|
|
flood-color="`+(r.color?r.color:"#000")+`"
|
|
flood-opacity="`+(r.opacity?r.opacity:1)+`"
|
|
/>`;t.innerHTML=i},e}();OE.default=Rnt;var PE={};Object.defineProperty(PE,"__esModule",{value:!0});var GD=Y,zD=xr,Bnt=function(){function e(r,t){this.cfg={};var i=zD.createSVGElement("marker"),n=GD.uniqueId("marker_");i.setAttribute("id",n);var a=zD.createSVGElement("path");a.setAttribute("stroke",r.stroke||"none"),a.setAttribute("fill",r.fill||"none"),i.appendChild(a),i.setAttribute("overflow","visible"),i.setAttribute("orient","auto-start-reverse"),this.el=i,this.child=a,this.id=n;var o=r[t==="marker-start"?"startArrow":"endArrow"];return this.stroke=r.stroke||"#000",o===!0?this._setDefaultPath(t,a):(this.cfg=o,this._setMarker(r.lineWidth,a)),this}return e.prototype.match=function(){return!1},e.prototype._setDefaultPath=function(r,t){var i=this.el;t.setAttribute("d","M0,0 L"+10*Math.cos(Math.PI/6)+",5 L0,10"),i.setAttribute("refX",""+10*Math.cos(Math.PI/6)),i.setAttribute("refY",""+5)},e.prototype._setMarker=function(r,t){var i=this.el,n=this.cfg.path,a=this.cfg.d;GD.isArray(n)&&(n=n.map(function(o){return o.join(" ")}).join("")),t.setAttribute("d",n),i.appendChild(t),a&&i.setAttribute("refX",""+a/r)},e.prototype.update=function(r){var t=this.child;t.attr?t.attr("fill",r):t.setAttribute("fill",r)},e}();PE.default=Bnt;var IE={};Object.defineProperty(IE,"__esModule",{value:!0});var Nnt=Y,Gnt=xr,znt=function(){function e(r){this.type="clip",this.cfg={};var t=Gnt.createSVGElement("clipPath");this.el=t,this.id=Nnt.uniqueId("clip_"),t.id=this.id;var i=r.cfg.el;return t.appendChild(i),this.cfg=r,this}return e.prototype.match=function(){return!1},e.prototype.remove=function(){var r=this.el;r.parentNode.removeChild(r)},e}();IE.default=znt;var LE={};Object.defineProperty(LE,"__esModule",{value:!0});var Vnt=Y,VD=xr,jnt=/^p\s*\(\s*([axyn])\s*\)\s*(.*)/i,Hnt=function(){function e(r){this.cfg={};var t=VD.createSVGElement("pattern");t.setAttribute("patternUnits","userSpaceOnUse");var i=VD.createSVGElement("image");t.appendChild(i);var n=Vnt.uniqueId("pattern_");t.id=n,this.el=t,this.id=n,this.cfg=r;var a=jnt.exec(r),o=a[2];i.setAttribute("href",o);var l=new Image;o.match(/^data:/i)||(l.crossOrigin="Anonymous"),l.src=o;function s(){t.setAttribute("width",""+l.width),t.setAttribute("height",""+l.height)}return l.complete?s():(l.onload=s,l.src=l.src),this}return e.prototype.match=function(r,t){return this.cfg===t},e}();LE.default=Hnt;Object.defineProperty(EE,"__esModule",{value:!0});var Ynt=Y,Wnt=FE,Xnt=OE,jD=PE,Unt=IE,qnt=LE,Znt=xr,Qnt=function(){function e(r){var t=Znt.createSVGElement("defs"),i=Ynt.uniqueId("defs_");t.id=i,r.appendChild(t),this.children=[],this.defaultArrow={},this.el=t,this.canvas=r}return e.prototype.find=function(r,t){for(var i=this.children,n=null,a=0;a<i.length;a++)if(i[a].match(r,t)){n=i[a].id;break}return n},e.prototype.findById=function(r){for(var t=this.children,i=null,n=0;n<t.length;n++)if(t[n].id===r){i=t[n];break}return i},e.prototype.add=function(r){this.children.push(r),r.canvas=this.canvas,r.parent=this},e.prototype.getDefaultArrow=function(r,t){var i=r.stroke||r.strokeStyle;if(this.defaultArrow[i])return this.defaultArrow[i].id;var n=new jD.default(r,t);return this.defaultArrow[i]=n,this.el.appendChild(n.el),this.add(n),n.id},e.prototype.addGradient=function(r){var t=new Wnt.default(r);return this.el.appendChild(t.el),this.add(t),t.id},e.prototype.addArrow=function(r,t){var i=new jD.default(r,t);return this.el.appendChild(i.el),this.add(i),i.id},e.prototype.addShadow=function(r){var t=new Xnt.default(r);return this.el.appendChild(t.el),this.add(t),t.id},e.prototype.addPattern=function(r){var t=new qnt.default(r);return this.el.appendChild(t.el),this.add(t),t.id},e.prototype.addClip=function(r){var t=new Unt.default(r);return this.el.appendChild(t.el),this.add(t),t.id},e}();EE.default=Qnt;Object.defineProperty(ME,"__esModule",{value:!0});var DC=V,Knt=ii,HD=ur,Jnt=ds,$C=Wn,YD=xr,tat=kp,eat=Rp,rat=EE,iat=function(e){DC.__extends(r,e);function r(t){return e.call(this,DC.__assign(DC.__assign({},t),{autoDraw:!0,renderer:"svg"}))||this}return r.prototype.getShapeBase=function(){return tat},r.prototype.getGroupBase=function(){return eat.default},r.prototype.getShape=function(t,i,n){var a=n.target||n.srcElement;if(!HD.SHAPE_TO_TAGS[a.tagName]){for(var o=a.parentNode;o&&!HD.SHAPE_TO_TAGS[o.tagName];)o=o.parentNode;a=o}return this.find(function(l){return l.get("el")===a})},r.prototype.createDom=function(){var t=YD.createSVGElement("svg"),i=new rat.default(t);return t.setAttribute("width",""+this.get("width")),t.setAttribute("height",""+this.get("height")),this.set("context",i),t},r.prototype.onCanvasChange=function(t){var i=this.get("context"),n=this.get("el");if(t==="sort"){var a=this.get("children");a&&a.length&&YD.sortDom(this,function(l,s){return a.indexOf(l)-a.indexOf(s)?1:0})}else if(t==="clear"){if(n){n.innerHTML="";var o=i.el;o.innerHTML="",n.appendChild(o)}}else t==="matrix"?$C.setTransform(this):t==="clip"?$C.setClip(this,i):t==="changeSize"&&(n.setAttribute("width",""+this.get("width")),n.setAttribute("height",""+this.get("height")))},r.prototype.draw=function(){var t=this.get("context"),i=this.getChildren();$C.setClip(this,t),i.length&&Jnt.drawChildren(t,i)},r}(Knt.AbstractCanvas);ME.default=iat;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.version=e.Shape=void 0;var r=V,t=kp;e.Shape=t,r.__exportStar(ii,e);var i=ME;Object.defineProperty(e,"Canvas",{enumerable:!0,get:function(){return i.default}});var n=Rp;Object.defineProperty(e,"Group",{enumerable:!0,get:function(){return n.default}}),e.version="0.5.6"})(dE);var nat=aM(dE),aat=jG({__proto__:null,default:nat},[dE]),ut={},Af={},DE={},Qu={};Object.defineProperty(Qu,"__esModule",{value:!0});Qu.registerEngine=Qu.getEngine=void 0;var f3={};function oat(e){var r=f3[e];if(!r)throw new Error("G engine '"+e+"' is not exist, please register it at first.");return r}Qu.getEngine=oat;function lat(e,r){f3[e]=r}Qu.registerEngine=lat;var ps={},Bp={},h3=br(A9);Object.defineProperty(Bp,"__esModule",{value:!0});var v3=V,sat=(0,v3.__importDefault)(h3),uat=function(e){(0,v3.__extends)(r,e);function r(t){var i=e.call(this)||this;i.destroyed=!1;var n=t.visible,a=n===void 0?!0:n;return i.visible=a,i}return r.prototype.show=function(){var t=this.visible;t||this.changeVisible(!0)},r.prototype.hide=function(){var t=this.visible;t&&this.changeVisible(!1)},r.prototype.destroy=function(){this.off(),this.destroyed=!0},r.prototype.changeVisible=function(t){this.visible!==t&&(this.visible=t)},r}(sat.default);Bp.default=uat;var nx={},_o={},Oe={},Zr={};Object.defineProperty(Zr,"__esModule",{value:!0});Zr.getMaxScale=Zr.getDefaultCategoryScaleRange=Zr.getName=Zr.syncScale=Zr.createScaleByField=void 0;var VA=V,Ja=Y,WD=Qn,cat=be,fat=/^(?:(?!0000)[0-9]{4}([-/.]+)(?:(?:0?[1-9]|1[0-2])\1(?:0?[1-9]|1[0-9]|2[0-8])|(?:0?[13-9]|1[0-2])\1(?:29|30)|(?:0?[13578]|1[02])\1(?:31))|(?:[0-9]{2}(?:0[48]|[2468][048]|[13579][26])|(?:0[48]|[2468][048]|[13579][26])00)([-/.]+)0?2\2(?:29))(\s+([01]|([01][0-9]|2[0-3])):([0-9]|[0-5][0-9]):([0-9]|[0-5][0-9]))?$/;function hat(e){var r="linear";return fat.test(e)?r="timeCat":(0,Ja.isString)(e)&&(r="cat"),r}function vat(e,r,t){var i=r||[];if((0,Ja.isNumber)(e)||(0,Ja.isNil)((0,Ja.firstValue)(i,e))&&(0,Ja.isEmpty)(t)){var n=(0,WD.getScale)("identity");return new n({field:e.toString(),values:[e]})}var a=(0,Ja.valuesOfKey)(i,e),o=(0,Ja.get)(t,"type",hat(a[0])),l=(0,WD.getScale)(o);return new l((0,VA.__assign)({field:e,values:a},t))}Zr.createScaleByField=vat;function dat(e,r){if(e.type!=="identity"&&r.type!=="identity"){var t={};for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(t[i]=r[i]);e.change(t)}}Zr.syncScale=dat;function pat(e){return e.alias||e.field}Zr.getName=pat;function gat(e,r,t){var i=e.values,n=i.length,a;if(n===1)a=[.5,1];else{var o=1,l=0;(0,cat.isFullCircle)(r)?r.isTransposed?(o=(0,Ja.get)(t,"widthRatio.multiplePie",1/1.3),l=1/n*o,a=[l/2,1-l/2]):a=[0,1-1/n]:(l=1/n/2,a=[l,1-l])}return a}Zr.getDefaultCategoryScaleRange=gat;function yat(e){var r=e.values.filter(function(t){return!(0,Ja.isNil)(t)&&!isNaN(t)});return Math.max.apply(Math,(0,VA.__spreadArray)((0,VA.__spreadArray)([],r,!1),[(0,Ja.isNil)(e.max)?-1/0:e.max],!1))}Zr.getMaxScale=yat;Object.defineProperty(Oe,"__esModule",{value:!0});Oe.getAxisTitleText=Oe.getAxisDirection=Oe.getAxisOption=Oe.getCircleAxisCenterRadius=Oe.getAxisTitleOptions=Oe.getAxisThemeCfg=Oe.getAxisFactorByRegion=Oe.isVertical=Oe.getAxisFactor=Oe.getAxisRegion=Oe.getCircleAxisRelativeRegion=Oe.getLineAxisRelativeRegion=void 0;var zi=Y,Xl=Jt,mat=Zr,XD=ta;function d3(e){var r,t;switch(e){case Xl.DIRECTION.TOP:r={x:0,y:1},t={x:1,y:1};break;case Xl.DIRECTION.RIGHT:r={x:1,y:0},t={x:1,y:1};break;case Xl.DIRECTION.BOTTOM:r={x:0,y:0},t={x:1,y:0};break;case Xl.DIRECTION.LEFT:r={x:0,y:0},t={x:0,y:1};break;default:r=t={x:0,y:0}}return{start:r,end:t}}Oe.getLineAxisRelativeRegion=d3;function p3(e){var r,t;return e.isTransposed?(r={x:0,y:0},t={x:1,y:0}):(r={x:0,y:0},t={x:0,y:1}),{start:r,end:t}}Oe.getCircleAxisRelativeRegion=p3;function xat(e,r){var t={start:{x:0,y:0},end:{x:0,y:0}};e.isRect?t=d3(r):e.isPolar&&(t=p3(e));var i=t.start,n=t.end;return{start:e.convert(i),end:e.convert(n)}}Oe.getAxisRegion=xat;function _at(e,r){if(e.isRect)return e.isTransposed?[Xl.DIRECTION.RIGHT,Xl.DIRECTION.BOTTOM].includes(r)?1:-1:[Xl.DIRECTION.BOTTOM,Xl.DIRECTION.RIGHT].includes(r)?-1:1;if(e.isPolar){var t=e.x.start;return t<0?-1:1}return 1}Oe.getAxisFactor=_at;function g3(e){var r=e.start,t=e.end;return r.x===t.x}Oe.isVertical=g3;function bat(e,r){var t=e.start,i=e.end,n=g3(e);return n?(t.y-i.y)*(r.x-t.x)>0?1:-1:(i.x-t.x)*(t.y-r.y)>0?-1:1}Oe.getAxisFactorByRegion=bat;function wat(e,r){var t=(0,zi.get)(e,["components","axis"],{});return(0,zi.deepMix)({},(0,zi.get)(t,["common"],{}),(0,zi.deepMix)({},(0,zi.get)(t,[r],{})))}Oe.getAxisThemeCfg=wat;function Cat(e,r,t){var i=(0,zi.get)(e,["components","axis"],{});return(0,zi.deepMix)({},(0,zi.get)(i,["common","title"],{}),(0,zi.deepMix)({},(0,zi.get)(i,[r,"title"],{})),t)}Oe.getAxisTitleOptions=Cat;function Sat(e){var r=e.x,t=e.y,i=e.circleCenter,n=t.start>t.end,a=e.isTransposed?e.convert({x:n?0:1,y:0}):e.convert({x:0,y:n?0:1}),o=[a.x-i.x,a.y-i.y],l=[1,0],s=a.y>i.y?XD.vec2.angle(o,l):XD.vec2.angle(o,l)*-1,u=s+(r.end-r.start),c=Math.sqrt(Math.pow(a.x-i.x,2)+Math.pow(a.y-i.y,2));return{center:i,radius:c,startAngle:s,endAngle:u}}Oe.getCircleAxisCenterRadius=Sat;function Aat(e,r){return(0,zi.isBoolean)(e)?e===!1?!1:{}:(0,zi.get)(e,[r])}Oe.getAxisOption=Aat;function Tat(e,r){return(0,zi.get)(e,"position",r)}Oe.getAxisDirection=Tat;function Mat(e,r){return(0,zi.get)(r,["title","text"],(0,mat.getName)(e))}Oe.getAxisTitleText=Mat;Object.defineProperty(_o,"__esModule",{value:!0});_o.Facet=void 0;var Lo=Y,Eat=Jt,UD=Oe,Fat=function(){function e(r,t){this.destroyed=!1,this.facets=[],this.view=r,this.cfg=(0,Lo.deepMix)({},this.getDefaultCfg(),t)}return e.prototype.init=function(){this.container||(this.container=this.createContainer());var r=this.view.getData();this.facets=this.generateFacets(r)},e.prototype.render=function(){this.renderViews()},e.prototype.update=function(){},e.prototype.clear=function(){this.clearFacetViews()},e.prototype.destroy=function(){this.clear(),this.container&&(this.container.remove(!0),this.container=void 0),this.destroyed=!0,this.view=void 0,this.facets=[]},e.prototype.facetToView=function(r){var t=r.region,i=r.data,n=r.padding,a=n===void 0?this.cfg.padding:n,o=this.view.createView({region:t,padding:a});o.data(i||[]),r.view=o,this.beforeEachView(o,r);var l=this.cfg.eachView;return l&&l(o,r),this.afterEachView(o,r),o},e.prototype.createContainer=function(){var r=this.view.getLayer(Eat.LAYER.FORE);return r.addGroup()},e.prototype.renderViews=function(){this.createFacetViews()},e.prototype.createFacetViews=function(){var r=this;return this.facets.map(function(t){return r.facetToView(t)})},e.prototype.clearFacetViews=function(){var r=this;(0,Lo.each)(this.facets,function(t){t.view&&(r.view.removeView(t.view),t.view=void 0)})},e.prototype.parseSpacing=function(){var r=this.view.viewBBox,t=r.width,i=r.height,n=this.cfg.spacing;return n.map(function(a,o){return(0,Lo.isNumber)(a)?a/(o===0?t:i):parseFloat(a)/100})},e.prototype.getFieldValues=function(r,t){var i=[],n={};return(0,Lo.each)(r,function(a){var o=a[t];!(0,Lo.isNil)(o)&&!n[o]&&(i.push(o),n[o]=!0)}),i},e.prototype.getRegion=function(r,t,i,n){var a=this.parseSpacing(),o=a[0],l=a[1],s=(1+o)/(t===0?1:t)-o,u=(1+l)/(r===0?1:r)-l,c={x:(s+o)*i,y:(u+l)*n},f={x:c.x+s,y:c.y+u};return{start:c,end:f}},e.prototype.getDefaultCfg=function(){return{eachView:void 0,showTitle:!0,spacing:[0,0],padding:10,fields:[]}},e.prototype.getDefaultTitleCfg=function(){var r=this.view.getTheme().fontFamily;return{style:{fontSize:14,fill:"#666",fontFamily:r}}},e.prototype.processAxis=function(r,t){var i=r.getOptions(),n=i.coordinate,a=r.geometries,o=(0,Lo.get)(n,"type","rect");if(o==="rect"&&a.length){(0,Lo.isNil)(i.axes)&&(i.axes={});var l=i.axes,s=a[0].getXYFields(),u=s[0],c=s[1],f=(0,UD.getAxisOption)(l,u),h=(0,UD.getAxisOption)(l,c);f!==!1&&(i.axes[u]=this.getXAxisOption(u,l,f,t)),h!==!1&&(i.axes[c]=this.getYAxisOption(c,l,h,t))}},e.prototype.getFacetDataFilter=function(r){return function(t){return(0,Lo.every)(r,function(i){var n=i.field,a=i.value;return!(0,Lo.isNil)(a)&&n?t[n]===a:!0})}},e}();_o.Facet=Fat;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.registerFacet=e.getFacet=e.Facet=void 0;var r=Y,t=_o;Object.defineProperty(e,"Facet",{enumerable:!0,get:function(){return t.Facet}});var i={},n=function(o){return i[(0,r.lowerCase)(o)]};e.getFacet=n;var a=function(o,l){i[(0,r.lowerCase)(o)]=l};e.registerFacet=a})(nx);var ax={},Np={},vn={},$E={},Ir={};Object.defineProperty(Ir,"__esModule",{value:!0});var Oat=Y,Pat=function(){function e(r,t){this.context=r,this.cfg=t,r.addAction(this)}return e.prototype.applyCfg=function(r){(0,Oat.assign)(this,r)},e.prototype.init=function(){this.applyCfg(this.cfg)},e.prototype.destroy=function(){this.context.removeAction(this),this.context=null},e}();Ir.default=Pat;Object.defineProperty($E,"__esModule",{value:!0});var y3=V,Iat=(0,y3.__importDefault)(Ir),Lat=function(e){(0,y3.__extends)(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.execute=function(){this.callback&&this.callback(this.context)},r.prototype.destroy=function(){e.prototype.destroy.call(this),this.callback=null},r}(Iat.default);$E.default=Lat;Object.defineProperty(vn,"__esModule",{value:!0});vn.createCallbackAction=m3=vn.unregisterAction=vn.registerAction=vn.getActionClass=vn.createAction=void 0;var Dat=V,$at=(0,Dat.__importDefault)($E),kat=Y,P1={};function Rat(e,r){var t=P1[e],i=null;if(t){var n=t.ActionClass,a=t.cfg;i=new n(r,a),i.name=e,i.init()}return i}vn.createAction=Rat;function Bat(e){var r=P1[e];return(0,kat.get)(r,"ActionClass")}vn.getActionClass=Bat;function Nat(e,r,t){P1[e]={ActionClass:r,cfg:t}}vn.registerAction=Nat;function Gat(e){delete P1[e]}var m3=vn.unregisterAction=Gat;function zat(e,r){var t=new $at.default(r);return t.callback=e,t.name="callback",t}vn.createCallbackAction=zat;var kE={},xt={},fc={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.convertPolarPath=e.convertNormalPath=e.getSplinePath=e.getLinePath=e.catmullRom2bezier=e.smoothBezier=void 0;var r=ta,t=Y,i=be;function n(p,x){var m=[];if(p.length){m.push(["M",p[0].x,p[0].y]);for(var _=1,b=p.length;_<b;_+=1){var w=p[_];m.push(["L",w.x,w.y])}x&&m.push(["Z"])}return m}function a(p,x){for(var m=[p[0]],_=1,b=p.length;_<b;_=_+2){var w=x.convert({x:p[_],y:p[_+1]});m.push(w.x,w.y)}return m}function o(p,x){var m=x.isTransposed,_=p[1],b=p[6],w=p[7],S=x.convert({x:b,y:w}),M=m?0:1;return["A",_,_,0,0,M,S.x,S.y]}function l(p,x,m){var _=m.isTransposed,b=m.startAngle,w=m.endAngle,S=p[0].toLowerCase()==="a"?{x:p[6],y:p[7]}:{x:p[1],y:p[2]},M={x:x[1],y:x[2]},F=[],O=_?"y":"x",L=Math.abs(M[O]-S[O])*(w-b),D=M[O]>=S[O]?1:0,k=L>Math.PI?1:0,H=m.convert(M),B=(0,i.getDistanceToCenter)(m,H);if(B>=.5)if(L===Math.PI*2){var j={x:(M.x+S.x)/2,y:(M.y+S.y)/2},U=m.convert(j);F.push(["A",B,B,0,k,D,U.x,U.y]),F.push(["A",B,B,0,k,D,H.x,H.y])}else F.push(["A",B,B,0,k,D,H.x,H.y]);return F}function s(p){(0,t.each)(p,function(x,m){var _=x;if(_[0].toLowerCase()==="a"){var b=p[m-1],w=p[m+1];w&&w[0].toLowerCase()==="a"?b&&b[0].toLowerCase()==="l"&&(b[0]="M"):b&&b[0].toLowerCase()==="a"&&w&&w[0].toLowerCase()==="l"&&(w[0]="M")}})}var u=function(p,x,m,_){var b=[],w=!!_,S,M,F,O,L,D,k;if(w){F=_[0],O=_[1];for(var H=0,B=p.length;H<B;H++){var j=p[H];F=r.vec2.min([0,0],F,j),O=r.vec2.max([0,0],O,j)}}for(var H=0,U=p.length;H<U;H++){var j=p[H];if(H===0&&!m)k=j;else if(H===U-1&&!m)D=j,b.push(k),b.push(D);else{S=p[m?H?H-1:U-1:H-1],M=p[m?(H+1)%U:H+1];var R=[0,0];R=r.vec2.sub(R,M,S),R=r.vec2.scale(R,R,x);var G=r.vec2.distance(j,S),N=r.vec2.distance(j,M),W=G+N;W!==0&&(G/=W,N/=W);var q=r.vec2.scale([0,0],R,-G),tt=r.vec2.scale([0,0],R,N);D=r.vec2.add([0,0],j,q),L=r.vec2.add([0,0],j,tt),L=r.vec2.min([0,0],L,r.vec2.max([0,0],M,j)),L=r.vec2.max([0,0],L,r.vec2.min([0,0],M,j)),q=r.vec2.sub([0,0],L,j),q=r.vec2.scale([0,0],q,-G/N),D=r.vec2.add([0,0],j,q),D=r.vec2.min([0,0],D,r.vec2.max([0,0],S,j)),D=r.vec2.max([0,0],D,r.vec2.min([0,0],S,j)),tt=r.vec2.sub([0,0],j,D),tt=r.vec2.scale([0,0],tt,N/G),L=r.vec2.add([0,0],j,tt),w&&(D=r.vec2.max([0,0],D,F),D=r.vec2.min([0,0],D,O),L=r.vec2.max([0,0],L,F),L=r.vec2.min([0,0],L,O)),b.push(k),b.push(D),k=L}}return m&&b.push(b.shift()),b};e.smoothBezier=u;function c(p,x,m){for(var _=!!x,b=[],w=0,S=p.length;w<S;w+=2)b.push([p[w],p[w+1]]);for(var M=(0,e.smoothBezier)(b,.4,_,m),F=b.length,O=[],L,D,k,w=0;w<F-1;w++)L=M[w*2],D=M[w*2+1],k=b[w+1],O.push(["C",L[0],L[1],D[0],D[1],k[0],k[1]]);return _&&(L=M[F],D=M[F+1],k=b[0],O.push(["C",L[0],L[1],D[0],D[1],k[0],k[1]])),O}e.catmullRom2bezier=c;function f(p,x){return n(p,x)}e.getLinePath=f;function h(p,x,m){var _=[],b=p[0],w=null;if(p.length<=2)return f(p,x);for(var S=0,M=p.length;S<M;S++){var F=p[S];(!w||!(w.x===F.x&&w.y===F.y))&&(_.push(F.x),_.push(F.y),w=F)}var O=m||[[0,0],[1,1]],L=c(_,x,O);return L.unshift(["M",b.x,b.y]),L}e.getSplinePath=h;function v(p,x){var m=[];return(0,t.each)(x,function(_){var b=_[0];switch(b.toLowerCase()){case"m":case"l":case"c":m.push(a(_,p));break;case"a":m.push(o(_,p));break;case"z":default:m.push(_);break}}),m}e.convertNormalPath=v;function d(p,x){var m=[],_,b,w,S;return(0,t.each)(x,function(M,F){var O=M[0];switch(O.toLowerCase()){case"m":case"c":case"q":m.push(a(M,p));break;case"l":_=x[F-1],b=M,w=p.isTransposed,S=w?_[_.length-2]===b[1]:_[_.length-1]===b[2],S?m=m.concat(l(_,b,p)):m.push(a(M,p));break;case"a":m.push(o(M,p));break;case"z":default:m.push(M);break}}),s(m),m}e.convertPolarPath=d})(fc);Object.defineProperty(xt,"__esModule",{value:!0});xt.getScaleByField=xt.isInRecords=xt.getSiblingPoint=xt.getSilbings=xt.isInBox=xt.getSpline=xt.distance=xt.getComponents=xt.getElementsByPath=xt.getIntersectElements=xt.intersectRect=xt.getElementValue=xt.getElementsByState=xt.getElementsByField=xt.getElements=xt.getSiblingMaskElements=xt.getMaskedElements=xt.isMask=xt.isSlider=xt.isList=xt.isElementChange=xt.getDelegationObject=xt.getCurrentElement=void 0;var ol=Y,qD=fc,Vat=ti,jat=A1;function x3(e,r){var t=e.event,i=t.target,n=i.getCanvasBBox();return n.width>=r||n.height>=r?n:null}function Hat(e,r){var t=e.event,i=t.target,n=i.getCanvasBBox();return n.width>=r||n.height>=r?i.attr("path"):null}function Yat(e){var r=e.event,t,i=r.target;return i&&(t=i.get("element")),t}xt.getCurrentElement=Yat;function Wat(e){var r=e.event,t=r.target,i;return t&&(i=t.get("delegateObject")),i}xt.getDelegationObject=Wat;function Xat(e){var r=e.event.gEvent;return!(r&&r.fromShape&&r.toShape&&r.fromShape.get("element")===r.toShape.get("element"))}xt.isElementChange=Xat;function Uat(e){return e&&e.component&&e.component.isList()}xt.isList=Uat;function qat(e){return e&&e.component&&e.component.isSlider()}xt.isSlider=qat;function Zat(e){var r=e.event,t=r.target;return t&&t.get("name")==="mask"}xt.isMask=Zat;function Qat(e,r){var t=e.event.target;if(t.get("type")==="path"){var i=Hat(e,r);return i?w3(e.view,i):void 0}var n=x3(e,r);return n?RE(e.view,n):null}xt.getMaskedElements=Qat;function Kat(e,r,t){var i=x3(e,t);if(!i)return null;var n=e.view,a=jA(n,r,{x:i.x,y:i.y}),o=jA(n,r,{x:i.maxX,y:i.maxY}),l={minX:a.x,minY:a.y,maxX:o.x,maxY:o.y};return RE(r,l)}xt.getSiblingMaskElements=Kat;function Gp(e){var r=e.geometries,t=[];return(0,ol.each)(r,function(i){var n=i.elements;t=t.concat(n)}),e.views&&e.views.length&&(0,ol.each)(e.views,function(i){t=t.concat(Gp(i))}),t}xt.getElements=Gp;function Jat(e,r,t){var i=Gp(e);return i.filter(function(n){return _3(n,r)===t})}xt.getElementsByField=Jat;function tot(e,r){var t=e.geometries,i=[];return(0,ol.each)(t,function(n){var a=n.getElementsBy(function(o){return o.hasState(r)});i=i.concat(a)}),i}xt.getElementsByState=tot;function _3(e,r){var t=e.getModel(),i=t.data,n;return(0,ol.isArray)(i)?n=i[0][r]:n=i[r],n}xt.getElementValue=_3;function b3(e,r){return!(r.minX>e.maxX||r.maxX<e.minX||r.minY>e.maxY||r.maxY<e.minY)}xt.intersectRect=b3;function RE(e,r){var t=Gp(e),i=[];return(0,ol.each)(t,function(n){var a=n.shape,o=a.getCanvasBBox();b3(r,o)&&i.push(n)}),i}xt.getIntersectElements=RE;function ZD(e){var r=[];return(0,ol.each)(e,function(t){var i=t[0];if(i!=="A")for(var n=1;n<t.length;n=n+2)r.push([t[n],t[n+1]]);else{var a=t.length;r.push([t[a-2],t[a-1]])}}),r}function w3(e,r){var t=Gp(e),i=ZD(r),n=t.filter(function(a){var o=a.shape,l;if(o.get("type")==="path")l=ZD(o.attr("path"));else{var s=o.getCanvasBBox();l=(0,Vat.toPoints)(s)}return(0,jat.isPolygonsIntersect)(i,l)});return n}xt.getElementsByPath=w3;function eot(e){return e.getComponents().map(function(r){return r.component})}xt.getComponents=eot;function rot(e,r){var t=r.x-e.x,i=r.y-e.y;return Math.sqrt(t*t+i*i)}xt.distance=rot;function iot(e,r){if(e.length<=2)return(0,qD.getLinePath)(e,!1);var t=e[0],i=[];(0,ol.each)(e,function(a){i.push(a.x),i.push(a.y)});var n=(0,qD.catmullRom2bezier)(i,r,null);return n.unshift(["M",t.x,t.y]),n}xt.getSpline=iot;function not(e,r){return e.x<=r.x&&e.maxX>=r.x&&e.y<=r.y&&e.maxY>r.y}xt.isInBox=not;function aot(e){var r=e.parent,t=null;return r&&(t=r.views.filter(function(i){return i!==e})),t}xt.getSilbings=aot;function oot(e,r){var t=e.getCoordinate();return t.invert(r)}function jA(e,r,t){var i=oot(e,t);return r.getCoordinate().convert(i)}xt.getSiblingPoint=jA;function lot(e,r,t,i){var n=!1;return(0,ol.each)(e,function(a){if(a[t]===r[t]&&a[i]===r[i])return n=!0,!1}),n}xt.isInRecords=lot;function C3(e,r){var t=e.getScaleByField(r);return!t&&e.views&&(0,ol.each)(e.views,function(i){if(t=C3(i,r),t)return!1}),t}xt.getScaleByField=C3;Object.defineProperty(kE,"__esModule",{value:!0});var QD=Y,kC=xt,sot=function(){function e(r){this.actions=[],this.event=null,this.cacheMap={},this.view=r}return e.prototype.cache=function(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];if(r.length===1)return this.cacheMap[r[0]];r.length===2&&(this.cacheMap[r[0]]=r[1])},e.prototype.getAction=function(r){return this.actions.find(function(t){return t.name===r})},e.prototype.addAction=function(r){this.actions.push(r)},e.prototype.removeAction=function(r){var t=this.actions,i=this.actions.indexOf(r);i>=0&&t.splice(i,1)},e.prototype.getCurrentPoint=function(){var r=this.event;if(r)if(r.target instanceof HTMLElement){var t=this.view.getCanvas(),i=t.getPointByClient(r.clientX,r.clientY);return i}else return{x:r.x,y:r.y};return null},e.prototype.getCurrentShape=function(){return(0,QD.get)(this.event,["gEvent","shape"])},e.prototype.isInPlot=function(){var r=this.getCurrentPoint();return r?this.view.isPointInPlot(r):!1},e.prototype.isInShape=function(r){var t=this.getCurrentShape();return t?t.get("name")===r:!1},e.prototype.isInComponent=function(r){var t=(0,kC.getComponents)(this.view),i=this.getCurrentPoint();return i?!!t.find(function(n){var a=n.getBBox();return r?n.get("name")===r&&(0,kC.isInBox)(a,i):(0,kC.isInBox)(a,i)}):!1},e.prototype.destroy=function(){(0,QD.each)(this.actions.slice(),function(r){r.destroy()}),this.view=null,this.event=null,this.actions=null,this.cacheMap=null},e}();kE.default=sot;var I1={};Object.defineProperty(I1,"__esModule",{value:!0});var uot=function(){function e(r,t){this.view=r,this.cfg=t}return e.prototype.init=function(){this.initEvents()},e.prototype.initEvents=function(){},e.prototype.clearEvents=function(){},e.prototype.destroy=function(){this.clearEvents()},e}();I1.default=uot;Object.defineProperty(Np,"__esModule",{value:!0});Np.parseAction=void 0;var BE=V,mi=Y,S3=vn,cot=(0,BE.__importDefault)(kE),fot=(0,BE.__importDefault)(I1);function HA(e,r,t){var i=e.split(":"),n=i[0],a=r.getAction(n)||(0,S3.createAction)(n,r);if(!a)throw new Error("There is no action named "+n);var o=i[1];return{action:a,methodName:o,arg:t}}Np.parseAction=HA;function KD(e){var r=e.action,t=e.methodName,i=e.arg;if(r[t])r[t](i);else throw new Error("Action("+r.name+") doesn't have a method called "+t)}var on={START:"start",SHOW_ENABLE:"showEnable",END:"end",ROLLBACK:"rollback",PROCESSING:"processing"},hot=function(e){(0,BE.__extends)(r,e);function r(t,i){var n=e.call(this,t,i)||this;return n.callbackCaches={},n.emitCaches={},n.steps=i,n}return r.prototype.init=function(){this.initContext(),e.prototype.init.call(this)},r.prototype.destroy=function(){e.prototype.destroy.call(this),this.steps=null,this.context&&(this.context.destroy(),this.context=null),this.callbackCaches=null,this.view=null},r.prototype.initEvents=function(){var t=this;(0,mi.each)(this.steps,function(i,n){(0,mi.each)(i,function(a){var o=t.getActionCallback(n,a);o&&t.bindEvent(a.trigger,o)})})},r.prototype.clearEvents=function(){var t=this;(0,mi.each)(this.steps,function(i,n){(0,mi.each)(i,function(a){var o=t.getActionCallback(n,a);o&&t.offEvent(a.trigger,o)})})},r.prototype.initContext=function(){var t=this.view,i=new cot.default(t);this.context=i;var n=this.steps;(0,mi.each)(n,function(a){(0,mi.each)(a,function(o){if((0,mi.isFunction)(o.action))o.actionObject={action:(0,S3.createCallbackAction)(o.action,i),methodName:"execute"};else if((0,mi.isString)(o.action))o.actionObject=HA(o.action,i,o.arg);else if((0,mi.isArray)(o.action)){var l=o.action,s=(0,mi.isArray)(o.arg)?o.arg:[o.arg];o.actionObject=[],(0,mi.each)(l,function(u,c){o.actionObject.push(HA(u,i,s[c]))})}})})},r.prototype.isAllowStep=function(t){var i=this.currentStepName,n=this.steps;if(i===t||t===on.SHOW_ENABLE)return!0;if(t===on.PROCESSING)return i===on.START;if(t===on.START)return i!==on.PROCESSING;if(t===on.END)return i===on.PROCESSING||i===on.START;if(t===on.ROLLBACK){if(n[on.END])return i===on.END;if(i===on.START)return!0}return!1},r.prototype.isAllowExecute=function(t,i){if(this.isAllowStep(t)){var n=this.getKey(t,i);return i.once&&this.emitCaches[n]?!1:i.isEnable?i.isEnable(this.context):!0}return!1},r.prototype.enterStep=function(t){this.currentStepName=t,this.emitCaches={}},r.prototype.afterExecute=function(t,i){t!==on.SHOW_ENABLE&&this.currentStepName!==t&&this.enterStep(t);var n=this.getKey(t,i);this.emitCaches[n]=!0},r.prototype.getKey=function(t,i){return t+i.trigger+i.action},r.prototype.getActionCallback=function(t,i){var n=this,a=this.context,o=this.callbackCaches,l=i.actionObject;if(i.action&&l){var s=this.getKey(t,i);if(!o[s]){var u=function(c){a.event=c,n.isAllowExecute(t,i)?((0,mi.isArray)(l)?(0,mi.each)(l,function(f){a.event=c,KD(f)}):(a.event=c,KD(l)),n.afterExecute(t,i),i.callback&&(a.event=c,i.callback(a))):a.event=null};i.debounce?o[s]=(0,mi.debounce)(u,i.debounce.wait,i.debounce.immediate):i.throttle?o[s]=(0,mi.throttle)(u,i.throttle.wait,{leading:i.throttle.leading,trailing:i.throttle.trailing}):o[s]=u}return o[s]}return null},r.prototype.bindEvent=function(t,i){var n=t.split(":");n[0]==="window"?window.addEventListener(n[1],i):n[0]==="document"?document.addEventListener(n[1],i):this.view.on(t,i)},r.prototype.offEvent=function(t,i){var n=t.split(":");n[0]==="window"?window.removeEventListener(n[1],i):n[0]==="document"?document.removeEventListener(n[1],i):this.view.off(t,i)},r}(fot.default);Np.default=hot;var zp={};(function(e){var r=kd&&kd.__importDefault||function(n){return n&&n.__esModule?n:{default:n}};Object.defineProperty(e,"__esModule",{value:!0}),e.getActionClass=e.registerAction=e.createAction=e.Action=void 0;var t=Ir;Object.defineProperty(e,"Action",{enumerable:!0,get:function(){return r(t).default}});var i=vn;Object.defineProperty(e,"createAction",{enumerable:!0,get:function(){return i.createAction}}),Object.defineProperty(e,"registerAction",{enumerable:!0,get:function(){return i.registerAction}}),Object.defineProperty(e,"getActionClass",{enumerable:!0,get:function(){return i.getActionClass}})})(zp);(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.getActionClass=e.registerAction=e.Action=e.Interaction=e.createInteraction=e.registerInteraction=e.getInteraction=void 0;var r=V,t=Y,i=(0,r.__importDefault)(Np),n={};function a(c){return n[(0,t.lowerCase)(c)]}e.getInteraction=a;function o(c,f){n[(0,t.lowerCase)(c)]=f}e.registerInteraction=o;function l(c,f,h){var v=a(c);if(!v)return null;if((0,t.isPlainObject)(v)){var d=(0,t.mix)((0,t.clone)(v),h);return new i.default(f,d)}else{var p=v;return new p(f,h)}}e.createInteraction=l;var s=I1;Object.defineProperty(e,"Interaction",{enumerable:!0,get:function(){return(0,r.__importDefault)(s).default}});var u=zp;Object.defineProperty(e,"Action",{enumerable:!0,get:function(){return u.Action}}),Object.defineProperty(e,"registerAction",{enumerable:!0,get:function(){return u.registerAction}}),Object.defineProperty(e,"getActionClass",{enumerable:!0,get:function(){return u.getActionClass}})})(ax);var Ku={},NE={},L1={},Vp={};Object.defineProperty(Vp,"__esModule",{value:!0});var D1=Vp.createThemeByStyleSheet=void 0,si=V,kc=w1,vot=ta,JD=Y,dot=Se;function pot(e){return{title:{autoRotate:!0,position:"center",spacing:e.axisTitleSpacing,style:{fill:e.axisTitleTextFillColor,fontSize:e.axisTitleTextFontSize,lineHeight:e.axisTitleTextLineHeight,textBaseline:"middle",fontFamily:e.fontFamily}},label:{autoRotate:!1,autoEllipsis:!1,autoHide:{type:"equidistance",cfg:{minGap:6}},offset:e.axisLabelOffset,style:{fill:e.axisLabelFillColor,fontSize:e.axisLabelFontSize,lineHeight:e.axisLabelLineHeight,fontFamily:e.fontFamily}},line:{style:{lineWidth:e.axisLineBorder,stroke:e.axisLineBorderColor}},grid:{line:{type:"line",style:{stroke:e.axisGridBorderColor,lineWidth:e.axisGridBorder,lineDash:e.axisGridLineDash}},alignTick:!0,animate:!0},tickLine:{style:{lineWidth:e.axisTickLineBorder,stroke:e.axisTickLineBorderColor},alignTick:!0,length:e.axisTickLineLength},subTickLine:null,animate:!0}}function got(e){return{title:null,marker:{symbol:"circle",spacing:e.legendMarkerSpacing,style:{r:e.legendCircleMarkerSize,fill:e.legendMarkerColor}},itemName:{spacing:5,style:{fill:e.legendItemNameFillColor,fontFamily:e.fontFamily,fontSize:e.legendItemNameFontSize,lineHeight:e.legendItemNameLineHeight,fontWeight:e.legendItemNameFontWeight,textAlign:"start",textBaseline:"middle"}},itemStates:{active:{nameStyle:{opacity:.8}},unchecked:{nameStyle:{fill:"#D8D8D8"},markerStyle:{fill:"#D8D8D8",stroke:"#D8D8D8"}},inactive:{nameStyle:{fill:"#D8D8D8"},markerStyle:{opacity:.2}}},flipPage:!0,pageNavigator:{marker:{style:{size:e.legendPageNavigatorMarkerSize,inactiveFill:e.legendPageNavigatorMarkerInactiveFillColor,inactiveOpacity:e.legendPageNavigatorMarkerInactiveFillOpacity,fill:e.legendPageNavigatorMarkerFillColor,opacity:e.legendPageNavigatorMarkerFillOpacity}},text:{style:{fill:e.legendPageNavigatorTextFillColor,fontSize:e.legendPageNavigatorTextFontSize}}},animate:!1,maxItemWidth:200,itemSpacing:e.legendItemSpacing,itemMarginBottom:e.legendItemMarginBottom,padding:e.legendPadding}}function yot(e){var r,t={point:{default:{fill:e.pointFillColor,r:e.pointSize,stroke:e.pointBorderColor,lineWidth:e.pointBorder,fillOpacity:e.pointFillOpacity},active:{stroke:e.pointActiveBorderColor,lineWidth:e.pointActiveBorder},selected:{stroke:e.pointSelectedBorderColor,lineWidth:e.pointSelectedBorder},inactive:{fillOpacity:e.pointInactiveFillOpacity,strokeOpacity:e.pointInactiveBorderOpacity}},hollowPoint:{default:{fill:e.hollowPointFillColor,lineWidth:e.hollowPointBorder,stroke:e.hollowPointBorderColor,strokeOpacity:e.hollowPointBorderOpacity,r:e.hollowPointSize},active:{stroke:e.hollowPointActiveBorderColor,strokeOpacity:e.hollowPointActiveBorderOpacity},selected:{lineWidth:e.hollowPointSelectedBorder,stroke:e.hollowPointSelectedBorderColor,strokeOpacity:e.hollowPointSelectedBorderOpacity},inactive:{strokeOpacity:e.hollowPointInactiveBorderOpacity}},area:{default:{fill:e.areaFillColor,fillOpacity:e.areaFillOpacity,stroke:null},active:{fillOpacity:e.areaActiveFillOpacity},selected:{fillOpacity:e.areaSelectedFillOpacity},inactive:{fillOpacity:e.areaInactiveFillOpacity}},hollowArea:{default:{fill:null,stroke:e.hollowAreaBorderColor,lineWidth:e.hollowAreaBorder,strokeOpacity:e.hollowAreaBorderOpacity},active:{fill:null,lineWidth:e.hollowAreaActiveBorder},selected:{fill:null,lineWidth:e.hollowAreaSelectedBorder},inactive:{strokeOpacity:e.hollowAreaInactiveBorderOpacity}},interval:{default:{fill:e.intervalFillColor,fillOpacity:e.intervalFillOpacity},active:{stroke:e.intervalActiveBorderColor,lineWidth:e.intervalActiveBorder},selected:{stroke:e.intervalSelectedBorderColor,lineWidth:e.intervalSelectedBorder},inactive:{fillOpacity:e.intervalInactiveFillOpacity,strokeOpacity:e.intervalInactiveBorderOpacity}},hollowInterval:{default:{fill:e.hollowIntervalFillColor,stroke:e.hollowIntervalBorderColor,lineWidth:e.hollowIntervalBorder,strokeOpacity:e.hollowIntervalBorderOpacity},active:{stroke:e.hollowIntervalActiveBorderColor,lineWidth:e.hollowIntervalActiveBorder,strokeOpacity:e.hollowIntervalActiveBorderOpacity},selected:{stroke:e.hollowIntervalSelectedBorderColor,lineWidth:e.hollowIntervalSelectedBorder,strokeOpacity:e.hollowIntervalSelectedBorderOpacity},inactive:{stroke:e.hollowIntervalInactiveBorderColor,lineWidth:e.hollowIntervalInactiveBorder,strokeOpacity:e.hollowIntervalInactiveBorderOpacity}},line:{default:{stroke:e.lineBorderColor,lineWidth:e.lineBorder,strokeOpacity:e.lineBorderOpacity,fill:null,lineAppendWidth:10,lineCap:"round",lineJoin:"round"},active:{lineWidth:e.lineActiveBorder},selected:{lineWidth:e.lineSelectedBorder},inactive:{strokeOpacity:e.lineInactiveBorderOpacity}}},i=pot(e),n=got(e);return{background:e.backgroundColor,defaultColor:e.brandColor,subColor:e.subColor,semanticRed:e.paletteSemanticRed,semanticGreen:e.paletteSemanticGreen,padding:"auto",fontFamily:e.fontFamily,columnWidthRatio:1/2,maxColumnWidth:null,minColumnWidth:null,roseWidthRatio:.9999999,multiplePieWidthRatio:1/1.3,colors10:e.paletteQualitative10,colors20:e.paletteQualitative20,sequenceColors:e.paletteSequence,shapes:{point:["hollow-circle","hollow-square","hollow-bowtie","hollow-diamond","hollow-hexagon","hollow-triangle","hollow-triangle-down","circle","square","bowtie","diamond","hexagon","triangle","triangle-down","cross","tick","plus","hyphen","line"],line:["line","dash","dot","smooth"],area:["area","smooth","line","smooth-line"],interval:["rect","hollow-rect","line","tick"]},sizes:[1,10],geometries:{interval:{rect:{default:{style:t.interval.default},active:{style:t.interval.active},inactive:{style:t.interval.inactive},selected:{style:function(a){var o=a.geometry.coordinate;if(o.isPolar&&o.isTransposed){var l=(0,dot.getAngle)(a.getModel(),o),s=l.startAngle,u=l.endAngle,c=(s+u)/2,f=7.5,h=f*Math.cos(c),v=f*Math.sin(c);return{matrix:vot.ext.transform(null,[["t",h,v]])}}return t.interval.selected}}},"hollow-rect":{default:{style:t.hollowInterval.default},active:{style:t.hollowInterval.active},inactive:{style:t.hollowInterval.inactive},selected:{style:t.hollowInterval.selected}},line:{default:{style:t.hollowInterval.default},active:{style:t.hollowInterval.active},inactive:{style:t.hollowInterval.inactive},selected:{style:t.hollowInterval.selected}},tick:{default:{style:t.hollowInterval.default},active:{style:t.hollowInterval.active},inactive:{style:t.hollowInterval.inactive},selected:{style:t.hollowInterval.selected}},funnel:{default:{style:t.interval.default},active:{style:t.interval.active},inactive:{style:t.interval.inactive},selected:{style:t.interval.selected}},pyramid:{default:{style:t.interval.default},active:{style:t.interval.active},inactive:{style:t.interval.inactive},selected:{style:t.interval.selected}}},line:{line:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},dot:{default:{style:(0,si.__assign)((0,si.__assign)({},t.line.default),{lineCap:null,lineDash:[1,1]})},active:{style:(0,si.__assign)((0,si.__assign)({},t.line.active),{lineCap:null,lineDash:[1,1]})},inactive:{style:(0,si.__assign)((0,si.__assign)({},t.line.inactive),{lineCap:null,lineDash:[1,1]})},selected:{style:(0,si.__assign)((0,si.__assign)({},t.line.selected),{lineCap:null,lineDash:[1,1]})}},dash:{default:{style:(0,si.__assign)((0,si.__assign)({},t.line.default),{lineCap:null,lineDash:[5.5,1]})},active:{style:(0,si.__assign)((0,si.__assign)({},t.line.active),{lineCap:null,lineDash:[5.5,1]})},inactive:{style:(0,si.__assign)((0,si.__assign)({},t.line.inactive),{lineCap:null,lineDash:[5.5,1]})},selected:{style:(0,si.__assign)((0,si.__assign)({},t.line.selected),{lineCap:null,lineDash:[5.5,1]})}},smooth:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},hv:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},vh:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},hvh:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},vhv:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}}},polygon:{polygon:{default:{style:t.interval.default},active:{style:t.interval.active},inactive:{style:t.interval.inactive},selected:{style:t.interval.selected}}},point:{circle:{default:{style:t.point.default},active:{style:t.point.active},inactive:{style:t.point.inactive},selected:{style:t.point.selected}},square:{default:{style:t.point.default},active:{style:t.point.active},inactive:{style:t.point.inactive},selected:{style:t.point.selected}},bowtie:{default:{style:t.point.default},active:{style:t.point.active},inactive:{style:t.point.inactive},selected:{style:t.point.selected}},diamond:{default:{style:t.point.default},active:{style:t.point.active},inactive:{style:t.point.inactive},selected:{style:t.point.selected}},hexagon:{default:{style:t.point.default},active:{style:t.point.active},inactive:{style:t.point.inactive},selected:{style:t.point.selected}},triangle:{default:{style:t.point.default},active:{style:t.point.active},inactive:{style:t.point.inactive},selected:{style:t.point.selected}},"triangle-down":{default:{style:t.point.default},active:{style:t.point.active},inactive:{style:t.point.inactive},selected:{style:t.point.selected}},"hollow-circle":{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},"hollow-square":{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},"hollow-bowtie":{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},"hollow-diamond":{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},"hollow-hexagon":{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},"hollow-triangle":{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},"hollow-triangle-down":{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},cross:{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},tick:{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},plus:{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},hyphen:{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},line:{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}}},area:{area:{default:{style:t.area.default},active:{style:t.area.active},inactive:{style:t.area.inactive},selected:{style:t.area.selected}},smooth:{default:{style:t.area.default},active:{style:t.area.active},inactive:{style:t.area.inactive},selected:{style:t.area.selected}},line:{default:{style:t.hollowArea.default},active:{style:t.hollowArea.active},inactive:{style:t.hollowArea.inactive},selected:{style:t.hollowArea.selected}},"smooth-line":{default:{style:t.hollowArea.default},active:{style:t.hollowArea.active},inactive:{style:t.hollowArea.inactive},selected:{style:t.hollowArea.selected}}},schema:{candle:{default:{style:t.hollowInterval.default},active:{style:t.hollowInterval.active},inactive:{style:t.hollowInterval.inactive},selected:{style:t.hollowInterval.selected}},box:{default:{style:t.hollowInterval.default},active:{style:t.hollowInterval.active},inactive:{style:t.hollowInterval.inactive},selected:{style:t.hollowInterval.selected}}},edge:{line:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},vhv:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},smooth:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},arc:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}}},violin:{violin:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},smooth:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},hollow:{default:{style:t.hollowArea.default},active:{style:t.hollowArea.active},inactive:{style:t.hollowArea.inactive},selected:{style:t.hollowArea.selected}},"hollow-smooth":{default:{style:t.hollowArea.default},active:{style:t.hollowArea.active},inactive:{style:t.hollowArea.inactive},selected:{style:t.hollowArea.selected}}}},components:{axis:{common:i,top:{position:"top",grid:null,title:null,verticalLimitLength:1/2},bottom:{position:"bottom",grid:null,title:null,verticalLimitLength:1/2},left:{position:"left",title:null,line:null,tickLine:null,verticalLimitLength:1/3},right:{position:"right",title:null,line:null,tickLine:null,verticalLimitLength:1/3},circle:{title:null,grid:(0,JD.deepMix)({},i.grid,{line:{type:"line"}})},radius:{title:null,grid:(0,JD.deepMix)({},i.grid,{line:{type:"circle"}})}},legend:{common:n,right:{layout:"vertical",padding:e.legendVerticalPadding},left:{layout:"vertical",padding:e.legendVerticalPadding},top:{layout:"horizontal",padding:e.legendHorizontalPadding},bottom:{layout:"horizontal",padding:e.legendHorizontalPadding},continuous:{title:null,background:null,track:{},rail:{type:"color",size:e.sliderRailHeight,defaultLength:e.sliderRailWidth,style:{fill:e.sliderRailFillColor,stroke:e.sliderRailBorderColor,lineWidth:e.sliderRailBorder}},label:{align:"rail",spacing:4,formatter:null,style:{fill:e.sliderLabelTextFillColor,fontSize:e.sliderLabelTextFontSize,lineHeight:e.sliderLabelTextLineHeight,textBaseline:"middle",fontFamily:e.fontFamily}},handler:{size:e.sliderHandlerWidth,style:{fill:e.sliderHandlerFillColor,stroke:e.sliderHandlerBorderColor}},slidable:!0,padding:n.padding}},tooltip:{showContent:!0,follow:!0,showCrosshairs:!1,showMarkers:!0,shared:!1,enterable:!1,position:"auto",marker:{symbol:"circle",stroke:"#fff",shadowBlur:10,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"rgba(0,0,0,0.09)",lineWidth:2,r:4},crosshairs:{line:{style:{stroke:e.tooltipCrosshairsBorderColor,lineWidth:e.tooltipCrosshairsBorder}},text:null,textBackground:{padding:2,style:{fill:"rgba(0, 0, 0, 0.25)",lineWidth:0,stroke:null}},follow:!1},domStyles:(r={},r[""+kc.TOOLTIP_CSS_CONST.CONTAINER_CLASS]={position:"absolute",visibility:"hidden",zIndex:8,transition:"left 0.4s cubic-bezier(0.23, 1, 0.32, 1) 0s, top 0.4s cubic-bezier(0.23, 1, 0.32, 1) 0s",backgroundColor:e.tooltipContainerFillColor,opacity:e.tooltipContainerFillOpacity,boxShadow:e.tooltipContainerShadow,borderRadius:e.tooltipContainerBorderRadius+"px",color:e.tooltipTextFillColor,fontSize:e.tooltipTextFontSize+"px",fontFamily:e.fontFamily,lineHeight:e.tooltipTextLineHeight+"px",padding:"0 12px 0 12px"},r[""+kc.TOOLTIP_CSS_CONST.TITLE_CLASS]={marginBottom:"12px",marginTop:"12px"},r[""+kc.TOOLTIP_CSS_CONST.LIST_CLASS]={margin:0,listStyleType:"none",padding:0},r[""+kc.TOOLTIP_CSS_CONST.LIST_ITEM_CLASS]={listStyleType:"none",padding:0,marginBottom:"12px",marginTop:"12px",marginLeft:0,marginRight:0},r[""+kc.TOOLTIP_CSS_CONST.MARKER_CLASS]={width:"8px",height:"8px",borderRadius:"50%",display:"inline-block",marginRight:"8px"},r[""+kc.TOOLTIP_CSS_CONST.VALUE_CLASS]={display:"inline-block",float:"right",marginLeft:"30px"},r)},annotation:{arc:{style:{stroke:e.annotationArcBorderColor,lineWidth:e.annotationArcBorder},animate:!0},line:{style:{stroke:e.annotationLineBorderColor,lineDash:e.annotationLineDash,lineWidth:e.annotationLineBorder},text:{position:"start",autoRotate:!0,style:{fill:e.annotationTextFillColor,stroke:e.annotationTextBorderColor,lineWidth:e.annotationTextBorder,fontSize:e.annotationTextFontSize,textAlign:"start",fontFamily:e.fontFamily,textBaseline:"bottom"}},animate:!0},text:{style:{fill:e.annotationTextFillColor,stroke:e.annotationTextBorderColor,lineWidth:e.annotationTextBorder,fontSize:e.annotationTextFontSize,textBaseline:"middle",textAlign:"start",fontFamily:e.fontFamily},animate:!0},region:{top:!1,style:{lineWidth:e.annotationRegionBorder,stroke:e.annotationRegionBorderColor,fill:e.annotationRegionFillColor,fillOpacity:e.annotationRegionFillOpacity},animate:!0},image:{top:!1,animate:!0},dataMarker:{top:!0,point:{style:{r:3,stroke:e.brandColor,lineWidth:2}},line:{style:{stroke:e.annotationLineBorderColor,lineWidth:e.annotationLineBorder},length:e.annotationDataMarkerLineLength},text:{style:{textAlign:"start",fill:e.annotationTextFillColor,stroke:e.annotationTextBorderColor,lineWidth:e.annotationTextBorder,fontSize:e.annotationTextFontSize,fontFamily:e.fontFamily}},direction:"upward",autoAdjust:!0,animate:!0},dataRegion:{style:{region:{fill:e.annotationRegionFillColor,fillOpacity:e.annotationRegionFillOpacity},text:{textAlign:"center",textBaseline:"bottom",fill:e.annotationTextFillColor,stroke:e.annotationTextBorderColor,lineWidth:e.annotationTextBorder,fontSize:e.annotationTextFontSize,fontFamily:e.fontFamily}},animate:!0}},slider:{common:{padding:[8,8,8,8],backgroundStyle:{fill:e.cSliderBackgroundFillColor,opacity:e.cSliderBackgroundFillOpacity},foregroundStyle:{fill:e.cSliderForegroundFillColor,opacity:e.cSliderForegroundFillOpacity},handlerStyle:{width:e.cSliderHandlerWidth,height:e.cSliderHandlerHeight,fill:e.cSliderHandlerFillColor,opacity:e.cSliderHandlerFillOpacity,stroke:e.cSliderHandlerBorderColor,lineWidth:e.cSliderHandlerBorder,radius:e.cSliderHandlerBorderRadius,highLightFill:e.cSliderHandlerHighlightFillColor},textStyle:{fill:e.cSliderTextFillColor,opacity:e.cSliderTextFillOpacity,fontSize:e.cSliderTextFontSize,lineHeight:e.cSliderTextLineHeight,fontWeight:e.cSliderTextFontWeight,stroke:e.cSliderTextBorderColor,lineWidth:e.cSliderTextBorder}}},scrollbar:{common:{padding:[8,8,8,8]},default:{style:{trackColor:e.scrollbarTrackFillColor,thumbColor:e.scrollbarThumbFillColor}},hover:{style:{thumbColor:e.scrollbarThumbHighlightFillColor}}}},labels:{offset:12,style:{fill:e.labelFillColor,fontSize:e.labelFontSize,fontFamily:e.fontFamily,stroke:e.labelBorderColor,lineWidth:e.labelBorder},fillColorDark:e.labelFillColorDark,fillColorLight:e.labelFillColorLight,autoRotate:!0},innerLabels:{style:{fill:e.innerLabelFillColor,fontSize:e.innerLabelFontSize,fontFamily:e.fontFamily,stroke:e.innerLabelBorderColor,lineWidth:e.innerLabelBorder},autoRotate:!0},overflowLabels:{style:{fill:e.overflowLabelFillColor,fontSize:e.overflowLabelFontSize,fontFamily:e.fontFamily,stroke:e.overflowLabelBorderColor,lineWidth:e.overflowLabelBorder}},pieLabels:{labelHeight:14,offset:10,labelLine:{style:{lineWidth:e.labelLineBorder}},autoRotate:!0}}}D1=Vp.createThemeByStyleSheet=yot;var $1={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.antvLight=e.createLightStyleSheet=void 0;var r={100:"#000",95:"#0D0D0D",85:"#262626",65:"#595959",45:"#8C8C8C",25:"#BFBFBF",15:"#D9D9D9",6:"#F0F0F0"},t={100:"#FFFFFF",95:"#F2F2F2",85:"#D9D9D9",65:"#A6A6A6",45:"#737373",25:"#404040",15:"#262626",6:"#0F0F0F"},i=["#5B8FF9","#5AD8A6","#5D7092","#F6BD16","#6F5EF9","#6DC8EC","#945FB9","#FF9845","#1E9493","#FF99C3"],n=["#5B8FF9","#CDDDFD","#5AD8A6","#CDF3E4","#5D7092","#CED4DE","#F6BD16","#FCEBB9","#6F5EF9","#D3CEFD","#6DC8EC","#D3EEF9","#945FB9","#DECFEA","#FF9845","#FFE0C7","#1E9493","#BBDEDE","#FF99C3","#FFE0ED"],a=["#B8E1FF","#9AC5FF","#7DAAFF","#5B8FF9","#3D76DD","#085EC0","#0047A5","#00318A","#001D70"],o=function(l){l===void 0&&(l={});var s=l.backgroundColor,u=s===void 0?"transparent":s,c=l.subColor,f=c===void 0?"rgba(0,0,0,0.05)":c,h=l.paletteQualitative10,v=h===void 0?i:h,d=l.paletteQualitative20,p=d===void 0?n:d,x=l.paletteSemanticRed,m=x===void 0?"#F4664A":x,_=l.paletteSemanticGreen,b=_===void 0?"#30BF78":_,w=l.paletteSemanticYellow,S=w===void 0?"#FAAD14":w,M=l.paletteSequence,F=M===void 0?a:M,O=l.fontFamily,L=O===void 0?`"Segoe UI", Roboto, "Helvetica Neue", Arial,
|
|
"Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol",
|
|
"Noto Color Emoji"`:O,D=l.brandColor,k=D===void 0?v[0]:D;return{backgroundColor:u,brandColor:k,subColor:f,paletteQualitative10:v,paletteQualitative20:p,paletteSemanticRed:m,paletteSemanticGreen:b,paletteSemanticYellow:S,paletteSequence:F,fontFamily:L,axisLineBorderColor:r[25],axisLineBorder:1,axisLineDash:null,axisTitleTextFillColor:r[65],axisTitleTextFontSize:12,axisTitleTextLineHeight:12,axisTitleTextFontWeight:"normal",axisTitleSpacing:12,axisTickLineBorderColor:r[25],axisTickLineLength:4,axisTickLineBorder:1,axisSubTickLineBorderColor:r[15],axisSubTickLineLength:2,axisSubTickLineBorder:1,axisLabelFillColor:r[45],axisLabelFontSize:12,axisLabelLineHeight:12,axisLabelFontWeight:"normal",axisLabelOffset:8,axisGridBorderColor:r[15],axisGridBorder:1,axisGridLineDash:null,legendTitleTextFillColor:r[45],legendTitleTextFontSize:12,legendTitleTextLineHeight:21,legendTitleTextFontWeight:"normal",legendMarkerColor:k,legendMarkerSpacing:8,legendMarkerSize:4,legendCircleMarkerSize:4,legendSquareMarkerSize:4,legendLineMarkerSize:5,legendItemNameFillColor:r[65],legendItemNameFontSize:12,legendItemNameLineHeight:12,legendItemNameFontWeight:"normal",legendItemSpacing:24,legendItemMarginBottom:12,legendPadding:[8,8,8,8],legendHorizontalPadding:[8,0,8,0],legendVerticalPadding:[0,8,0,8],legendPageNavigatorMarkerSize:12,legendPageNavigatorMarkerInactiveFillColor:r[100],legendPageNavigatorMarkerInactiveFillOpacity:.45,legendPageNavigatorMarkerFillColor:r[100],legendPageNavigatorMarkerFillOpacity:1,legendPageNavigatorTextFillColor:r[45],legendPageNavigatorTextFontSize:12,sliderRailFillColor:r[15],sliderRailBorder:0,sliderRailBorderColor:null,sliderRailWidth:100,sliderRailHeight:12,sliderLabelTextFillColor:r[45],sliderLabelTextFontSize:12,sliderLabelTextLineHeight:12,sliderLabelTextFontWeight:"normal",sliderHandlerFillColor:r[6],sliderHandlerWidth:10,sliderHandlerHeight:14,sliderHandlerBorder:1,sliderHandlerBorderColor:r[25],annotationArcBorderColor:r[15],annotationArcBorder:1,annotationLineBorderColor:r[25],annotationLineBorder:1,annotationLineDash:null,annotationTextFillColor:r[65],annotationTextFontSize:12,annotationTextLineHeight:12,annotationTextFontWeight:"normal",annotationTextBorderColor:null,annotationTextBorder:0,annotationRegionFillColor:r[100],annotationRegionFillOpacity:.06,annotationRegionBorder:0,annotationRegionBorderColor:null,annotationDataMarkerLineLength:16,tooltipCrosshairsBorderColor:r[25],tooltipCrosshairsBorder:1,tooltipCrosshairsLineDash:null,tooltipContainerFillColor:"rgb(255, 255, 255)",tooltipContainerFillOpacity:.95,tooltipContainerShadow:"0px 0px 10px #aeaeae",tooltipContainerBorderRadius:3,tooltipTextFillColor:r[65],tooltipTextFontSize:12,tooltipTextLineHeight:12,tooltipTextFontWeight:"bold",labelFillColor:r[65],labelFillColorDark:"#2c3542",labelFillColorLight:"#ffffff",labelFontSize:12,labelLineHeight:12,labelFontWeight:"normal",labelBorderColor:null,labelBorder:0,innerLabelFillColor:t[100],innerLabelFontSize:12,innerLabelLineHeight:12,innerLabelFontWeight:"normal",innerLabelBorderColor:null,innerLabelBorder:0,overflowLabelFillColor:r[65],overflowLabelFontSize:12,overflowLabelLineHeight:12,overflowLabelFontWeight:"normal",overflowLabelBorderColor:t[100],overflowLabelBorder:1,labelLineBorder:1,labelLineBorderColor:r[25],cSliderRailHieght:16,cSliderBackgroundFillColor:"#416180",cSliderBackgroundFillOpacity:.05,cSliderForegroundFillColor:"#5B8FF9",cSliderForegroundFillOpacity:.15,cSliderHandlerHeight:24,cSliderHandlerWidth:10,cSliderHandlerFillColor:"#F7F7F7",cSliderHandlerFillOpacity:1,cSliderHandlerHighlightFillColor:"#FFF",cSliderHandlerBorderColor:"#BFBFBF",cSliderHandlerBorder:1,cSliderHandlerBorderRadius:2,cSliderTextFillColor:"#000",cSliderTextFillOpacity:.45,cSliderTextFontSize:12,cSliderTextLineHeight:12,cSliderTextFontWeight:"normal",cSliderTextBorderColor:null,cSliderTextBorder:0,scrollbarTrackFillColor:"rgba(0,0,0,0)",scrollbarThumbFillColor:"rgba(0,0,0,0.15)",scrollbarThumbHighlightFillColor:"rgba(0,0,0,0.2)",pointFillColor:k,pointFillOpacity:.95,pointSize:4,pointBorder:1,pointBorderColor:t[100],pointBorderOpacity:1,pointActiveBorderColor:r[100],pointSelectedBorder:2,pointSelectedBorderColor:r[100],pointInactiveFillOpacity:.3,pointInactiveBorderOpacity:.3,hollowPointSize:4,hollowPointBorder:1,hollowPointBorderColor:k,hollowPointBorderOpacity:.95,hollowPointFillColor:t[100],hollowPointActiveBorder:1,hollowPointActiveBorderColor:r[100],hollowPointActiveBorderOpacity:1,hollowPointSelectedBorder:2,hollowPointSelectedBorderColor:r[100],hollowPointSelectedBorderOpacity:1,hollowPointInactiveBorderOpacity:.3,lineBorder:2,lineBorderColor:k,lineBorderOpacity:1,lineActiveBorder:3,lineSelectedBorder:3,lineInactiveBorderOpacity:.3,areaFillColor:k,areaFillOpacity:.25,areaActiveFillColor:k,areaActiveFillOpacity:.5,areaSelectedFillColor:k,areaSelectedFillOpacity:.5,areaInactiveFillOpacity:.3,hollowAreaBorderColor:k,hollowAreaBorder:2,hollowAreaBorderOpacity:1,hollowAreaActiveBorder:3,hollowAreaActiveBorderColor:r[100],hollowAreaSelectedBorder:3,hollowAreaSelectedBorderColor:r[100],hollowAreaInactiveBorderOpacity:.3,intervalFillColor:k,intervalFillOpacity:.95,intervalActiveBorder:1,intervalActiveBorderColor:r[100],intervalActiveBorderOpacity:1,intervalSelectedBorder:2,intervalSelectedBorderColor:r[100],intervalSelectedBorderOpacity:1,intervalInactiveBorderOpacity:.3,intervalInactiveFillOpacity:.3,hollowIntervalBorder:2,hollowIntervalBorderColor:k,hollowIntervalBorderOpacity:1,hollowIntervalFillColor:t[100],hollowIntervalActiveBorder:2,hollowIntervalActiveBorderColor:r[100],hollowIntervalSelectedBorder:3,hollowIntervalSelectedBorderColor:r[100],hollowIntervalSelectedBorderOpacity:1,hollowIntervalInactiveBorderOpacity:.3}};e.createLightStyleSheet=o,e.antvLight=(0,e.createLightStyleSheet)()})($1);Object.defineProperty(L1,"__esModule",{value:!0});L1.createTheme=void 0;var mot=V,xot=Y,_ot=Vp,bot=$1;function wot(e){var r=e.styleSheet,t=r===void 0?{}:r,i=(0,mot.__rest)(e,["styleSheet"]),n=(0,bot.createLightStyleSheet)(t);return(0,xot.deepMix)({},(0,_ot.createThemeByStyleSheet)(n),i)}L1.createTheme=wot;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.createTheme=void 0;var r=L1;Object.defineProperty(e,"createTheme",{enumerable:!0,get:function(){return r.createTheme}})})(NE);Object.defineProperty(Ku,"__esModule",{value:!0});var k1=Ku.registerTheme=Ku.getTheme=void 0,YA=Y,A3=NE,Cot=(0,A3.createTheme)({}),WA={default:Cot};function Sot(e){return(0,YA.get)(WA,(0,YA.lowerCase)(e),WA.default)}Ku.getTheme=Sot;function Aot(e,r){WA[(0,YA.lowerCase)(e)]=(0,A3.createTheme)(r)}k1=Ku.registerTheme=Aot;var mn={};Object.defineProperty(mn,"__esModule",{value:!0});mn.findItemsFromViewRecurisive=mn.findItemsFromView=mn.getTooltipItems=mn.findDataByPoint=void 0;var Tot=V,Ar=Y,_i=Jt,T3=Zr;function t$(e,r,t){var i=t.translate(e),n=t.translate(r);return(0,Ar.isNumberEqual)(i,n)}function Mot(e,r){var t=r.coordinate,i=r.getXScale(),n=i.range,a=n[n.length-1],o=n[0],l=t.invert(e),s=l.x;return t.isPolar&&s>(1+a)/2&&(s=o),i.translate(i.invert(s))}function e$(e,r,t){var i=t.coordinate,n=t.getYScale(),a=n.field,o=i.invert(r),l=n.invert(o.y),s=(0,Ar.find)(e,function(u){var c=u[_i.FIELD_ORIGIN];return c[a][0]<=l&&c[a][1]>=l});return s||e[e.length-1]}var Eot=(0,Ar.memoize)(function(e){if(e.isCategory)return 1;for(var r=e.values,t=r.length,i=e.translate(r[0]),n=i,a=0;a<t;a++){var o=r[a],l=e.translate(o);l<i&&(i=l),l>n&&(n=l)}return(n-i)/(t-1)});function Fot(e,r,t){var i=r.getAttribute("position"),n=i.getFields(),a=r.scales,o=(0,Ar.isFunction)(t)||!t?n[0]:t,l=a[o],s=l?l.getText(e[o]):e[o]||o;return(0,Ar.isFunction)(t)?t(s,e):s}function Oot(e){var r=(0,Ar.values)(e.attributes);return(0,Ar.filter)(r,function(t){return(0,Ar.contains)(_i.GROUP_ATTRS,t.type)})}function M3(e){for(var r=Oot(e),t,i=0,n=r;i<n.length;i++){var a=n[i],o=a.getScale(a.type);if(o&&o.isLinear){t=o;break}}var l=e.getXScale(),s=e.getYScale();return t||s||l}function Pot(e,r){var t=r.field,i=e[t];if((0,Ar.isArray)(i)){var n=i.map(function(a){return r.getText(a)});return n.join("-")}return r.getText(i)}function Iot(e,r){var t,i=r.getGroupScales();if(i.length&&(t=i[0]),t){var n=t.field;return t.getText(e[n])}var a=M3(r);return(0,T3.getName)(a)}function E3(e,r,t){if(r.length===0)return null;var i=t.type,n=t.getXScale(),a=t.getYScale(),o=n.field,l=a.field,s=null;if(i==="heatmap"||i==="point"){for(var u=t.coordinate,c=u.invert(e),f=n.invert(c.x),h=a.invert(c.y),v=1/0,d=0;d<r.length;d++){var p=r[d],x=p[_i.FIELD_ORIGIN],m=Math.pow(x[o]-f,2)+Math.pow(x[l]-h,2);m<v&&(v=m,s=p)}return s}var _=r[0],b=r[r.length-1],w=Mot(e,t),S=_[_i.FIELD_ORIGIN][o],M=_[_i.FIELD_ORIGIN][l],F=b[_i.FIELD_ORIGIN][o],O=a.isLinear&&(0,Ar.isArray)(M);if((0,Ar.isArray)(S)){for(var d=0;d<r.length;d++){var L=r[d],x=L[_i.FIELD_ORIGIN];if(n.translate(x[o][0])<=w&&n.translate(x[o][1])>=w)if(O)(0,Ar.isArray)(s)||(s=[]),s.push(L);else{s=L;break}}(0,Ar.isArray)(s)&&(s=e$(s,e,t))}else{var D=void 0;if(!n.isLinear&&n.type!=="timeCat"){for(var d=0;d<r.length;d++){var L=r[d],x=L[_i.FIELD_ORIGIN];if(t$(x[o],w,n))if(O)(0,Ar.isArray)(s)||(s=[]),s.push(L);else{s=L;break}else n.translate(x[o])<=w&&(b=L,D=r[d+1])}(0,Ar.isArray)(s)&&(s=e$(s,e,t))}else{if((w>n.translate(F)||w<n.translate(S))&&(w>n.max||w<n.min))return null;for(var k=0,H=r.length-1,B=void 0;k<=H;){B=Math.floor((k+H)/2);var j=r[B][_i.FIELD_ORIGIN][o];if(t$(j,w,n))return r[B];n.translate(j)<=n.translate(w)?(k=B+1,b=r[B],D=r[B+1]):(H===0&&(b=r[0]),H=B-1)}}b&&D&&Math.abs(n.translate(b[_i.FIELD_ORIGIN][o])-w)>Math.abs(n.translate(D[_i.FIELD_ORIGIN][o])-w)&&(b=D)}var U=Eot(t.getXScale());return!s&&Math.abs(n.translate(b[_i.FIELD_ORIGIN][o])-w)<=U/2&&(s=b),s}mn.findDataByPoint=E3;function GE(e,r,t,i){t===void 0&&(t=""),i===void 0&&(i=!1);var n=e[_i.FIELD_ORIGIN],a=Fot(n,r,t),o=r.tooltipOption,l=r.theme.defaultColor,s=[],u,c;function f(F,O){if(i||!(0,Ar.isNil)(O)&&O!==""){var L={title:a,data:n,mappingData:e,name:F,value:O,color:e.color||l,marker:!0};s.push(L)}}if((0,Ar.isObject)(o)){var h=o.fields,v=o.callback;if(v){var d=h.map(function(F){return e[_i.FIELD_ORIGIN][F]}),p=v.apply(void 0,d),x=(0,Tot.__assign)({data:e[_i.FIELD_ORIGIN],mappingData:e,title:a,color:e.color||l,marker:!0},p);s.push(x)}else for(var m=r.scales,_=0,b=h;_<b.length;_++){var w=b[_];if(!(0,Ar.isNil)(n[w])){var S=m[w];u=(0,T3.getName)(S),c=S.getText(n[w]),f(u,c)}}}else{var M=M3(r);c=Pot(n,M),u=Iot(n,r),f(u,c)}return s}mn.getTooltipItems=GE;function r$(e,r,t,i){var n=i.showNil,a=[],o=e.dataArray;if(!(0,Ar.isEmpty)(o)){e.sort(o);for(var l=0,s=o;l<s.length;l++){var u=s[l],c=E3(r,u,e);if(c){var f=e.getElementId(c),h=e.elementsMap[f];if(e.type==="heatmap"||h.visible){var v=GE(c,e,t,n);v.length&&a.push(v)}}}}return a}function i$(e,r,t,i){var n=i.showNil,a=[],o=e.container,l=o.getShape(r.x,r.y);if(l&&l.get("visible")&&l.get("origin")){var s=l.get("origin").mappingData,u=GE(s,e,t,n);u.length&&a.push(u)}return a}function XA(e,r,t){for(var i=[],n=e.geometries,a=t.shared,o=t.title,l=t.reversed,s=0,u=n;s<u.length;s++){var c=u[s];if(c.visible&&c.tooltipOption!==!1){var f=c.type,h=void 0;["point","edge","polygon"].includes(f)?h=i$(c,r,o,t):["area","line","path","heatmap"].includes(f)||a!==!1?h=r$(c,r,o,t):h=i$(c,r,o,t),h.length&&(l&&h.reverse(),i.push(h))}}return i}mn.findItemsFromView=XA;function Lot(e,r,t){for(var i=XA(e,r,t),n=0,a=e.views;n<a.length;n++){var o=a[n];i=i.concat(XA(o,r,t))}return i}mn.findItemsFromViewRecurisive=Lot;var gs={};Object.defineProperty(gs,"__esModule",{value:!0});gs.parsePadding=gs.isAutoPadding=void 0;var sm=V,UA=Y;function Dot(e){return!(0,UA.isNumber)(e)&&!(0,UA.isArray)(e)}gs.isAutoPadding=Dot;function $ot(e){e===void 0&&(e=0);var r=(0,UA.isArray)(e)?e:[e];switch(r.length){case 0:r=[0,0,0,0];break;case 1:r=new Array(4).fill(r[0]);break;case 2:r=(0,sm.__spreadArray)((0,sm.__spreadArray)([],r,!0),r,!0);break;case 3:r=(0,sm.__spreadArray)((0,sm.__spreadArray)([],r,!0),[r[1]],!1);break;default:r=r.slice(0,4);break}return r}gs.parsePadding=$ot;var xa={};Object.defineProperty(xa,"__esModule",{value:!0});xa.getComponentController=xa.getComponentControllerNames=xa.unregisterComponentController=xa.registerComponentController=void 0;var R1={};function kot(e,r){R1[e]=r}xa.registerComponentController=kot;function Rot(e){delete R1[e]}xa.unregisterComponentController=Rot;function Bot(){return Object.keys(R1)}xa.getComponentControllerNames=Bot;function Not(e){return R1[e]}xa.getComponentController=Not;var zE={};Object.defineProperty(zE,"__esModule",{value:!0});var n$=V,RC=Y,Got=Qn,zot=function(){function e(r){this.option=this.wrapperOption(r)}return e.prototype.update=function(r){return this.option=this.wrapperOption(r),this},e.prototype.hasAction=function(r){var t=this.option.actions;return(0,RC.some)(t,function(i){return i[0]===r})},e.prototype.create=function(r,t){var i=this.option,n=i.type,a=i.cfg,o=n==="theta",l=(0,n$.__assign)({start:r,end:t},a),s=(0,Got.getCoordinate)(o?"polar":n);return this.coordinate=new s(l),this.coordinate.type=n,o&&(this.hasAction("transpose")||this.transpose()),this.execActions(),this.coordinate},e.prototype.adjust=function(r,t){return this.coordinate.update({start:r,end:t}),this.coordinate.resetMatrix(),this.execActions(["scale","rotate","translate"]),this.coordinate},e.prototype.rotate=function(r){return this.option.actions.push(["rotate",r]),this},e.prototype.reflect=function(r){return this.option.actions.push(["reflect",r]),this},e.prototype.scale=function(r,t){return this.option.actions.push(["scale",r,t]),this},e.prototype.transpose=function(){return this.option.actions.push(["transpose"]),this},e.prototype.getOption=function(){return this.option},e.prototype.getCoordinate=function(){return this.coordinate},e.prototype.wrapperOption=function(r){return(0,n$.__assign)({type:"rect",actions:[],cfg:{}},r)},e.prototype.execActions=function(r){var t=this,i=this.option.actions;(0,RC.each)(i,function(n){var a,o=n[0],l=n.slice(1),s=(0,RC.isNil)(r)?!0:r.includes(o);s&&(a=t.coordinate)[o].apply(a,l)})},e}();zE.default=zot;var jp={};Object.defineProperty(jp,"__esModule",{value:!0});var Vot=Qn,jot=function(){function e(r,t,i){this.view=r,this.gEvent=t,this.data=i,this.type=t.type}return e.fromData=function(r,t,i){return new e(r,new Vot.Event(t,{}),i)},Object.defineProperty(e.prototype,"target",{get:function(){return this.gEvent.target},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"event",{get:function(){return this.gEvent.originalEvent},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"x",{get:function(){return this.gEvent.x},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"y",{get:function(){return this.gEvent.y},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"clientX",{get:function(){return this.gEvent.clientX},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"clientY",{get:function(){return this.gEvent.clientY},enumerable:!1,configurable:!0}),e.prototype.toString=function(){return"[Event (type="+this.type+")]"},e.prototype.clone=function(){return new e(this.view,this.gEvent,this.data)},e}();jp.default=jot;var VE={};Object.defineProperty(VE,"__esModule",{value:!0});function Hot(e){var r=e.getController("axis"),t=e.getController("legend"),i=e.getController("annotation"),n=e.getController("slider"),a=e.getController("scrollbar");[r,n,a,t,i].forEach(function(o){o&&o.layout()})}VE.default=Hot;var B1={};Object.defineProperty(B1,"__esModule",{value:!0});B1.ScalePool=void 0;var ja=Y,BC=Zr,Yot=function(){function e(){this.scales=new Map,this.syncScales=new Map}return e.prototype.createScale=function(r,t,i,n){var a=i,o=this.getScaleMeta(n);if(t.length===0&&o){var l=o.scale,s={type:l.type};l.isCategory&&(s.values=l.values),a=(0,ja.deepMix)(s,o.scaleDef,i)}var u=(0,BC.createScaleByField)(r,t,a);return this.cacheScale(u,i,n),u},e.prototype.sync=function(r,t){var i=this;this.syncScales.forEach(function(n,a){var o=Number.MAX_SAFE_INTEGER,l=Number.MIN_SAFE_INTEGER,s=[];(0,ja.each)(n,function(u){var c=i.getScale(u);l=(0,ja.isNumber)(c.max)?Math.max(l,c.max):l,o=(0,ja.isNumber)(c.min)?Math.min(o,c.min):o,(0,ja.each)(c.values,function(f){s.includes(f)||s.push(f)})}),(0,ja.each)(n,function(u){var c=i.getScale(u);if(c.isContinuous)c.change({min:o,max:l,values:s});else if(c.isCategory){var f=c.range,h=i.getScaleMeta(u);s&&!(0,ja.get)(h,["scaleDef","range"])&&(f=(0,BC.getDefaultCategoryScaleRange)((0,ja.deepMix)({},c,{values:s}),r,t)),c.change({values:s,range:f})}})})},e.prototype.cacheScale=function(r,t,i){var n=this.getScaleMeta(i);n&&n.scale.type===r.type?((0,BC.syncScale)(n.scale,r),n.scaleDef=t):(n={key:i,scale:r,scaleDef:t},this.scales.set(i,n));var a=this.getSyncKey(n);if(n.syncKey=a,this.removeFromSyncScales(i),a){var o=this.syncScales.get(a);o||(o=[],this.syncScales.set(a,o)),o.push(i)}},e.prototype.getScale=function(r){var t=this.getScaleMeta(r);if(!t){var i=(0,ja.last)(r.split("-")),n=this.syncScales.get(i);n&&n.length&&(t=this.getScaleMeta(n[0]))}return t&&t.scale},e.prototype.deleteScale=function(r){var t=this.getScaleMeta(r);if(t){var i=t.syncKey,n=this.syncScales.get(i);if(n&&n.length){var a=n.indexOf(r);a!==-1&&n.splice(a,1)}}this.scales.delete(r)},e.prototype.clear=function(){this.scales.clear(),this.syncScales.clear()},e.prototype.removeFromSyncScales=function(r){var t=this;this.syncScales.forEach(function(i,n){var a=i.indexOf(r);if(a!==-1)return i.splice(a,1),i.length===0&&t.syncScales.delete(n),!1})},e.prototype.getSyncKey=function(r){var t=r.scale,i=r.scaleDef,n=t.field,a=(0,ja.get)(i,["sync"]);return a===!0?n:a===!1?void 0:a},e.prototype.getScaleMeta=function(r){return this.scales.get(r)},e}();B1.ScalePool=Yot;var Hp={};Object.defineProperty(Hp,"__esModule",{value:!0});Hp.PaddingCal=void 0;var Wot=V,kn=Jt,Xot=function(){function e(r,t,i,n){r===void 0&&(r=0),t===void 0&&(t=0),i===void 0&&(i=0),n===void 0&&(n=0),this.top=r,this.right=t,this.bottom=i,this.left=n}return e.instance=function(r,t,i,n){return r===void 0&&(r=0),t===void 0&&(t=0),i===void 0&&(i=0),n===void 0&&(n=0),new e(r,t,i,n)},e.prototype.max=function(r){var t=r[0],i=r[1],n=r[2],a=r[3];return this.top=Math.max(this.top,t),this.right=Math.max(this.right,i),this.bottom=Math.max(this.bottom,n),this.left=Math.max(this.left,a),this},e.prototype.shrink=function(r){var t=r[0],i=r[1],n=r[2],a=r[3];return this.top+=t,this.right+=i,this.bottom+=n,this.left+=a,this},e.prototype.inc=function(r,t){var i=r.width,n=r.height;switch(t){case kn.DIRECTION.TOP:case kn.DIRECTION.TOP_LEFT:case kn.DIRECTION.TOP_RIGHT:this.top+=n;break;case kn.DIRECTION.RIGHT:case kn.DIRECTION.RIGHT_TOP:case kn.DIRECTION.RIGHT_BOTTOM:this.right+=i;break;case kn.DIRECTION.BOTTOM:case kn.DIRECTION.BOTTOM_LEFT:case kn.DIRECTION.BOTTOM_RIGHT:this.bottom+=n;break;case kn.DIRECTION.LEFT:case kn.DIRECTION.LEFT_TOP:case kn.DIRECTION.LEFT_BOTTOM:this.left+=i;break}return this},e.prototype.getPadding=function(){return[this.top,this.right,this.bottom,this.left]},e.prototype.clone=function(){return new(e.bind.apply(e,(0,Wot.__spreadArray)([void 0],this.getPadding(),!1)))},e}();Hp.PaddingCal=Xot;var N1={};Object.defineProperty(N1,"__esModule",{value:!0});N1.calculatePadding=void 0;var Uot=V,um=Y,Rc=Jt,NC=ti,a$=gs,GC=Hp;function qot(e){var r=e.padding;if(!(0,a$.isAutoPadding)(r))return new(GC.PaddingCal.bind.apply(GC.PaddingCal,(0,Uot.__spreadArray)([void 0],(0,a$.parsePadding)(r),!1)));var t=e.viewBBox,i=new GC.PaddingCal,n=[],a=[],o=[];return(0,um.each)(e.getComponents(),function(l){var s=l.type;s===Rc.COMPONENT_TYPE.AXIS?n.push(l):[Rc.COMPONENT_TYPE.LEGEND,Rc.COMPONENT_TYPE.SLIDER,Rc.COMPONENT_TYPE.SCROLLBAR].includes(s)?a.push(l):s!==Rc.COMPONENT_TYPE.GRID&&s!==Rc.COMPONENT_TYPE.TOOLTIP&&o.push(l)}),(0,um.each)(n,function(l){var s=l.component,u=s.getLayoutBBox(),c=new NC.BBox(u.x,u.y,u.width,u.height),f=c.exceed(t);i.max(f)}),(0,um.each)(a,function(l){var s=l.component,u=l.direction,c=s.getLayoutBBox(),f=s.get("padding"),h=new NC.BBox(c.x,c.y,c.width,c.height).expand(f);i.inc(h,u)}),(0,um.each)(o,function(l){var s=l.component,u=l.direction,c=s.getLayoutBBox(),f=new NC.BBox(c.x,c.y,c.width,c.height);i.inc(f,u)}),i}N1.calculatePadding=qot;var G1={};Object.defineProperty(G1,"__esModule",{value:!0});G1.defaultSyncViewPadding=void 0;function Zot(e,r,t){var i=t.instance();r.forEach(function(n){n.autoPadding=i.max(n.autoPadding.getPadding())})}G1.defaultSyncViewPadding=Zot;Object.defineProperty(ps,"__esModule",{value:!0});ps.registerGeometry=ps.View=void 0;var Nr=V,Tt=Y,ge=Jt,Qot=(0,Nr.__importDefault)(Bp),Kot=nx,Jot=ax,zC=Ku,o$=ti,l$=be,VC=mr,tlt=mn,elt=gs,rlt=Zr,s$=NE,u$=xa,ilt=(0,Nr.__importDefault)(zE),gv=(0,Nr.__importDefault)(jp),nlt=(0,Nr.__importDefault)(VE),alt=B1,olt=Hp,llt=N1,slt=G1,jE=function(e){(0,Nr.__extends)(r,e);function r(t){var i=e.call(this,{visible:t.visible})||this;i.views=[],i.geometries=[],i.controllers=[],i.interactions={},i.limitInPlot=!1,i.options={data:[],animate:!0},i.usedControllers=(0,u$.getComponentControllerNames)(),i.scalePool=new alt.ScalePool,i.layoutFunc=nlt.default,i.isPreMouseInPlot=!1,i.isDataChanged=!1,i.isCoordinateChanged=!1,i.createdScaleKeys=new Map,i.onCanvasEvent=function(b){var w=b.name;if(!w.includes(":")){var S=i.createViewEvent(b);i.doPlotEvent(S),i.emit(w,S)}},i.onDelegateEvents=function(b){var w=b.name;if(!!w.includes(":")){var S=i.createViewEvent(b);i.emit(w,S)}};var n=t.id,a=n===void 0?(0,Tt.uniqueId)("view"):n,o=t.parent,l=t.canvas,s=t.backgroundGroup,u=t.middleGroup,c=t.foregroundGroup,f=t.region,h=f===void 0?{start:{x:0,y:0},end:{x:1,y:1}}:f,v=t.padding,d=t.appendPadding,p=t.theme,x=t.options,m=t.limitInPlot,_=t.syncViewPadding;return i.parent=o,i.canvas=l,i.backgroundGroup=s,i.middleGroup=u,i.foregroundGroup=c,i.region=h,i.padding=v,i.appendPadding=d,i.options=(0,Nr.__assign)((0,Nr.__assign)({},i.options),x),i.limitInPlot=m,i.id=a,i.syncViewPadding=_,i.themeObject=(0,Tt.isObject)(p)?(0,Tt.deepMix)({},(0,zC.getTheme)("default"),(0,s$.createTheme)(p)):(0,zC.getTheme)(p),i.init(),i}return r.prototype.setLayout=function(t){this.layoutFunc=t},r.prototype.init=function(){this.calculateViewBBox(),this.initEvents(),this.initComponentController(),this.initOptions()},r.prototype.render=function(t,i){t===void 0&&(t=!1),this.emit(ge.VIEW_LIFE_CIRCLE.BEFORE_RENDER,gv.default.fromData(this,ge.VIEW_LIFE_CIRCLE.BEFORE_RENDER,i)),this.paint(t),this.emit(ge.VIEW_LIFE_CIRCLE.AFTER_RENDER,gv.default.fromData(this,ge.VIEW_LIFE_CIRCLE.AFTER_RENDER,i)),this.visible===!1&&this.changeVisible(!1)},r.prototype.clear=function(){var t=this;this.emit(ge.VIEW_LIFE_CIRCLE.BEFORE_CLEAR),this.filteredData=[],this.coordinateInstance=void 0,this.isDataChanged=!1,this.isCoordinateChanged=!1;for(var i=this.geometries,n=0;n<i.length;n++)i[n].clear(),i[n].container.remove(!0),i[n].labelsContainer.remove(!0);this.geometries=[];for(var a=this.controllers,n=0;n<a.length;n++)a[n].name==="annotation"?a[n].clear(!0):a[n].clear();this.createdScaleKeys.forEach(function(l,s){t.getRootView().scalePool.deleteScale(s)}),this.createdScaleKeys.clear();for(var o=this.views,n=0;n<o.length;n++)o[n].clear();this.emit(ge.VIEW_LIFE_CIRCLE.AFTER_CLEAR)},r.prototype.destroy=function(){this.emit(ge.VIEW_LIFE_CIRCLE.BEFORE_DESTROY);var t=this.interactions;(0,Tt.each)(t,function(l){l&&l.destroy()}),this.clear();for(var i=this.controllers,n=0,a=i.length;n<a;n++){var o=i[n];o.destroy()}this.backgroundGroup.remove(!0),this.middleGroup.remove(!0),this.foregroundGroup.remove(!0),e.prototype.destroy.call(this)},r.prototype.changeVisible=function(t){e.prototype.changeVisible.call(this,t);for(var i=this.geometries,n=0,a=i.length;n<a;n++){var o=i[n];o.changeVisible(t)}for(var l=this.controllers,n=0,a=l.length;n<a;n++){var s=l[n];s.changeVisible(t)}return this.foregroundGroup.set("visible",t),this.middleGroup.set("visible",t),this.backgroundGroup.set("visible",t),this.getCanvas().draw(),this},r.prototype.data=function(t){return(0,Tt.set)(this.options,"data",t),this.isDataChanged=!0,this},r.prototype.source=function(t){return console.warn("This method will be removed at G2 V4.1. Please use chart.data() instead."),this.data(t)},r.prototype.filter=function(t,i){return(0,Tt.isFunction)(i)?((0,Tt.set)(this.options,["filters",t],i),this):(!i&&(0,Tt.get)(this.options,["filters",t])&&delete this.options.filters[t],this)},r.prototype.axis=function(t,i){return(0,Tt.isBoolean)(t)?(0,Tt.set)(this.options,["axes"],t):(0,Tt.set)(this.options,["axes",t],i),this},r.prototype.legend=function(t,i){return(0,Tt.isBoolean)(t)?(0,Tt.set)(this.options,["legends"],t):(0,Tt.isString)(t)?((0,Tt.set)(this.options,["legends",t],i),(0,Tt.isPlainObject)(i)&&(i==null?void 0:i.selected)&&(0,Tt.set)(this.options,["filters",t],function(n){var a;return(a=i==null?void 0:i.selected[n])!==null&&a!==void 0?a:!0})):(0,Tt.set)(this.options,["legends"],t),this},r.prototype.scale=function(t,i){var n=this;return(0,Tt.isString)(t)?(0,Tt.set)(this.options,["scales",t],i):(0,Tt.isObject)(t)&&(0,Tt.each)(t,function(a,o){(0,Tt.set)(n.options,["scales",o],a)}),this},r.prototype.tooltip=function(t){return(0,Tt.set)(this.options,"tooltip",t),this},r.prototype.annotation=function(){return this.getController("annotation")},r.prototype.guide=function(){return console.warn("This method will be removed at G2 V4.1. Please use chart.annotation() instead."),this.annotation()},r.prototype.coordinate=function(t,i){return(0,Tt.isString)(t)?(0,Tt.set)(this.options,"coordinate",{type:t,cfg:i}):(0,Tt.set)(this.options,"coordinate",t),this.coordinateController.update(this.options.coordinate),this.coordinateController},r.prototype.coord=function(t,i){return console.warn("This method will be removed at G2 V4.1. Please use chart.coordinate() instead."),this.coordinate(t,i)},r.prototype.facet=function(t,i){this.facetInstance&&this.facetInstance.destroy();var n=(0,Kot.getFacet)(t);if(!n)throw new Error("facet '"+t+"' is not exist!");return this.facetInstance=new n(this,(0,Nr.__assign)((0,Nr.__assign)({},i),{type:t})),this},r.prototype.animate=function(t){return(0,Tt.set)(this.options,"animate",t),this},r.prototype.updateOptions=function(t){return this.clear(),(0,Tt.mix)(this.options,t),this.views.forEach(function(i){return i.destroy()}),this.views=[],this.initOptions(),this.coordinateBBox=this.viewBBox,this},r.prototype.option=function(t,i){if(r.prototype[t])throw new Error(`Can't use built in variable name "`+t+'", please change another one.');return(0,Tt.set)(this.options,t,i),this},r.prototype.theme=function(t){return this.themeObject=(0,Tt.isObject)(t)?(0,Tt.deepMix)({},this.themeObject,(0,s$.createTheme)(t)):(0,zC.getTheme)(t),this},r.prototype.interaction=function(t,i){var n=this.interactions[t];n&&n.destroy();var a=(0,Jot.createInteraction)(t,this,i);return a&&(a.init(),this.interactions[t]=a),this},r.prototype.removeInteraction=function(t){var i=this.interactions[t];i&&(i.destroy(),this.interactions[t]=void 0)},r.prototype.changeData=function(t){this.isDataChanged=!0,this.emit(ge.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_DATA,gv.default.fromData(this,ge.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_DATA,null)),this.data(t),this.paint(!0);for(var i=this.views,n=0,a=i.length;n<a;n++){var o=i[n];o.changeData(t)}this.emit(ge.VIEW_LIFE_CIRCLE.AFTER_CHANGE_DATA,gv.default.fromData(this,ge.VIEW_LIFE_CIRCLE.AFTER_CHANGE_DATA,null))},r.prototype.createView=function(t){this.parent&&this.parent.parent&&console.warn("The view nesting recursive feature will be removed at G2 V4.1. Please avoid to use it.");var i={data:this.options.data,scales:(0,Tt.clone)(this.options.scales),axes:(0,Tt.clone)(this.options.axes),coordinate:(0,Tt.clone)(this.coordinateController.getOption()),tooltip:(0,Tt.clone)(this.options.tooltip),legends:(0,Tt.clone)(this.options.legends),animate:this.options.animate,visible:this.visible},n=new r((0,Nr.__assign)((0,Nr.__assign)({parent:this,canvas:this.canvas,backgroundGroup:this.backgroundGroup.addGroup({zIndex:ge.GROUP_Z_INDEX.BG}),middleGroup:this.middleGroup.addGroup({zIndex:ge.GROUP_Z_INDEX.MID}),foregroundGroup:this.foregroundGroup.addGroup({zIndex:ge.GROUP_Z_INDEX.FORE}),theme:this.themeObject,padding:this.padding},t),{options:(0,Nr.__assign)((0,Nr.__assign)({},i),(0,Tt.get)(t,"options",{}))}));return this.views.push(n),n},r.prototype.view=function(t){return console.warn("This method will be removed at G2 V4.1. Please use chart.createView() instead."),this.createView(t)},r.prototype.removeView=function(t){var i=(0,Tt.remove)(this.views,function(n){return n===t})[0];return i&&i.destroy(),i},r.prototype.getCoordinate=function(){return this.coordinateInstance},r.prototype.getTheme=function(){return this.themeObject},r.prototype.getXScale=function(){var t=this.geometries[0];return t?t.getXScale():null},r.prototype.getYScales=function(){var t={},i=[];return this.geometries.forEach(function(n){var a=n.getYScale(),o=a.field;t[o]||(t[o]=!0,i.push(a))}),i},r.prototype.getScalesByDim=function(t){for(var i=this.geometries,n={},a=0,o=i.length;a<o;a++){var l=i[a],s=t==="x"?l.getXScale():l.getYScale();s&&!n[s.field]&&(n[s.field]=s)}return n},r.prototype.getScale=function(t,i){var n=i||this.getScaleKey(t);return this.getRootView().scalePool.getScale(n)},r.prototype.getScaleByField=function(t,i){return this.getScale(t,i)},r.prototype.getOptions=function(){return this.options},r.prototype.getData=function(){return this.filteredData},r.prototype.getOriginalData=function(){return this.options.data},r.prototype.getPadding=function(){return this.autoPadding.getPadding()},r.prototype.getGeometries=function(){return this.geometries},r.prototype.getElements=function(){return(0,Tt.reduce)(this.geometries,function(t,i){return t.concat(i.getElements())},[])},r.prototype.getElementsBy=function(t){return this.getElements().filter(function(i){return t(i)})},r.prototype.getLayer=function(t){return t===ge.LAYER.BG?this.backgroundGroup:t===ge.LAYER.MID?this.middleGroup:t===ge.LAYER.FORE?this.foregroundGroup:this.foregroundGroup},r.prototype.isPointInPlot=function(t){return(0,l$.isPointInCoordinate)(this.getCoordinate(),t)},r.prototype.getLegendAttributes=function(){return(0,Tt.flatten)(this.geometries.map(function(t){return t.getGroupAttributes()}))},r.prototype.getGroupScales=function(){var t=this.geometries.map(function(i){return i.getGroupScales()});return(0,VC.uniq)((0,Tt.flatten)(t))},r.prototype.getCanvas=function(){return this.getRootView().canvas},r.prototype.getRootView=function(){for(var t=this;;){if(t.parent){t=t.parent;continue}break}return t},r.prototype.getXY=function(t){var i=this.getCoordinate(),n=this.getScalesByDim("x"),a=this.getScalesByDim("y"),o,l;if((0,Tt.each)(t,function(s,u){n[u]&&(o=n[u].scale(s)),a[u]&&(l=a[u].scale(s))}),!(0,Tt.isNil)(o)&&!(0,Tt.isNil)(l))return i.convert({x:o,y:l})},r.prototype.getController=function(t){return(0,Tt.find)(this.controllers,function(i){return i.name===t})},r.prototype.showTooltip=function(t){var i=this.getController("tooltip");return i&&i.showTooltip(t),this},r.prototype.hideTooltip=function(){var t=this.getController("tooltip");return t&&t.hideTooltip(),this},r.prototype.lockTooltip=function(){var t=this.getController("tooltip");return t&&t.lockTooltip(),this},r.prototype.unlockTooltip=function(){var t=this.getController("tooltip");return t&&t.unlockTooltip(),this},r.prototype.isTooltipLocked=function(){var t=this.getController("tooltip");return t&&t.isTooltipLocked()},r.prototype.getTooltipItems=function(t){var i=this.getController("tooltip");return i?i.getTooltipItems(t):[]},r.prototype.getSnapRecords=function(t){for(var i=this.geometries,n=[],a=0,o=i.length;a<o;a++){var l=i[a],s=l.dataArray;l.sort(s);for(var u=void 0,c=0,f=s.length;c<f;c++){var h=s[c];u=(0,tlt.findDataByPoint)(t,h,l),u&&n.push(u)}}for(var v=this.views,a=0,o=v.length;a<o;a++){var d=v[a],p=d.getSnapRecords(t);n=n.concat(p)}return n},r.prototype.getComponents=function(){for(var t=[],i=this.controllers,n=0,a=i.length;n<a;n++){var o=i[n];t=t.concat(o.getComponents())}return t},r.prototype.filterData=function(t){var i=this.options.filters;return(0,Tt.size)(i)===0?t:(0,Tt.filter)(t,function(n,a){var o=Object.keys(i);return o.every(function(l){var s=i[l];return s(n[l],n,a)})})},r.prototype.filterFieldData=function(t,i){var n=this.options.filters,a=(0,Tt.get)(n,t);return(0,Tt.isUndefined)(a)?i:i.filter(function(o,l){return a(o[t],o,l)})},r.prototype.adjustCoordinate=function(){var t=this.getCoordinate(),i=t.start,n=t.end,a=this.coordinateBBox.bl,o=this.coordinateBBox.tr;if((0,Tt.isEqual)(i,a)&&(0,Tt.isEqual)(n,o)){this.isCoordinateChanged=!1;return}this.isCoordinateChanged=!0,this.coordinateInstance=this.coordinateController.adjust(a,o)},r.prototype.paint=function(t){this.renderDataRecursive(t),this.syncScale(),this.emit(ge.VIEW_LIFE_CIRCLE.BEFORE_PAINT),this.renderPaddingRecursive(t),this.renderLayoutRecursive(t),this.renderBackgroundStyleShape(),this.renderPaintRecursive(t),this.emit(ge.VIEW_LIFE_CIRCLE.AFTER_PAINT),this.isDataChanged=!1},r.prototype.renderBackgroundStyleShape=function(){if(!this.parent){var t=(0,Tt.get)(this.themeObject,"background");if(t){this.backgroundStyleRectShape||(this.backgroundStyleRectShape=this.backgroundGroup.addShape("rect",{attrs:{},zIndex:-1,capture:!1}),this.backgroundStyleRectShape.toBack());var i=this.viewBBox,n=i.x,a=i.y,o=i.width,l=i.height;this.backgroundStyleRectShape.attr({fill:t,x:n,y:a,width:o,height:l})}else this.backgroundStyleRectShape&&(this.backgroundStyleRectShape.remove(!0),this.backgroundStyleRectShape=void 0)}},r.prototype.renderPaddingRecursive=function(t){this.calculateViewBBox(),this.adjustCoordinate(),this.initComponents(t),this.autoPadding=(0,llt.calculatePadding)(this).shrink((0,elt.parsePadding)(this.appendPadding)),this.coordinateBBox=this.viewBBox.shrink(this.autoPadding.getPadding()),this.adjustCoordinate();for(var i=this.views,n=0,a=i.length;n<a;n++){var o=i[n];o.renderPaddingRecursive(t)}},r.prototype.renderLayoutRecursive=function(t){var i=this.syncViewPadding===!0?slt.defaultSyncViewPadding:(0,Tt.isFunction)(this.syncViewPadding)?this.syncViewPadding:void 0;i&&(i(this,this.views,olt.PaddingCal),this.views.forEach(function(s){s.coordinateBBox=s.viewBBox.shrink(s.autoPadding.getPadding()),s.adjustCoordinate()})),this.doLayout();for(var n=this.views,a=0,o=n.length;a<o;a++){var l=n[a];l.renderLayoutRecursive(t)}},r.prototype.renderPaintRecursive=function(t){var i=this.middleGroup;if(this.limitInPlot){var n=(0,l$.getCoordinateClipCfg)(this.coordinateInstance),a=n.type,o=n.attrs;i.setClip({type:a,attrs:o})}else i.setClip(void 0);this.paintGeometries(t),this.renderComponents(t);for(var l=this.views,s=0,u=l.length;s<u;s++){var c=l[s];c.renderPaintRecursive(t)}},r.prototype.createScale=function(t,i,n,a){var o=(0,Tt.get)(this.options.scales,[t]),l=(0,Nr.__assign)((0,Nr.__assign)({},o),n);return this.parent?this.parent.createScale(t,i,l,a):this.scalePool.createScale(t,i,l,a)},r.prototype.renderDataRecursive=function(t){this.doFilterData(),this.createCoordinate(),this.initGeometries(t),this.renderFacet(t);for(var i=this.views,n=0,a=i.length;n<a;n++){var o=i[n];o.renderDataRecursive(t)}},r.prototype.calculateViewBBox=function(){var t,i,n,a;if(this.parent){var o=this.parent.coordinateBBox;t=o.x,i=o.y,n=o.width,a=o.height}else t=0,i=0,n=this.canvas.get("width"),a=this.canvas.get("height");var l=this.region,s=l.start,u=l.end,c=new o$.BBox(t+n*s.x,i+a*s.y,n*(u.x-s.x),a*(u.y-s.y));(!this.viewBBox||!this.viewBBox.isEqual(c))&&(this.viewBBox=new o$.BBox(t+n*s.x,i+a*s.y,n*(u.x-s.x),a*(u.y-s.y))),this.coordinateBBox=this.viewBBox},r.prototype.initEvents=function(){this.foregroundGroup.on("*",this.onDelegateEvents),this.middleGroup.on("*",this.onDelegateEvents),this.backgroundGroup.on("*",this.onDelegateEvents),this.canvas.on("*",this.onCanvasEvent)},r.prototype.initComponentController=function(){for(var t=this.usedControllers,i=0,n=t.length;i<n;i++){var a=t[i],o=(0,u$.getComponentController)(a);o&&this.controllers.push(new o(this))}},r.prototype.createViewEvent=function(t){var i=t.shape,n=t.name,a=i?i.get("origin"):null,o=new gv.default(this,t,a);return o.type=n,o},r.prototype.doPlotEvent=function(t){var i=t.type,n=t.x,a=t.y,o={x:n,y:a},l=["mousedown","mouseup","mousemove","mouseleave","mousewheel","touchstart","touchmove","touchend","touchcancel","click","dblclick","contextmenu"];if(l.includes(i)){var s=this.isPointInPlot(o),u=t.clone();if(s){var c="plot:"+i;u.type=c,this.emit(c,u),(i==="mouseleave"||i==="touchend")&&(this.isPreMouseInPlot=!1)}i==="mousemove"||i==="touchmove"?(this.isPreMouseInPlot&&!s?(i==="mousemove"&&(u.type=ge.PLOT_EVENTS.MOUSE_LEAVE,this.emit(ge.PLOT_EVENTS.MOUSE_LEAVE,u)),u.type=ge.PLOT_EVENTS.LEAVE,this.emit(ge.PLOT_EVENTS.LEAVE,u)):!this.isPreMouseInPlot&&s&&(i==="mousemove"&&(u.type=ge.PLOT_EVENTS.MOUSE_ENTER,this.emit(ge.PLOT_EVENTS.MOUSE_ENTER,u)),u.type=ge.PLOT_EVENTS.ENTER,this.emit(ge.PLOT_EVENTS.ENTER,u)),this.isPreMouseInPlot=s):(i==="mouseleave"||i==="touchend")&&this.isPreMouseInPlot&&(i==="mouseleave"&&(u.type=ge.PLOT_EVENTS.MOUSE_LEAVE,this.emit(ge.PLOT_EVENTS.MOUSE_LEAVE,u)),u.type=ge.PLOT_EVENTS.LEAVE,this.emit(ge.PLOT_EVENTS.LEAVE,u),this.isPreMouseInPlot=!1)}},r.prototype.doFilterData=function(){var t=this.options.data;this.filteredData=this.filterData(t)},r.prototype.initGeometries=function(t){this.createOrUpdateScales();for(var i=this.getCoordinate(),n=(0,Tt.get)(this.options,"scales",{}),a=this.geometries,o=0,l=a.length;o<l;o++){var s=a[o];s.scales=this.getGeometryScales();var u={coordinate:i,scaleDefs:n,data:this.filteredData,theme:this.themeObject,isDataChanged:this.isDataChanged,isCoordinateChanged:this.isCoordinateChanged};t?s.update(u):s.init(u)}this.adjustScales()},r.prototype.createOrUpdateScales=function(){for(var t=this.getScaleFields(),i=this.getGroupedFields(),n=this.getOptions(),a=n.data,o=n.scales,l=o===void 0?{}:o,s=this.filteredData,u=0,c=t.length;u<c;u++){var f=t[u],h=l[f],v=this.getScaleKey(f);this.createScale(f,i.includes(f)?a:s,h,v),this.createdScaleKeys.set(v,!0)}},r.prototype.syncScale=function(){this.getRootView().scalePool.sync(this.getCoordinate(),this.theme)},r.prototype.getGeometryScales=function(){for(var t=this.getScaleFields(),i={},n=0;n<t.length;n++){var a=t[n];i[a]=this.getScaleByField(a)}return i},r.prototype.getScaleFields=function(){for(var t=[],i=new Map,n=this.geometries,a=0;a<n.length;a++){var o=n[a],l=o.getScaleFields();(0,VC.uniq)(l,t,i)}return t},r.prototype.getGroupedFields=function(){for(var t=[],i=new Map,n=this.geometries,a=0;a<n.length;a++){var o=n[a],l=o.getGroupFields();(0,VC.uniq)(l,t,i)}return t},r.prototype.adjustScales=function(){this.adjustCategoryScaleRange()},r.prototype.adjustCategoryScaleRange=function(){var t=this,i=(0,Nr.__spreadArray)([this.getXScale()],this.getYScales(),!0).filter(function(o){return!!o}),n=this.getCoordinate(),a=this.options.scales;(0,Tt.each)(i,function(o){var l=o.field,s=o.values,u=o.isCategory,c=o.isIdentity;(u||c)&&s&&!(0,Tt.get)(a,[l,"range"])&&(o.range=(0,rlt.getDefaultCategoryScaleRange)(o,n,t.theme))})},r.prototype.initComponents=function(t){for(var i=this.controllers,n=0;n<i.length;n++){var a=i[n];t?a.update():(a.clear(),a.render())}},r.prototype.doLayout=function(){this.layoutFunc(this)},r.prototype.createCoordinate=function(){var t=this.coordinateBBox.bl,i=this.coordinateBBox.tr;this.coordinateInstance=this.coordinateController.create(t,i)},r.prototype.paintGeometries=function(t){for(var i=this.options.animate,n=this.getCoordinate(),a={x:this.viewBBox.x,y:this.viewBBox.y,minX:this.viewBBox.minX,minY:this.viewBBox.minY,maxX:this.viewBBox.maxX,maxY:this.viewBBox.maxY,width:this.viewBBox.width,height:this.viewBBox.height},o=this.geometries,l=0;l<o.length;l++){var s=o[l];s.coordinate=n,s.canvasRegion=a,i||s.animate(!1),s.paint(t)}},r.prototype.renderComponents=function(t){for(var i=0;i<this.getComponents().length;i++){var n=this.getComponents()[i];n.component.render()}},r.prototype.renderFacet=function(t){this.facetInstance&&(t?this.facetInstance.update():(this.facetInstance.clear(),this.facetInstance.init(),this.facetInstance.render()))},r.prototype.initOptions=function(){var t=this,i=this.options,n=i.geometries,a=n===void 0?[]:n,o=i.interactions,l=o===void 0?[]:o,s=i.views,u=s===void 0?[]:s,c=i.annotations,f=c===void 0?[]:c,h=i.coordinate,v=i.events,d=i.facets;this.coordinateController?h&&this.coordinateController.update(h):this.coordinateController=new ilt.default(h);for(var p=0;p<a.length;p++){var x=a[p];this.createGeometry(x)}for(var m=0;m<l.length;m++){var _=l[m],b=_.type,w=_.cfg;this.interaction(b,w)}for(var S=0;S<u.length;S++){var M=u[S];this.createView(M)}for(var F=this.getController("annotation"),O=0;O<f.length;O++){var L=f[O];F.annotation(L)}v&&(0,Tt.each)(v,function(D,k){t.on(k,D)}),d&&(0,Tt.each)(d,function(D){var k=D.type,H=(0,Nr.__rest)(D,["type"]);t.facet(k,H)})},r.prototype.createGeometry=function(t){var i=t.type,n=t.cfg,a=n===void 0?{}:n;if(this[i]){var o=this[i](a);(0,Tt.each)(t,function(l,s){(0,Tt.isFunction)(o[s])&&o[s](l)})}},r.prototype.getScaleKey=function(t){return this.id+"-"+t},r}(Qot.default);ps.View=jE;function ult(e,r){jE.prototype[e.toLowerCase()]=function(t){t===void 0&&(t={});var i=(0,Nr.__assign)({container:this.middleGroup.addGroup(),labelsContainer:this.foregroundGroup.addGroup()},t),n=new r(i);return this.geometries.push(n),n}}ps.registerGeometry=ult;ps.default=jE;Object.defineProperty(DE,"__esModule",{value:!0});var qA=V,jC=Y,yv=Jt,clt=Qu,mv=v1,flt=(0,qA.__importDefault)(ps),hlt=function(e){(0,qA.__extends)(r,e);function r(t){var i=this,n=t.container,a=t.width,o=t.height,l=t.autoFit,s=l===void 0?!1:l,u=t.padding,c=t.appendPadding,f=t.renderer,h=f===void 0?"canvas":f,v=t.pixelRatio,d=t.localRefresh,p=d===void 0?!0:d,x=t.visible,m=x===void 0?!0:x,_=t.supportCSSTransform,b=_===void 0?!1:_,w=t.defaultInteractions,S=w===void 0?["tooltip","legend-filter","legend-active","continuous-filter","ellipsis-text"]:w,M=t.options,F=t.limitInPlot,O=t.theme,L=t.syncViewPadding,D=(0,jC.isString)(n)?document.getElementById(n):n,k=(0,mv.createDom)('<div style="position:relative;"></div>');D.appendChild(k);var H=(0,mv.getChartSize)(D,s,a,o),B=(0,clt.getEngine)(h),j=new B.Canvas((0,qA.__assign)({container:k,pixelRatio:v,localRefresh:p,supportCSSTransform:b},H));return i=e.call(this,{parent:null,canvas:j,backgroundGroup:j.addGroup({zIndex:yv.GROUP_Z_INDEX.BG}),middleGroup:j.addGroup({zIndex:yv.GROUP_Z_INDEX.MID}),foregroundGroup:j.addGroup({zIndex:yv.GROUP_Z_INDEX.FORE}),padding:u,appendPadding:c,visible:m,options:M,limitInPlot:F,theme:O,syncViewPadding:L})||this,i.onResize=(0,jC.debounce)(function(){i.forceFit()},300),i.ele=D,i.canvas=j,i.width=H.width,i.height=H.height,i.autoFit=s,i.localRefresh=p,i.renderer=h,i.wrapperElement=k,i.updateCanvasStyle(),i.bindAutoFit(),i.initDefaultInteractions(S),i}return r.prototype.initDefaultInteractions=function(t){var i=this;(0,jC.each)(t,function(n){i.interaction(n)})},r.prototype.aria=function(t){var i="aria-label";t===!1?this.ele.removeAttribute(i):this.ele.setAttribute(i,t.label)},r.prototype.changeSize=function(t,i){return this.width===t&&this.height===i?this:(this.emit(yv.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_SIZE),this.width=t,this.height=i,this.canvas.changeSize(t,i),this.render(!0),this.emit(yv.VIEW_LIFE_CIRCLE.AFTER_CHANGE_SIZE),this)},r.prototype.clear=function(){e.prototype.clear.call(this),this.aria(!1)},r.prototype.destroy=function(){e.prototype.destroy.call(this),this.unbindAutoFit(),this.canvas.destroy(),(0,mv.removeDom)(this.wrapperElement),this.wrapperElement=null},r.prototype.changeVisible=function(t){return e.prototype.changeVisible.call(this,t),this.wrapperElement.style.display=t?"":"none",this},r.prototype.forceFit=function(){if(!this.destroyed){var t=(0,mv.getChartSize)(this.ele,!0,this.width,this.height),i=t.width,n=t.height;this.changeSize(i,n)}},r.prototype.updateCanvasStyle=function(){(0,mv.modifyCSS)(this.canvas.get("el"),{display:"inline-block",verticalAlign:"middle"})},r.prototype.bindAutoFit=function(){this.autoFit&&window.addEventListener("resize",this.onResize)},r.prototype.unbindAutoFit=function(){this.autoFit&&window.removeEventListener("resize",this.onResize)},r}(flt.default);DE.default=hlt;(function(e){var r=kd&&kd.__importDefault||function(o){return o&&o.__esModule?o:{default:o}};Object.defineProperty(e,"__esModule",{value:!0}),e.registerComponentController=e.Event=e.registerGeometry=e.View=e.Chart=void 0;var t=DE;Object.defineProperty(e,"Chart",{enumerable:!0,get:function(){return r(t).default}});var i=ps;Object.defineProperty(e,"View",{enumerable:!0,get:function(){return r(i).default}}),Object.defineProperty(e,"registerGeometry",{enumerable:!0,get:function(){return i.registerGeometry}});var n=jp;Object.defineProperty(e,"Event",{enumerable:!0,get:function(){return r(n).default}});var a=xa;Object.defineProperty(e,"registerComponentController",{enumerable:!0,get:function(){return a.registerComponentController}})})(Af);var z1={};Object.defineProperty(z1,"__esModule",{value:!0});var Ua=V,Ve=Y,cm=Qn,fm=be,vlt=Se,dlt=mn,plt=ti,glt=mo,HC=(0,Ua.__importDefault)(jp);function ylt(e){for(var r=[],t=function(n){var a=e[n],o=(0,Ve.find)(r,function(l){return l.color===a.color&&l.name===a.name&&l.value===a.value&&l.title===a.title});o||r.push(a)},i=0;i<e.length;i++)t(i);return r}var mlt=function(e){(0,Ua.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.isLocked=!1,t}return Object.defineProperty(r.prototype,"name",{get:function(){return"tooltip"},enumerable:!1,configurable:!0}),r.prototype.init=function(){},r.prototype.isVisible=function(){var t=this.view.getOptions().tooltip;return t!==!1},r.prototype.render=function(){},r.prototype.showTooltip=function(t){if(this.point=t,!!this.isVisible()){var i=this.view,n=this.getTooltipItems(t);if(!n.length){this.hideTooltip();return}var a=this.getTitle(n),o={x:n[0].x,y:n[0].y};i.emit("tooltip:show",HC.default.fromData(i,"tooltip:show",(0,Ua.__assign)({items:n,title:a},t)));var l=this.getTooltipCfg(),s=l.follow,u=l.showMarkers,c=l.showCrosshairs,f=l.showContent,h=l.marker,v=this.items,d=this.title;if(!(0,Ve.isEqual)(d,a)||!(0,Ve.isEqual)(v,n)?(i.emit("tooltip:change",HC.default.fromData(i,"tooltip:change",(0,Ua.__assign)({items:n,title:a},t))),((0,Ve.isFunction)(f)?f(n):f)&&(this.tooltip||this.renderTooltip(),this.tooltip.update((0,Ve.mix)({},l,{items:this.getItemsAfterProcess(n),title:a},s?t:{})),this.tooltip.show()),u&&this.renderTooltipMarkers(n,h)):(this.tooltip&&s&&(this.tooltip.update(t),this.tooltip.show()),this.tooltipMarkersGroup&&this.tooltipMarkersGroup.show()),this.items=n,this.title=a,c){var p=(0,Ve.get)(l,["crosshairs","follow"],!1);this.renderCrosshairs(p?t:o,l)}}},r.prototype.hideTooltip=function(){var t=this.getTooltipCfg().follow;if(!t){this.point=null;return}var i=this.tooltipMarkersGroup;i&&i.hide();var n=this.xCrosshair,a=this.yCrosshair;n&&n.hide(),a&&a.hide();var o=this.tooltip;o&&o.hide(),this.view.emit("tooltip:hide",HC.default.fromData(this.view,"tooltip:hide",{})),this.point=null},r.prototype.lockTooltip=function(){this.isLocked=!0,this.tooltip&&this.tooltip.setCapture(!0)},r.prototype.unlockTooltip=function(){this.isLocked=!1;var t=this.getTooltipCfg();this.tooltip&&this.tooltip.setCapture(t.capture)},r.prototype.isTooltipLocked=function(){return this.isLocked},r.prototype.clear=function(){var t=this,i=t.tooltip,n=t.xCrosshair,a=t.yCrosshair,o=t.tooltipMarkersGroup;i&&(i.hide(),i.clear()),n&&n.clear(),a&&a.clear(),o&&o.clear(),i!=null&&i.get("customContent")&&(this.tooltip.destroy(),this.tooltip=null),this.title=null,this.items=null},r.prototype.destroy=function(){this.tooltip&&this.tooltip.destroy(),this.xCrosshair&&this.xCrosshair.destroy(),this.yCrosshair&&this.yCrosshair.destroy(),this.guideGroup&&this.guideGroup.remove(!0),this.reset()},r.prototype.reset=function(){this.items=null,this.title=null,this.tooltipMarkersGroup=null,this.tooltipCrosshairsGroup=null,this.xCrosshair=null,this.yCrosshair=null,this.tooltip=null,this.guideGroup=null,this.isLocked=!1,this.point=null},r.prototype.changeVisible=function(t){if(this.visible!==t){var i=this,n=i.tooltip,a=i.tooltipMarkersGroup,o=i.xCrosshair,l=i.yCrosshair;t?(n&&n.show(),a&&a.show(),o&&o.show(),l&&l.show()):(n&&n.hide(),a&&a.hide(),o&&o.hide(),l&&l.hide()),this.visible=t}},r.prototype.getTooltipItems=function(t){var i=this.findItemsFromView(this.view,t);if(i.length){i=(0,Ve.flatten)(i);for(var n=0,a=i;n<a.length;n++)for(var o=a[n],l=0,s=o;l<s.length;l++){var u=s[l],c=u.mappingData,f=c.x,h=c.y;u.x=(0,Ve.isArray)(f)?f[f.length-1]:f,u.y=(0,Ve.isArray)(h)?h[h.length-1]:h}var v=this.getTooltipCfg().shared;if(v===!1&&i.length>1){for(var d=i[0],p=Math.abs(t.y-d[0].y),x=0,m=i;x<m.length;x++){var _=m[x],b=Math.abs(t.y-_[0].y);b<=p&&(d=_,p=b)}i=[d]}return ylt((0,Ve.flatten)(i))}return[]},r.prototype.layout=function(){},r.prototype.update=function(){if(this.point&&this.showTooltip(this.point),this.tooltip){var t=this.view.getCanvas();this.tooltip.set("region",{start:{x:0,y:0},end:{x:t.get("width"),y:t.get("height")}})}},r.prototype.isCursorEntered=function(t){if(this.tooltip){var i=this.tooltip.getContainer(),n=this.tooltip.get("capture");if(i&&n){var a=i.getBoundingClientRect(),o=a.x,l=a.y,s=a.width,u=a.height;return new plt.BBox(o,l,s,u).isPointIn(t)}}return!1},r.prototype.getTooltipCfg=function(){var t=this.view,i=t.getOptions().tooltip,n=this.processCustomContent(i),a=t.getTheme(),o=(0,Ve.get)(a,["components","tooltip"],{}),l=(0,Ve.get)(n,"enterable",o.enterable);return(0,Ve.deepMix)({},o,n,{capture:!!(l||this.isLocked)})},r.prototype.processCustomContent=function(t){if((0,Ve.isBoolean)(t)||!(0,Ve.get)(t,"customContent"))return t;var i=t.customContent,n=function(a,o){var l=i(a,o)||"";return(0,Ve.isString)(l)?'<div class="g2-tooltip">'+l+"</div>":l};return(0,Ua.__assign)((0,Ua.__assign)({},t),{customContent:n})},r.prototype.getTitle=function(t){var i=t[0].title||t[0].name;return this.title=i,i},r.prototype.renderTooltip=function(){var t=this.view.getCanvas(),i={start:{x:0,y:0},end:{x:t.get("width"),y:t.get("height")}},n=this.getTooltipCfg(),a=new cm.HtmlTooltip((0,Ua.__assign)((0,Ua.__assign)({parent:t.get("el").parentNode,region:i},n),{visible:!1,crosshairs:null}));a.init(),this.tooltip=a},r.prototype.renderTooltipMarkers=function(t,i){for(var n=this.getTooltipMarkersGroup(),a=0,o=t;a<o.length;a++){var l=o[a],s=l.x,u=l.y,c=(0,Ua.__assign)((0,Ua.__assign)({fill:l.color,symbol:"circle",shadowColor:l.color},i),{x:s,y:u});n.addShape("marker",{attrs:c})}},r.prototype.renderCrosshairs=function(t,i){var n=(0,Ve.get)(i,["crosshairs","type"],"x");n==="x"?(this.yCrosshair&&this.yCrosshair.hide(),this.renderXCrosshairs(t,i)):n==="y"?(this.xCrosshair&&this.xCrosshair.hide(),this.renderYCrosshairs(t,i)):n==="xy"&&(this.renderXCrosshairs(t,i),this.renderYCrosshairs(t,i))},r.prototype.renderXCrosshairs=function(t,i){var n=this.getViewWithGeometry(this.view).getCoordinate();if(!!(0,fm.isPointInCoordinate)(n,t)){var a,o;if(n.isRect)n.isTransposed?(a={x:n.start.x,y:t.y},o={x:n.end.x,y:t.y}):(a={x:t.x,y:n.end.y},o={x:t.x,y:n.start.y});else{var l=(0,fm.getAngleByPoint)(n,t),s=n.getCenter(),u=n.getRadius();o=(0,vlt.polarToCartesian)(s.x,s.y,u,l),a=s}var c=(0,Ve.deepMix)({start:a,end:o,container:this.getTooltipCrosshairsGroup()},(0,Ve.get)(i,"crosshairs",{}),this.getCrosshairsText("x",t,i));delete c.type;var f=this.xCrosshair;f?f.update(c):(f=new cm.Crosshair.Line(c),f.init()),f.render(),f.show(),this.xCrosshair=f}},r.prototype.renderYCrosshairs=function(t,i){var n=this.getViewWithGeometry(this.view).getCoordinate();if(!!(0,fm.isPointInCoordinate)(n,t)){var a,o;if(n.isRect){var l=void 0,s=void 0;n.isTransposed?(l={x:t.x,y:n.end.y},s={x:t.x,y:n.start.y}):(l={x:n.start.x,y:t.y},s={x:n.end.x,y:t.y}),a={start:l,end:s},o="Line"}else a={center:n.getCenter(),radius:(0,fm.getDistanceToCenter)(n,t),startAngle:n.startAngle,endAngle:n.endAngle},o="Circle";a=(0,Ve.deepMix)({container:this.getTooltipCrosshairsGroup()},a,(0,Ve.get)(i,"crosshairs",{}),this.getCrosshairsText("y",t,i)),delete a.type;var u=this.yCrosshair;u?n.isRect&&u.get("type")==="circle"||!n.isRect&&u.get("type")==="line"?(u=new cm.Crosshair[o](a),u.init()):u.update(a):(u=new cm.Crosshair[o](a),u.init()),u.render(),u.show(),this.yCrosshair=u}},r.prototype.getCrosshairsText=function(t,i,n){var a=(0,Ve.get)(n,["crosshairs","text"]),o=(0,Ve.get)(n,["crosshairs","follow"]),l=this.items;if(a){var s=this.getViewWithGeometry(this.view),u=l[0],c=s.getXScale(),f=s.getYScales()[0],h=void 0,v=void 0;if(o){var d=this.view.getCoordinate().invert(i);h=c.invert(d.x),v=f.invert(d.y)}else h=u.data[c.field],v=u.data[f.field];var p=t==="x"?h:v;return(0,Ve.isFunction)(a)?a=a(t,p,l,i):a.content=p,{text:a}}},r.prototype.getGuideGroup=function(){if(!this.guideGroup){var t=this.view.foregroundGroup;this.guideGroup=t.addGroup({name:"tooltipGuide",capture:!1})}return this.guideGroup},r.prototype.getTooltipMarkersGroup=function(){var t=this.tooltipMarkersGroup;return t&&!t.destroyed?(t.clear(),t.show()):(t=this.getGuideGroup().addGroup({name:"tooltipMarkersGroup"}),t.toFront(),this.tooltipMarkersGroup=t),t},r.prototype.getTooltipCrosshairsGroup=function(){var t=this.tooltipCrosshairsGroup;return t||(t=this.getGuideGroup().addGroup({name:"tooltipCrosshairsGroup",capture:!1}),t.toBack(),this.tooltipCrosshairsGroup=t),t},r.prototype.findItemsFromView=function(t,i){if(t.getOptions().tooltip===!1)return[];for(var n=this.getTooltipCfg(),a=(0,dlt.findItemsFromView)(t,i,n),o=0,l=t.views;o<l.length;o++){var s=l[o];a=a.concat(this.findItemsFromView(s,i))}return a},r.prototype.getViewWithGeometry=function(t){var i=this;return t.geometries.length?t:(0,Ve.find)(t.views,function(n){return i.getViewWithGeometry(n)})},r.prototype.getItemsAfterProcess=function(t){var i=this.getTooltipCfg().customItems,n=i||function(a){return a};return n(t)},r}(glt.Controller),xlt=z1.default=mlt,Pa={},Yp={},Fh={};Object.defineProperty(Fh,"__esModule",{value:!0});Fh.BACKGROUND_SHAPE=void 0;Fh.BACKGROUND_SHAPE="element-background";Object.defineProperty(Yp,"__esModule",{value:!0});var Jc=V,ln=Y,_lt=w1,YC=cl,blt=(0,Jc.__importDefault)(Bp),wlt=Se,WC=Jt,Clt=Fh,Slt=function(e){(0,Jc.__extends)(r,e);function r(t){var i=e.call(this,t)||this;i.states=[];var n=t.shapeFactory,a=t.container,o=t.offscreenGroup,l=t.elementIndex,s=t.visible,u=s===void 0?!0:s;return i.shapeFactory=n,i.container=a,i.offscreenGroup=o,i.visible=u,i.elementIndex=l,i}return r.prototype.draw=function(t,i){i===void 0&&(i=!1),this.model=t,this.data=t.data,this.shapeType=this.getShapeType(t),this.drawShape(t,i),this.visible===!1&&this.changeVisible(!1)},r.prototype.update=function(t){var i=this,n=i.shapeFactory,a=i.shape;if(!!a){this.model=t,this.data=t.data,this.shapeType=this.getShapeType(t),this.setShapeInfo(a,t);var o=this.getOffscreenGroup(),l=n.drawShape(this.shapeType,t,o);l.cfg.data=this.data,l.cfg.origin=t,l.cfg.element=this,this.syncShapeStyle(a,l,this.getStates(),this.getAnimateCfg("update"))}},r.prototype.destroy=function(){var t=this,i=t.shapeFactory,n=t.shape;if(n){var a=this.getAnimateCfg("leave");a?(0,YC.doAnimate)(n,a,{coordinate:i.coordinate,toAttrs:(0,Jc.__assign)({},n.attr())}):n.remove(!0)}this.states=[],this.shapeFactory=void 0,this.container=void 0,this.shape=void 0,this.animate=void 0,this.geometry=void 0,this.labelShape=void 0,this.model=void 0,this.data=void 0,this.offscreenGroup=void 0,this.statesStyle=void 0,e.prototype.destroy.call(this)},r.prototype.changeVisible=function(t){e.prototype.changeVisible.call(this,t),t?(this.shape&&this.shape.show(),this.labelShape&&this.labelShape.forEach(function(i){i.show()})):(this.shape&&this.shape.hide(),this.labelShape&&this.labelShape.forEach(function(i){i.hide()}))},r.prototype.setState=function(t,i){var n=this,a=n.states,o=n.shapeFactory,l=n.model,s=n.shape,u=n.shapeType,c=a.indexOf(t);if(i){if(c>-1)return;a.push(t),(t==="active"||t==="selected")&&(s==null||s.toFront())}else{if(c===-1)return;a.splice(c,1),(t==="active"||t==="selected")&&(this.geometry.zIndexReversed?s.setZIndex(this.geometry.elements.length-this.elementIndex):s.setZIndex(this.elementIndex))}var f=o.drawShape(u,l,this.getOffscreenGroup());a.length?this.syncShapeStyle(s,f,a,null):this.syncShapeStyle(s,f,["reset"],null),f.remove(!0);var h={state:t,stateStatus:i,element:this,target:this.container};this.container.emit("statechange",h),(0,_lt.propagationDelegate)(this.shape,"statechange",h)},r.prototype.clearStates=function(){var t=this,i=this.states;(0,ln.each)(i,function(n){t.setState(n,!1)}),this.states=[]},r.prototype.hasState=function(t){return this.states.includes(t)},r.prototype.getStates=function(){return this.states},r.prototype.getData=function(){return this.data},r.prototype.getModel=function(){return this.model},r.prototype.getBBox=function(){var t=this,i=t.shape,n=t.labelShape,a={x:0,y:0,minX:0,minY:0,maxX:0,maxY:0,width:0,height:0};return i&&(a=i.getCanvasBBox()),n&&n.forEach(function(o){var l=o.getCanvasBBox();a.x=Math.min(l.x,a.x),a.y=Math.min(l.y,a.y),a.minX=Math.min(l.minX,a.minX),a.minY=Math.min(l.minY,a.minY),a.maxX=Math.max(l.maxX,a.maxX),a.maxY=Math.max(l.maxY,a.maxY)}),a.width=a.maxX-a.minX,a.height=a.maxY-a.minY,a},r.prototype.getStatesStyle=function(){if(!this.statesStyle){var t=this,i=t.shapeType,n=t.geometry,a=t.shapeFactory,o=n.stateOption,l=a.defaultShapeType,s=a.theme[i]||a.theme[l];this.statesStyle=(0,ln.deepMix)({},s,o)}return this.statesStyle},r.prototype.getStateStyle=function(t,i){var n=this.getStatesStyle(),a=(0,ln.get)(n,[t,"style"],{}),o=a[i]||a;return(0,ln.isFunction)(o)?o(this):o},r.prototype.getAnimateCfg=function(t){var i=this,n=this.animate;if(n){var a=n[t];return a&&(0,Jc.__assign)((0,Jc.__assign)({},a),{callback:function(){var o;(0,ln.isFunction)(a.callback)&&a.callback(),(o=i.geometry)===null||o===void 0||o.emit(WC.GEOMETRY_LIFE_CIRCLE.AFTER_DRAW_ANIMATE)}})}return null},r.prototype.drawShape=function(t,i){var n;i===void 0&&(i=!1);var a=this,o=a.shapeFactory,l=a.container,s=a.shapeType;if(this.shape=o.drawShape(s,t,l),this.shape){this.setShapeInfo(this.shape,t);var u=this.shape.cfg.name;u?(0,ln.isString)(u)&&(this.shape.cfg.name=["element",u]):this.shape.cfg.name=["element",this.shapeFactory.geometryType];var c=i?"enter":"appear",f=this.getAnimateCfg(c);f&&((n=this.geometry)===null||n===void 0||n.emit(WC.GEOMETRY_LIFE_CIRCLE.BEFORE_DRAW_ANIMATE),(0,YC.doAnimate)(this.shape,f,{coordinate:o.coordinate,toAttrs:(0,Jc.__assign)({},this.shape.attr())}))}},r.prototype.getOffscreenGroup=function(){if(!this.offscreenGroup){var t=this.container.getGroupBase();this.offscreenGroup=new t({})}return this.offscreenGroup},r.prototype.setShapeInfo=function(t,i){var n=this;if(t.cfg.origin=i,t.cfg.element=this,t.isGroup()){var a=t.get("children");a.forEach(function(o){n.setShapeInfo(o,i)})}},r.prototype.syncShapeStyle=function(t,i,n,a,o){var l=this,s;if(n===void 0&&(n=[]),o===void 0&&(o=0),!(!t||!i)){var u=t.get("clipShape"),c=i.get("clipShape");if(this.syncShapeStyle(u,c,n,a),t.isGroup())for(var f=t.get("children"),h=i.get("children"),v=0;v<f.length;v++)this.syncShapeStyle(f[v],h[v],n,a,o+v);else{if(!(0,ln.isEmpty)(n)&&!(0,ln.isEqual)(n,["reset"])){var d=t.get("name");(0,ln.isArray)(d)&&(d=d[1]),(0,ln.each)(n,function(x){if(i.get("name")!==Clt.BACKGROUND_SHAPE){var m=l.getStateStyle(x,d||o);i.attr(m)}})}var p=(0,wlt.getReplaceAttrs)(t,i);this.animate?a?((s=this.geometry)===null||s===void 0||s.emit(WC.GEOMETRY_LIFE_CIRCLE.BEFORE_DRAW_ANIMATE),(0,YC.doAnimate)(t,a,{coordinate:this.shapeFactory.coordinate,toAttrs:p,shapeModel:this.model})):(0,ln.isEmpty)(n)?t.attr(p):(t.stopAnimate(),t.animate(p,{duration:300})):t.attr(p)}}},r.prototype.getShapeType=function(t){var i=(0,ln.get)(t,"shape");return(0,ln.isArray)(i)?i[0]:i},r}(blt.default);Yp.default=Slt;var jn={};Object.defineProperty(jn,"__esModule",{value:!0});jn.registerGeometryLabelLayout=jn.getGeometryLabelLayout=jn.registerGeometryLabel=jn.getGeometryLabel=void 0;var F3={},O3={};function Alt(e){return F3[e.toLowerCase()]}jn.getGeometryLabel=Alt;function Tlt(e,r){F3[e.toLowerCase()]=r}jn.registerGeometryLabel=Tlt;function Mlt(e){return O3[e.toLowerCase()]}jn.getGeometryLabelLayout=Mlt;function Elt(e,r){O3[e.toLowerCase()]=r}jn.registerGeometryLabelLayout=Elt;var re={};Object.defineProperty(re,"__esModule",{value:!0});re.getShapeFactory=re.registerShape=re.registerShapeFactory=void 0;var md=V,Flt=A1,Tf=Y,c$=fc,Olt={coordinate:null,defaultShapeType:null,theme:null,getShapePoints:function(e,r){var t=this.getShape(e);return t.getPoints?t.getPoints(r):this.getDefaultPoints(r)},getShape:function(e){var r=this[e]||this[this.defaultShapeType];return r.coordinate=this.coordinate,r},getDefaultPoints:function(){return[]},getDefaultStyle:function(e){return(0,Tf.get)(e,[this.defaultShapeType,"default","style"],{})},getMarker:function(e,r){var t=this.getShape(e);if(!t.getMarker){var i=this.defaultShapeType;t=this.getShape(i)}var n=this.theme,a=(0,Tf.get)(n,[e,"default"],{}),o=t.getMarker(r);return(0,Tf.deepMix)({},a,o)},drawShape:function(e,r,t){var i=this.getShape(e);return i.draw(r,t)}},Plt={coordinate:null,parsePath:function(e){var r=this.coordinate,t=(0,Flt.parsePathString)(e);return r.isPolar?t=(0,c$.convertPolarPath)(r,t):t=(0,c$.convertNormalPath)(r,t),t},parsePoint:function(e){var r=this.coordinate;return r.convert(e)},parsePoints:function(e){var r=this.coordinate;return e.map(function(t){return r.convert(t)})},draw:function(e,r){}},HE={};function Ilt(e,r){var t=(0,Tf.upperFirst)(e),i=(0,md.__assign)((0,md.__assign)((0,md.__assign)({},Olt),r),{geometryType:e});return HE[t]=i,i}re.registerShapeFactory=Ilt;function Llt(e,r,t){var i=(0,Tf.upperFirst)(e),n=HE[i],a=(0,md.__assign)((0,md.__assign)({},Plt),t);return n[r]=a,a}re.registerShape=Llt;function Dlt(e){var r=(0,Tf.upperFirst)(e);return HE[r]}re.getShapeFactory=Dlt;var V1={};Object.defineProperty(V1,"__esModule",{value:!0});V1.group=void 0;var $lt=Y;function klt(e,r,t){if(t===void 0&&(t={}),!r)return[e];var i=(0,$lt.groupToMap)(e,r),n=[];if(r.length===1&&t[r[0]])for(var a=t[r[0]],o=0,l=a;o<l.length;o++){var s=l[o],u=i["_"+s];u&&n.push(u)}else for(var c in i)if(i.hasOwnProperty(c)){var f=i[c];n.push(f)}return n}V1.group=klt;var Wp={};Object.defineProperty(Wp,"__esModule",{value:!0});Wp.isModelChange=void 0;var f$=Y;function Rlt(e,r){return(0,f$.some)(["color","shape","size","x","y","isInCircle","data","style","defaultStyle","points","mappingData"],function(t){return!(0,f$.isEqual)(e[t],r[t])})}Wp.isModelChange=Rlt;var j1={};Object.defineProperty(j1,"__esModule",{value:!0});j1.parseFields=void 0;var Blt=Y;function Nlt(e){return(0,Blt.isArray)(e)?e:e.split("*")}j1.parseFields=Nlt;var Xp={};Object.defineProperty(Xp,"__esModule",{value:!0});Xp.diff=void 0;function Glt(e,r){for(var t=[],i=[],n=[],a=new Map,o=0;o<r.length;o++){var l=r[o];e[l]?i.push(l):t.push(l),a.set(l,!0)}return Object.keys(e).forEach(function(s){a.has(s)||n.push(s)}),{added:t,updated:i,removed:n}}Xp.diff=Glt;Object.defineProperty(Pa,"__esModule",{value:!0});var vf=V,zlt=zV,Vlt=LA,Ot=Y,h$=cl,jlt=(0,vf.__importDefault)(Bp),Ha=Jt,xv=mr,Hlt=(0,vf.__importDefault)(Yp),Ylt=jn,v$=re,Wlt=V1,Xlt=Wp,_v=j1,Ult=Xp,qlt=be;function Zlt(e,r){var t=[];return(0,Ot.each)(r,function(i,n){var a=n.split(" ")[0];a===e&&t.push(i)}),t}var Qlt=function(e){(0,vf.__extends)(r,e);function r(t){var i=e.call(this,t)||this;i.type="base",i.attributes={},i.elements=[],i.elementsMap={},i.animateOption=!0,i.attributeOption={},i.lastElementsMap={},i.generatePoints=!1,i.beforeMappingData=null,i.adjusts={},i.idFields=[],i.hasSorted=!1,i.isCoordinateChanged=!1;var n=t.container,a=t.labelsContainer,o=t.coordinate,l=t.data,s=t.sortable,u=s===void 0?!1:s,c=t.visible,f=c===void 0?!0:c,h=t.theme,v=t.scales,d=v===void 0?{}:v,p=t.scaleDefs,x=p===void 0?{}:p,m=t.intervalPadding,_=t.dodgePadding,b=t.maxColumnWidth,w=t.minColumnWidth,S=t.columnWidthRatio,M=t.roseWidthRatio,F=t.multiplePieWidthRatio,O=t.zIndexReversed;return i.container=n,i.labelsContainer=a,i.coordinate=o,i.data=l,i.sortable=u,i.visible=f,i.userTheme=h,i.scales=d,i.scaleDefs=x,i.intervalPadding=m,i.dodgePadding=_,i.maxColumnWidth=b,i.minColumnWidth=w,i.columnWidthRatio=S,i.roseWidthRatio=M,i.multiplePieWidthRatio=F,i.zIndexReversed=O,i}return r.prototype.position=function(t){var i=t;(0,Ot.isPlainObject)(t)||(i={fields:(0,_v.parseFields)(t)});var n=(0,Ot.get)(i,"fields");return n.length===1&&(n.unshift("1"),(0,Ot.set)(i,"fields",n)),(0,Ot.set)(this.attributeOption,"position",i),this},r.prototype.color=function(t,i){return this.createAttrOption("color",t,i),this},r.prototype.shape=function(t,i){return this.createAttrOption("shape",t,i),this},r.prototype.size=function(t,i){return this.createAttrOption("size",t,i),this},r.prototype.adjust=function(t){var i=t;return((0,Ot.isString)(t)||(0,Ot.isPlainObject)(t))&&(i=[t]),(0,Ot.each)(i,function(n,a){(0,Ot.isObject)(n)||(i[a]={type:n})}),this.adjustOption=i,this},r.prototype.style=function(t,i){if((0,Ot.isString)(t)){var n=(0,_v.parseFields)(t);this.styleOption={fields:n,callback:i}}else{var a=t,n=a.fields,o=a.callback,l=a.cfg;n||o||l?this.styleOption=t:this.styleOption={cfg:t}}return this},r.prototype.tooltip=function(t,i){if((0,Ot.isString)(t)){var n=(0,_v.parseFields)(t);this.tooltipOption={fields:n,callback:i}}else this.tooltipOption=t;return this},r.prototype.animate=function(t){return this.animateOption=t,this},r.prototype.label=function(t,i,n){if((0,Ot.isString)(t)){var a={},o=(0,_v.parseFields)(t);a.fields=o,(0,Ot.isFunction)(i)?a.callback=i:(0,Ot.isPlainObject)(i)&&(a.cfg=i),n&&(a.cfg=n),this.labelOption=a}else this.labelOption=t;return this},r.prototype.state=function(t){return this.stateOption=t,this},r.prototype.customInfo=function(t){return this.customOption=t,this},r.prototype.init=function(t){t===void 0&&(t={}),this.setCfg(t),this.initAttributes(),this.processData(this.data),this.adjustScale()},r.prototype.update=function(t){t===void 0&&(t={});var i=t.data,n=t.isDataChanged,a=t.isCoordinateChanged,o=this,l=o.attributeOption,s=o.lastAttributeOption;(0,Ot.isEqual)(l,s)?i&&(n||!(0,Ot.isEqual)(i,this.data))?(this.setCfg(t),this.initAttributes(),this.processData(i)):this.setCfg(t):this.init(t),this.adjustScale(),this.isCoordinateChanged=a},r.prototype.paint=function(t){t===void 0&&(t=!1),this.animateOption&&(this.animateOption=(0,Ot.deepMix)({},(0,h$.getDefaultAnimateCfg)(this.type,this.coordinate),this.animateOption)),this.defaultSize=void 0,this.elementsMap={},this.elements=[];var i=this.getOffscreenGroup();i.clear();var n=this.beforeMappingData,a=this.beforeMapping(n);this.dataArray=new Array(a.length);for(var o=0;o<a.length;o++){var l=a[o];this.dataArray[o]=this.mapping(l)}if(this.updateElements(this.dataArray,t),this.lastElementsMap=this.elementsMap,this.canDoGroupAnimation(t)){var s=this.container,u=this.type,c=this.coordinate,f=(0,Ot.get)(this.animateOption,"appear"),h=this.getYScale(),v=c.convert({x:0,y:h.scale(this.getYMinValue())});(0,h$.doGroupAppearAnimate)(s,f,u,c,v)}this.labelOption&&this.renderLabels((0,Ot.flatten)(this.dataArray),t),this.lastAttributeOption=(0,vf.__assign)({},this.attributeOption),this.visible===!1&&this.changeVisible(!1)},r.prototype.clear=function(){var t=this,i=t.container,n=t.geometryLabel,a=t.offscreenGroup;i&&i.clear(),n&&n.clear(),a&&a.clear(),this.scaleDefs=void 0,this.attributes={},this.scales={},this.elementsMap={},this.lastElementsMap={},this.elements=[],this.adjusts={},this.dataArray=null,this.beforeMappingData=null,this.lastAttributeOption=void 0,this.defaultSize=void 0,this.idFields=[],this.groupScales=void 0,this.hasSorted=!1,this.isCoordinateChanged=!1},r.prototype.destroy=function(){this.clear();var t=this.container;t.remove(!0),this.offscreenGroup&&(this.offscreenGroup.remove(!0),this.offscreenGroup=null),this.geometryLabel&&(this.geometryLabel.destroy(),this.geometryLabel=null),this.theme=void 0,this.shapeFactory=void 0,e.prototype.destroy.call(this)},r.prototype.getGroupScales=function(){return this.groupScales},r.prototype.getAttribute=function(t){return this.attributes[t]},r.prototype.getXScale=function(){return this.getAttribute("position").scales[0]},r.prototype.getYScale=function(){return this.getAttribute("position").scales[1]},r.prototype.getGroupAttributes=function(){var t=[];return(0,Ot.each)(this.attributes,function(i){Ha.GROUP_ATTRS.includes(i.type)&&t.push(i)}),t},r.prototype.getDefaultValue=function(t){var i,n=this.getAttribute(t);return n&&(0,Ot.isEmpty)(n.scales)&&(i=n.values[0]),i},r.prototype.getAttributeValues=function(t,i){for(var n=[],a=t.scales,o=0,l=a.length;o<l;o++){var s=a[o],u=s.field;s.isIdentity?n.push(s.values):n.push(i[u])}return t.mapping.apply(t,n)},r.prototype.getAdjust=function(t){return this.adjusts[t]},r.prototype.getCoordinate=function(){return this.coordinate},r.prototype.getData=function(){return this.data},r.prototype.getShapeMarker=function(t,i){var n=this.getShapeFactory();return n.getMarker(t,i)},r.prototype.getElementsBy=function(t){return this.elements.filter(function(i){return t(i)})},r.prototype.getElements=function(){return this.elements},r.prototype.getElementId=function(t){t=(0,Ot.isArray)(t)?t[0]:t;var i=t[Ha.FIELD_ORIGIN];if(this.idFields.length){for(var n=i[this.idFields[0]],a=1;a<this.idFields.length;a++)n+="-"+i[this.idFields[a]];return n}var o=this.type,l=this.getXScale(),s=this.getYScale(),u=l.field||"x",c=s.field||"y",f=i[c],h;l.type==="identity"?h=l.values[0]:h=i[u];var v;o==="interval"||o==="schema"?v=""+h:o==="line"||o==="area"||o==="path"?v=o:v=h+"-"+f;var d=this.groupScales;(0,Ot.isEmpty)(d)&&(d=(0,Ot.get)(this.getAttribute("color"),"scales",[]));for(var a=0,p=d.length;a<p;a++){var x=d[a],m=x.field;v=v+"-"+i[m]}var _=this.getAdjust("dodge");if(_){var b=_.dodgeBy;b&&(v=v+"-"+i[b])}return this.getAdjust("jitter")&&(v=v+"-"+t.x+"-"+t.y),v},r.prototype.getScaleFields=function(){var t=[],i=new Map,n=this,a=n.attributeOption,o=n.labelOption,l=n.tooltipOption;for(var s in a)if(a.hasOwnProperty(s)){var u=a[s];u.fields?(0,xv.uniq)(u.fields,t,i):u.values&&(0,xv.uniq)(u.values,t,i)}return o&&o.fields&&(0,xv.uniq)(o.fields,t,i),(0,Ot.isObject)(l)&&l.fields&&(0,xv.uniq)(l.fields,t,i),t},r.prototype.changeVisible=function(t){e.prototype.changeVisible.call(this,t);for(var i=this.elements,n=0,a=i.length;n<a;n++){var o=i[n];o.changeVisible(t)}t?(this.container&&this.container.show(),this.labelsContainer&&this.labelsContainer.show()):(this.container&&this.container.hide(),this.labelsContainer&&this.labelsContainer.hide())},r.prototype.getFields=function(){var t=new Map,i=[];return Object.values(this.attributeOption).forEach(function(n){var a=(n==null?void 0:n.fields)||[];a.forEach(function(o){t.has(o)||i.push(o),t.set(o,!0)})},[]),i},r.prototype.getGroupFields=function(){for(var t=[],i=new Map,n=0,a=Ha.GROUP_ATTRS.length;n<a;n++){var o=Ha.GROUP_ATTRS[n],l=this.attributeOption[o];l&&l.fields&&(0,xv.uniq)(l.fields,t,i)}return t},r.prototype.getXYFields=function(){var t=this.attributeOption.position.fields,i=t[0],n=t[1];return[i,n]},r.prototype.getXField=function(){return(0,Ot.get)(this.getXYFields(),[0])},r.prototype.getYField=function(){return(0,Ot.get)(this.getXYFields(),[1])},r.prototype.getShapes=function(){return this.elements.map(function(t){return t.shape})},r.prototype.getOffscreenGroup=function(){if(!this.offscreenGroup){var t=this.container.getGroupBase();this.offscreenGroup=new t({})}return this.offscreenGroup},r.prototype.sort=function(t){if(!this.hasSorted)for(var i=this.getXScale(),n=i.field,a=0;a<t.length;a++){var o=t[a];o.sort(function(l,s){return i.translate(l[Ha.FIELD_ORIGIN][n])-i.translate(s[Ha.FIELD_ORIGIN][n])})}this.hasSorted=!0},r.prototype.adjustScale=function(){var t=this.getYScale();t&&this.getAdjust("stack")&&this.updateStackRange(t,this.beforeMappingData)},r.prototype.getShapeFactory=function(){var t=this.shapeType;if(!!(0,v$.getShapeFactory)(t))return this.shapeFactory||(this.shapeFactory=(0,Ot.clone)((0,v$.getShapeFactory)(t))),this.shapeFactory.coordinate=this.coordinate,this.shapeFactory.theme=this.theme.geometries[t]||{},this.shapeFactory},r.prototype.createShapePointsCfg=function(t){var i=this.getXScale(),n=this.getYScale(),a=this.normalizeValues(t[i.field],i),o;return n?o=this.normalizeValues(t[n.field],n):o=t.y?t.y:.1,{x:a,y:o,y0:n?n.scale(this.getYMinValue()):void 0}},r.prototype.createElement=function(t,i,n){n===void 0&&(n=!1);var a=this.container,o=this.getDrawCfg(t),l=this.getShapeFactory(),s=new Hlt.default({shapeFactory:l,container:a,offscreenGroup:this.getOffscreenGroup(),elementIndex:i});return s.animate=this.animateOption,s.geometry=this,s.draw(o,n),s},r.prototype.getDrawCfg=function(t){var i=t[Ha.FIELD_ORIGIN],n={mappingData:t,data:i,x:t.x,y:t.y,color:t.color,size:t.size,isInCircle:this.coordinate.isPolar,customInfo:this.customOption},a=t.shape;!a&&this.getShapeFactory()&&(a=this.getShapeFactory().defaultShapeType),n.shape=a;var o=this.theme.geometries[this.shapeType];n.defaultStyle=(0,Ot.get)(o,[a,"default"],{}).style,!n.defaultStyle&&this.getShapeFactory()&&(n.defaultStyle=this.getShapeFactory().getDefaultStyle(o));var l=this.styleOption;return l&&(n.style=this.getStyleCfg(l,i)),this.generatePoints&&(n.points=t.points,n.nextPoints=t.nextPoints),n},r.prototype.updateElements=function(t,i){i===void 0&&(i=!1);for(var n=new Map,a=[],o=new Map,l=0,s=0;s<t.length;s++)for(var u=t[s],c=0;c<u.length;c++){var f=u[c],h=this.getElementId(f),v=n.has(h)?h+"-"+s+"-"+c:h;a.push(v),n.set(v,f),o.set(v,l),l++}this.elements=new Array(l);for(var d=(0,Ult.diff)(this.lastElementsMap,a),p=d.added,x=d.updated,m=d.removed,_=0,b=p;_<b.length;_++){var h=b[_],f=n.get(h),s=o.get(h),w=this.createElement(f,s,i);this.elements[s]=w,this.elementsMap[h]=w,w.shape&&w.shape.setZIndex(this.zIndexReversed?this.elements.length-s:s)}for(var S=0,M=x;S<M.length;S++){var h=M[S],w=this.lastElementsMap[h],f=n.get(h),F=this.getDrawCfg(f),O=w.getModel(),s=o.get(h);(this.isCoordinateChanged||(0,Xlt.isModelChange)(F,O))&&(w.animate=this.animateOption,w.update(F)),this.elements[s]=w,this.elementsMap[h]=w,w.shape&&w.shape.setZIndex(this.zIndexReversed?this.elements.length-s:s)}for(var L=0,D=m;L<D.length;L++){var h=D[L],w=this.lastElementsMap[h];w.animate=this.animateOption,w.destroy()}},r.prototype.getLabelType=function(){var t=this,i=t.labelOption,n=t.coordinate,a=t.type,o=n.type,l=n.isTransposed,s=(0,Ot.get)(i,["cfg","type"]);return s||(o==="polar"?s=l?"pie":"polar":o==="theta"?s="pie":a==="interval"||a==="polygon"?s="interval":s="base"),s},r.prototype.getYMinValue=function(){var t=this.getYScale(),i=t.min,n=t.max,a;return i>=0?a=i:n<=0?a=n:a=0,a},r.prototype.createAttrOption=function(t,i,n){if((0,Ot.isNil)(i)||(0,Ot.isObject)(i))(0,Ot.isObject)(i)&&(0,Ot.isEqual)(Object.keys(i),["values"])?(0,Ot.set)(this.attributeOption,t,{fields:i.values}):(0,Ot.set)(this.attributeOption,t,i);else{var a={};(0,Ot.isNumber)(i)?a.values=[i]:a.fields=(0,_v.parseFields)(i),n&&((0,Ot.isFunction)(n)?a.callback=n:a.values=n),(0,Ot.set)(this.attributeOption,t,a)}},r.prototype.initAttributes=function(){var t=this,i=this,n=i.attributes,a=i.attributeOption,o=i.theme,l=i.shapeType;this.groupScales=[];var s={},u=function(h){if(a.hasOwnProperty(h)){var v=a[h];if(!v)return{value:void 0};var d=(0,vf.__assign)({},v),p=d.callback,x=d.values,m=d.fields,_=m===void 0?[]:m,b=_.map(function(S){var M=t.scales[S];return M.isCategory&&!s[S]&&Ha.GROUP_ATTRS.includes(h)&&(t.groupScales.push(M),s[S]=!0),M});d.scales=b,h!=="position"&&b.length===1&&b[0].type==="identity"?d.values=b[0].values:!p&&!x&&(h==="size"?d.values=o.sizes:h==="shape"?d.values=o.shapes[l]||[]:h==="color"&&(b.length?d.values=b[0].values.length<=10?o.colors10:o.colors20:d.values=o.colors10));var w=(0,Vlt.getAttribute)(h);n[h]=new w(d)}};for(var c in a){var f=u(c);if(typeof f=="object")return f.value}},r.prototype.processData=function(t){this.hasSorted=!1;for(var i=this.getAttribute("position").scales,n=i.filter(function(S){return S.isCategory}),a=this.groupData(t),o=[],l=0,s=a.length;l<s;l++){for(var u=a[l],c=[],f=0,h=u.length;f<h;f++){var v=u[f],d={};for(var p in v)d[p]=v[p];d[Ha.FIELD_ORIGIN]=v;for(var x=0,m=n;x<m.length;x++){var _=m[x],b=_.field;d[b]=_.translate(d[b])}c.push(d)}o.push(c)}var w=this.adjustData(o);return this.beforeMappingData=w,w},r.prototype.adjustData=function(t){var i=this.adjustOption,n=this,a=n.intervalPadding,o=n.dodgePadding,l=n.theme,s=this.maxColumnWidth||l.maxColumnWidth,u=this.minColumnWidth||l.minColumnWidth,c=this.columnWidthRatio||l.columnWidthRatio,f=t;if(i){var h=this.getXScale(),v=this.getYScale(),d=h.field,p=v?v.field:null,x=(0,qlt.getXDimensionLength)(this.coordinate),m=h.values.length,_=this.getAttribute("size"),b=void 0;_&&(b=_.values[0]);for(var w=0,S=i.length;w<S;w++){var M=i[w],F=(0,vf.__assign)({xField:d,yField:p,intervalPadding:a,dodgePadding:o,xDimensionLength:x,groupNum:m,defaultSize:b,maxColumnWidth:s,minColumnWidth:u,columnWidthRatio:c},M),O=M.type;if(O==="dodge"){var L=[];if(h.isCategory||h.type==="identity")L.push("x");else if(!v)L.push("y");else throw new Error("dodge is not support linear attribute, please use category attribute!");F.adjustNames=L,F.dodgeRatio=c}else if(O==="stack"){var D=this.coordinate;if(!v){F.height=D.getHeight();var k=this.getDefaultValue("size")||3;F.size=k}!D.isTransposed&&(0,Ot.isNil)(F.reverseOrder)&&(F.reverseOrder=!0)}var H=(0,zlt.getAdjust)(O),B=new H(F);f=B.process(f),this.adjusts[O]=B}}return f},r.prototype.groupData=function(t){for(var i=this.getGroupScales(),n=this.scaleDefs,a={},o=[],l=0;l<i.length;l++){var s=i[l],u=s.field;o.push(u),(0,Ot.get)(n,[u,"values"])&&(a[u]=n[u].values)}return(0,Wlt.group)(t,o,a)},r.prototype.updateStackRange=function(t,i){for(var n=(0,Ot.flatten)(i),a=t.field,o=t.min,l=t.max,s=0;s<n.length;s++){var u=n[s],c=Math.min.apply(null,u[a]),f=Math.max.apply(null,u[a]);c<o&&(o=c),f>l&&(l=f)}var h=this.scaleDefs,v={};o<t.min&&!(0,Ot.get)(h,[a,"min"])&&(v.min=o),l>t.max&&!(0,Ot.get)(h,[a,"max"])&&(v.max=l),t.change(v)},r.prototype.beforeMapping=function(t){var i=t;if(this.sortable&&this.sort(i),this.generatePoints)for(var n=0,a=i.length;n<a;n++){var o=i[n];this.generateShapePoints(o);var l=i[n+1];l&&(this.generateShapePoints(l),o[0].nextPoints=l[0].points)}return i},r.prototype.generateShapePoints=function(t){for(var i=this.getShapeFactory(),n=this.getAttribute("shape"),a=0;a<t.length;a++){var o=t[a],l=this.createShapePointsCfg(o),s=n?this.getAttributeValues(n,o):null,u=i.getShapePoints(s,l);o.points=u}},r.prototype.normalizeValues=function(t,i){var n=[];if((0,Ot.isArray)(t))for(var a=0;a<t.length;a++){var o=t[a];n.push(i.scale(o))}else n=i.scale(t);return n},r.prototype.mapping=function(t){for(var i=this.attributes,n=[],a=0;a<t.length;a++){var o=t[a],l={_origin:o[Ha.FIELD_ORIGIN],points:o.points,nextPoints:o.nextPoints};for(var s in i)if(i.hasOwnProperty(s)){var u=i[s],c=u.names,f=this.getAttributeValues(u,o);if(c.length>1)for(var h=0;h<f.length;h+=1){var v=f[h],d=c[h];l[d]=(0,Ot.isArray)(v)&&v.length===1?v[0]:v}else l[c[0]]=f.length===1?f[0]:f}this.convertPoint(l),n.push(l)}return n},r.prototype.convertPoint=function(t){var i=t.x,n=t.y,a,o,l,s=this.coordinate;if((0,Ot.isArray)(i)&&(0,Ot.isArray)(n)){a=[],o=[];for(var u=0,c=0,f=i.length,h=n.length;u<f&&c<h;u+=1,c+=1)l=s.convert({x:i[u],y:n[c]}),a.push(l.x),o.push(l.y)}else if((0,Ot.isArray)(n)){o=[];for(var v=0;v<n.length;v++){var d=n[v];l=s.convert({x:i,y:d}),a&&a!==l.x?((0,Ot.isArray)(a)||(a=[a]),a.push(l.x)):a=l.x,o.push(l.y)}}else if((0,Ot.isArray)(i)){a=[];for(var v=0;v<i.length;v++){var p=i[v];l=s.convert({x:p,y:n}),o&&o!==l.y?((0,Ot.isArray)(o)||(o=[o]),o.push(l.y)):o=l.y,a.push(l.x)}}else{var x=s.convert({x:i,y:n});a=x.x,o=x.y}t.x=a,t.y=o},r.prototype.getStyleCfg=function(t,i){var n=t.fields,a=n===void 0?[]:n,o=t.callback,l=t.cfg;if(l)return l;var s=a.map(function(u){return i[u]});return o.apply(void 0,s)},r.prototype.setCfg=function(t){var i=this,n=t.coordinate,a=t.data,o=t.theme,l=t.scaleDefs;n&&(this.coordinate=n),a&&(this.data=a),l&&(this.scaleDefs=l,this.idFields=[],(0,Ot.each)(l,function(s,u){s&&s.key&&i.idFields.push(u)})),o&&(this.theme=this.userTheme?(0,Ot.deepMix)({},o,this.userTheme):o)},r.prototype.renderLabels=function(t,i){i===void 0&&(i=!1);var n=this.geometryLabel;if(!n){var a=this.getLabelType(),o=(0,Ylt.getGeometryLabel)(a);n=new o(this),this.geometryLabel=n}n.render(t,i);var l=n.labelsRenderer.shapesMap;(0,Ot.each)(this.elementsMap,function(s,u){var c=Zlt(u,l);if(c.length){s.labelShape=c;for(var f=0;f<c.length;f++)for(var h=c[f],v=h.getChildren(),d=0;d<v.length;d++){var p=v[d];p.cfg.name=["element","label"],p.cfg.element=s}}})},r.prototype.canDoGroupAnimation=function(t){return!t&&this.animateOption&&((0,Ot.get)(this.animateOption,"appear")===void 0||(0,Ot.get)(this.animateOption,"appear")&&(0,Ot.get)(this.animateOption,["appear","animation"])===void 0)},r}(jlt.default);Pa.default=Qlt;var Oh={},YE={},Ti={},Tr={};Object.defineProperty(Tr,"__esModule",{value:!0});Tr.zoom=Tr.getIdentityMatrix=Tr.rotate=Tr.getRotateMatrix=Tr.translate=Tr.transform=void 0;var Klt=ta,H1=Klt.ext.transform;Tr.transform=H1;function Jlt(e,r,t){var i=H1(e.getMatrix(),[["t",r,t]]);e.setMatrix(i)}Tr.translate=Jlt;function P3(e,r){var t=e.attr(),i=t.x,n=t.y,a=H1(e.getMatrix(),[["t",-i,-n],["r",r],["t",i,n]]);return a}Tr.getRotateMatrix=P3;function tst(e,r){var t=P3(e,r);e.setMatrix(t)}Tr.rotate=tst;function est(){return[1,0,0,0,1,0,0,0,1]}Tr.getIdentityMatrix=est;function rst(e,r){var t=e.getBBox(),i=(t.minX+t.maxX)/2,n=(t.minY+t.maxY)/2;e.applyToMatrix([i,n,1]);var a=H1(e.getMatrix(),[["t",-i,-n],["s",r,r],["t",i,n]]);e.setMatrix(a)}Tr.zoom=rst;Object.defineProperty(Ti,"__esModule",{value:!0});Ti.checkShapeOverlap=Ti.getOverlapArea=Ti.getlLabelBackgroundInfo=Ti.findLabelTextShape=void 0;var ZA=Y,ist=Tr;function nst(e){return e.find(function(r){return r.get("type")==="text"})}Ti.findLabelTextShape=nst;function ast(e,r,t){t===void 0&&(t=[0,0,0,0]);var i=e.getChildren()[0];if(i){var n=i.clone();r!=null&&r.rotate&&(0,ist.rotate)(n,-r.rotate);var a=n.getCanvasBBox(),o=a.x,l=a.y,s=a.width,u=a.height;n.destroy();var c=t;return(0,ZA.isNil)(c)?c=[2,2,2,2]:(0,ZA.isNumber)(c)&&(c=new Array(4).fill(c)),{x:o-c[3],y:l-c[0],width:s+c[1]+c[3],height:u+c[0]+c[2],rotation:(r==null?void 0:r.rotate)||0}}}Ti.getlLabelBackgroundInfo=ast;function I3(e,r,t){t===void 0&&(t=0);var i=Math.max(0,Math.min(e.x+e.width+t,r.x+r.width+t)-Math.max(e.x-t,r.x-t)),n=Math.max(0,Math.min(e.y+e.height+t,r.y+r.height+t)-Math.max(e.y-t,r.y-t));return i*n}Ti.getOverlapArea=I3;function ost(e,r){var t=e.getBBox();return(0,ZA.some)(r,function(i){var n=i.getBBox();return I3(t,n,2)>0})}Ti.checkShapeOverlap=ost;var Y1={};Object.defineProperty(Y1,"__esModule",{value:!0});Y1.updateLabel=void 0;var d$=Y,lst=cl,sst=Se;function L3(e,r,t){var i=t.data,n=t.origin,a=t.animateCfg,o=t.coordinate,l=(0,d$.get)(a,"update");e.set("data",i),e.set("origin",n),e.set("animateCfg",a),e.set("coordinate",o),e.set("visible",r.get("visible")),e.getChildren().forEach(function(s,u){var c=r.getChildByIndex(u);if(!c)e.removeChild(s),s.remove(!0);else{s.set("data",i),s.set("origin",n),s.set("animateCfg",a),s.set("coordinate",o);var f=(0,sst.getReplaceAttrs)(s,c);l?(0,lst.doAnimate)(s,l,{toAttrs:f,coordinate:o}):s.attr(f),c.isGroup()&&L3(s,c,t)}}),(0,d$.each)(r.getChildren(),function(s,u){u>=e.getCount()&&(s.destroyed||e.add(s))})}Y1.updateLabel=L3;Object.defineProperty(YE,"__esModule",{value:!0});var la=V,tr=Y,p$=cl,ust=jn,cst=Ti,fst=Se,g$=Tr,hst=Jt,vst=Y1,dst=function(){function e(r){this.shapesMap={},this.lastShapesMap={};var t=r.layout,i=r.container;this.layout=t,this.container=i}return e.prototype.render=function(r,t,i){var n=this;i===void 0&&(i=!1),this.shapesMap={};var a=this.container,o=this.createOffscreenGroup();if(r.length){for(var l=0,s=r;l<s.length;l++){var u=s[l];u&&this.renderLabel(u,o)}this.doLayout(r,t),this.renderLabelLine(r),this.renderLabelBackground(r),this.adjustLabel(r)}var c=this.lastShapesMap,f=this.shapesMap;(0,tr.each)(f,function(h,v){if(h.destroyed)delete f[v];else{if(c[v]){var d=h.get("data"),p=h.get("origin"),x=h.get("coordinate"),m=h.get("animateCfg"),_=c[v];(0,vst.updateLabel)(_,f[v],{data:d,origin:p,animateCfg:m,coordinate:x}),n.shapesMap[v]=_}else{a.add(h);var b=(0,tr.get)(h.get("animateCfg"),i?"enter":"appear");b&&(0,p$.doAnimate)(h,b,{toAttrs:(0,la.__assign)({},h.attr()),coordinate:h.get("coordinate")})}delete c[v]}}),(0,tr.each)(c,function(h){var v=(0,tr.get)(h.get("animateCfg"),"leave");v?(0,p$.doAnimate)(h,v,{toAttrs:null,coordinate:h.get("coordinate")}):h.remove(!0)}),this.lastShapesMap=f,o.destroy()},e.prototype.clear=function(){this.container.clear(),this.shapesMap={},this.lastShapesMap={}},e.prototype.destroy=function(){this.container.destroy(),this.shapesMap=null,this.lastShapesMap=null},e.prototype.renderLabel=function(r,t){var i=r.id,n=r.elementId,a=r.data,o=r.mappingData,l=r.coordinate,s=r.animate,u=r.content,c={id:i,elementId:n,data:a,origin:(0,la.__assign)((0,la.__assign)({},o),{data:o[hst.FIELD_ORIGIN]}),coordinate:l},f=t.addGroup((0,la.__assign)({name:"label",animateCfg:this.animate===!1||s===null||s===!1?!1:(0,tr.deepMix)({},this.animate,s)},c)),h;if(u.isGroup&&u.isGroup()||u.isShape&&u.isShape()){var v=u.getCanvasBBox(),d=v.width,p=v.height,x=(0,tr.get)(r,"textAlign","left"),m=r.x,_=r.y-p/2;x==="center"?m=m-d/2:(x==="right"||x==="end")&&(m=m-d),(0,g$.translate)(u,m,_),h=u,f.add(u)}else{var b=(0,tr.get)(r,["style","fill"]);h=f.addShape("text",(0,la.__assign)({attrs:(0,la.__assign)((0,la.__assign)({x:r.x,y:r.y,textAlign:r.textAlign,textBaseline:(0,tr.get)(r,"textBaseline","middle"),text:r.content},r.style),{fill:(0,tr.isNull)(b)?r.color:b})},c))}r.rotate&&(0,g$.rotate)(h,r.rotate),this.shapesMap[i]=f},e.prototype.doLayout=function(r,t){var i=this;if(this.layout){var n=(0,tr.isArray)(this.layout)?this.layout:[this.layout];(0,tr.each)(n,function(a){var o=(0,ust.getGeometryLabelLayout)((0,tr.get)(a,"type",""));if(o){var l=[],s=[];(0,tr.each)(i.shapesMap,function(u,c){l.push(u),s.push(t[u.get("elementId")])}),o(r,l,s,i.region,a.cfg)}})}},e.prototype.renderLabelLine=function(r){var t=this;(0,tr.each)(r,function(i){var n=(0,tr.get)(i,"coordinate");if(!(!i||!n)){var a=n.getCenter(),o=n.getRadius();if(!!i.labelLine){var l=(0,tr.get)(i,"labelLine",{}),s=i.id,u=l.path;if(!u){var c=(0,fst.polarToCartesian)(a.x,a.y,o,i.angle);u=[["M",c.x,c.y],["L",i.x,i.y]]}var f=t.shapesMap[s];f.destroyed||f.addShape("path",{capture:!1,attrs:(0,la.__assign)({path:u,stroke:i.color?i.color:(0,tr.get)(i,["style","fill"],"#000"),fill:null},l.style),id:s,origin:i.mappingData,data:i.data,coordinate:i.coordinate})}}})},e.prototype.renderLabelBackground=function(r){var t=this;(0,tr.each)(r,function(i){var n=(0,tr.get)(i,"coordinate"),a=(0,tr.get)(i,"background");if(!(!a||!n)){var o=i.id,l=t.shapesMap[o];if(!l.destroyed){var s=l.getChildren()[0];if(s){var u=(0,cst.getlLabelBackgroundInfo)(l,i,a.padding),c=u.rotation,f=(0,la.__rest)(u,["rotation"]),h=l.addShape("rect",{attrs:(0,la.__assign)((0,la.__assign)({},f),a.style||{}),id:o,origin:i.mappingData,data:i.data,coordinate:i.coordinate});if(h.setZIndex(-1),c){var v=s.getMatrix();h.setMatrix(v)}}}}})},e.prototype.createOffscreenGroup=function(){var r=this.container,t=r.getGroupBase(),i=new t({});return i},e.prototype.adjustLabel=function(r){var t=this;(0,tr.each)(r,function(i){if(i){var n=i.id,a=t.shapesMap[n];if(!a.destroyed){var o=a.findAll(function(l){return l.get("type")!=="path"});(0,tr.each)(o,function(l){l&&(i.offsetX&&l.attr("x",l.attr("x")+i.offsetX),i.offsetY&&l.attr("y",l.attr("y")+i.offsetY))})}}})},e}();YE.default=dst;Object.defineProperty(Oh,"__esModule",{value:!0});var Xv=V,Ee=Y,y$=Jt,pst=cl,gst=Se,yst=(0,Xv.__importDefault)(YE);function m$(e){var r=0;return(0,Ee.each)(e,function(t){r+=t}),r/e.length}var mst=function(){function e(r){this.geometry=r}return e.prototype.getLabelItems=function(r){var t=this,i=[],n=this.getLabelCfgs(r);return(0,Ee.each)(r,function(a,o){var l=n[o];if(!l||(0,Ee.isNil)(a.x)||(0,Ee.isNil)(a.y)){i.push(null);return}var s=(0,Ee.isArray)(l.content)?l.content:[l.content];l.content=s;var u=s.length;(0,Ee.each)(s,function(c,f){if((0,Ee.isNil)(c)||c===""){i.push(null);return}var h=(0,Xv.__assign)((0,Xv.__assign)({},l),t.getLabelPoint(l,a,f));h.textAlign||(h.textAlign=t.getLabelAlign(h,f,u)),h.offset<=0&&(h.labelLine=null),i.push(h)})}),i},e.prototype.render=function(r,t){t===void 0&&(t=!1);var i=this.getLabelItems(r),n=this.getLabelsRenderer(),a=this.getGeometryShapes();n.render(i,a,t)},e.prototype.clear=function(){var r=this.labelsRenderer;r&&r.clear()},e.prototype.destroy=function(){var r=this.labelsRenderer;r&&r.destroy(),this.labelsRenderer=null},e.prototype.getCoordinate=function(){return this.geometry.coordinate},e.prototype.getDefaultLabelCfg=function(r,t){var i=this.geometry,n=i.type,a=i.theme;return n==="polygon"||n==="interval"&&t==="middle"||r<0&&!["line","point","path"].includes(n)?(0,Ee.get)(a,"innerLabels",{}):(0,Ee.get)(a,"labels",{})},e.prototype.getThemedLabelCfg=function(r){var t=this.geometry,i=this.getDefaultLabelCfg(),n=t.type,a=t.theme,o;return n==="polygon"||r.offset<0&&!["line","point","path"].includes(n)?o=(0,Ee.deepMix)({},i,a.innerLabels,r):o=(0,Ee.deepMix)({},i,a.labels,r),o},e.prototype.setLabelPosition=function(r,t,i,n){},e.prototype.getLabelOffset=function(r){var t=this.getCoordinate(),i=this.getOffsetVector(r);return t.isTransposed?i[0]:i[1]},e.prototype.getLabelOffsetPoint=function(r,t,i){var n=r.offset,a=this.getCoordinate(),o=a.isTransposed,l=o?"x":"y",s=o?1:-1,u={x:0,y:0};return t>0||i===1?u[l]=n*s:u[l]=n*s*-1,u},e.prototype.getLabelPoint=function(r,t,i){var n=this.getCoordinate(),a=r.content.length;function o(x,m,_){_===void 0&&(_=!1);var b=x;return(0,Ee.isArray)(b)&&(r.content.length===1?_?b=m$(b):b.length<=2?b=b[x.length-1]:b=m$(b):b=b[m]),b}var l={content:r.content[i],x:0,y:0,start:{x:0,y:0},color:"#fff"},s=(0,Ee.isArray)(t.shape)?t.shape[0]:t.shape,u=s==="funnel"||s==="pyramid";if(this.geometry.type==="polygon"){var c=(0,gst.getPolygonCentroid)(t.x,t.y);l.x=c[0],l.y=c[1]}else this.geometry.type==="interval"&&!u?(l.x=o(t.x,i,!0),l.y=o(t.y,i)):(l.x=o(t.x,i),l.y=o(t.y,i));if(u){var f=(0,Ee.get)(t,"nextPoints"),h=(0,Ee.get)(t,"points");if(f){var v=n.convert(h[1]),d=n.convert(f[1]);l.x=(v.x+d.x)/2,l.y=(v.y+d.y)/2}else if(s==="pyramid"){var v=n.convert(h[1]),d=n.convert(h[2]);l.x=(v.x+d.x)/2,l.y=(v.y+d.y)/2}}r.position&&this.setLabelPosition(l,t,i,r.position);var p=this.getLabelOffsetPoint(r,i,a);return l.start={x:l.x,y:l.y},l.x+=p.x,l.y+=p.y,l.color=t.color,l},e.prototype.getLabelAlign=function(r,t,i){var n="center",a=this.getCoordinate();if(a.isTransposed){var o=r.offset;o<0?n="right":o===0?n="center":n="left",i>1&&t===0&&(n==="right"?n="left":n==="left"&&(n="right"))}return n},e.prototype.getLabelId=function(r){var t=this.geometry,i=t.type,n=t.getXScale(),a=t.getYScale(),o=r[y$.FIELD_ORIGIN],l=t.getElementId(r);return i==="line"||i==="area"?l+=" "+o[n.field]:i==="path"&&(l+=" "+o[n.field]+"-"+o[a.field]),l},e.prototype.getLabelsRenderer=function(){var r=this.geometry,t=r.labelsContainer,i=r.labelOption,n=r.canvasRegion,a=r.animateOption,o=this.geometry.coordinate,l=this.labelsRenderer;return l||(l=new yst.default({container:t,layout:(0,Ee.get)(i,["cfg","layout"],{type:this.defaultLayout})}),this.labelsRenderer=l),l.region=n,l.animate=a?(0,pst.getDefaultAnimateCfg)("label",o):!1,l},e.prototype.getLabelCfgs=function(r){var t=this,i=this.geometry,n=i.labelOption,a=i.scales,o=i.coordinate,l=n,s=l.fields,u=l.callback,c=l.cfg,f=s.map(function(v){return a[v]}),h=[];return(0,Ee.each)(r,function(v,d){var p=v[y$.FIELD_ORIGIN],x=t.getLabelText(p,f),m;if(u){var _=s.map(function(F){return p[F]});if(m=u.apply(void 0,_),(0,Ee.isNil)(m)){h.push(null);return}}var b=(0,Xv.__assign)((0,Xv.__assign)({id:t.getLabelId(v),elementId:t.geometry.getElementId(v),data:p,mappingData:v,coordinate:o},c),m);(0,Ee.isFunction)(b.position)&&(b.position=b.position(p,v,d));var w=t.getLabelOffset(b.offset||0),S=t.getDefaultLabelCfg(w,b.position);b=(0,Ee.deepMix)({},S,b),b.offset=t.getLabelOffset(b.offset||0);var M=b.content;(0,Ee.isFunction)(M)?b.content=M(p,v,d):(0,Ee.isUndefined)(M)&&(b.content=x[0]),h.push(b)}),h},e.prototype.getLabelText=function(r,t){var i=[];return(0,Ee.each)(t,function(n){var a=r[n.field];(0,Ee.isArray)(a)?a=a.map(function(o){return n.getText(o)}):a=n.getText(a),(0,Ee.isNil)(a)||a===""?i.push(null):i.push(a)}),i},e.prototype.getOffsetVector=function(r){r===void 0&&(r=0);var t=this.getCoordinate(),i=0;return(0,Ee.isNumber)(r)&&(i=r),t.isTransposed?t.applyMatrix(i,0):t.applyMatrix(0,i)},e.prototype.getGeometryShapes=function(){var r=this.geometry,t={};return(0,Ee.each)(r.elementsMap,function(i,n){t[n]=i.shape}),(0,Ee.each)(r.getOffscreenGroup().getChildren(),function(i){var n=r.getElementId(i.get("origin").mappingData);t[n]=i}),t},e}(),D3=Oh.default=mst,$3={};Object.defineProperty($3,"__esModule",{value:!0});var Up={};Object.defineProperty(Up,"__esModule",{value:!0});Up.getMappingValue=void 0;var xst=V;function _st(e,r,t){if(!e)return t;var i;if(e.callback&&e.callback.length>1){var n=Array(e.callback.length-1).fill("");i=e.mapping.apply(e,(0,xst.__spreadArray)([r],n,!1)).join("")}else i=e.mapping(r).join("");return i||t}Up.getMappingValue=_st;var _a={},Is={};Object.defineProperty(Is,"__esModule",{value:!0});Is.MarkerSymbols=void 0;Is.MarkerSymbols={hexagon:function(e,r,t){var i=t/2*Math.sqrt(3);return[["M",e,r-t],["L",e+i,r-t/2],["L",e+i,r+t/2],["L",e,r+t],["L",e-i,r+t/2],["L",e-i,r-t/2],["Z"]]},bowtie:function(e,r,t){var i=t-1.5;return[["M",e-t,r-i],["L",e+t,r+i],["L",e+t,r-i],["L",e-t,r+i],["Z"]]},cross:function(e,r,t){return[["M",e-t,r-t],["L",e+t,r+t],["M",e+t,r-t],["L",e-t,r+t]]},tick:function(e,r,t){return[["M",e-t/2,r-t],["L",e+t/2,r-t],["M",e,r-t],["L",e,r+t],["M",e-t/2,r+t],["L",e+t/2,r+t]]},plus:function(e,r,t){return[["M",e-t,r],["L",e+t,r],["M",e,r-t],["L",e,r+t]]},hyphen:function(e,r,t){return[["M",e-t,r],["L",e+t,r]]},line:function(e,r,t){return[["M",e,r-t],["L",e,r+t]]}};Object.defineProperty(_a,"__esModule",{value:!0});_a.getLegendThemeCfg=_a.getCustomLegendItems=_a.getLegendItems=_a.getLegendLayout=void 0;var x$=V,lr=Y,_$=Jt,b$=Up,bst=mr,w$=Is,wst=["line","cross","tick","plus","hyphen"];function Cst(e,r){return(0,lr.isFunction)(r)?r(e):(0,lr.deepMix)({},e,r)}function Sst(e,r){var t=e.symbol;if((0,lr.isString)(t)&&wst.indexOf(t)!==-1){var i=(0,lr.get)(e,"style",{}),n=(0,lr.get)(i,"lineWidth",1),a=i.stroke||i.fill||r;e.style=(0,lr.deepMix)({},e.style,{lineWidth:n,stroke:a,fill:null})}}function k3(e){var r=e.symbol;(0,lr.isString)(r)&&w$.MarkerSymbols[r]&&(e.symbol=w$.MarkerSymbols[r])}function Ast(e){return e.startsWith(_$.DIRECTION.LEFT)||e.startsWith(_$.DIRECTION.RIGHT)?"vertical":"horizontal"}_a.getLegendLayout=Ast;function Tst(e,r,t,i,n){var a=t.getScale(t.type);if(a.isCategory){var o=a.field,l=r.getAttribute("color"),s=r.getAttribute("shape"),u=e.getTheme().defaultColor,c=r.coordinate.isPolar;return a.getTicks().map(function(f,h){var v,d=f.text,p=f.value,x=d,m=a.invert(p),_=e.filterFieldData(o,[(v={},v[o]=m,v)]).length===0;(0,lr.each)(e.views,function(F){var O;F.filterFieldData(o,[(O={},O[o]=m,O)]).length||(_=!0)});var b=(0,b$.getMappingValue)(l,m,u),w=(0,b$.getMappingValue)(s,m,"point"),S=r.getShapeMarker(w,{color:b,isInPolar:c}),M=n;return(0,lr.isFunction)(M)&&(M=M(x,h,(0,x$.__assign)({name:x,value:m},(0,lr.deepMix)({},i,S)))),S=(0,lr.deepMix)({},i,S,(0,bst.omit)((0,x$.__assign)({},M),["style"])),Sst(S,b),M&&M.style&&(S.style=Cst(S.style,M.style)),k3(S),{id:m,name:x,value:m,marker:S,unchecked:_}})}return[]}_a.getLegendItems=Tst;function Mst(e,r,t){return t.map(function(i,n){var a=r;(0,lr.isFunction)(a)&&(a=a(i.name,n,(0,lr.deepMix)({},e,i)));var o=(0,lr.isFunction)(i.marker)?i.marker(i.name,n,(0,lr.deepMix)({},e,i)):i.marker,l=(0,lr.deepMix)({},e,a,o);return k3(l),i.marker=l,i})}_a.getCustomLegendItems=Mst;function Est(e,r){var t=(0,lr.get)(e,["components","legend"],{});return(0,lr.deepMix)({},(0,lr.get)(t,["common"],{}),(0,lr.deepMix)({},(0,lr.get)(t,[r],{})))}_a.getLegendThemeCfg=Est;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Util=e.Scale=e.Coordinate=e.DIRECTION=e.LAYER=e.getAnimation=e.registerAnimation=e.getEngine=e.registerEngine=e.registerTheme=e.getTheme=e.registerFacet=e.getFacet=e.getActionClass=e.registerAction=e.registerInteraction=e.getInteraction=e.getGeometryLabelLayout=e.getGeometryLabel=e.registerGeometryLabelLayout=e.registerGeometryLabel=e.getShapeFactory=e.registerShapeFactory=e.registerShape=e.registerGeometry=e.registerComponentController=e.InteractionAction=e.Facet=e.Action=e.Interaction=e.GeometryLabel=e.Element=e.Geometry=e.TooltipController=e.ComponentController=e.Event=e.View=e.Chart=e.VERSION=void 0;var r=V;e.VERSION="4.1.32";var t=Af;Object.defineProperty(e,"Chart",{enumerable:!0,get:function(){return t.Chart}}),Object.defineProperty(e,"View",{enumerable:!0,get:function(){return t.View}}),Object.defineProperty(e,"Event",{enumerable:!0,get:function(){return t.Event}});var i=mo;Object.defineProperty(e,"ComponentController",{enumerable:!0,get:function(){return i.Controller}});var n=z1;Object.defineProperty(e,"TooltipController",{enumerable:!0,get:function(){return(0,r.__importDefault)(n).default}});var a=Pa;Object.defineProperty(e,"Geometry",{enumerable:!0,get:function(){return(0,r.__importDefault)(a).default}});var o=Yp;Object.defineProperty(e,"Element",{enumerable:!0,get:function(){return(0,r.__importDefault)(o).default}});var l=Oh;Object.defineProperty(e,"GeometryLabel",{enumerable:!0,get:function(){return(0,r.__importDefault)(l).default}});var s=ax;Object.defineProperty(e,"Interaction",{enumerable:!0,get:function(){return s.Interaction}}),Object.defineProperty(e,"Action",{enumerable:!0,get:function(){return s.Action}});var u=nx;Object.defineProperty(e,"Facet",{enumerable:!0,get:function(){return u.Facet}});var c=Ir;Object.defineProperty(e,"InteractionAction",{enumerable:!0,get:function(){return(0,r.__importDefault)(c).default}});var f=Af;Object.defineProperty(e,"registerComponentController",{enumerable:!0,get:function(){return f.registerComponentController}});var h=Af;Object.defineProperty(e,"registerGeometry",{enumerable:!0,get:function(){return h.registerGeometry}});var v=re;Object.defineProperty(e,"registerShape",{enumerable:!0,get:function(){return v.registerShape}}),Object.defineProperty(e,"registerShapeFactory",{enumerable:!0,get:function(){return v.registerShapeFactory}}),Object.defineProperty(e,"getShapeFactory",{enumerable:!0,get:function(){return v.getShapeFactory}});var d=jn;Object.defineProperty(e,"registerGeometryLabel",{enumerable:!0,get:function(){return d.registerGeometryLabel}}),Object.defineProperty(e,"registerGeometryLabelLayout",{enumerable:!0,get:function(){return d.registerGeometryLabelLayout}}),Object.defineProperty(e,"getGeometryLabel",{enumerable:!0,get:function(){return d.getGeometryLabel}}),Object.defineProperty(e,"getGeometryLabelLayout",{enumerable:!0,get:function(){return d.getGeometryLabelLayout}});var p=ax;Object.defineProperty(e,"getInteraction",{enumerable:!0,get:function(){return p.getInteraction}}),Object.defineProperty(e,"registerInteraction",{enumerable:!0,get:function(){return p.registerInteraction}}),Object.defineProperty(e,"registerAction",{enumerable:!0,get:function(){return p.registerAction}}),Object.defineProperty(e,"getActionClass",{enumerable:!0,get:function(){return p.getActionClass}});var x=nx;Object.defineProperty(e,"getFacet",{enumerable:!0,get:function(){return x.getFacet}}),Object.defineProperty(e,"registerFacet",{enumerable:!0,get:function(){return x.registerFacet}});var m=Ku;Object.defineProperty(e,"getTheme",{enumerable:!0,get:function(){return m.getTheme}}),Object.defineProperty(e,"registerTheme",{enumerable:!0,get:function(){return m.registerTheme}});var _=Qu;Object.defineProperty(e,"registerEngine",{enumerable:!0,get:function(){return _.registerEngine}}),Object.defineProperty(e,"getEngine",{enumerable:!0,get:function(){return _.getEngine}});var b=Zu;Object.defineProperty(e,"registerAnimation",{enumerable:!0,get:function(){return b.registerAnimation}}),Object.defineProperty(e,"getAnimation",{enumerable:!0,get:function(){return b.getAnimation}});var w=Jt;Object.defineProperty(e,"LAYER",{enumerable:!0,get:function(){return w.LAYER}}),Object.defineProperty(e,"DIRECTION",{enumerable:!0,get:function(){return w.DIRECTION}}),(0,r.__importStar)($3);var S=Qn;Object.defineProperty(e,"Coordinate",{enumerable:!0,get:function(){return S.Coordinate}}),Object.defineProperty(e,"Scale",{enumerable:!0,get:function(){return S.Scale}});var M=Up,F=_a,O=Se,L=Tr,D=mn,k=xt;e.Util={getLegendItems:F.getLegendItems,translate:L.translate,rotate:L.rotate,zoom:L.zoom,transform:L.transform,getAngle:O.getAngle,getSectorPath:O.getSectorPath,polarToCartesian:O.polarToCartesian,getDelegationObject:k.getDelegationObject,getTooltipItems:D.getTooltipItems,getMappingValue:M.getMappingValue}})(ut);var R3={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.setGlobal=e.GLOBAL=void 0;var r=Y;e.GLOBAL={locale:"en-US"};function t(i){r.each(i,function(n,a){return e.GLOBAL[a]=n})}e.setGlobal=t})(R3);var df=[1,1.2,1.5,2,2.2,2.4,2.5,3,4,5,6,7.5,8,10],Fst=5,Ost=function(e){var r=e||{},t=r.tickCount,i=r.tickInterval,n=e||{},a=n.min,o=n.max;a=isNaN(a)?0:a,o=isNaN(o)?0:o;var l=t&&t>=2?t:Fst,s=i||Ist({tickCount:l,max:o,min:a}),u=Math.floor(a/s)*s;if(i){var c=Math.abs(Math.ceil((o-u)/i))+1;l=Math.max(l,c)}for(var f=[],h=0,v=QA(s);h<l;)f.push(N3(u+h*s,v)),h++;return f},Pst=12;function C$(e){e=Math.abs(e);var r=1;if(e===0)return r;if(e<1){for(var t=0;e<1;)r=r/10,e=e*10,t++;return r.toString().length>Pst&&(r=parseFloat(r.toFixed(t))),r}for(;e>10;)r=r*10,e=e/10;return r}function Ist(e){var r=e.tickCount,t=e.min,i=e.max;if(t===i)return 1*C$(i);for(var n=(i-t)/(r-1),a=C$(n),o=n/a,l=i/a,s=t/a,u=0,c=0;c<df.length;c++){var f=df[c];if(o<=f){u=c;break}}var h=B3(u,r,s,l),v=QA(h)+QA(a);return N3(h*a,v)}function B3(e,r,t,i){for(var n=!1,a=df[e],o=e;o<df.length;o++)if(Lst({interval:df[o],tickCount:r,max:i,min:t})){a=df[o],n=!0;break}return n?a:10*B3(0,r,t/10,i/10)}function Lst(e){var r=e.interval,t=e.tickCount,i=e.max,n=e.min,a=Math.floor(n/r)*r;return a+(t-1)*r>=i}function QA(e){var r=e.toString(),t=r.indexOf("."),i=r.indexOf("e-"),n=i>=0?parseInt(r.substr(i+2),10):r.substr(t+1).length;return n>20&&(n=20),n}function N3(e,r){return parseFloat(e.toFixed(r))}var Dst=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}();Kn("linear-strict-tick-method",Ost);var $st=function(e){Dst(r,e);function r(t){var i=e.call(this,t)||this;return i.type="linear-strict",i}return r.prototype.initCfg=function(){e.prototype.initCfg.call(this),this.tickMethod="linear-strict-tick-method"},r.prototype.calculateTicks=function(){var t=this.nice;this.nice=!0;var i=e.prototype.calculateTicks.call(this);return this.nice=t,i.length&&(this.min=i[0],this.max=i[i.length-1]),i},r}(Ah);zd("linear-strict")||Jn("linear-strict",$st);var jf={};Object.defineProperty(jf,"__esModule",{value:!0});var G3=jf.fadeOut=z3=jf.fadeIn=void 0,XC=Y;function kst(e,r,t){var i={fillOpacity:(0,XC.isNil)(e.attr("fillOpacity"))?1:e.attr("fillOpacity"),strokeOpacity:(0,XC.isNil)(e.attr("strokeOpacity"))?1:e.attr("strokeOpacity"),opacity:(0,XC.isNil)(e.attr("opacity"))?1:e.attr("opacity")};e.attr({fillOpacity:0,strokeOpacity:0,opacity:0}),e.animate(i,r)}var z3=jf.fadeIn=kst;function Rst(e,r,t){var i={fillOpacity:0,strokeOpacity:0,opacity:0},n=r.easing,a=r.duration,o=r.delay;e.animate(i,a,n,function(){e.remove(!0)},o)}G3=jf.fadeOut=Rst;var Jl={},Hf={};Object.defineProperty(Hf,"__esModule",{value:!0});Hf.doScaleAnimate=Hf.transformShape=void 0;var Bc=ta;function V3(e,r,t){var i,n=r[0],a=r[1];return e.applyToMatrix([n,a,1]),t==="x"?(e.setMatrix(Bc.ext.transform(e.getMatrix(),[["t",-n,-a],["s",.01,1],["t",n,a]])),i=Bc.ext.transform(e.getMatrix(),[["t",-n,-a],["s",100,1],["t",n,a]])):t==="y"?(e.setMatrix(Bc.ext.transform(e.getMatrix(),[["t",-n,-a],["s",1,.01],["t",n,a]])),i=Bc.ext.transform(e.getMatrix(),[["t",-n,-a],["s",1,100],["t",n,a]])):t==="xy"&&(e.setMatrix(Bc.ext.transform(e.getMatrix(),[["t",-n,-a],["s",.01,.01],["t",n,a]])),i=Bc.ext.transform(e.getMatrix(),[["t",-n,-a],["s",100,100],["t",n,a]])),i}Hf.transformShape=V3;function Bst(e,r,t,i,n){var a=t.start,o=t.end,l=t.getWidth(),s=t.getHeight(),u,c;n==="y"?(u=a.x+l/2,c=i.y<a.y?i.y:a.y):n==="x"?(u=i.x>a.x?i.x:a.x,c=a.y+s/2):n==="xy"&&(t.isPolar?(u=t.getCenter().x,c=t.getCenter().y):(u=(a.x+o.x)/2,c=(a.y+o.y)/2));var f=V3(e,[u,c],n);e.animate({matrix:f},r)}Hf.doScaleAnimate=Bst;Object.defineProperty(Jl,"__esModule",{value:!0});var j3=Jl.growInXY=Y3=Jl.growInY=H3=Jl.growInX=void 0,WE=Hf;function Nst(e,r,t){var i=t.coordinate,n=t.minYPoint;(0,WE.doScaleAnimate)(e,r,i,n,"x")}var H3=Jl.growInX=Nst;function Gst(e,r,t){var i=t.coordinate,n=t.minYPoint;(0,WE.doScaleAnimate)(e,r,i,n,"y")}var Y3=Jl.growInY=Gst;function zst(e,r,t){var i=t.coordinate,n=t.minYPoint;(0,WE.doScaleAnimate)(e,r,i,n,"xy")}j3=Jl.growInXY=zst;var W1={};Object.defineProperty(W1,"__esModule",{value:!0});var XE=W1.pathIn=void 0;function Vst(e,r,t){var i=e.getTotalLength();e.attr("lineDash",[i]),e.animate(function(n){return{lineDashOffset:(1-n)*i}},r)}XE=W1.pathIn=Vst;var X1={};Object.defineProperty(X1,"__esModule",{value:!0});var W3=X1.positionUpdate=void 0;function jst(e,r,t){var i=t.toAttrs,n=i.x,a=i.y;delete i.x,delete i.y,e.attr(i),e.animate({x:n,y:a},r)}W3=X1.positionUpdate=jst;var Yf={};Object.defineProperty(Yf,"__esModule",{value:!0});var X3=Yf.scaleInY=U3=Yf.scaleInX=void 0,ox=ta;function Hst(e,r,t){var i=e.getBBox(),n=e.get("origin").mappingData,a=n.points,o=a[0].y-a[1].y>0?i.maxX:i.minX,l=(i.minY+i.maxY)/2;e.applyToMatrix([o,l,1]);var s=ox.ext.transform(e.getMatrix(),[["t",-o,-l],["s",.01,1],["t",o,l]]);e.setMatrix(s),e.animate({matrix:ox.ext.transform(e.getMatrix(),[["t",-o,-l],["s",100,1],["t",o,l]])},r)}var U3=Yf.scaleInX=Hst;function Yst(e,r,t){var i=e.getBBox(),n=e.get("origin").mappingData,a=(i.minX+i.maxX)/2,o=n.points,l=o[0].y-o[1].y<=0?i.maxY:i.minY;e.applyToMatrix([a,l,1]);var s=ox.ext.transform(e.getMatrix(),[["t",-a,-l],["s",1,.01],["t",a,l]]);e.setMatrix(s),e.animate({matrix:ox.ext.transform(e.getMatrix(),[["t",-a,-l],["s",1,100],["t",a,l]])},r)}X3=Yf.scaleInY=Yst;var U1={};function Wst(){return window?window.devicePixelRatio:1}function q3(e,r,t,i){var n=e-t,a=r-i;return Math.sqrt(n*n+a*a)}function Tu(e,r,t,i,n,a){return n>=e&&n<=e+t&&a>=r&&a<=r+i}function Wd(e,r){return!(r.minX>e.maxX||r.maxX<e.minX||r.minY>e.maxY||r.maxY<e.minY)}function Xst(e,r){return!e||!r?e||r:{minX:Math.min(e.minX,r.minX),minY:Math.min(e.minY,r.minY),maxX:Math.max(e.maxX,r.maxX),maxY:Math.max(e.maxY,r.maxY)}}function S$(e,r){return e[0]===r[0]&&e[1]===r[1]}var Ust=/^l\s*\(\s*([\d.]+)\s*\)\s*(.*)/i,qst=/^r\s*\(\s*([\d.]+)\s*,\s*([\d.]+)\s*,\s*([\d.]+)\s*\)\s*(.*)/i,Zst=/^p\s*\(\s*([axyn])\s*\)\s*(.*)/i,Z3=/[\d.]+:(#[^\s]+|[^\)]+\))/gi;function Q3(e,r){var t=e.match(Z3);P(t,function(i){var n=i.split(":");r.addColorStop(n[0],n[1])})}function Qst(e,r,t){var i=Ust.exec(t),n=parseFloat(i[1])%360*(Math.PI/180),a=i[2],o=r.getBBox(),l,s;n>=0&&n<1/2*Math.PI?(l={x:o.minX,y:o.minY},s={x:o.maxX,y:o.maxY}):1/2*Math.PI<=n&&n<Math.PI?(l={x:o.maxX,y:o.minY},s={x:o.minX,y:o.maxY}):Math.PI<=n&&n<3/2*Math.PI?(l={x:o.maxX,y:o.maxY},s={x:o.minX,y:o.minY}):(l={x:o.minX,y:o.maxY},s={x:o.maxX,y:o.minY});var u=Math.tan(n),c=u*u,f=(s.x-l.x+u*(s.y-l.y))/(c+1)+l.x,h=u*(s.x-l.x+u*(s.y-l.y))/(c+1)+l.y,v=e.createLinearGradient(l.x,l.y,f,h);return Q3(a,v),v}function Kst(e,r,t){var i=qst.exec(t),n=parseFloat(i[1]),a=parseFloat(i[2]),o=parseFloat(i[3]),l=i[4];if(o===0){var s=l.match(Z3);return s[s.length-1].split(":")[1]}var u=r.getBBox(),c=u.maxX-u.minX,f=u.maxY-u.minY,h=Math.sqrt(c*c+f*f)/2,v=e.createRadialGradient(u.minX+c*n,u.minY+f*a,0,u.minX+c/2,u.minY+f/2,o*h);return Q3(l,v),v}function Jst(e,r,t){if(r.get("patternSource")&&r.get("patternSource")===t)return r.get("pattern");var i,n,a=Zst.exec(t),o=a[1],l=a[2];function s(){i=e.createPattern(n,o),r.set("pattern",i),r.set("patternSource",t)}switch(o){case"a":o="repeat";break;case"x":o="repeat-x";break;case"y":o="repeat-y";break;case"n":o="no-repeat";break;default:o="no-repeat"}return n=new Image,l.match(/^data:/i)||(n.crossOrigin="Anonymous"),n.src=l,n.complete?s():(n.onload=s,n.src=n.src),i}function tut(e,r,t){var i=r.getBBox();if(isNaN(i.x)||isNaN(i.y)||isNaN(i.width)||isNaN(i.height))return t;if(Ct(t)){if(t[1]==="("||t[2]==="("){if(t[0]==="l")return Qst(e,r,t);if(t[0]==="r")return Kst(e,r,t);if(t[0]==="p")return Jst(e,r,t)}return t}if(t instanceof CanvasPattern)return t}function eut(e){var r=0,t=0,i=0,n=0;return it(e)?e.length===1?r=t=i=n=e[0]:e.length===2?(r=i=e[0],t=n=e[1]):e.length===3?(r=e[0],t=n=e[1],i=e[2]):(r=e[0],t=e[1],i=e[2],n=e[3]):r=t=i=n=e,[r,t,i,n]}function hm(e){return Math.sqrt(e[0]*e[0]+e[1]*e[1])}function KA(e,r){return hm(e)*hm(r)?(e[0]*r[0]+e[1]*r[1])/(hm(e)*hm(r)):1}function A$(e,r){return(e[0]*r[1]<e[1]*r[0]?-1:1)*Math.acos(KA(e,r))}function lx(e,r){var t=r[1],i=r[2],n=Kx(Jx(r[3]),Math.PI*2),a=r[4],o=r[5],l=e[0],s=e[1],u=r[6],c=r[7],f=Math.cos(n)*(l-u)/2+Math.sin(n)*(s-c)/2,h=-1*Math.sin(n)*(l-u)/2+Math.cos(n)*(s-c)/2,v=f*f/(t*t)+h*h/(i*i);v>1&&(t*=Math.sqrt(v),i*=Math.sqrt(v));var d=t*t*(h*h)+i*i*(f*f),p=d?Math.sqrt((t*t*(i*i)-d)/d):1;a===o&&(p*=-1),isNaN(p)&&(p=0);var x=i?p*t*h/i:0,m=t?p*-i*f/t:0,_=(l+u)/2+Math.cos(n)*x-Math.sin(n)*m,b=(s+c)/2+Math.sin(n)*x+Math.cos(n)*m,w=[(f-x)/t,(h-m)/i],S=[(-1*f-x)/t,(-1*h-m)/i],M=A$([1,0],w),F=A$(w,S);return KA(w,S)<=-1&&(F=Math.PI),KA(w,S)>=1&&(F=0),o===0&&F>0&&(F=F-2*Math.PI),o===1&&F<0&&(F=F+2*Math.PI),{cx:_,cy:b,rx:S$(e,[u,c])?0:t,ry:S$(e,[u,c])?0:i,startAngle:M,endAngle:M+F,xRotation:n,arcFlag:a,sweepFlag:o}}var sx=Math.sin,ux=Math.cos,UE=Math.atan2,vm=Math.PI;function K3(e,r,t,i,n,a,o){var l=r.stroke,s=r.lineWidth,u=t-n,c=i-a,f=UE(c,u),h=new JE({type:"path",canvas:e.get("canvas"),isArrowShape:!0,attrs:{path:"M"+10*ux(vm/6)+","+10*sx(vm/6)+" L0,0 L"+10*ux(vm/6)+",-"+10*sx(vm/6),stroke:l,lineWidth:s}});h.translate(n,a),h.rotateAtPoint(n,a,f),e.set(o?"startArrowShape":"endArrowShape",h)}function J3(e,r,t,i,n,a,o){var l=r.startArrow,s=r.endArrow,u=r.stroke,c=r.lineWidth,f=o?l:s,h=f.d,v=f.fill,d=f.stroke,p=f.lineWidth,x=ue(f,["d","fill","stroke","lineWidth"]),m=t-n,_=i-a,b=UE(_,m);h&&(n=n-ux(b)*h,a=a-sx(b)*h);var w=new JE({type:"path",canvas:e.get("canvas"),isArrowShape:!0,attrs:A(A({},x),{stroke:d||u,lineWidth:p||c,fill:v})});w.translate(n,a),w.rotateAtPoint(n,a,b),e.set(o?"startArrowShape":"endArrowShape",w)}function Nu(e,r,t,i,n){var a=UE(i-r,t-e);return{dx:ux(a)*n,dy:sx(a)*n}}function qE(e,r,t,i,n,a){typeof r.startArrow=="object"?J3(e,r,t,i,n,a,!0):r.startArrow?K3(e,r,t,i,n,a,!0):e.set("startArrowShape",null)}function ZE(e,r,t,i,n,a){typeof r.endArrow=="object"?J3(e,r,t,i,n,a,!1):r.endArrow?K3(e,r,t,i,n,a,!1):e.set("startArrowShape",null)}var T$={fill:"fillStyle",stroke:"strokeStyle",opacity:"globalAlpha"};function Wf(e,r){var t=r.attr();for(var i in t){var n=t[i],a=T$[i]?T$[i]:i;a==="matrix"&&n?e.transform(n[0],n[1],n[3],n[4],n[6],n[7]):a==="lineDash"&&e.setLineDash?it(n)&&e.setLineDash(n):(a==="strokeStyle"||a==="fillStyle"?n=tut(e,r,n):a==="globalAlpha"&&(n=n*e.globalAlpha),e[a]=n)}}function JA(e,r,t){for(var i=0;i<r.length;i++){var n=r[i];n.cfg.visible?n.draw(e,t):n.skipDraw()}}function rut(e,r,t){var i=e.get("refreshElements");P(i,function(n){if(n!==e)for(var a=n.cfg.parent;a&&a!==e&&!a.cfg.refresh;)a.cfg.refresh=!0,a=a.cfg.parent}),i[0]===e?QE(r):tT(r,t)}function tT(e,r){for(var t=0;t<e.length;t++){var i=e[t];if(i.cfg.visible)if(i.cfg.hasChanged)i.cfg.refresh=!0,i.isGroup()&&QE(i.cfg.children);else if(i.cfg.refresh)i.isGroup()&&tT(i.cfg.children,r);else{var n=iut(i,r);i.cfg.refresh=n,n&&i.isGroup()&&tT(i.cfg.children,r)}}}function tj(e){for(var r=0;r<e.length;r++){var t=e[r];t.cfg.hasChanged=!1,t.isGroup()&&!t.destroyed&&tj(t.cfg.children)}}function QE(e,r){for(var t=0;t<e.length;t++){var i=e[t];i.cfg.refresh=!0,i.isGroup()&&QE(i.get("children"))}}function iut(e,r){var t=e.cfg.cacheCanvasBBox,i=e.cfg.isInView&&t&&Wd(t,r);return i}function ej(e,r,t,i){var n=t.path,a=t.startArrow,o=t.endArrow;if(!!n){var l=[0,0],s=[0,0],u={dx:0,dy:0};r.beginPath();for(var c=0;c<n.length;c++){var f=n[c],h=f[0];if(c===0&&a&&a.d){var v=e.getStartTangent();u=Nu(v[0][0],v[0][1],v[1][0],v[1][1],a.d)}else if(c===n.length-2&&n[c+1][0]==="Z"&&o&&o.d){var d=n[c+1];if(d[0]==="Z"){var v=e.getEndTangent();u=Nu(v[0][0],v[0][1],v[1][0],v[1][1],o.d)}}else if(c===n.length-1&&o&&o.d&&n[0]!=="Z"){var v=e.getEndTangent();u=Nu(v[0][0],v[0][1],v[1][0],v[1][1],o.d)}var p=u.dx,x=u.dy;switch(h){case"M":r.moveTo(f[1]-p,f[2]-x),s=[f[1],f[2]];break;case"L":r.lineTo(f[1]-p,f[2]-x);break;case"Q":r.quadraticCurveTo(f[1],f[2],f[3]-p,f[4]-x);break;case"C":r.bezierCurveTo(f[1],f[2],f[3],f[4],f[5]-p,f[6]-x);break;case"A":{var m=void 0;i?(m=i[c],m||(m=lx(l,f),i[c]=m)):m=lx(l,f);var _=m.cx,b=m.cy,w=m.rx,S=m.ry,M=m.startAngle,F=m.endAngle,O=m.xRotation,L=m.sweepFlag;if(r.ellipse)r.ellipse(_,b,w,S,O,M,F,1-L);else{var D=w>S?w:S,k=w>S?1:w/S,H=w>S?S/w:1;r.translate(_,b),r.rotate(O),r.scale(k,H),r.arc(0,0,D,M,F,1-L),r.scale(1/k,1/H),r.rotate(-O),r.translate(-_,-b)}break}case"Z":r.closePath();break}if(h==="Z")l=s;else{var B=f.length;l=[f[B-2],f[B-1]]}}}}function rj(e,r){var t=e.get("canvas");t&&(r==="remove"&&(e._cacheCanvasBBox=e.get("cacheCanvasBBox")),e.get("hasChanged")||(e.set("hasChanged",!0),e.cfg.parent&&e.cfg.parent.get("hasChanged")||(t.refreshElement(e,r,t),t.get("autoDraw")&&t.draw())))}function nut(e){var r;if(e.destroyed)r=e._cacheCanvasBBox;else{var t=e.get("cacheCanvasBBox"),i=t&&!!(t.width&&t.height),n=e.getCanvasBBox(),a=n&&!!(n.width&&n.height);i&&a?r=Xst(t,n):i?r=t:a&&(r=n)}return r}function aut(e){if(!e.length)return null;var r=[],t=[],i=[],n=[];return P(e,function(a){var o=nut(a);o&&(r.push(o.minX),t.push(o.minY),i.push(o.maxX),n.push(o.maxY))}),{minX:Or(r),minY:Or(t),maxX:gr(i),maxY:gr(n)}}function out(e,r){return!e||!r||!Wd(e,r)?null:{minX:Math.max(e.minX,r.minX),minY:Math.max(e.minY,r.minY),maxX:Math.min(e.maxX,r.maxX),maxY:Math.min(e.maxY,r.maxY)}}var KE=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.onCanvasChange=function(t){rj(this,t)},r.prototype.getShapeBase=function(){return Ux},r.prototype.getGroupBase=function(){return r},r.prototype._applyClip=function(t,i){i&&(t.save(),Wf(t,i),i.createPath(t),t.restore(),t.clip(),i._afterDraw())},r.prototype.cacheCanvasBBox=function(){var t=this.cfg.children,i=[],n=[];P(t,function(h){var v=h.cfg.cacheCanvasBBox;v&&h.cfg.isInView&&(i.push(v.minX,v.maxX),n.push(v.minY,v.maxY))});var a=null;if(i.length){var o=Or(i),l=gr(i),s=Or(n),u=gr(n);a={minX:o,minY:s,x:o,y:s,maxX:l,maxY:u,width:l-o,height:u-s};var c=this.cfg.canvas;if(c){var f=c.getViewRange();this.set("isInView",Wd(a,f))}}else this.set("isInView",!1);this.set("cacheCanvasBBox",a)},r.prototype.draw=function(t,i){var n=this.cfg.children,a=i?this.cfg.refresh:!0;n.length&&a&&(t.save(),Wf(t,this),this._applyClip(t,this.getClip()),JA(t,n,i),t.restore(),this.cacheCanvasBBox()),this.cfg.refresh=null,this.set("hasChanged",!1)},r.prototype.skipDraw=function(){this.set("cacheCanvasBBox",null),this.set("hasChanged",!1)},r}(wp),lut=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return A(A({},t),{lineWidth:1,lineAppendWidth:0,strokeOpacity:1,fillOpacity:1})},r.prototype.getShapeBase=function(){return Ux},r.prototype.getGroupBase=function(){return KE},r.prototype.onCanvasChange=function(t){rj(this,t)},r.prototype.calculateBBox=function(){var t=this.get("type"),i=this.getHitLineWidth(),n=Sp(t),a=n(this),o=i/2,l=a.x-o,s=a.y-o,u=a.x+a.width+o,c=a.y+a.height+o;return{x:l,minX:l,y:s,minY:s,width:a.width+i,height:a.height+i,maxX:u,maxY:c}},r.prototype.isFill=function(){return!!this.attrs.fill||this.isClipShape()},r.prototype.isStroke=function(){return!!this.attrs.stroke},r.prototype._applyClip=function(t,i){i&&(t.save(),Wf(t,i),i.createPath(t),t.restore(),t.clip(),i._afterDraw())},r.prototype.draw=function(t,i){var n=this.cfg.clipShape;if(i){if(this.cfg.refresh===!1){this.set("hasChanged",!1);return}var a=this.getCanvasBBox();if(!Wd(i,a)){this.set("hasChanged",!1),this.cfg.isInView&&this._afterDraw();return}}t.save(),Wf(t,this),this._applyClip(t,n),this.drawPath(t),t.restore(),this._afterDraw()},r.prototype.getCanvasViewBox=function(){var t=this.cfg.canvas;return t?t.getViewRange():null},r.prototype.cacheCanvasBBox=function(){var t=this.getCanvasViewBox();if(t){var i=this.getCanvasBBox(),n=Wd(i,t);this.set("isInView",n),n?this.set("cacheCanvasBBox",i):this.set("cacheCanvasBBox",null)}},r.prototype._afterDraw=function(){this.cacheCanvasBBox(),this.set("hasChanged",!1),this.set("refresh",null)},r.prototype.skipDraw=function(){this.set("cacheCanvasBBox",null),this.set("isInView",null),this.set("hasChanged",!1)},r.prototype.drawPath=function(t){this.createPath(t),this.strokeAndFill(t),this.afterDrawPath(t)},r.prototype.fill=function(t){t.fill()},r.prototype.stroke=function(t){t.stroke()},r.prototype.strokeAndFill=function(t){var i=this.attrs,n=i.lineWidth,a=i.opacity,o=i.strokeOpacity,l=i.fillOpacity;this.isFill()&&(!K(l)&&l!==1?(t.globalAlpha=l,this.fill(t),t.globalAlpha=a):this.fill(t)),this.isStroke()&&n>0&&(!K(o)&&o!==1&&(t.globalAlpha=o),this.stroke(t)),this.afterDrawPath(t)},r.prototype.createPath=function(t){},r.prototype.afterDrawPath=function(t){},r.prototype.isInShape=function(t,i){var n=this.isStroke(),a=this.isFill(),o=this.getHitLineWidth();return this.isInStrokeOrPath(t,i,n,a,o)},r.prototype.isInStrokeOrPath=function(t,i,n,a,o){return!1},r.prototype.getHitLineWidth=function(){if(!this.isStroke())return 0;var t=this.attrs;return t.lineWidth+t.lineAppendWidth},r}(Cp),Ia=lut,sut=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return A(A({},t),{x:0,y:0,r:0})},r.prototype.isInStrokeOrPath=function(t,i,n,a,o){var l=this.attr(),s=l.x,u=l.y,c=l.r,f=o/2,h=q3(s,u,t,i);return a&&n?h<=c+f:a?h<=c:n?h>=c-f&&h<=c+f:!1},r.prototype.createPath=function(t){var i=this.attr(),n=i.x,a=i.y,o=i.r;t.beginPath(),t.arc(n,a,o,0,Math.PI*2,!1),t.closePath()},r}(Ia),uut=sut;function dm(e,r,t,i){return e/(t*t)+r/(i*i)}var cut=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return A(A({},t),{x:0,y:0,rx:0,ry:0})},r.prototype.isInStrokeOrPath=function(t,i,n,a,o){var l=this.attr(),s=o/2,u=l.x,c=l.y,f=l.rx,h=l.ry,v=(t-u)*(t-u),d=(i-c)*(i-c);return a&&n?dm(v,d,f+s,h+s)<=1:a?dm(v,d,f,h)<=1:n?dm(v,d,f-s,h-s)>=1&&dm(v,d,f+s,h+s)<=1:!1},r.prototype.createPath=function(t){var i=this.attr(),n=i.x,a=i.y,o=i.rx,l=i.ry;if(t.beginPath(),t.ellipse)t.ellipse(n,a,o,l,0,0,Math.PI*2,!1);else{var s=o>l?o:l,u=o>l?1:o/l,c=o>l?l/o:1;t.save(),t.translate(n,a),t.scale(u,c),t.arc(0,0,s,0,Math.PI*2),t.restore(),t.closePath()}},r}(Ia),fut=cut;function M$(e){return e instanceof HTMLElement&&Ct(e.nodeName)&&e.nodeName.toUpperCase()==="CANVAS"}var hut=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return A(A({},t),{x:0,y:0,width:0,height:0})},r.prototype.initAttrs=function(t){this._setImage(t.img)},r.prototype.isStroke=function(){return!1},r.prototype.isOnlyHitBox=function(){return!0},r.prototype._afterLoading=function(){if(this.get("toDraw")===!0){var t=this.get("canvas");t?t.draw():this.createPath(this.get("context"))}},r.prototype._setImage=function(t){var i=this,n=this.attrs;if(Ct(t)){var a=new Image;a.onload=function(){if(i.destroyed)return!1;i.attr("img",a),i.set("loading",!1),i._afterLoading();var o=i.get("callback");o&&o.call(i)},a.crossOrigin="Anonymous",a.src=t,this.set("loading",!0)}else t instanceof Image?(n.width||(n.width=t.width),n.height||(n.height=t.height)):M$(t)&&(n.width||(n.width=Number(t.getAttribute("width"))),n.height||(n.height,Number(t.getAttribute("height"))))},r.prototype.onAttrChange=function(t,i,n){e.prototype.onAttrChange.call(this,t,i,n),t==="img"&&this._setImage(i)},r.prototype.createPath=function(t){if(this.get("loading")){this.set("toDraw",!0),this.set("context",t);return}var i=this.attr(),n=i.x,a=i.y,o=i.width,l=i.height,s=i.sx,u=i.sy,c=i.swidth,f=i.sheight,h=i.img;(h instanceof Image||M$(h))&&(!K(s)&&!K(u)&&!K(c)&&!K(f)?t.drawImage(h,s,u,c,f,n,a,o,l):t.drawImage(h,n,a,o,l))},r}(Ia),vut=hut;function Ul(e,r,t,i,n,a,o){var l=Math.min(e,t),s=Math.max(e,t),u=Math.min(r,i),c=Math.max(r,i),f=n/2;return a>=l-f&&a<=s+f&&o>=u-f&&o<=c+f?Er.pointToLine(e,r,t,i,a,o)<=n/2:!1}var dut=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return A(A({},t),{x1:0,y1:0,x2:0,y2:0,startArrow:!1,endArrow:!1})},r.prototype.initAttrs=function(t){this.setArrow()},r.prototype.onAttrChange=function(t,i,n){e.prototype.onAttrChange.call(this,t,i,n),this.setArrow()},r.prototype.setArrow=function(){var t=this.attr(),i=t.x1,n=t.y1,a=t.x2,o=t.y2,l=t.startArrow,s=t.endArrow;l&&qE(this,t,a,o,i,n),s&&ZE(this,t,i,n,a,o)},r.prototype.isInStrokeOrPath=function(t,i,n,a,o){if(!n||!o)return!1;var l=this.attr(),s=l.x1,u=l.y1,c=l.x2,f=l.y2;return Ul(s,u,c,f,o,t,i)},r.prototype.createPath=function(t){var i=this.attr(),n=i.x1,a=i.y1,o=i.x2,l=i.y2,s=i.startArrow,u=i.endArrow,c={dx:0,dy:0},f={dx:0,dy:0};s&&s.d&&(c=Nu(n,a,o,l,i.startArrow.d)),u&&u.d&&(f=Nu(n,a,o,l,i.endArrow.d)),t.beginPath(),t.moveTo(n+c.dx,a+c.dy),t.lineTo(o-f.dx,l-f.dy)},r.prototype.afterDrawPath=function(t){var i=this.get("startArrowShape"),n=this.get("endArrowShape");i&&i.draw(t),n&&n.draw(t)},r.prototype.getTotalLength=function(){var t=this.attr(),i=t.x1,n=t.y1,a=t.x2,o=t.y2;return Er.length(i,n,a,o)},r.prototype.getPoint=function(t){var i=this.attr(),n=i.x1,a=i.y1,o=i.x2,l=i.y2;return Er.pointAt(n,a,o,l,t)},r}(Ia),put=dut,gut={circle:function(e,r,t){return[["M",e-t,r],["A",t,t,0,1,0,e+t,r],["A",t,t,0,1,0,e-t,r]]},square:function(e,r,t){return[["M",e-t,r-t],["L",e+t,r-t],["L",e+t,r+t],["L",e-t,r+t],["Z"]]},diamond:function(e,r,t){return[["M",e-t,r],["L",e,r-t],["L",e+t,r],["L",e,r+t],["Z"]]},triangle:function(e,r,t){var i=t*Math.sin(.3333333333333333*Math.PI);return[["M",e-t,r+i],["L",e,r-i],["L",e+t,r+i],["Z"]]},"triangle-down":function(e,r,t){var i=t*Math.sin(.3333333333333333*Math.PI);return[["M",e-t,r-i],["L",e+t,r-i],["L",e,r+i],["Z"]]}},yut=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.initAttrs=function(t){this._resetParamsCache()},r.prototype._resetParamsCache=function(){this.set("paramsCache",{})},r.prototype.onAttrChange=function(t,i,n){e.prototype.onAttrChange.call(this,t,i,n),["symbol","x","y","r","radius"].indexOf(t)!==-1&&this._resetParamsCache()},r.prototype.isOnlyHitBox=function(){return!0},r.prototype._getR=function(t){return K(t.r)?t.radius:t.r},r.prototype._getPath=function(){var t=this.attr(),i=t.x,n=t.y,a=t.symbol||"circle",o=this._getR(t),l,s;if(pt(a))l=a,s=l(i,n,o),s=f1(s);else{if(l=r.Symbols[a],!l)return console.warn(a+" marker is not supported."),null;s=l(i,n,o)}return s},r.prototype.createPath=function(t){var i=this._getPath(),n=this.get("paramsCache");ej(this,t,{path:i},n)},r.Symbols=gut,r}(Ia),mut=yut;function ij(e,r,t){var i=Tp();return e.createPath(i),i.isPointInPath(r,t)}var xut=1e-6;function UC(e){return Math.abs(e)<xut?0:e<0?-1:1}function _ut(e,r,t){return(t[0]-e[0])*(r[1]-e[1])===(r[0]-e[0])*(t[1]-e[1])&&Math.min(e[0],r[0])<=t[0]&&t[0]<=Math.max(e[0],r[0])&&Math.min(e[1],r[1])<=t[1]&&t[1]<=Math.max(e[1],r[1])}function nj(e,r,t){var i=!1,n=e.length;if(n<=2)return!1;for(var a=0;a<n;a++){var o=e[a],l=e[(a+1)%n];if(_ut(o,l,[r,t]))return!0;UC(o[1]-t)>0!=UC(l[1]-t)>0&&UC(r-(t-o[1])*(o[0]-l[0])/(o[1]-l[1])-o[0])<0&&(i=!i)}return i}function Uv(e,r,t,i,n,a,o,l){var s=(Math.atan2(l-r,o-e)+Math.PI*2)%(Math.PI*2);if(s<i||s>n)return!1;var u={x:e+t*Math.cos(s),y:r+t*Math.sin(s)};return q3(u.x,u.y,o,l)<=a/2}var but=rr;function wut(e){for(var r=!1,t=e.length,i=0;i<t;i++){var n=e[i],a=n[0];if(a==="C"||a==="A"||a==="Q"){r=!0;break}}return r}function Cut(e,r,t,i,n){for(var a=!1,o=r/2,l=0;l<e.length;l++){var s=e[l],u=s.currentPoint,c=s.params,f=s.prePoint,h=s.box;if(!(h&&!Tu(h.x-o,h.y-o,h.width+r,h.height+r,t,i))){switch(s.command){case"L":case"Z":a=Ul(f[0],f[1],u[0],u[1],r,t,i);break;case"Q":var v=EM.pointDistance(f[0],f[1],c[1],c[2],c[3],c[4],t,i);a=v<=r/2;break;case"C":var d=Cf.pointDistance(f[0],f[1],c[1],c[2],c[3],c[4],c[5],c[6],t,i,n);a=d<=r/2;break;case"A":var p=s.arcParams,x=p.cx,m=p.cy,_=p.rx,b=p.ry,w=p.startAngle,S=p.endAngle,M=p.xRotation,F=[t,i,1],O=_>b?_:b,L=_>b?1:_/b,D=_>b?b/_:1,k=but(null,[["t",-x,-m],["r",-M],["s",1/L,1/D]]);kf(F,F,k),a=Uv(0,0,O,w,S,r,F[0],F[1]);break}if(a)break}}return a}function Sut(e){for(var r=e.length,t=[],i=[],n=[],a=0;a<r;a++){var o=e[a],l=o[0];l==="M"?(n.length&&(i.push(n),n=[]),n.push([o[1],o[2]])):l==="Z"?n.length&&(t.push(n),n=[]):n.push([o[1],o[2]])}return n.length>0&&i.push(n),{polygons:t,polylines:i}}var pm=A({hasArc:wut,extractPolygons:Sut,isPointInStroke:Cut},a1);function E$(e,r,t){for(var i=!1,n=0;n<e.length;n++){var a=e[n];if(i=nj(a,r,t),i)break}return i}var Aut=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return A(A({},t),{startArrow:!1,endArrow:!1})},r.prototype.initAttrs=function(t){this._setPathArr(t.path),this.setArrow()},r.prototype.onAttrChange=function(t,i,n){e.prototype.onAttrChange.call(this,t,i,n),t==="path"&&this._setPathArr(i),this.setArrow()},r.prototype._setPathArr=function(t){this.attrs.path=f1(t);var i=pm.hasArc(t);this.set("hasArc",i),this.set("paramsCache",{}),this.set("segments",null),this.set("curve",null),this.set("tCache",null),this.set("totalLength",null)},r.prototype.getSegments=function(){var t=this.get("segements");return t||(t=OM(this.attr("path")),this.set("segments",t)),t},r.prototype.setArrow=function(){var t=this.attr(),i=t.startArrow,n=t.endArrow;if(i){var a=this.getStartTangent();qE(this,t,a[0][0],a[0][1],a[1][0],a[1][1])}if(n){var a=this.getEndTangent();ZE(this,t,a[0][0],a[0][1],a[1][0],a[1][1])}},r.prototype.isInStrokeOrPath=function(t,i,n,a,o){var l=this.getSegments(),s=this.get("hasArc"),u=!1;if(n){var c=this.getTotalLength();u=pm.isPointInStroke(l,o,t,i,c)}if(!u&&a)if(s)u=ij(this,t,i);else{var f=this.attr("path"),h=pm.extractPolygons(f);u=E$(h.polygons,t,i)||E$(h.polylines,t,i)}return u},r.prototype.createPath=function(t){var i=this.attr(),n=this.get("paramsCache");ej(this,t,i,n)},r.prototype.afterDrawPath=function(t){var i=this.get("startArrowShape"),n=this.get("endArrowShape");i&&i.draw(t),n&&n.draw(t)},r.prototype.getTotalLength=function(){var t=this.get("totalLength");return K(t)?(this._calculateCurve(),this._setTcache(),this.get("totalLength")):t},r.prototype.getPoint=function(t){var i=this.get("tCache");i||(this._calculateCurve(),this._setTcache(),i=this.get("tCache"));var n,a,o=this.get("curve");if(!i||i.length===0)return o?{x:o[0][1],y:o[0][2]}:null;P(i,function(c,f){t>=c[0]&&t<=c[1]&&(n=(t-c[0])/(c[1]-c[0]),a=f)});var l=o[a];if(K(l)||K(a))return null;var s=l.length,u=o[a+1];return Cf.pointAt(l[s-2],l[s-1],u[1],u[2],u[3],u[4],u[5],u[6],n)},r.prototype._calculateCurve=function(){var t=this.attr().path;this.set("curve",pm.pathToCurve(t))},r.prototype._setTcache=function(){var t=0,i=0,n=[],a,o,l,s,u=this.get("curve");if(!!u){if(P(u,function(c,f){l=u[f+1],s=c.length,l&&(t+=Cf.length(c[s-2],c[s-1],l[1],l[2],l[3],l[4],l[5],l[6])||0)}),this.set("totalLength",t),t===0){this.set("tCache",[]);return}P(u,function(c,f){l=u[f+1],s=c.length,l&&(a=[],a[0]=i/t,o=Cf.length(c[s-2],c[s-1],l[1],l[2],l[3],l[4],l[5],l[6]),i+=o||0,a[1]=i/t,n.push(a))}),this.set("tCache",n)}},r.prototype.getStartTangent=function(){var t=this.getSegments(),i;if(t.length>1){var n=t[0].currentPoint,a=t[1].currentPoint,o=t[1].startTangent;i=[],o?(i.push([n[0]-o[0],n[1]-o[1]]),i.push([n[0],n[1]])):(i.push([a[0],a[1]]),i.push([n[0],n[1]]))}return i},r.prototype.getEndTangent=function(){var t=this.getSegments(),i=t.length,n;if(i>1){var a=t[i-2].currentPoint,o=t[i-1].currentPoint,l=t[i-1].endTangent;n=[],l?(n.push([o[0]-l[0],o[1]-l[1]]),n.push([o[0],o[1]])):(n.push([a[0],a[1]]),n.push([o[0],o[1]]))}return n},r}(Ia),JE=Aut;function aj(e,r,t,i,n){var a=e.length;if(a<2)return!1;for(var o=0;o<a-1;o++){var l=e[o][0],s=e[o][1],u=e[o+1][0],c=e[o+1][1];if(Ul(l,s,u,c,r,t,i))return!0}if(n){var f=e[0],h=e[a-1];if(Ul(f[0],f[1],h[0],h[1],r,t,i))return!0}return!1}var Tut=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.isInStrokeOrPath=function(t,i,n,a,o){var l=this.attr().points,s=!1;return n&&(s=aj(l,o,t,i,!0)),!s&&a&&(s=nj(l,t,i)),s},r.prototype.createPath=function(t){var i=this.attr(),n=i.points;if(!(n.length<2)){t.beginPath();for(var a=0;a<n.length;a++){var o=n[a];a===0?t.moveTo(o[0],o[1]):t.lineTo(o[0],o[1])}t.closePath()}},r}(Ia),Mut=Tut,Eut=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return A(A({},t),{startArrow:!1,endArrow:!1})},r.prototype.initAttrs=function(t){this.setArrow()},r.prototype.onAttrChange=function(t,i,n){e.prototype.onAttrChange.call(this,t,i,n),this.setArrow(),["points"].indexOf(t)!==-1&&this._resetCache()},r.prototype._resetCache=function(){this.set("totalLength",null),this.set("tCache",null)},r.prototype.setArrow=function(){var t=this.attr(),i=this.attrs,n=i.points,a=i.startArrow,o=i.endArrow,l=n.length,s=n[0][0],u=n[0][1],c=n[l-1][0],f=n[l-1][1];a&&qE(this,t,n[1][0],n[1][1],s,u),o&&ZE(this,t,n[l-2][0],n[l-2][1],c,f)},r.prototype.isFill=function(){return!1},r.prototype.isInStrokeOrPath=function(t,i,n,a,o){if(!n||!o)return!1;var l=this.attr().points;return aj(l,o,t,i,!1)},r.prototype.isStroke=function(){return!0},r.prototype.createPath=function(t){var i=this.attr(),n=i.points,a=i.startArrow,o=i.endArrow,l=n.length;if(!(n.length<2)){var s=n[0][0],u=n[0][1],c=n[l-1][0],f=n[l-1][1];if(a&&a.d){var h=Nu(s,u,n[1][0],n[1][1],a.d);s+=h.dx,u+=h.dy}if(o&&o.d){var h=Nu(n[l-2][0],n[l-2][1],c,f,o.d);c-=h.dx,f-=h.dy}t.beginPath(),t.moveTo(s,u);for(var v=0;v<l-1;v++){var d=n[v];t.lineTo(d[0],d[1])}t.lineTo(c,f)}},r.prototype.afterDrawPath=function(t){var i=this.get("startArrowShape"),n=this.get("endArrowShape");i&&i.draw(t),n&&n.draw(t)},r.prototype.getTotalLength=function(){var t=this.attr().points,i=this.get("totalLength");return K(i)?(this.set("totalLength",u1.length(t)),this.get("totalLength")):i},r.prototype.getPoint=function(t){var i=this.attr().points,n=this.get("tCache");n||(this._setTcache(),n=this.get("tCache"));var a,o;return P(n,function(l,s){t>=l[0]&&t<=l[1]&&(a=(t-l[0])/(l[1]-l[0]),o=s)}),Er.pointAt(i[o][0],i[o][1],i[o+1][0],i[o+1][1],a)},r.prototype._setTcache=function(){var t=this.attr().points;if(!(!t||t.length===0)){var i=this.getTotalLength();if(!(i<=0)){var n=0,a=[],o,l;P(t,function(s,u){t[u+1]&&(o=[],o[0]=n/i,l=Er.length(s[0],s[1],t[u+1][0],t[u+1][1]),n+=l,o[1]=n/i,a.push(o))}),this.set("tCache",a)}}},r.prototype.getStartTangent=function(){var t=this.attr().points,i=[];return i.push([t[1][0],t[1][1]]),i.push([t[0][0],t[0][1]]),i},r.prototype.getEndTangent=function(){var t=this.attr().points,i=t.length-1,n=[];return n.push([t[i-1][0],t[i-1][1]]),n.push([t[i][0],t[i][1]]),n},r}(Ia),Fut=Eut;function Out(e,r,t,i,n,a,o){var l=n/2;return Tu(e-l,r-l,t,n,a,o)||Tu(e+t-l,r-l,n,i,a,o)||Tu(e+l,r+i-l,t,n,a,o)||Tu(e-l,r+l,n,i,a,o)}function Put(e,r,t,i,n,a,o,l){return Ul(e+n,r,e+t-n,r,a,o,l)||Ul(e+t,r+n,e+t,r+i-n,a,o,l)||Ul(e+t-n,r+i,e+n,r+i,a,o,l)||Ul(e,r+i-n,e,r+n,a,o,l)||Uv(e+t-n,r+n,n,1.5*Math.PI,2*Math.PI,a,o,l)||Uv(e+t-n,r+i-n,n,0,.5*Math.PI,a,o,l)||Uv(e+n,r+i-n,n,.5*Math.PI,Math.PI,a,o,l)||Uv(e+n,r+n,n,Math.PI,1.5*Math.PI,a,o,l)}var Iut=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return A(A({},t),{x:0,y:0,width:0,height:0,radius:0})},r.prototype.isInStrokeOrPath=function(t,i,n,a,o){var l=this.attr(),s=l.x,u=l.y,c=l.width,f=l.height,h=l.radius;if(h){var d=!1;return n&&(d=Put(s,u,c,f,h,o,t,i)),!d&&a&&(d=ij(this,t,i)),d}else{var v=o/2;if(a&&n)return Tu(s-v,u-v,c+v,f+v,t,i);if(a)return Tu(s,u,c,f,t,i);if(n)return Out(s,u,c,f,o,t,i)}},r.prototype.createPath=function(t){var i=this.attr(),n=i.x,a=i.y,o=i.width,l=i.height,s=i.radius;if(t.beginPath(),s===0)t.rect(n,a,o,l);else{var u=eut(s),c=u[0],f=u[1],h=u[2],v=u[3];t.moveTo(n+c,a),t.lineTo(n+o-f,a),f!==0&&t.arc(n+o-f,a+f,f,-Math.PI/2,0),t.lineTo(n+o,a+l-h),h!==0&&t.arc(n+o-h,a+l-h,h,0,Math.PI/2),t.lineTo(n+v,a+l),v!==0&&t.arc(n+v,a+l-v,v,Math.PI/2,Math.PI),t.lineTo(n,a+c),c!==0&&t.arc(n+c,a+c,c,Math.PI,Math.PI*1.5),t.closePath()}},r}(Ia),Lut=Iut,Dut=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return A(A({},t),{x:0,y:0,text:null,fontSize:12,fontFamily:"sans-serif",fontStyle:"normal",fontWeight:"normal",fontVariant:"normal",textAlign:"start",textBaseline:"bottom"})},r.prototype.isOnlyHitBox=function(){return!0},r.prototype.initAttrs=function(t){this._assembleFont(),t.text&&this._setText(t.text)},r.prototype._assembleFont=function(){var t=this.attrs;t.font=Ep(t)},r.prototype._setText=function(t){var i=null;Ct(t)&&t.indexOf(`
|
|
`)!==-1&&(i=t.split(`
|
|
`)),this.set("textArr",i)},r.prototype.onAttrChange=function(t,i,n){e.prototype.onAttrChange.call(this,t,i,n),t.startsWith("font")&&this._assembleFont(),t==="text"&&this._setText(i)},r.prototype._getSpaceingY=function(){var t=this.attrs,i=t.lineHeight,n=t.fontSize*1;return i?i-n:n*.14},r.prototype._drawTextArr=function(t,i,n){var a=this.attrs,o=a.textBaseline,l=a.x,s=a.y,u=a.fontSize*1,c=this._getSpaceingY(),f=Mp(a.text,a.fontSize,a.lineHeight),h;P(i,function(v,d){h=s+d*(c+u)-f+u,o==="middle"&&(h+=f-u-(f-u)/2),o==="top"&&(h+=f-u),K(v)||(n?t.fillText(v,l,h):t.strokeText(v,l,h))})},r.prototype._drawText=function(t,i){var n=this.attr(),a=n.x,o=n.y,l=this.get("textArr");if(l)this._drawTextArr(t,l,i);else{var s=n.text;K(s)||(i?t.fillText(s,a,o):t.strokeText(s,a,o))}},r.prototype.strokeAndFill=function(t){var i=this.attrs,n=i.lineWidth,a=i.opacity,o=i.strokeOpacity,l=i.fillOpacity;this.isStroke()&&n>0&&(!K(o)&&o!==1&&(t.globalAlpha=a),this.stroke(t)),this.isFill()&&(!K(l)&&l!==1?(t.globalAlpha=l,this.fill(t),t.globalAlpha=a):this.fill(t)),this.afterDrawPath(t)},r.prototype.fill=function(t){this._drawText(t,!0)},r.prototype.stroke=function(t){this._drawText(t,!1)},r}(Ia),$ut=Dut;function kut(e,r){if(r){var t=xp(r);return ro(t,e)}return e}function oj(e,r,t){var i=e.getTotalMatrix();if(i){var n=kut([r,t,1],i),a=n[0],o=n[1];return[a,o]}return[r,t]}function F$(e,r,t){if(e.isCanvas&&e.isCanvas())return!0;if(!$f(e)||e.cfg.isInView===!1)return!1;if(e.cfg.clipShape){var i=oj(e,r,t),n=i[0],a=i[1];if(e.isClipped(n,a))return!1}var o=e.cfg.cacheCanvasBBox||e.getCanvasBBox();return r>=o.minX&&r<=o.maxX&&t>=o.minY&&t<=o.maxY}function lj(e,r,t){if(!F$(e,r,t))return null;for(var i=null,n=e.getChildren(),a=n.length,o=a-1;o>=0;o--){var l=n[o];if(l.isGroup())i=lj(l,r,t);else if(F$(l,r,t)){var s=l,u=oj(l,r,t),c=u[0],f=u[1];s.isInShape(c,f)&&(i=l)}if(i)break}return i}var sj=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){var t=e.prototype.getDefaultCfg.call(this);return t.renderer="canvas",t.autoDraw=!0,t.localRefresh=!0,t.refreshElements=[],t.clipView=!0,t.quickHit=!1,t},r.prototype.onCanvasChange=function(t){(t==="attr"||t==="sort"||t==="changeSize")&&(this.set("refreshElements",[this]),this.draw())},r.prototype.getShapeBase=function(){return Ux},r.prototype.getGroupBase=function(){return KE},r.prototype.getPixelRatio=function(){var t=this.get("pixelRatio")||Wst();return t>=1?Math.ceil(t):1},r.prototype.getViewRange=function(){return{minX:0,minY:0,maxX:this.cfg.width,maxY:this.cfg.height}},r.prototype.createDom=function(){var t=document.createElement("canvas"),i=t.getContext("2d");return this.set("context",i),t},r.prototype.setDOMSize=function(t,i){e.prototype.setDOMSize.call(this,t,i);var n=this.get("context"),a=this.get("el"),o=this.getPixelRatio();a.width=o*t,a.height=o*i,o>1&&n.scale(o,o)},r.prototype.clear=function(){e.prototype.clear.call(this),this._clearFrame();var t=this.get("context"),i=this.get("el");t.clearRect(0,0,i.width,i.height)},r.prototype.getShape=function(t,i){var n;return this.get("quickHit")?n=lj(this,t,i):n=e.prototype.getShape.call(this,t,i,null),n},r.prototype._getRefreshRegion=function(){var t=this.get("refreshElements"),i=this.getViewRange(),n;if(t.length&&t[0]===this)n=i;else if(n=aut(t),n){n.minX=Math.floor(n.minX),n.minY=Math.floor(n.minY),n.maxX=Math.ceil(n.maxX),n.maxY=Math.ceil(n.maxY),n.maxY+=1;var a=this.get("clipView");a&&(n=out(n,i))}return n},r.prototype.refreshElement=function(t){var i=this.get("refreshElements");i.push(t)},r.prototype._clearFrame=function(){var t=this.get("drawFrame");t&&(rz(t),this.set("drawFrame",null),this.set("refreshElements",[]))},r.prototype.draw=function(){var t=this.get("drawFrame");this.get("autoDraw")&&t||this._startDraw()},r.prototype._drawAll=function(){var t=this.get("context"),i=this.get("el"),n=this.getChildren();t.clearRect(0,0,i.width,i.height),Wf(t,this),JA(t,n),this.set("refreshElements",[])},r.prototype._drawRegion=function(){var t=this.get("context"),i=this.get("refreshElements"),n=this.getChildren(),a=this._getRefreshRegion();a?(t.clearRect(a.minX,a.minY,a.maxX-a.minX,a.maxY-a.minY),t.save(),t.beginPath(),t.rect(a.minX,a.minY,a.maxX-a.minX,a.maxY-a.minY),t.clip(),Wf(t,this),rut(this,n,a),JA(t,n,a),t.restore()):i.length&&tj(i),P(i,function(o){o.get("hasChanged")&&o.set("hasChanged",!1)}),this.set("refreshElements",[])},r.prototype._startDraw=function(){var t=this,i=this.get("drawFrame");i||(i=ez(function(){t.get("localRefresh")?t._drawRegion():t._drawAll(),t.set("drawFrame",null)}),this.set("drawFrame",i))},r.prototype.skipDraw=function(){},r.prototype.removeDom=function(){var t=this.get("el");t.width=0,t.height=0,t.parentNode.removeChild(t)},r}(bp),Rut="0.5.12",uj=Object.freeze(Object.defineProperty({__proto__:null,Shape:Ux,version:Rut,Canvas:sj,Group:KE,getArcParams:lx,Event:bh,Base:mp,AbstractCanvas:bp,AbstractGroup:wp,AbstractShape:Cp,getBBoxMethod:Sp,registerBBox:wn,getTextHeight:Mp,assembleFont:Ep,isAllowCapture:$f,multiplyVec2:ro,invert:xp,getOffScreenContext:Tp,registerEasing:MM,PathUtil:a1},Symbol.toStringTag,{value:"Module"})),cj=br(uj);Object.defineProperty(U1,"__esModule",{value:!0});var fj=U1.sectorPathUpdate=void 0,gm=V,But=cj,Mu=Y,O$=Se;function P$(e,r){var t,i=(0,But.getArcParams)(e,r),n=i.startAngle,a=i.endAngle;return!(0,Mu.isNumberEqual)(n,-Math.PI*.5)&&n<-Math.PI*.5&&(n+=Math.PI*2),!(0,Mu.isNumberEqual)(a,-Math.PI*.5)&&a<-Math.PI*.5&&(a+=Math.PI*2),r[5]===0&&(t=[a,n],n=t[0],a=t[1]),(0,Mu.isNumberEqual)(n,Math.PI*1.5)&&(n=Math.PI*-.5),(0,Mu.isNumberEqual)(a,Math.PI*-.5)&&(a=Math.PI*1.5),{startAngle:n,endAngle:a}}function I$(e){var r;return e[0]==="M"||e[0]==="L"?r=[e[1],e[2]]:(e[0]==="a"||e[0]==="A"||e[0]==="C")&&(r=[e[e.length-2],e[e.length-1]]),r}function L$(e){var r,t,i,n=e.filter(function(b){return b[0]==="A"||b[0]==="a"});if(n.length===0)return{startAngle:0,endAngle:0,radius:0,innerRadius:0};var a=n[0],o=n.length>1?n[1]:n[0],l=e.indexOf(a),s=e.indexOf(o),u=I$(e[l-1]),c=I$(e[s-1]),f=P$(u,a),h=f.startAngle,v=f.endAngle,d=P$(c,o),p=d.startAngle,x=d.endAngle;(0,Mu.isNumberEqual)(h,p)&&(0,Mu.isNumberEqual)(v,x)?(t=h,i=v):(t=Math.min(h,p),i=Math.max(v,x));var m=a[1],_=n[n.length-1][1];return m<_?(r=[_,m],m=r[0],_=r[1]):m===_&&(_=0),{startAngle:t,endAngle:i,radius:m,innerRadius:_}}function Nut(e,r,t){var i=t.toAttrs,n=t.coordinate,a=i.path||[],o=a.map(function(_){return _[0]});if(!(a.length<1)){var l=L$(a),s=l.startAngle,u=l.endAngle,c=l.radius,f=l.innerRadius,h=L$(e.attr("path")),v=h.startAngle,d=h.endAngle,p=n.getCenter(),x=s-v,m=u-d;if(x===0&&m===0){e.attr("path",a);return}e.animate(function(_){var b=v+_*x,w=d+_*m;return(0,gm.__assign)((0,gm.__assign)({},i),{path:(0,Mu.isEqual)(o,["M","A","A","Z"])?(0,O$.getArcPath)(p.x,p.y,c,b,w):(0,O$.getSectorPath)(p.x,p.y,c,b,w,f)})},(0,gm.__assign)((0,gm.__assign)({},r),{callback:function(){e.attr("path",a)}}))}}fj=U1.sectorPathUpdate=Nut;var q1={};Object.defineProperty(q1,"__esModule",{value:!0});var hj=q1.waveIn=void 0,D$=V,Gut=be;function zut(e,r,t){var i=(0,Gut.getCoordinateClipCfg)(t.coordinate,20),n=i.type,a=i.startState,o=i.endState,l=e.setClip({type:n,attrs:a});l.animate(o,(0,D$.__assign)((0,D$.__assign)({},r),{callback:function(){e&&!e.get("destroyed")&&e.set("clipShape",null),l.remove(!0)}}))}hj=q1.waveIn=zut;var Xf={};Object.defineProperty(Xf,"__esModule",{value:!0});var vj=Xf.zoomOut=dj=Xf.zoomIn=void 0,$$=V,qC=ta,Vut=Y;function tF(e,r,t){if(e.isGroup())(0,Vut.each)(e.getChildren(),function(l){tF(l,r,t)});else{var i=e.getBBox(),n=(i.minX+i.maxX)/2,a=(i.minY+i.maxY)/2;if(e.applyToMatrix([n,a,1]),t==="zoomIn"){var o=qC.ext.transform(e.getMatrix(),[["t",-n,-a],["s",.01,.01],["t",n,a]]);e.setMatrix(o),e.animate({matrix:qC.ext.transform(e.getMatrix(),[["t",-n,-a],["s",100,100],["t",n,a]])},r)}else e.animate({matrix:qC.ext.transform(e.getMatrix(),[["t",-n,-a],["s",.01,.01],["t",n,a]])},(0,$$.__assign)((0,$$.__assign)({},r),{callback:function(){e.remove(!0)}}))}}function jut(e,r,t){tF(e,r,"zoomIn")}var dj=Xf.zoomIn=jut;function Hut(e,r,t){tF(e,r,"zoomOut")}vj=Xf.zoomOut=Hut;ut.registerAnimation("fade-in",z3);ut.registerAnimation("fade-out",G3);ut.registerAnimation("grow-in-x",H3);ut.registerAnimation("grow-in-xy",j3);ut.registerAnimation("grow-in-y",Y3);ut.registerAnimation("scale-in-x",U3);ut.registerAnimation("scale-in-y",X3);ut.registerAnimation("wave-in",hj);ut.registerAnimation("zoom-in",dj);ut.registerAnimation("zoom-out",vj);ut.registerAnimation("position-update",W3);ut.registerAnimation("sector-path-update",fj);ut.registerAnimation("path-in",XE);var eF={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.antvDark=e.createDarkStyleSheet=void 0;var r={100:"#000",95:"#0D0D0D",85:"#262626",65:"#595959",45:"#8C8C8C",25:"#BFBFBF",15:"#D9D9D9",6:"#F0F0F0"},t={100:"#FFFFFF",95:"#F2F2F2",85:"#D9D9D9",65:"#A6A6A6",45:"#737373",25:"#404040",15:"#262626",6:"#0F0F0F"},i=["#5B8FF9","#5AD8A6","#5D7092","#F6BD16","#E86452","#6DC8EC","#945FB9","#FF9845","#1E9493","#FF99C3"],n=["#5B8FF9","#CDDDFD","#5AD8A6","#CDF3E4","#5D7092","#CED4DE","#F6BD16","#FCEBB9","#E86452","#F8D0CB","#6DC8EC","#D3EEF9","#945FB9","#DECFEA","#FF9845","#FFE0C7","#1E9493","#BBDEDE","#FF99C3","#FFE0ED"],a=["#B8E1FF","#9AC5FF","#7DAAFF","#5B8FF9","#3D76DD","#085EC0","#0047A5","#00318A","#001D70"],o=function(l){l===void 0&&(l={});var s=l.backgroundColor,u=s===void 0?"#141414":s,c=l.subColor,f=c===void 0?"rgba(255,255,255,0.05)":c,h=l.paletteQualitative10,v=h===void 0?i:h,d=l.paletteQualitative20,p=d===void 0?n:d,x=l.paletteSemanticRed,m=x===void 0?"#F4664A":x,_=l.paletteSemanticGreen,b=_===void 0?"#30BF78":_,w=l.paletteSemanticYellow,S=w===void 0?"#FAAD14":w,M=l.paletteSequence,F=M===void 0?a:M,O=l.fontFamily,L=O===void 0?`"Segoe UI", Roboto, "Helvetica Neue", Arial,
|
|
"Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol",
|
|
"Noto Color Emoji"`:O,D=l.brandColor,k=D===void 0?v[0]:D;return{backgroundColor:u,brandColor:k,subColor:f,paletteQualitative10:v,paletteQualitative20:p,paletteSemanticRed:m,paletteSemanticGreen:b,paletteSemanticYellow:S,paletteSequence:F,fontFamily:L,axisLineBorderColor:t[25],axisLineBorder:1,axisLineDash:null,axisTitleTextFillColor:t[65],axisTitleTextFontSize:12,axisTitleTextLineHeight:12,axisTitleTextFontWeight:"normal",axisTitleSpacing:12,axisTickLineBorderColor:t[25],axisTickLineLength:4,axisTickLineBorder:1,axisSubTickLineBorderColor:t[15],axisSubTickLineLength:2,axisSubTickLineBorder:1,axisLabelFillColor:t[45],axisLabelFontSize:12,axisLabelLineHeight:12,axisLabelFontWeight:"normal",axisLabelOffset:8,axisGridBorderColor:t[15],axisGridBorder:1,axisGridLineDash:null,legendTitleTextFillColor:t[45],legendTitleTextFontSize:12,legendTitleTextLineHeight:21,legendTitleTextFontWeight:"normal",legendMarkerColor:i[0],legendMarkerSpacing:8,legendMarkerSize:4,legendCircleMarkerSize:4,legendSquareMarkerSize:4,legendLineMarkerSize:5,legendItemNameFillColor:t[65],legendItemNameFontSize:12,legendItemNameLineHeight:12,legendItemNameFontWeight:"normal",legendItemSpacing:24,legendItemMarginBottom:12,legendSpacing:16,legendPadding:[8,8,8,8],legendHorizontalPadding:[8,0,8,0],legendVerticalPadding:[0,8,0,8],legendPageNavigatorMarkerSize:12,legendPageNavigatorMarkerInactiveFillColor:t[45],legendPageNavigatorMarkerInactiveFillOpacity:.45,legendPageNavigatorMarkerFillColor:t[45],legendPageNavigatorMarkerFillOpacity:1,legendPageNavigatorTextFillColor:t[65],legendPageNavigatorTextFontSize:12,sliderRailFillColor:t[15],sliderRailBorder:0,sliderRailBorderColor:null,sliderRailWidth:100,sliderRailHeight:12,sliderLabelTextFillColor:t[45],sliderLabelTextFontSize:12,sliderLabelTextLineHeight:12,sliderLabelTextFontWeight:"normal",sliderHandlerFillColor:r[6],sliderHandlerWidth:10,sliderHandlerHeight:14,sliderHandlerBorder:1,sliderHandlerBorderColor:r[25],annotationArcBorderColor:t[15],annotationArcBorder:1,annotationLineBorderColor:t[25],annotationLineBorder:1,annotationLineDash:null,annotationTextFillColor:t[65],annotationTextFontSize:12,annotationTextLineHeight:12,annotationTextFontWeight:"normal",annotationTextBorderColor:null,annotationTextBorder:0,annotationRegionFillColor:t[100],annotationRegionFillOpacity:.06,annotationRegionBorder:0,annotationRegionBorderColor:null,annotationDataMarkerLineLength:16,tooltipCrosshairsBorderColor:t[25],tooltipCrosshairsBorder:1,tooltipCrosshairsLineDash:null,tooltipContainerFillColor:"#1f1f1f",tooltipContainerFillOpacity:.95,tooltipContainerShadow:"0px 2px 4px rgba(0,0,0,.5)",tooltipContainerBorderRadius:3,tooltipTextFillColor:t[65],tooltipTextFontSize:12,tooltipTextLineHeight:12,tooltipTextFontWeight:"bold",labelFillColor:t[65],labelFillColorDark:"#2c3542",labelFillColorLight:"#ffffff",labelFontSize:12,labelLineHeight:12,labelFontWeight:"normal",labelBorderColor:null,labelBorder:0,innerLabelFillColor:r[100],innerLabelFontSize:12,innerLabelLineHeight:12,innerLabelFontWeight:"normal",innerLabelBorderColor:null,innerLabelBorder:0,overflowLabelFillColor:t[65],overflowLabelFillColorDark:"#2c3542",overflowLabelFillColorLight:"#ffffff",overflowLabelFontSize:12,overflowLabelLineHeight:12,overflowLabelFontWeight:"normal",overflowLabelBorderColor:r[100],overflowLabelBorder:1,labelLineBorder:1,labelLineBorderColor:t[25],cSliderRailHieght:16,cSliderBackgroundFillColor:"#416180",cSliderBackgroundFillOpacity:.05,cSliderForegroundFillColor:"#5B8FF9",cSliderForegroundFillOpacity:.15,cSliderHandlerHeight:24,cSliderHandlerWidth:10,cSliderHandlerFillColor:"#F7F7F7",cSliderHandlerFillOpacity:1,cSliderHandlerHighlightFillColor:"#FFF",cSliderHandlerBorderColor:"#BFBFBF",cSliderHandlerBorder:1,cSliderHandlerBorderRadius:2,cSliderTextFillColor:"#fff",cSliderTextFillOpacity:.45,cSliderTextFontSize:12,cSliderTextLineHeight:12,cSliderTextFontWeight:"normal",cSliderTextBorderColor:null,cSliderTextBorder:0,scrollbarTrackFillColor:"rgba(255,255,255,0.65)",scrollbarThumbFillColor:"rgba(0,0,0,0.35)",scrollbarThumbHighlightFillColor:"rgba(0,0,0,0.45)",pointFillColor:i[0],pointFillOpacity:.95,pointSize:4,pointBorder:1,pointBorderColor:r[100],pointBorderOpacity:1,pointActiveBorderColor:t[100],pointSelectedBorder:2,pointSelectedBorderColor:t[100],pointInactiveFillOpacity:.3,pointInactiveBorderOpacity:.3,hollowPointSize:4,hollowPointBorder:1,hollowPointBorderColor:i[0],hollowPointBorderOpacity:.95,hollowPointFillColor:r[100],hollowPointActiveBorder:1,hollowPointActiveBorderColor:t[100],hollowPointActiveBorderOpacity:1,hollowPointSelectedBorder:2,hollowPointSelectedBorderColor:t[100],hollowPointSelectedBorderOpacity:1,hollowPointInactiveBorderOpacity:.3,lineBorder:2,lineBorderColor:i[0],lineBorderOpacity:1,lineActiveBorder:3,lineSelectedBorder:3,lineInactiveBorderOpacity:.3,areaFillColor:i[0],areaFillOpacity:.25,areaActiveFillColor:i[0],areaActiveFillOpacity:.5,areaSelectedFillColor:i[0],areaSelectedFillOpacity:.5,areaInactiveFillOpacity:.3,hollowAreaBorderColor:i[0],hollowAreaBorder:2,hollowAreaBorderOpacity:1,hollowAreaActiveBorder:3,hollowAreaActiveBorderColor:t[100],hollowAreaSelectedBorder:3,hollowAreaSelectedBorderColor:t[100],hollowAreaInactiveBorderOpacity:.3,intervalFillColor:i[0],intervalFillOpacity:.95,intervalActiveBorder:1,intervalActiveBorderColor:t[100],intervalActiveBorderOpacity:1,intervalSelectedBorder:2,intervalSelectedBorderColor:t[100],intervalSelectedBorderOpacity:1,intervalInactiveBorderOpacity:.3,intervalInactiveFillOpacity:.3,hollowIntervalBorder:2,hollowIntervalBorderColor:i[0],hollowIntervalBorderOpacity:1,hollowIntervalFillColor:r[100],hollowIntervalActiveBorder:2,hollowIntervalActiveBorderColor:t[100],hollowIntervalSelectedBorder:3,hollowIntervalSelectedBorderColor:t[100],hollowIntervalSelectedBorderOpacity:1,hollowIntervalInactiveBorderOpacity:.3}};e.createDarkStyleSheet=o,e.antvDark=(0,e.createDarkStyleSheet)()})(eF);k1("dark",D1(eF.antvDark));k1("default",D1($1.antvLight));k1("light",D1($1.antvLight));var Yut=function(e,r){return e===void 0&&(e=[]),r===void 0&&(r=[]),e.length!==r.length||e.some(function(t,i){return!Object.is(t,r[i])})},k$={error:null},Wut=function(e){v8(r,e);function r(){for(var i,n=arguments.length,a=new Array(n),o=0;o<n;o++)a[o]=arguments[o];return i=e.call.apply(e,[this].concat(a))||this,i.state=k$,i.updatedWithError=!1,i.resetErrorBoundary=function(){for(var l,s=arguments.length,u=new Array(s),c=0;c<s;c++)u[c]=arguments[c];i.props.onReset==null||(l=i.props).onReset.apply(l,u),i.reset()},i}r.getDerivedStateFromError=function(n){return{error:n}};var t=r.prototype;return t.reset=function(){this.updatedWithError=!1,this.setState(k$)},t.componentDidCatch=function(n,a){var o,l;(o=(l=this.props).onError)==null||o.call(l,n,a)},t.componentDidUpdate=function(n){var a=this.state.error,o=this.props.resetKeys;if(a!==null&&!this.updatedWithError){this.updatedWithError=!0;return}if(a!==null&&Yut(n.resetKeys,o)){var l,s;(l=(s=this.props).onResetKeysChange)==null||l.call(s,n.resetKeys,o),this.reset()}},t.render=function(){var n=this.state.error,a=this.props,o=a.fallbackRender,l=a.FallbackComponent,s=a.fallback;if(n!==null){var u={error:n,resetErrorBoundary:this.resetErrorBoundary};if(Pt.isValidElement(s))return s;if(typeof o=="function")return o(u);if(l)return Pt.createElement(l,u);throw new Error("react-error-boundary requires either a fallback, fallbackRender, or FallbackComponent prop")}return this.props.children},r}(Pt.Component),Xut=function(e){var r=e.error;return Pt.createElement("div",{className:"bizcharts-error",role:"alert"},Pt.createElement("p",null,"BizCharts something went wrong:"),Pt.createElement("pre",null,r.message))};function pj(e){return Xut(e)}var Xd=Wut;ut.registerEngine("canvas",yit);ut.registerEngine("svg",aat);var Uut=Dp.Canvas.prototype.getPointByClient;Dp.Canvas.prototype.getPointByClient=function(e,r){var t=Uut.call(this,e,r),i=this.get("el"),n=i.getBoundingClientRect(),a=this.get("width"),o=this.get("height"),l=n.width,s=n.height;return{x:t.x/(l/a),y:t.y/(s/o)}};var qut=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}(),Vl=globalThis&&globalThis.__assign||function(){return Vl=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Vl.apply(this,arguments)};ut.registerComponentController("annotation",xet);var La=function(e){qut(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.annotationType="line",t}return r.prototype.componentDidMount=function(){var t=this.getChartIns();this.id=Oa("annotation"),this.annotation=t.annotation(),this.annotationType==="ReactElement"?this.annotation.annotation(Vl({type:"html",isReactElement:!0},this.props)):this.annotation.annotation(Vl({type:this.annotationType},this.props)),this.annotation.option[this.annotation.option.length-1].__id=this.id},r.prototype.componentDidUpdate=function(){var t=this,i=null;this.annotation.option.forEach(function(n,a){n.__id===t.id&&(i=a)}),this.annotationType==="ReactElement"?this.annotation.option[i]=Vl(Vl({type:"html",isReactElement:!0},this.props),{__id:this.id}):this.annotation.option[i]=Vl(Vl({type:this.annotationType},this.props),{__id:this.id})},r.prototype.componentWillUnmount=function(){var t=this,i=null;!this.annotation||(this.annotation.option.forEach(function(n,a){n.__id===t.id&&(i=a)}),i!==null&&this.annotation.option.splice(i,1),this.annotation=null)},r.prototype.getChartIns=function(){return this.context},r.prototype.render=function(){return Pt.createElement(Pt.Fragment,null)},r}(Pt.Component);La.contextType=Ps;var Zut=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}();(function(e){Zut(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.annotationType="arc",t}return r})(La);var Qut=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}();(function(e){Qut(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.annotationType="dataMarker",t}return r})(La);var Kut=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}();(function(e){Kut(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.annotationType="dataRegion",t}return r})(La);var Jut=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}();(function(e){Jut(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.annotationType="regionFilter",t}return r})(La);var tct=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}();(function(e){tct(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.annotationType="html",t}return r})(La);var ect=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}();(function(e){ect(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.annotationType="ReactElement",t}return r})(La);var rct=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}();(function(e){rct(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.annotationType="image",t}return r})(La);var ict=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}();(function(e){ict(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.annotationType="line",t}return r})(La);var nct=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}();(function(e){nct(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.annotationType="region",t}return r})(La);var act=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}();(function(e){act(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.annotationType="text",t}return r})(La);var gj={},eT={rect:"path",circle:"circle",line:"line",path:"path",marker:"path",text:"text",polyline:"polyline",polygon:"polygon",image:"image",ellipse:"ellipse",dom:"foreignObject"},ee={opacity:"opacity",fillStyle:"fill",fill:"fill",fillOpacity:"fill-opacity",strokeStyle:"stroke",strokeOpacity:"stroke-opacity",stroke:"stroke",x:"x",y:"y",r:"r",rx:"rx",ry:"ry",width:"width",height:"height",x1:"x1",x2:"x2",y1:"y1",y2:"y2",lineCap:"stroke-linecap",lineJoin:"stroke-linejoin",lineWidth:"stroke-width",lineDash:"stroke-dasharray",lineDashOffset:"stroke-dashoffset",miterLimit:"stroke-miterlimit",font:"font",fontSize:"font-size",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",fontFamily:"font-family",startArrow:"marker-start",endArrow:"marker-end",path:"d",class:"class",id:"id",style:"style",preserveAspectRatio:"preserveAspectRatio"};function qn(e){return document.createElementNS("http://www.w3.org/2000/svg",e)}function yj(e){var r=eT[e.type],t=e.getParent();if(!r)throw new Error("the type "+e.type+" is not supported by svg");var i=qn(r);if(e.get("id")&&(i.id=e.get("id")),e.set("el",i),e.set("attrs",{}),t){var n=t.get("el");n||(n=t.createDom(),t.set("el",n)),n.appendChild(i)}return i}function mj(e,r){var t=e.get("el"),i=az(t.children).sort(r),n=document.createDocumentFragment();i.forEach(function(a){n.appendChild(a)}),t.appendChild(n)}function oct(e,r){var t=e.parentNode,i=Array.from(t.childNodes).filter(function(l){return l.nodeType===1&&l.nodeName.toLowerCase()!=="defs"}),n=i[r],a=i.indexOf(e);if(n){if(a>r)t.insertBefore(e,n);else if(a<r){var o=i[r+1];o?t.insertBefore(e,o):t.appendChild(e)}}else t.appendChild(e)}function lct(e,r){var t=e.cfg.el,i=e.attr(),n={dx:i.shadowOffsetX,dy:i.shadowOffsetY,blur:i.shadowBlur,color:i.shadowColor};if(!n.dx&&!n.dy&&!n.blur&&!n.color)t.removeAttribute("filter");else{var a=r.find("filter",n);a||(a=r.addShadow(n)),t.setAttribute("filter","url(#"+a+")")}}function qp(e){var r=e.attr().matrix;if(r){for(var t=e.cfg.el,i=[],n=0;n<9;n+=3)i.push(r[n]+","+r[n+1]);i=i.join(","),i.indexOf("NaN")===-1?t.setAttribute("transform","matrix("+i+")"):console.warn("invalid matrix:",r)}}function Ud(e,r){var t=e.getClip(),i=e.get("el");if(!t)i.removeAttribute("clip-path");else if(t&&!i.hasAttribute("clip-path")){yj(t),t.createPath(r);var n=r.addClip(t);i.setAttribute("clip-path","url(#"+n+")")}}function xj(e,r){r.forEach(function(t){t.draw(e)})}function _j(e,r){var t=e.get("canvas");if(t&&t.get("autoDraw")){var i=t.get("context"),n=e.getParent(),a=n?n.getChildren():[t],o=e.get("el");if(r==="remove"){var l=e.get("isClipShape");if(l){var s=o&&o.parentNode,u=s&&s.parentNode;s&&u&&u.removeChild(s)}else o&&o.parentNode&&o.parentNode.removeChild(o)}else if(r==="show")o.setAttribute("visibility","visible");else if(r==="hide")o.setAttribute("visibility","hidden");else if(r==="zIndex")oct(o,a.indexOf(e));else if(r==="sort"){var c=e.get("children");c&&c.length&&mj(e,function(f,h){return c.indexOf(f)-c.indexOf(h)?1:0})}else r==="clear"?o&&(o.innerHTML=""):r==="matrix"?qp(e):r==="clip"?Ud(e,i):r==="attr"||r==="add"&&e.draw(i)}}var rF=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.isEntityGroup=function(){return!0},r.prototype.createDom=function(){var t=qn("g");this.set("el",t);var i=this.getParent();if(i){var n=i.get("el");n||(n=i.createDom(),i.set("el",n)),n.appendChild(t)}return t},r.prototype.afterAttrsChange=function(t){e.prototype.afterAttrsChange.call(this,t);var i=this.get("canvas");if(i&&i.get("autoDraw")){var n=i.get("context");this.createPath(n,t)}},r.prototype.onCanvasChange=function(t){_j(this,t)},r.prototype.getShapeBase=function(){return qx},r.prototype.getGroupBase=function(){return r},r.prototype.draw=function(t){var i=this.getChildren(),n=this.get("el");this.get("destroyed")?n&&n.parentNode.removeChild(n):(n||this.createDom(),Ud(this,t),this.createPath(t),i.length&&xj(t,i))},r.prototype.createPath=function(t,i){var n=this.attr(),a=this.get("el");P(i||n,function(o,l){ee[l]&&a.setAttribute(ee[l],o)}),qp(this)},r}(wp),sct=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="svg",t.canFill=!1,t.canStroke=!1,t}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return A(A({},t),{lineWidth:1,lineAppendWidth:0,strokeOpacity:1,fillOpacity:1})},r.prototype.afterAttrsChange=function(t){e.prototype.afterAttrsChange.call(this,t);var i=this.get("canvas");if(i&&i.get("autoDraw")){var n=i.get("context");this.draw(n,t)}},r.prototype.getShapeBase=function(){return qx},r.prototype.getGroupBase=function(){return rF},r.prototype.onCanvasChange=function(t){_j(this,t)},r.prototype.calculateBBox=function(){var t=this.get("el"),i=null;if(t)i=t.getBBox();else{var n=Sp(this.get("type"));n&&(i=n(this))}if(i){var a=i.x,o=i.y,l=i.width,s=i.height,u=this.getHitLineWidth(),c=u/2,f=a-c,h=o-c,v=a+l+c,d=o+s+c;return{x:f,y:h,minX:f,minY:h,maxX:v,maxY:d,width:l+u,height:s+u}}return{x:0,y:0,minX:0,minY:0,maxX:0,maxY:0,width:0,height:0}},r.prototype.isFill=function(){var t=this.attr(),i=t.fill,n=t.fillStyle;return(i||n||this.isClipShape())&&this.canFill},r.prototype.isStroke=function(){var t=this.attr(),i=t.stroke,n=t.strokeStyle;return(i||n)&&this.canStroke},r.prototype.draw=function(t,i){var n=this.get("el");this.get("destroyed")?n&&n.parentNode.removeChild(n):(n||yj(this),Ud(this,t),this.createPath(t,i),this.shadow(t,i),this.strokeAndFill(t,i),this.transform(i))},r.prototype.createPath=function(t,i){},r.prototype.strokeAndFill=function(t,i){var n=i||this.attr(),a=n.fill,o=n.fillStyle,l=n.stroke,s=n.strokeStyle,u=n.fillOpacity,c=n.strokeOpacity,f=n.lineWidth,h=this.get("el");this.canFill&&(i?"fill"in n?this._setColor(t,"fill",a):"fillStyle"in n&&this._setColor(t,"fill",o):this._setColor(t,"fill",a||o),u&&h.setAttribute(ee.fillOpacity,u)),this.canStroke&&f>0&&(i?"stroke"in n?this._setColor(t,"stroke",l):"strokeStyle"in n&&this._setColor(t,"stroke",s):this._setColor(t,"stroke",l||s),c&&h.setAttribute(ee.strokeOpacity,c),f&&h.setAttribute(ee.lineWidth,f))},r.prototype._setColor=function(t,i,n){var a=this.get("el");if(!n){a.setAttribute(ee[i],"none");return}if(n=n.trim(),/^[r,R,L,l]{1}[\s]*\(/.test(n)){var o=t.find("gradient",n);o||(o=t.addGradient(n)),a.setAttribute(ee[i],"url(#"+o+")")}else if(/^[p,P]{1}[\s]*\(/.test(n)){var o=t.find("pattern",n);o||(o=t.addPattern(n)),a.setAttribute(ee[i],"url(#"+o+")")}else a.setAttribute(ee[i],n)},r.prototype.shadow=function(t,i){var n=this.attr(),a=i||n,o=a.shadowOffsetX,l=a.shadowOffsetY,s=a.shadowBlur,u=a.shadowColor;(o||l||s||u)&&lct(this,t)},r.prototype.transform=function(t){var i=this.attr(),n=(t||i).matrix;n&&qp(this)},r.prototype.isInShape=function(t,i){return this.isPointInPath(t,i)},r.prototype.isPointInPath=function(t,i){var n=this.get("el"),a=this.get("canvas"),o=a.get("el").getBoundingClientRect(),l=t+o.left,s=i+o.top,u=document.elementFromPoint(l,s);return!!(u&&u.isEqualNode(n))},r.prototype.getHitLineWidth=function(){var t=this.attrs,i=t.lineWidth,n=t.lineAppendWidth;return this.isStroke()?i+n:0},r}(Cp),ea=sct,uct=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="circle",t.canFill=!0,t.canStroke=!0,t}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return A(A({},t),{x:0,y:0,r:0})},r.prototype.createPath=function(t,i){var n=this.attr(),a=this.get("el");P(i||n,function(o,l){l==="x"||l==="y"?a.setAttribute("c"+l,o):ee[l]&&a.setAttribute(ee[l],o)})},r}(ea),cct=uct,fct=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="dom",t.canFill=!1,t.canStroke=!1,t}return r.prototype.createPath=function(t,i){var n=this.attr(),a=this.get("el");if(P(i||n,function(u,c){ee[c]&&a.setAttribute(ee[c],u)}),typeof n.html=="function"){var o=n.html.call(this,n);if(o instanceof Element||o instanceof HTMLDocument){for(var l=a.childNodes,s=l.length-1;s>=0;s--)a.removeChild(l[s]);a.appendChild(o)}else a.innerHTML=o}else a.innerHTML=n.html},r}(ea),hct=fct,vct=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="ellipse",t.canFill=!0,t.canStroke=!0,t}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return A(A({},t),{x:0,y:0,rx:0,ry:0})},r.prototype.createPath=function(t,i){var n=this.attr(),a=this.get("el");P(i||n,function(o,l){l==="x"||l==="y"?a.setAttribute("c"+l,o):ee[l]&&a.setAttribute(ee[l],o)})},r}(ea),dct=vct,pct=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="image",t.canFill=!1,t.canStroke=!1,t}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return A(A({},t),{x:0,y:0,width:0,height:0})},r.prototype.createPath=function(t,i){var n=this,a=this.attr(),o=this.get("el");P(i||a,function(l,s){s==="img"?n._setImage(a.img):ee[s]&&o.setAttribute(ee[s],l)})},r.prototype.setAttr=function(t,i){this.attrs[t]=i,t==="img"&&this._setImage(i)},r.prototype._setImage=function(t){var i=this.attr(),n=this.get("el");if(Ct(t))n.setAttribute("href",t);else if(t instanceof window.Image)i.width||(n.setAttribute("width",t.width),this.attr("width",t.width)),i.height||(n.setAttribute("height",t.height),this.attr("height",t.height)),n.setAttribute("href",t.src);else if(t instanceof HTMLElement&&Ct(t.nodeName)&&t.nodeName.toUpperCase()==="CANVAS")n.setAttribute("href",t.toDataURL());else if(t instanceof ImageData){var a=document.createElement("canvas");a.setAttribute("width",""+t.width),a.setAttribute("height",""+t.height),a.getContext("2d").putImageData(t,0,0),i.width||(n.setAttribute("width",""+t.width),this.attr("width",t.width)),i.height||(n.setAttribute("height",""+t.height),this.attr("height",t.height)),n.setAttribute("href",a.toDataURL())}},r}(ea),gct=pct,yct=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="line",t.canFill=!1,t.canStroke=!0,t}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return A(A({},t),{x1:0,y1:0,x2:0,y2:0,startArrow:!1,endArrow:!1})},r.prototype.createPath=function(t,i){var n=this.attr(),a=this.get("el");P(i||n,function(o,l){if(l==="startArrow"||l==="endArrow")if(o){var s=Zt(o)?t.addArrow(n,ee[l]):t.getDefaultArrow(n,ee[l]);a.setAttribute(ee[l],"url(#"+s+")")}else a.removeAttribute(ee[l]);else ee[l]&&a.setAttribute(ee[l],o)})},r.prototype.getTotalLength=function(){var t=this.attr(),i=t.x1,n=t.y1,a=t.x2,o=t.y2;return Er.length(i,n,a,o)},r.prototype.getPoint=function(t){var i=this.attr(),n=i.x1,a=i.y1,o=i.x2,l=i.y2;return Er.pointAt(n,a,o,l,t)},r}(ea),mct=yct,ym={circle:function(e,r,t){return[["M",e,r],["m",-t,0],["a",t,t,0,1,0,t*2,0],["a",t,t,0,1,0,-t*2,0]]},square:function(e,r,t){return[["M",e-t,r-t],["L",e+t,r-t],["L",e+t,r+t],["L",e-t,r+t],["Z"]]},diamond:function(e,r,t){return[["M",e-t,r],["L",e,r-t],["L",e+t,r],["L",e,r+t],["Z"]]},triangle:function(e,r,t){var i=t*Math.sin(.3333333333333333*Math.PI);return[["M",e-t,r+i],["L",e,r-i],["L",e+t,r+i],["z"]]},triangleDown:function(e,r,t){var i=t*Math.sin(.3333333333333333*Math.PI);return[["M",e-t,r-i],["L",e+t,r-i],["L",e,r+i],["Z"]]}},R$={get:function(e){return ym[e]},register:function(e,r){ym[e]=r},remove:function(e){delete ym[e]},getAll:function(){return ym}},xct=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="marker",t.canFill=!0,t.canStroke=!0,t}return r.prototype.createPath=function(t){var i=this.get("el");i.setAttribute("d",this._assembleMarker())},r.prototype._assembleMarker=function(){var t=this._getPath();return it(t)?t.map(function(i){return i.join(" ")}).join(""):t},r.prototype._getPath=function(){var t=this.attr(),i=t.x,n=t.y,a=t.r||t.radius,o=t.symbol||"circle",l;return pt(o)?l=o:l=R$.get(o),l?l(i,n,a):(console.warn(l+" symbol is not exist."),null)},r.symbolsFactory=R$,r}(ea),_ct=xct,bct=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="path",t.canFill=!0,t.canStroke=!0,t}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return A(A({},t),{startArrow:!1,endArrow:!1})},r.prototype.createPath=function(t,i){var n=this,a=this.attr(),o=this.get("el");P(i||a,function(l,s){if(s==="path"&&it(l))o.setAttribute("d",n._formatPath(l));else if(s==="startArrow"||s==="endArrow")if(l){var u=Zt(l)?t.addArrow(a,ee[s]):t.getDefaultArrow(a,ee[s]);o.setAttribute(ee[s],"url(#"+u+")")}else o.removeAttribute(ee[s]);else ee[s]&&o.setAttribute(ee[s],l)})},r.prototype._formatPath=function(t){var i=t.map(function(n){return n.join(" ")}).join("");return~i.indexOf("NaN")?"":i},r.prototype.getTotalLength=function(){var t=this.get("el");return t?t.getTotalLength():null},r.prototype.getPoint=function(t){var i=this.get("el"),n=this.getTotalLength();if(n===0)return null;var a=i?i.getPointAtLength(t*n):null;return a?{x:a.x,y:a.y}:null},r}(ea),wct=bct,Cct=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="polygon",t.canFill=!0,t.canStroke=!0,t}return r.prototype.createPath=function(t,i){var n=this.attr(),a=this.get("el");P(i||n,function(o,l){l==="points"&&it(o)&&o.length>=2?a.setAttribute("points",o.map(function(s){return s[0]+","+s[1]}).join(" ")):ee[l]&&a.setAttribute(ee[l],o)})},r}(ea),Sct=Cct,Act=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="polyline",t.canFill=!0,t.canStroke=!0,t}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return A(A({},t),{startArrow:!1,endArrow:!1})},r.prototype.onAttrChange=function(t,i,n){e.prototype.onAttrChange.call(this,t,i,n),["points"].indexOf(t)!==-1&&this._resetCache()},r.prototype._resetCache=function(){this.set("totalLength",null),this.set("tCache",null)},r.prototype.createPath=function(t,i){var n=this.attr(),a=this.get("el");P(i||n,function(o,l){l==="points"&&it(o)&&o.length>=2?a.setAttribute("points",o.map(function(s){return s[0]+","+s[1]}).join(" ")):ee[l]&&a.setAttribute(ee[l],o)})},r.prototype.getTotalLength=function(){var t=this.attr().points,i=this.get("totalLength");return K(i)?(this.set("totalLength",u1.length(t)),this.get("totalLength")):i},r.prototype.getPoint=function(t){var i=this.attr().points,n=this.get("tCache");n||(this._setTcache(),n=this.get("tCache"));var a,o;return P(n,function(l,s){t>=l[0]&&t<=l[1]&&(a=(t-l[0])/(l[1]-l[0]),o=s)}),Er.pointAt(i[o][0],i[o][1],i[o+1][0],i[o+1][1],a)},r.prototype._setTcache=function(){var t=this.attr().points;if(!(!t||t.length===0)){var i=this.getTotalLength();if(!(i<=0)){var n=0,a=[],o,l;P(t,function(s,u){t[u+1]&&(o=[],o[0]=n/i,l=Er.length(s[0],s[1],t[u+1][0],t[u+1][1]),n+=l,o[1]=n/i,a.push(o))}),this.set("tCache",a)}}},r.prototype.getStartTangent=function(){var t=this.attr().points,i=[];return i.push([t[1][0],t[1][1]]),i.push([t[0][0],t[0][1]]),i},r.prototype.getEndTangent=function(){var t=this.attr().points,i=t.length-1,n=[];return n.push([t[i-1][0],t[i-1][1]]),n.push([t[i][0],t[i][1]]),n},r}(ea),Tct=Act;function Mct(e){var r=0,t=0,i=0,n=0;return it(e)?e.length===1?r=t=i=n=e[0]:e.length===2?(r=i=e[0],t=n=e[1]):e.length===3?(r=e[0],t=n=e[1],i=e[2]):(r=e[0],t=e[1],i=e[2],n=e[3]):r=t=i=n=e,{r1:r,r2:t,r3:i,r4:n}}var Ect=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="rect",t.canFill=!0,t.canStroke=!0,t}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return A(A({},t),{x:0,y:0,width:0,height:0,radius:0})},r.prototype.createPath=function(t,i){var n=this,a=this.attr(),o=this.get("el"),l=!1,s=["x","y","width","height","radius"];P(i||a,function(u,c){s.indexOf(c)!==-1&&!l?(o.setAttribute("d",n._assembleRect(a)),l=!0):s.indexOf(c)===-1&&ee[c]&&o.setAttribute(ee[c],u)})},r.prototype._assembleRect=function(t){var i=t.x,n=t.y,a=t.width,o=t.height,l=t.radius;if(!l)return"M "+i+","+n+" l "+a+",0 l 0,"+o+" l"+-a+" 0 z";var s=Mct(l);it(l)?l.length===1?s.r1=s.r2=s.r3=s.r4=l[0]:l.length===2?(s.r1=s.r3=l[0],s.r2=s.r4=l[1]):l.length===3?(s.r1=l[0],s.r2=s.r4=l[1],s.r3=l[2]):(s.r1=l[0],s.r2=l[1],s.r3=l[2],s.r4=l[3]):s.r1=s.r2=s.r3=s.r4=l;var u=[["M "+(i+s.r1)+","+n],["l "+(a-s.r1-s.r2)+",0"],["a "+s.r2+","+s.r2+",0,0,1,"+s.r2+","+s.r2],["l 0,"+(o-s.r2-s.r3)],["a "+s.r3+","+s.r3+",0,0,1,"+-s.r3+","+s.r3],["l "+(s.r3+s.r4-a)+",0"],["a "+s.r4+","+s.r4+",0,0,1,"+-s.r4+","+-s.r4],["l 0,"+(s.r4+s.r1-o)],["a "+s.r1+","+s.r1+",0,0,1,"+s.r1+","+-s.r1],["z"]];return u.join(" ")},r}(ea),Fct=Ect,B$=.3,Oct={top:"before-edge",middle:"central",bottom:"after-edge",alphabetic:"baseline",hanging:"hanging"},Pct={top:"text-before-edge",middle:"central",bottom:"text-after-edge",alphabetic:"alphabetic",hanging:"hanging"},Ict={left:"left",start:"left",center:"middle",right:"end",end:"end"},Lct=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="text",t.canFill=!0,t.canStroke=!0,t}return r.prototype.getDefaultAttrs=function(){var t=e.prototype.getDefaultAttrs.call(this);return A(A({},t),{x:0,y:0,text:null,fontSize:12,fontFamily:"sans-serif",fontStyle:"normal",fontWeight:"normal",fontVariant:"normal",textAlign:"start",textBaseline:"bottom"})},r.prototype.createPath=function(t,i){var n=this,a=this.attr(),o=this.get("el");this._setFont(),P(i||a,function(l,s){s==="text"?n._setText(""+l):s==="matrix"&&l?qp(n):ee[s]&&o.setAttribute(ee[s],l)}),o.setAttribute("paint-order","stroke"),o.setAttribute("style","stroke-linecap:butt; stroke-linejoin:miter;")},r.prototype._setFont=function(){var t=this.get("el"),i=this.attr(),n=i.textBaseline,a=i.textAlign,o=gM();o&&o.name==="firefox"?t.setAttribute("dominant-baseline",Pct[n]||"alphabetic"):t.setAttribute("alignment-baseline",Oct[n]||"baseline"),t.setAttribute("text-anchor",Ict[a]||"left")},r.prototype._setText=function(t){var i=this.get("el"),n=this.attr(),a=n.x,o=n.textBaseline,l=o===void 0?"bottom":o;if(!t)i.innerHTML="";else if(~t.indexOf(`
|
|
`)){var s=t.split(`
|
|
`),u=s.length-1,c="";P(s,function(f,h){h===0?l==="alphabetic"?c+='<tspan x="'+a+'" dy="'+-u+'em">'+f+"</tspan>":l==="top"?c+='<tspan x="'+a+'" dy="0.9em">'+f+"</tspan>":l==="middle"?c+='<tspan x="'+a+'" dy="'+-(u-1)/2+'em">'+f+"</tspan>":l==="bottom"?c+='<tspan x="'+a+'" dy="-'+(u+B$)+'em">'+f+"</tspan>":l==="hanging"&&(c+='<tspan x="'+a+'" dy="'+(-(u-1)-B$)+'em">'+f+"</tspan>"):c+='<tspan x="'+a+'" dy="1em">'+f+"</tspan>"}),i.innerHTML=c}else i.innerHTML=t},r}(ea),Dct=Lct,$ct=/^l\s*\(\s*([\d.]+)\s*\)\s*(.*)/i,kct=/^r\s*\(\s*([\d.]+)\s*,\s*([\d.]+)\s*,\s*([\d.]+)\s*\)\s*(.*)/i,Rct=/[\d.]+:(#[^\s]+|[^)]+\))/gi;function bj(e){var r=e.match(Rct);if(!r)return"";var t="";return r.sort(function(i,n){return i=i.split(":"),n=n.split(":"),Number(i[0])-Number(n[0])}),P(r,function(i){i=i.split(":"),t+='<stop offset="'+i[0]+'" stop-color="'+i[1]+'"></stop>'}),t}function Bct(e,r){var t=$ct.exec(e),i=Kx(Jx(parseFloat(t[1])),Math.PI*2),n=t[2],a,o;i>=0&&i<.5*Math.PI?(a={x:0,y:0},o={x:1,y:1}):.5*Math.PI<=i&&i<Math.PI?(a={x:1,y:0},o={x:0,y:1}):Math.PI<=i&&i<1.5*Math.PI?(a={x:1,y:1},o={x:0,y:0}):(a={x:0,y:1},o={x:1,y:0});var l=Math.tan(i),s=l*l,u=(o.x-a.x+l*(o.y-a.y))/(s+1)+a.x,c=l*(o.x-a.x+l*(o.y-a.y))/(s+1)+a.y;r.setAttribute("x1",a.x),r.setAttribute("y1",a.y),r.setAttribute("x2",u),r.setAttribute("y2",c),r.innerHTML=bj(n)}function Nct(e,r){var t=kct.exec(e),i=parseFloat(t[1]),n=parseFloat(t[2]),a=parseFloat(t[3]),o=t[4];r.setAttribute("cx",i),r.setAttribute("cy",n),r.setAttribute("r",a),r.innerHTML=bj(o)}var Gct=function(){function e(r){this.cfg={};var t=null,i=Oa("gradient_");return r.toLowerCase()[0]==="l"?(t=qn("linearGradient"),Bct(r,t)):(t=qn("radialGradient"),Nct(r,t)),t.setAttribute("id",i),this.el=t,this.id=i,this.cfg=r,this}return e.prototype.match=function(r,t){return this.cfg===t},e}(),zct={shadowColor:"color",shadowOpacity:"opacity",shadowBlur:"blur",shadowOffsetX:"dx",shadowOffsetY:"dy"},Vct={x:"-40%",y:"-40%",width:"200%",height:"200%"},jct=function(){function e(r){this.type="filter",this.cfg={},this.type="filter";var t=qn("filter");return P(Vct,function(i,n){t.setAttribute(n,i)}),this.el=t,this.id=Oa("filter_"),this.el.id=this.id,this.cfg=r,this._parseShadow(r,t),this}return e.prototype.match=function(r,t){if(this.type!==r)return!1;var i=!0,n=this.cfg;return P(Object.keys(n),function(a){if(n[a]!==t[a])return i=!1,!1}),i},e.prototype.update=function(r,t){var i=this.cfg;return i[zct[r]]=t,this._parseShadow(i,this.el),this},e.prototype._parseShadow=function(r,t){var i=`<feDropShadow
|
|
dx="`+(r.dx||0)+`"
|
|
dy="`+(r.dy||0)+`"
|
|
stdDeviation="`+(r.blur?r.blur/10:0)+`"
|
|
flood-color="`+(r.color?r.color:"#000")+`"
|
|
flood-opacity="`+(r.opacity?r.opacity:1)+`"
|
|
/>`;t.innerHTML=i},e}(),N$=function(){function e(r,t){this.cfg={};var i=qn("marker"),n=Oa("marker_");i.setAttribute("id",n);var a=qn("path");a.setAttribute("stroke",r.stroke||"none"),a.setAttribute("fill",r.fill||"none"),i.appendChild(a),i.setAttribute("overflow","visible"),i.setAttribute("orient","auto-start-reverse"),this.el=i,this.child=a,this.id=n;var o=r[t==="marker-start"?"startArrow":"endArrow"];return this.stroke=r.stroke||"#000",o===!0?this._setDefaultPath(t,a):(this.cfg=o,this._setMarker(r.lineWidth,a)),this}return e.prototype.match=function(){return!1},e.prototype._setDefaultPath=function(r,t){var i=this.el;t.setAttribute("d","M0,0 L"+10*Math.cos(Math.PI/6)+",5 L0,10"),i.setAttribute("refX",""+10*Math.cos(Math.PI/6)),i.setAttribute("refY",""+5)},e.prototype._setMarker=function(r,t){var i=this.el,n=this.cfg.path,a=this.cfg.d;it(n)&&(n=n.map(function(o){return o.join(" ")}).join("")),t.setAttribute("d",n),i.appendChild(t),a&&i.setAttribute("refX",""+a/r)},e.prototype.update=function(r){var t=this.child;t.attr?t.attr("fill",r):t.setAttribute("fill",r)},e}(),Hct=function(){function e(r){this.type="clip",this.cfg={};var t=qn("clipPath");this.el=t,this.id=Oa("clip_"),t.id=this.id;var i=r.cfg.el;return t.appendChild(i),this.cfg=r,this}return e.prototype.match=function(){return!1},e.prototype.remove=function(){var r=this.el;r.parentNode.removeChild(r)},e}(),Yct=/^p\s*\(\s*([axyn])\s*\)\s*(.*)/i,Wct=function(){function e(r){this.cfg={};var t=qn("pattern");t.setAttribute("patternUnits","userSpaceOnUse");var i=qn("image");t.appendChild(i);var n=Oa("pattern_");t.id=n,this.el=t,this.id=n,this.cfg=r;var a=Yct.exec(r),o=a[2];i.setAttribute("href",o);var l=new Image;o.match(/^data:/i)||(l.crossOrigin="Anonymous"),l.src=o;function s(){t.setAttribute("width",""+l.width),t.setAttribute("height",""+l.height)}return l.complete?s():(l.onload=s,l.src=l.src),this}return e.prototype.match=function(r,t){return this.cfg===t},e}(),Xct=function(){function e(r){var t=qn("defs"),i=Oa("defs_");t.id=i,r.appendChild(t),this.children=[],this.defaultArrow={},this.el=t,this.canvas=r}return e.prototype.find=function(r,t){for(var i=this.children,n=null,a=0;a<i.length;a++)if(i[a].match(r,t)){n=i[a].id;break}return n},e.prototype.findById=function(r){for(var t=this.children,i=null,n=0;n<t.length;n++)if(t[n].id===r){i=t[n];break}return i},e.prototype.add=function(r){this.children.push(r),r.canvas=this.canvas,r.parent=this},e.prototype.getDefaultArrow=function(r,t){var i=r.stroke||r.strokeStyle;if(this.defaultArrow[i])return this.defaultArrow[i].id;var n=new N$(r,t);return this.defaultArrow[i]=n,this.el.appendChild(n.el),this.add(n),n.id},e.prototype.addGradient=function(r){var t=new Gct(r);return this.el.appendChild(t.el),this.add(t),t.id},e.prototype.addArrow=function(r,t){var i=new N$(r,t);return this.el.appendChild(i.el),this.add(i),i.id},e.prototype.addShadow=function(r){var t=new jct(r);return this.el.appendChild(t.el),this.add(t),t.id},e.prototype.addPattern=function(r){var t=new Wct(r);return this.el.appendChild(t.el),this.add(t),t.id},e.prototype.addClip=function(r){var t=new Hct(r);return this.el.appendChild(t.el),this.add(t),t.id},e}(),wj=function(e){X(r,e);function r(t){return e.call(this,A(A({},t),{autoDraw:!0,renderer:"svg"}))||this}return r.prototype.getShapeBase=function(){return qx},r.prototype.getGroupBase=function(){return rF},r.prototype.getShape=function(t,i,n){var a=n.target||n.srcElement;if(!eT[a.tagName]){for(var o=a.parentNode;o&&!eT[o.tagName];)o=o.parentNode;a=o}return this.find(function(l){return l.get("el")===a})},r.prototype.createDom=function(){var t=qn("svg"),i=new Xct(t);return t.setAttribute("width",""+this.get("width")),t.setAttribute("height",""+this.get("height")),this.set("context",i),t},r.prototype.onCanvasChange=function(t){var i=this.get("context"),n=this.get("el");if(t==="sort"){var a=this.get("children");a&&a.length&&mj(this,function(l,s){return a.indexOf(l)-a.indexOf(s)?1:0})}else if(t==="clear"){if(n){n.innerHTML="";var o=i.el;o.innerHTML="",n.appendChild(o)}}else t==="matrix"?qp(this):t==="clip"?Ud(this,i):t==="changeSize"&&(n.setAttribute("width",""+this.get("width")),n.setAttribute("height",""+this.get("height")))},r.prototype.draw=function(){var t=this.get("context"),i=this.getChildren();Ud(this,t),i.length&&xj(t,i)},r}(bp),Uct="0.5.6",Cj=Object.freeze(Object.defineProperty({__proto__:null,Shape:qx,version:Uct,Canvas:wj,Group:rF,Event:bh,Base:mp,AbstractCanvas:bp,AbstractGroup:wp,AbstractShape:Cp,getBBoxMethod:Sp,registerBBox:wn,getTextHeight:Mp,assembleFont:Ep,isAllowCapture:$f,multiplyVec2:ro,invert:xp,getOffScreenContext:Tp,registerEasing:MM,PathUtil:a1},Symbol.toStringTag,{value:"Module"})),qct=br(Cj),iF={},Zp={},Sj={},xn={};Object.defineProperty(xn,"__esModule",{value:!0});xn.getSmoothViolinPath=xn.getViolinPath=xn.getPathPoints=void 0;var G$=Y,z$=fc;function ZC(e){return e?!1:e==null||isNaN(e)}function V$(e){if((0,G$.isArray)(e))return ZC(e[1].y);var r=e.y;return(0,G$.isArray)(r)?ZC(r[0]):ZC(r)}function Zct(e,r,t){if(r===void 0&&(r=!1),t===void 0&&(t=!0),!e.length||e.length===1&&!t)return[];if(r){for(var i=[],n=0,a=e.length;n<a;n++){var o=e[n];V$(o)||i.push(o)}return[i]}for(var l=[],s=[],n=0,a=e.length;n<a;n++){var o=e[n];V$(o)?s.length&&(s.length===1&&!t||l.push(s),s=[]):s.push(o)}return s.length&&l.push(s),l}xn.getPathPoints=Zct;function Qct(e){for(var r=[],t=0;t<e.length;t++){var i=e[t];if(i){var n=t===0?"M":"L";r.push([n,i.x,i.y])}}var a=e[0];return a&&(r.push(["L",a.x,a.y]),r.push(["z"])),r}xn.getViolinPath=Qct;function Kct(e){for(var r=e.length/2,t=[],i=[],n=0;n<e.length;n++)n<r?t.push(e[n]):i.push(e[n]);var a=(0,z$.getSplinePath)(t,!1),o=(0,z$.getSplinePath)(i,!1);i.length&&a.push(["L",i[0].x,i[0].y]),o.shift();var l=a.concat(o);return t.length&&l.push(["L",t[0].x,t[0].y]),l.push(["z"]),l}xn.getSmoothViolinPath=Kct;var ke={};Object.defineProperty(ke,"__esModule",{value:!0});ke.getBackgroundRectStyle=ke.getStyle=void 0;var j$=V,cx=Y;function Jct(e,r,t,i){i===void 0&&(i="");var n=e.style,a=n===void 0?{}:n,o=e.defaultStyle,l=e.color,s=e.size,u=(0,j$.__assign)((0,j$.__assign)({},o),a);return l&&(r&&(a.stroke||(u.stroke=l)),t&&(a.fill||(u.fill=l))),i&&(0,cx.isNil)(a[i])&&!(0,cx.isNil)(s)&&(u[i]=s),u}ke.getStyle=Jct;function tft(e){return(0,cx.deepMix)({},{fill:"#CCD6EC",fillOpacity:.3},(0,cx.get)(e,["background","style"]))}ke.getBackgroundRectStyle=tft;var Ph={};Object.defineProperty(Ph,"__esModule",{value:!0});Ph.splitPoints=void 0;var H$=Y;function eft(e){var r=e.x,t=(0,H$.isArray)(e.y)?e.y:[e.y];return t.map(function(i,n){return{x:(0,H$.isArray)(r)?r[n]:r,y:i}})}Ph.splitPoints=eft;var Qp={};Object.defineProperty(Qp,"__esModule",{value:!0});Qp.getLineMarker=void 0;var rft={line:function(e,r,t){return[["M",e-t,r],["L",e+t,r]]},dot:function(e,r,t){return[["M",e-t,r],["L",e+t,r]]},dash:function(e,r,t){return[["M",e-t,r],["L",e+t,r]]},smooth:function(e,r,t){return[["M",e-t,r],["A",t/2,t/2,0,1,1,e,r],["A",t/2,t/2,0,1,0,e+t,r]]},hv:function(e,r,t){return[["M",e-t-1,r-2.5],["L",e,r-2.5],["L",e,r+2.5],["L",e+t+1,r+2.5]]},vh:function(e,r,t){return[["M",e-t-1,r+2.5],["L",e,r+2.5],["L",e,r-2.5],["L",e+t+1,r-2.5]]},hvh:function(e,r,t){return[["M",e-(t+1),r+2.5],["L",e-t/2,r+2.5],["L",e-t/2,r-2.5],["L",e+t/2,r-2.5],["L",e+t/2,r+2.5],["L",e+t+1,r+2.5]]},vhv:function(e,r){return[["M",e-5,r+2.5],["L",e-5,r],["L",e,r],["L",e,r-3],["L",e,r+3],["L",e+6.5,r+3]]}};function ift(e,r){var t=e.color;return{symbol:rft[r],style:{lineWidth:2,r:6,stroke:t}}}Qp.getLineMarker=ift;Object.defineProperty(Sj,"__esModule",{value:!0});var nF=Y,Aj=re,nft=xn,aft=ke,Y$=fc,oft=Ph,lft=Qp;function sft(e,r,t){for(var i=e.isStack,n=e.connectNulls,a=e.isInCircle,o=e.showSinglePoint,l=(0,aft.getStyle)(e,!0,!1,"lineWidth"),s=(0,nft.getPathPoints)(e.points,n,o),u=[],c=0,f=s.length;c<f;c++){var h=s[c];u=u.concat(cft(h,a,i,r,t,l))}return l.path=u,l}function rT(e,r,t,i,n){if(e.length===1)return[["M",e[0].x,e[0].y-n.lineWidth/2],["L",e[0].x,e[0].y],["L",e[0].x,e[0].y+n.lineWidth/2]];var a;return t?(r&&e.length&&e.push({x:e[0].x,y:e[0].y}),a=(0,Y$.getSplinePath)(e,!1,i)):(a=(0,Y$.getLinePath)(e,!1),r&&a.push(["Z"])),a}function uft(e,r,t,i,n,a){var o=[],l=[];(0,nF.each)(e,function(c){var f=(0,oft.splitPoints)(c);o.push(f[1]),l.push(f[0])});var s=rT(o,r,i,n,a),u=rT(l,r,i,n,a);return t?s:s.concat(u)}function cft(e,r,t,i,n,a){if(e.length){var o=e[0];return(0,nF.isArray)(o.y)?uft(e,r,t,i,n,a):rT(e,r,i,n,a)}return[]}var fft=(0,Aj.registerShapeFactory)("line",{defaultShapeType:"line"});(0,nF.each)(["line","dot","dash","smooth"],function(e){(0,Aj.registerShape)("line",e,{draw:function(r,t){var i=e==="smooth",n;if(i){var a=this.coordinate,o=a.start,l=a.end;n=[[o.x,l.y],[l.x,o.y]]}var s=sft(r,i,n),u=t.addShape({type:"path",attrs:s,name:"line",capture:!i});return u},getMarker:function(r){return(0,lft.getLineMarker)(r,e)}})});Sj.default=fft;Object.defineProperty(Zp,"__esModule",{value:!0});var aF=V,hft=Jt,vft=(0,aF.__importDefault)(Pa),dft=(0,aF.__importDefault)(Yp),pft=Wp,gft=Xp,yft=function(e){(0,aF.__extends)(r,e);function r(t){var i=e.call(this,t)||this;i.type="path",i.shapeType="line";var n=t.connectNulls,a=n===void 0?!1:n,o=t.showSinglePoint,l=o===void 0?!0:o;return i.connectNulls=a,i.showSinglePoint=l,i}return r.prototype.updateElements=function(t,i){i===void 0&&(i=!1);for(var n=new Map,a=new Map,o=[],l=0,s=0;s<t.length;s++){var u=t[s],c=this.getElementId(u);o.push(c),n.set(c,u),a.set(c,l),l++}this.elements=new Array(l);for(var f=(0,gft.diff)(this.lastElementsMap,o),h=f.added,v=f.updated,d=f.removed,p=0,x=h;p<x.length;p++){var c=x[p],u=n.get(c),m=this.getShapeFactory(),_=this.getShapeInfo(u),s=a.get(c),b=new dft.default({shapeFactory:m,container:this.container,offscreenGroup:this.getOffscreenGroup(),elementIndex:s});b.geometry=this,b.animate=this.animateOption,b.draw(_,i),this.elementsMap[c]=b,this.elements[s]=b}for(var w=0,S=v;w<S.length;w++){var c=S[w],u=n.get(c),b=this.lastElementsMap[c],s=a.get(c),_=this.getShapeInfo(u),M=b.getModel();(this.isCoordinateChanged||(0,pft.isModelChange)(M,_))&&(b.animate=this.animateOption,b.update(_)),this.elementsMap[c]=b,this.elements[s]=b}for(var F=0,O=d;F<O.length;F++){var c=O[F],b=this.lastElementsMap[c];b.animate=this.animateOption,b.destroy()}},r.prototype.getPointsAndData=function(t){for(var i=[],n=[],a=0,o=t.length;a<o;a++){var l=t[a];i.push({x:l.x,y:l.y}),n.push(l[hft.FIELD_ORIGIN])}return{points:i,data:n}},r.prototype.getShapeInfo=function(t){var i=this.getDrawCfg(t[0]),n=this.getPointsAndData(t),a=n.points,o=n.data;return i.mappingData=t,i.data=o,i.isStack=!!this.getAdjust("stack"),i.points=a,i.connectNulls=this.connectNulls,i.showSinglePoint=this.showSinglePoint,i},r}(vft.default),mft=Zp.default=yft,Tj={},ll={};Object.defineProperty(ll,"__esModule",{value:!0});var Mj=ll.getConstraint=oF=ll.getShapeAttrs=void 0,xft=Y,_ft=xn,bft=ke,W$=fc;function wft(e,r,t,i,n){var a=[];if(e.length){for(var o=[],l=[],s=0,u=e.length;s<u;s++){var c=e[s];o.push(c[1]),l.push(c[0])}l=l.reverse(),(0,xft.each)([o,l],function(f,h){var v=[],d=i.parsePoints(f),p=d[0];o.length===1&&l.length===1?v=h===0?[["M",p.x-.5,p.y],["L",p.x+.5,p.y]]:[["L",p.x+.5,p.y],["L",p.x-.5,p.y]]:(r&&d.push({x:p.x,y:p.y}),t?v=(0,W$.getSplinePath)(d,!1,n):v=(0,W$.getLinePath)(d,!1),h>0&&(v[0][0]="L")),a=a.concat(v)}),a.push(["Z"])}return a}function Cft(e,r,t,i,n){for(var a=(0,bft.getStyle)(e,r,!r,"lineWidth"),o=e.connectNulls,l=e.isInCircle,s=e.points,u=e.showSinglePoint,c=(0,_ft.getPathPoints)(s,o,u),f=[],h=0,v=c.length;h<v;h++){var d=c[h];f=f.concat(wft(d,l,t,i,n))}return a.path=f,a}var oF=ll.getShapeAttrs=Cft;function Sft(e){var r=e.start,t=e.end;return[[r.x,t.y],[t.x,r.y]]}Mj=ll.getConstraint=Sft;Object.defineProperty(Tj,"__esModule",{value:!0});var Aft=Y,Ej=re,Tft=ll,Mft=(0,Ej.registerShapeFactory)("area",{defaultShapeType:"area",getDefaultPoints:function(e){var r=e.x,t=e.y0,i=(0,Aft.isArray)(e.y)?e.y:[t,e.y];return i.map(function(n){return{x:r,y:n}})}});(0,Ej.registerShape)("area","area",{draw:function(e,r){var t=(0,Tft.getShapeAttrs)(e,!1,!1,this),i=r.addShape({type:"path",attrs:t,name:"area"});return i},getMarker:function(e){var r=e.color;return{symbol:function(t,i,n){return n===void 0&&(n=5.5),[["M",t-n,i-4],["L",t+n,i-4],["L",t+n,i+4],["L",t-n,i+4],["Z"]]},style:{r:5,fill:r}}}});Tj.default=Mft;Object.defineProperty(iF,"__esModule",{value:!0});var Fj=V,Eft=Jt,Fft=(0,Fj.__importDefault)(Zp),Oft=function(e){(0,Fj.__extends)(r,e);function r(t){var i=e.call(this,t)||this;i.type="area",i.shapeType="area",i.generatePoints=!0,i.startOnZero=!0;var n=t.startOnZero,a=n===void 0?!0:n,o=t.sortable,l=o===void 0?!1:o,s=t.showSinglePoint,u=s===void 0?!1:s;return i.startOnZero=a,i.sortable=l,i.showSinglePoint=u,i}return r.prototype.getPointsAndData=function(t){for(var i=[],n=[],a=0,o=t.length;a<o;a++){var l=t[a];i.push(l.points),n.push(l[Eft.FIELD_ORIGIN])}return{points:i,data:n}},r.prototype.getYMinValue=function(){if(this.startOnZero)return e.prototype.getYMinValue.call(this);var t=this.getYScale();return t.min},r}(Fft.default),Pft=iF.default=Oft,lF={},Oj={};Object.defineProperty(Oj,"__esModule",{value:!0});var X$=V,Pj=re,Ift=ke,Lft=fc,Dft=Ph,$ft=(0,Pj.registerShapeFactory)("edge",{defaultShapeType:"line",getDefaultPoints:function(e){return(0,Dft.splitPoints)(e)}});(0,Pj.registerShape)("edge","line",{draw:function(e,r){var t=(0,Ift.getStyle)(e,!0,!1,"lineWidth"),i=(0,Lft.getLinePath)(this.parsePoints(e.points),this.coordinate.isPolar);return r.addShape("path",{attrs:(0,X$.__assign)((0,X$.__assign)({},t),{path:i})})},getMarker:function(e){return{symbol:"circle",style:{r:4.5,fill:e.color}}}});Oj.default=$ft;Object.defineProperty(lF,"__esModule",{value:!0});var Ij=V,kft=(0,Ij.__importDefault)(Pa),Rft=function(e){(0,Ij.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="edge",t.shapeType="edge",t.generatePoints=!0,t}return r}(kft.default),Bft=lF.default=Rft,sF={},Lj=br(EK);Object.defineProperty(sF,"__esModule",{value:!0});var xd=V,Nft=(0,xd.__importDefault)(Lj),mm=Y,bv=Jt,Gft=(0,xd.__importDefault)(Pa),zft=function(e){(0,xd.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="heatmap",t.paletteCache={},t}return r.prototype.updateElements=function(t,i){for(var n=0;n<t.length;n++){var a=t[n],o=this.prepareRange(a),l=this.prepareSize(),s=(0,mm.get)(this.styleOption,["cfg","shadowBlur"]);(0,mm.isNumber)(s)||(s=l/2),this.prepareGreyScaleBlurredCircle(l,s),this.drawWithRange(a,o,l,s)}},r.prototype.color=function(t,i){return this.createAttrOption("color",t,typeof i!="function"?i:""),this},r.prototype.clear=function(){e.prototype.clear.call(this),this.clearShadowCanvasCtx(),this.paletteCache={}},r.prototype.prepareRange=function(t){var i=this.getAttribute("color"),n=i.getFields()[0],a=1/0,o=-1/0;return t.forEach(function(l){var s=l[bv.FIELD_ORIGIN][n];s>o&&(o=s),s<a&&(a=s)}),a===o&&(a=o-1),[a,o]},r.prototype.prepareSize=function(){var t=this.getDefaultValue("size");return(0,mm.isNumber)(t)||(t=this.getDefaultSize()),t},r.prototype.prepareGreyScaleBlurredCircle=function(t,i){var n=this.getGrayScaleBlurredCanvas(),a=t+i,o=n.getContext("2d");n.width=n.height=a*2,o.clearRect(0,0,n.width,n.height),o.shadowOffsetX=o.shadowOffsetY=a*2,o.shadowBlur=i,o.shadowColor="black",o.beginPath(),o.arc(-a,-a,t,0,Math.PI*2,!0),o.closePath(),o.fill()},r.prototype.drawWithRange=function(t,i,n,a){var o=this.coordinate,l=o.start,s=o.end,u=this.coordinate.getWidth(),c=this.coordinate.getHeight(),f=this.getAttribute("color"),h=f.getFields()[0];this.clearShadowCanvasCtx();var v=this.getShadowCanvasCtx();i&&(t=t.filter(function(O){return O[bv.FIELD_ORIGIN][h]<=i[1]&&O[bv.FIELD_ORIGIN][h]>=i[0]}));for(var d=this.scales[h],p=0,x=t;p<x.length;p++){var m=x[p],_=this.getDrawCfg(m),b=_.x,w=_.y,S=d.scale(m[bv.FIELD_ORIGIN][h]);this.drawGrayScaleBlurredCircle(b-l.x,w-s.y,n+a,S,v)}var M=v.getImageData(0,0,u,c);this.clearShadowCanvasCtx(),this.colorize(M),v.putImageData(M,0,0);var F=this.getImageShape();F.attr("x",l.x),F.attr("y",s.y),F.attr("width",u),F.attr("height",c),F.attr("img",v.canvas),F.set("origin",this.getShapeInfo(t))},r.prototype.getDefaultSize=function(){var t=this.getAttribute("position"),i=this.coordinate;return Math.min(i.getWidth()/(t.scales[0].ticks.length*4),i.getHeight()/(t.scales[1].ticks.length*4))},r.prototype.clearShadowCanvasCtx=function(){var t=this.getShadowCanvasCtx();t.clearRect(0,0,t.canvas.width,t.canvas.height)},r.prototype.getShadowCanvasCtx=function(){var t=this.shadowCanvas;return t||(t=document.createElement("canvas"),this.shadowCanvas=t),t.width=this.coordinate.getWidth(),t.height=this.coordinate.getHeight(),t.getContext("2d")},r.prototype.getGrayScaleBlurredCanvas=function(){return this.grayScaleBlurredCanvas||(this.grayScaleBlurredCanvas=document.createElement("canvas")),this.grayScaleBlurredCanvas},r.prototype.drawGrayScaleBlurredCircle=function(t,i,n,a,o){var l=this.getGrayScaleBlurredCanvas();o.globalAlpha=a,o.drawImage(l,t-n,i-n)},r.prototype.colorize=function(t){for(var i=this.getAttribute("color"),n=t.data,a=this.paletteCache,o=3;o<n.length;o+=4){var l=n[o];if((0,mm.isNumber)(l)){var s=a[l]?a[l]:Nft.default.rgb2arr(i.gradient(l/256));n[o-3]=s[0],n[o-2]=s[1],n[o-1]=s[2],n[o]=l}}},r.prototype.getImageShape=function(){var t=this.imageShape;if(t)return t;var i=this.container;return t=i.addShape({type:"image",attrs:{}}),this.imageShape=t,t},r.prototype.getShapeInfo=function(t){var i=this.getDrawCfg(t[0]),n=t.map(function(a){return a[bv.FIELD_ORIGIN]});return(0,xd.__assign)((0,xd.__assign)({},i),{mappingData:t,data:n})},r}(Gft.default),Vft=sF.default=zft,uF={},Dj={},pr={};Object.defineProperty(pr,"__esModule",{value:!0});pr.getRectWithCornerRadius=pr.getFunnelPath=pr.getIntervalRectPath=pr.getBackgroundRectPath=pr.parseRadius=pr.getRectPath=pr.getRectPoints=void 0;var qd=Y,QC=Se;function jft(e){var r=e.x,t=e.y,i=e.y0,n=e.size,a,o;(0,qd.isArray)(t)?(a=t[0],o=t[1]):(a=i,o=t);var l,s;(0,qd.isArray)(r)?(l=r[0],s=r[1]):(l=r-n/2,s=r+n/2);var u=[{x:l,y:a},{x:l,y:o}];return u.push({x:s,y:o},{x:s,y:a}),u}pr.getRectPoints=jft;function $j(e,r){r===void 0&&(r=!0);var t=[],i=e[0];t.push(["M",i.x,i.y]);for(var n=1,a=e.length;n<a;n++)t.push(["L",e[n].x,e[n].y]);return r&&(t.push(["L",i.x,i.y]),t.push(["z"])),t}pr.getRectPath=$j;function pf(e,r){var t=0,i=0,n=0,a=0;return(0,qd.isArray)(e)?e.length===1?t=i=n=a=e[0]:e.length===2?(t=n=e[0],i=a=e[1]):e.length===3?(t=e[0],i=a=e[1],n=e[2]):(t=e[0],i=e[1],n=e[2],a=e[3]):t=i=n=a=e,t+i>r&&(t=t?r/(1+i/t):0,i=r-t),n+a>r&&(n=n?r/(1+a/n):0,a=r-n),[t||0,i||0,n||0,a||0]}pr.parseRadius=pf;function Hft(e,r,t){var i=[];if(t.isRect){var n=t.isTransposed?{x:t.start.x,y:r[0].y}:{x:r[0].x,y:t.start.y},a=t.isTransposed?{x:t.end.x,y:r[2].y}:{x:r[3].x,y:t.end.y},o=(0,qd.get)(e,["background","style","radius"]);if(o){var l=t.isTransposed?Math.abs(r[0].y-r[2].y):r[2].x-r[1].x,s=t.isTransposed?t.getWidth():t.getHeight(),u=pf(o,Math.min(l,s)),c=u[0],f=u[1],h=u[2],v=u[3];i.push(["M",n.x,a.y+c]),c!==0&&i.push(["A",c,c,0,0,1,n.x+c,a.y]),i.push(["L",a.x-f,a.y]),f!==0&&i.push(["A",f,f,0,0,1,a.x,a.y+f]),i.push(["L",a.x,n.y-h]),h!==0&&i.push(["A",h,h,0,0,1,a.x-h,n.y]),i.push(["L",n.x+v,n.y]),v!==0&&i.push(["A",v,v,0,0,1,n.x,n.y-v])}else i.push(["M",n.x,n.y]),i.push(["L",a.x,n.y]),i.push(["L",a.x,a.y]),i.push(["L",n.x,a.y]),i.push(["L",n.x,n.y]);i.push(["z"])}if(t.isPolar){var d=t.getCenter(),p=(0,QC.getAngle)(e,t),x=p.startAngle,m=p.endAngle;if(t.type!=="theta"&&!t.isTransposed)i=(0,QC.getSectorPath)(d.x,d.y,t.getRadius(),x,m);else{var _=function(S){return Math.pow(S,2)},c=Math.sqrt(_(d.x-r[0].x)+_(d.y-r[0].y)),f=Math.sqrt(_(d.x-r[2].x)+_(d.y-r[2].y));i=(0,QC.getSectorPath)(d.x,d.y,c,t.startAngle,t.endAngle,f)}}return i}pr.getBackgroundRectPath=Hft;function Yft(e,r,t){var i=t.getWidth(),n=t.getHeight(),a=t.type==="rect",o=[],l=(e[2].x-e[1].x)/2,s=t.isTransposed?l*n/i:l*i/n;return r==="round"?(a?(o.push(["M",e[0].x,e[0].y+s]),o.push(["L",e[1].x,e[1].y-s]),o.push(["A",l,l,0,0,1,e[2].x,e[2].y-s]),o.push(["L",e[3].x,e[3].y+s]),o.push(["A",l,l,0,0,1,e[0].x,e[0].y+s])):(o.push(["M",e[0].x,e[0].y]),o.push(["L",e[1].x,e[1].y]),o.push(["A",l,l,0,0,1,e[2].x,e[2].y]),o.push(["L",e[3].x,e[3].y]),o.push(["A",l,l,0,0,1,e[0].x,e[0].y])),o.push(["z"])):o=$j(e),o}pr.getIntervalRectPath=Yft;function Wft(e,r,t){var i=[];return(0,qd.isNil)(r)?t?i.push(["M",e[0].x,e[0].y],["L",e[1].x,e[1].y],["L",(e[2].x+e[3].x)/2,(e[2].y+e[3].y)/2],["Z"]):i.push(["M",e[0].x,e[0].y],["L",e[1].x,e[1].y],["L",e[2].x,e[2].y],["L",e[3].x,e[3].y],["Z"]):i.push(["M",e[0].x,e[0].y],["L",e[1].x,e[1].y],["L",r[1].x,r[1].y],["L",r[0].x,r[0].y],["Z"]),i}pr.getFunnelPath=Wft;function Xft(e,r,t){var i,n,a,o,l=e[0],s=e[1],u=e[2],c=e[3],f=[0,0,0,0],h=f[0],v=f[1],d=f[2],p=f[3];l.y<s.y?(s=e[0],l=e[1],c=e[2],u=e[3],i=pf(t,Math.min(c.x-l.x,l.y-s.y)),p=i[0],d=i[1],v=i[2],h=i[3]):(n=pf(t,Math.min(c.x-l.x,l.y-s.y)),h=n[0],v=n[1],d=n[2],p=n[3]),r.isTransposed&&(l=e[0],c=e[1],u=e[2],s=e[3],e[0].x>e[1].x?(c=e[0],l=e[1],s=e[2],u=e[3],a=pf(t,Math.min(c.x-l.x,l.y-s.y)),h=a[0],p=a[1],d=a[2],v=a[3]):(o=pf(t,Math.min(c.x-l.x,l.y-s.y)),v=o[0],d=o[1],p=o[2],h=o[3]));var x=[];return x.push(["M",s.x,s.y+h]),h!==0&&x.push(["A",h,h,0,0,1,s.x+h,s.y]),x.push(["L",u.x-v,u.y]),v!==0&&x.push(["A",v,v,0,0,1,u.x,u.y+v]),x.push(["L",c.x,c.y-d]),d!==0&&x.push(["A",d,d,0,0,1,c.x-d,c.y]),x.push(["L",l.x+p,l.y]),p!==0&&x.push(["A",p,p,0,0,1,l.x,l.y-p]),x.push(["L",s.x,s.y+h]),x.push(["z"]),x}pr.getRectWithCornerRadius=Xft;Object.defineProperty(Dj,"__esModule",{value:!0});var xm=V,kj=re,Uft=Fh,U$=ke,m0=pr,qft=(0,kj.registerShapeFactory)("interval",{defaultShapeType:"rect",getDefaultPoints:function(e){return(0,m0.getRectPoints)(e)}});(0,kj.registerShape)("interval","rect",{draw:function(e,r){var t=(0,U$.getStyle)(e,!1,!0),i=r,n=e==null?void 0:e.background;if(n){i=r.addGroup();var a=(0,U$.getBackgroundRectStyle)(e),o=(0,m0.getBackgroundRectPath)(e,this.parsePoints(e.points),this.coordinate);i.addShape("path",{attrs:(0,xm.__assign)((0,xm.__assign)({},a),{path:o}),zIndex:-1,name:Uft.BACKGROUND_SHAPE})}var l;t.radius&&this.coordinate.isRect?l=(0,m0.getRectWithCornerRadius)(this.parsePoints(e.points),this.coordinate,t.radius):l=this.parsePath((0,m0.getIntervalRectPath)(e.points,t.lineCap,this.coordinate));var s=i.addShape("path",{attrs:(0,xm.__assign)((0,xm.__assign)({},t),{path:l}),name:"interval"});return n?i:s},getMarker:function(e){var r=e.color,t=e.isInPolar;return t?{symbol:"circle",style:{r:4.5,fill:r}}:{symbol:"square",style:{r:4,fill:r}}}});Dj.default=qft;var Ih={};Object.defineProperty(Ih,"__esModule",{value:!0});Ih.getDefaultSize=void 0;var jl=Y,Zft=be;function Qft(e,r){var t=e.length,i=e;(0,jl.isString)(i[0])&&(i=e.map(function(l){return r.translate(l)}));for(var n=i[1]-i[0],a=2;a<t;a++){var o=i[a]-i[a-1];n>o&&(n=o)}return n}function Kft(e,r){if(r){var t=(0,jl.flatten)(e),i=(0,jl.valuesOfKey)(t,r);return i.length}return e.length}function Jft(e){var r=e.theme,t=e.coordinate,i=e.getXScale(),n=i.values,a=e.beforeMappingData,o=n.length,l=(0,Zft.getXDimensionLength)(e.coordinate),s=e.intervalPadding,u=e.dodgePadding,c=e.maxColumnWidth||r.maxColumnWidth,f=e.minColumnWidth||r.minColumnWidth,h=e.columnWidthRatio||r.columnWidthRatio,v=e.multiplePieWidthRatio||r.multiplePieWidthRatio,d=e.roseWidthRatio||r.roseWidthRatio;if(i.isLinear&&n.length>1){n.sort();var p=Qft(n,i);o=(i.max-i.min)/p,n.length>o&&(o=n.length)}var x=i.range,m=1/o,_=1;if(t.isPolar?t.isTransposed&&o>1?_=v:_=d:(i.isLinear&&(m*=x[1]-x[0]),_=h),!(0,jl.isNil)(s)&&s>=0){var b=s/l;m=(1-(o-1)*b)/o}else m*=_;if(e.getAdjust("dodge")){var w=e.getAdjust("dodge"),S=w.dodgeBy,M=Kft(a,S);if(!(0,jl.isNil)(u)&&u>=0){var F=u/l;m=(m-F*(M-1))/M}else!(0,jl.isNil)(s)&&s>=0&&(m*=_),m=m/M;m=m>=0?m:0}if(!(0,jl.isNil)(c)&&c>=0){var O=c/l;m>O&&(m=O)}if(!(0,jl.isNil)(f)&&f>=0){var L=f/l;m<L&&(m=L)}return m}Ih.getDefaultSize=Jft;Object.defineProperty(uF,"__esModule",{value:!0});var Rj=V,q$=Y,tht=be,eht=(0,Rj.__importDefault)(Pa),rht=Ih,iht=Zr,nht=function(e){(0,Rj.__extends)(r,e);function r(t){var i=e.call(this,t)||this;i.type="interval",i.shapeType="interval",i.generatePoints=!0;var n=t.background;return i.background=n,i}return r.prototype.createShapePointsCfg=function(t){var i=e.prototype.createShapePointsCfg.call(this,t),n,a=this.getAttribute("size");if(a){n=this.getAttributeValues(a,t)[0];var o=this.coordinate,l=(0,tht.getXDimensionLength)(o);n=n/l}else this.defaultSize||(this.defaultSize=(0,rht.getDefaultSize)(this)),n=this.defaultSize;return i.size=n,i},r.prototype.adjustScale=function(){e.prototype.adjustScale.call(this);var t=this.getYScale();if(this.coordinate.type==="theta")t.change({nice:!1,min:0,max:(0,iht.getMaxScale)(t)});else{var i=this.scaleDefs,n=t.field,a=t.min,o=t.max,l=t.type;l!=="time"&&(a>0&&!(0,q$.get)(i,[n,"min"])&&t.change({min:0}),o<=0&&!(0,q$.get)(i,[n,"max"])&&t.change({max:0}))}},r.prototype.getDrawCfg=function(t){var i=e.prototype.getDrawCfg.call(this,t);return i.background=this.background,i},r}(eht.default),aht=uF.default=nht,cF={};Object.defineProperty(cF,"__esModule",{value:!0});var Bj=V,oht=(0,Bj.__importDefault)(Zp),lht=function(e){(0,Bj.__extends)(r,e);function r(t){var i=e.call(this,t)||this;i.type="line";var n=t.sortable,a=n===void 0?!1:n;return i.sortable=a,i}return r}(oht.default),sht=cF.default=lht,fF={},Nj={},uo={};Object.defineProperty(uo,"__esModule",{value:!0});uo.drawPoints=uo.HOLLOW_SHAPES=uo.SHAPES=void 0;var Nc=V,Z$=Is,uht=ke;uo.SHAPES=["circle","square","bowtie","diamond","hexagon","triangle","triangle-down"];uo.HOLLOW_SHAPES=["cross","tick","plus","hyphen","line"];function cht(e,r,t,i,n){var a=(0,uht.getStyle)(r,n,!n,"r"),o=e.parsePoints(r.points),l=o[0];if(r.isStack)l=o[1];else if(o.length>1){for(var s=t.addGroup(),u=0,c=o;u<c.length;u++){var f=c[u];s.addShape({type:"marker",attrs:(0,Nc.__assign)((0,Nc.__assign)((0,Nc.__assign)({},a),{symbol:Z$.MarkerSymbols[i]||i}),f)})}return s}return t.addShape({type:"marker",attrs:(0,Nc.__assign)((0,Nc.__assign)((0,Nc.__assign)({},a),{symbol:Z$.MarkerSymbols[i]||i}),l)})}uo.drawPoints=cht;Object.defineProperty(Nj,"__esModule",{value:!0});var fht=Y,hht=Is,Gj=re,vht=Ph,Q$=uo,dht=(0,Gj.registerShapeFactory)("point",{defaultShapeType:"hollow-circle",getDefaultPoints:function(e){return(0,vht.splitPoints)(e)}});(0,fht.each)(Q$.SHAPES,function(e){(0,Gj.registerShape)("point","hollow-"+e,{draw:function(r,t){return(0,Q$.drawPoints)(this,r,t,e,!0)},getMarker:function(r){var t=r.color;return{symbol:hht.MarkerSymbols[e]||e,style:{r:4.5,stroke:t,fill:null}}}})});Nj.default=dht;Object.defineProperty(fF,"__esModule",{value:!0});var x0=V,pht=(0,x0.__importDefault)(Pa),ght=function(e){(0,x0.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="point",t.shapeType="point",t.generatePoints=!0,t}return r.prototype.getDrawCfg=function(t){var i=e.prototype.getDrawCfg.call(this,t);return(0,x0.__assign)((0,x0.__assign)({},i),{isStack:!!this.getAdjust("stack")})},r}(pht.default),yht=fF.default=ght,hF={},zj={};Object.defineProperty(zj,"__esModule",{value:!0});var K$=V,fx=Y,Vj=re,mht=ke;function xht(e){for(var r=e[0],t=1,i=[["M",r.x,r.y]];t<e.length;){var n=e[t];(n.x!==e[t-1].x||n.y!==e[t-1].y)&&(i.push(["L",n.x,n.y]),n.x===r.x&&n.y===r.y&&t<e.length-1&&(r=e[t+1],i.push(["Z"]),i.push(["M",r.x,r.y]),t++)),t++}return(0,fx.isEqual)((0,fx.last)(i),r)||i.push(["L",r.x,r.y]),i.push(["Z"]),i}var _ht=(0,Vj.registerShapeFactory)("polygon",{defaultShapeType:"polygon",getDefaultPoints:function(e){var r=[];return(0,fx.each)(e.x,function(t,i){var n=e.y[i];r.push({x:t,y:n})}),r}});(0,Vj.registerShape)("polygon","polygon",{draw:function(e,r){if(!(0,fx.isEmpty)(e.points)){var t=(0,mht.getStyle)(e,!0,!0),i=this.parsePath(xht(e.points));return r.addShape("path",{attrs:(0,K$.__assign)((0,K$.__assign)({},t),{path:i}),name:"polygon"})}},getMarker:function(e){var r=e.color;return{symbol:"square",style:{r:4,fill:r}}}});zj.default=_ht;Object.defineProperty(hF,"__esModule",{value:!0});var jj=V,_m=Y,bht=(0,jj.__importDefault)(Pa),wht=function(e){(0,jj.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="polygon",t.shapeType="polygon",t.generatePoints=!0,t}return r.prototype.createShapePointsCfg=function(t){var i=e.prototype.createShapePointsCfg.call(this,t),n=i.x,a=i.y,o;if(!((0,_m.isArray)(n)&&(0,_m.isArray)(a))){var l=this.getXScale(),s=this.getYScale(),u=l.values.length,c=s.values.length,f=.5*1/u,h=.5*1/c;l.isCategory&&s.isCategory?(n=[n-f,n-f,n+f,n+f],a=[a-h,a+h,a+h,a-h]):(0,_m.isArray)(n)?(o=n,n=[o[0],o[0],o[1],o[1]],a=[a-h/2,a+h/2,a+h/2,a-h/2]):(0,_m.isArray)(a)&&(o=a,a=[o[0],o[1],o[1],o[0]],n=[n-f/2,n-f/2,n+f/2,n+f/2]),i.x=n,i.y=a}return i},r}(bht.default),Cht=hF.default=wht,vF={},Hj={};Object.defineProperty(Hj,"__esModule",{value:!0});var Sht=re,Aht=(0,Sht.registerShapeFactory)("schema",{defaultShapeType:""});Hj.default=Aht;Object.defineProperty(vF,"__esModule",{value:!0});var Yj=V,Tht=be,Mht=(0,Yj.__importDefault)(Pa),Eht=Ih,Fht=function(e){(0,Yj.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="schema",t.shapeType="schema",t.generatePoints=!0,t}return r.prototype.createShapePointsCfg=function(t){var i=e.prototype.createShapePointsCfg.call(this,t),n,a=this.getAttribute("size");if(a){n=this.getAttributeValues(a,t)[0];var o=this.coordinate,l=(0,Tht.getXDimensionLength)(o);n=n/l}else this.defaultSize||(this.defaultSize=(0,Eht.getDefaultSize)(this)),n=this.defaultSize;return i.size=n,i},r}(Mht.default),Oht=vF.default=Fht,dF={},Wj={};Object.defineProperty(Wj,"__esModule",{value:!0});var J$=V,_0=Y,Xj=re,Pht=xn,Iht=ke;function Lht(e){if(!(0,_0.isArray)(e))return[];var r=(0,_0.max)(e);return(0,_0.map)(e,function(t){return t/r})}var Dht=(0,Xj.registerShapeFactory)("violin",{defaultShapeType:"violin",getDefaultPoints:function(e){var r=e.size/2,t=[],i=Lht(e._size);return(0,_0.each)(e.y,function(n,a){var o=i[a]*r,l=a===0,s=a===e.y.length-1;t.push({isMin:l,isMax:s,x:e.x-o,y:n}),t.unshift({isMin:l,isMax:s,x:e.x+o,y:n})}),t}});(0,Xj.registerShape)("violin","violin",{draw:function(e,r){var t=(0,Iht.getStyle)(e,!0,!0),i=this.parsePath((0,Pht.getViolinPath)(e.points));return r.addShape("path",{attrs:(0,J$.__assign)((0,J$.__assign)({},t),{path:i}),name:"violin"})},getMarker:function(e){var r=e.color;return{symbol:"circle",style:{r:4,fill:r}}}});Wj.default=Dht;Object.defineProperty(dF,"__esModule",{value:!0});var Uj=V,$ht=Y,kht=Jt,Rht=be,Bht=Ih,Nht=(0,Uj.__importDefault)(Pa),Ght=function(e){(0,Uj.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="violin",t.shapeType="violin",t.generatePoints=!0,t}return r.prototype.createShapePointsCfg=function(t){var i=e.prototype.createShapePointsCfg.call(this,t),n,a=this.getAttribute("size");if(a){n=this.getAttributeValues(a,t)[0];var o=this.coordinate,l=(0,Rht.getXDimensionLength)(o);n=n/l}else this.defaultSize||(this.defaultSize=(0,Bht.getDefaultSize)(this)),n=this.defaultSize;return i.size=n,i._size=(0,$ht.get)(t[kht.FIELD_ORIGIN],[this._sizeField]),i},r.prototype.initAttributes=function(){var t=this.attributeOption,i=t.size?t.size.fields[0]:this._sizeField?this._sizeField:"size";this._sizeField=i,delete t.size,e.prototype.initAttributes.call(this)},r}(Nht.default);dF.default=Ght;var zht=re,Vht=ll;(0,zht.registerShape)("area","line",{draw:function(e,r){var t=(0,Vht.getShapeAttrs)(e,!0,!1,this),i=r.addShape({type:"path",attrs:t,name:"area"});return i},getMarker:function(e){var r=e.color;return{symbol:function(t,i,n){return n===void 0&&(n=5.5),[["M",t-n,i-4],["L",t+n,i-4],["L",t+n,i+4],["L",t-n,i+4],["Z"]]},style:{r:5,stroke:r,fill:null}}}});var jht=re,tk=ll;(0,jht.registerShape)("area","smooth",{draw:function(e,r){var t=this.coordinate,i=(0,tk.getShapeAttrs)(e,!1,!0,this,(0,tk.getConstraint)(t)),n=r.addShape({type:"path",attrs:i,name:"area"});return n},getMarker:function(e){var r=e.color;return{symbol:function(t,i,n){return n===void 0&&(n=5.5),[["M",t-n,i-4],["L",t+n,i-4],["L",t+n,i+4],["L",t-n,i+4],["Z"]]},style:{r:5,fill:r}}}});var Hht=re,ek=ll;(0,Hht.registerShape)("area","smooth-line",{draw:function(e,r){var t=this.coordinate,i=(0,ek.getShapeAttrs)(e,!0,!0,this,(0,ek.getConstraint)(t)),n=r.addShape({type:"path",attrs:i,name:"area"});return n},getMarker:function(e){var r=e.color;return{symbol:function(t,i,n){return n===void 0&&(n=5.5),[["M",t-n,i-4],["L",t+n,i-4],["L",t+n,i+4],["L",t-n,i+4],["Z"]]},style:{r:5,stroke:r,fill:null}}}});var Ju={};Object.defineProperty(Ju,"__esModule",{value:!0});Ju.getQPath=Ju.getCPath=void 0;var Yht=Y;function Wht(e,r){return["C",e.x*1/2+r.x*1/2,e.y,e.x*1/2+r.x*1/2,r.y,r.x,r.y]}Ju.getCPath=Wht;function Xht(e,r){var t=[];t.push({x:r.x,y:r.y}),t.push(e);var i=["Q"];return(0,Yht.each)(t,function(n){i.push(n.x,n.y)}),i}Ju.getQPath=Xht;var Gc=V,Uht=Se,qht=re,Zht=ke,Zd=Ju;function Qht(e,r,t){var i=(0,Zd.getQPath)(r,t),n=[["M",e.x,e.y]];return n.push(i),n}function Kht(e,r){var t=(0,Zd.getQPath)(e[1],r),i=(0,Zd.getQPath)(e[3],r),n=[["M",e[0].x,e[0].y]];return n.push(i),n.push(["L",e[3].x,e[3].y]),n.push(["L",e[2].x,e[2].y]),n.push(t),n.push(["L",e[1].x,e[1].y]),n.push(["L",e[0].x,e[0].y]),n.push(["Z"]),n}(0,qht.registerShape)("edge","arc",{draw:function(e,r){var t=(0,Zht.getStyle)(e,!0,!1,"lineWidth"),i=e.points,n=i.length>2?"weight":"normal",a;if(e.isInCircle){var o={x:0,y:1};return n==="normal"?a=Qht(i[0],i[1],o):(t.fill=t.stroke,a=Kht(i,o)),a=this.parsePath(a),r.addShape("path",{attrs:(0,Gc.__assign)((0,Gc.__assign)({},t),{path:a})})}else{if(n==="normal")return i=this.parsePoints(i),a=(0,Uht.getArcPath)((i[1].x+i[0].x)/2,i[0].y,Math.abs(i[1].x-i[0].x)/2,Math.PI,Math.PI*2),r.addShape("path",{attrs:(0,Gc.__assign)((0,Gc.__assign)({},t),{path:a})});var l=(0,Zd.getCPath)(i[1],i[3]),s=(0,Zd.getCPath)(i[2],i[0]);return a=[["M",i[0].x,i[0].y],["L",i[1].x,i[1].y],l,["L",i[3].x,i[3].y],["L",i[2].x,i[2].y],s,["Z"]],a=this.parsePath(a),t.fill=t.stroke,r.addShape("path",{attrs:(0,Gc.__assign)((0,Gc.__assign)({},t),{path:a})})}},getMarker:function(e){return{symbol:"circle",style:{r:4.5,fill:e.color}}}});var rk=V,Jht=re,tvt=ke,evt=Ju;function rvt(e,r){var t=(0,evt.getCPath)(e,r),i=[["M",e.x,e.y]];return i.push(t),i}(0,Jht.registerShape)("edge","smooth",{draw:function(e,r){var t=(0,tvt.getStyle)(e,!0,!1,"lineWidth"),i=e.points,n=this.parsePath(rvt(i[0],i[1]));return r.addShape("path",{attrs:(0,rk.__assign)((0,rk.__assign)({},t),{path:n})})},getMarker:function(e){return{symbol:"circle",style:{r:4.5,fill:e.color}}}});var ik=V,ivt=Y,nvt=re,avt=ke,bm=1/3;function ovt(e,r){var t=[];t.push({x:e.x,y:e.y*(1-bm)+r.y*bm}),t.push({x:r.x,y:e.y*(1-bm)+r.y*bm}),t.push(r);var i=[["M",e.x,e.y]];return(0,ivt.each)(t,function(n){i.push(["L",n.x,n.y])}),i}(0,nvt.registerShape)("edge","vhv",{draw:function(e,r){var t=(0,avt.getStyle)(e,!0,!1,"lineWidth"),i=e.points,n=this.parsePath(ovt(i[0],i[1]));return r.addShape("path",{attrs:(0,ik.__assign)((0,ik.__assign)({},t),{path:n})})},getMarker:function(e){return{symbol:"circle",style:{r:4.5,fill:e.color}}}});var nk=V,lvt=re,svt=ke,ak=pr;(0,lvt.registerShape)("interval","funnel",{getPoints:function(e){return e.size=e.size*2,(0,ak.getRectPoints)(e)},draw:function(e,r){var t=(0,svt.getStyle)(e,!1,!0),i=this.parsePath((0,ak.getFunnelPath)(e.points,e.nextPoints,!1)),n=r.addShape("path",{attrs:(0,nk.__assign)((0,nk.__assign)({},t),{path:i}),name:"interval"});return n},getMarker:function(e){var r=e.color;return{symbol:"square",style:{r:4,fill:r}}}});var wm=V,uvt=re,cvt=Fh,ok=ke,lk=pr;(0,uvt.registerShape)("interval","hollow-rect",{draw:function(e,r){var t=(0,ok.getStyle)(e,!0,!1),i=r,n=e==null?void 0:e.background;if(n){i=r.addGroup();var a=(0,ok.getBackgroundRectStyle)(e),o=(0,lk.getBackgroundRectPath)(e,this.parsePoints(e.points),this.coordinate);i.addShape("path",{attrs:(0,wm.__assign)((0,wm.__assign)({},a),{path:o}),zIndex:-1,name:cvt.BACKGROUND_SHAPE})}var l=this.parsePath((0,lk.getRectPath)(e.points)),s=i.addShape("path",{attrs:(0,wm.__assign)((0,wm.__assign)({},t),{path:l}),name:"interval"});return n?i:s},getMarker:function(e){var r=e.color,t=e.isInPolar;return t?{symbol:"circle",style:{r:4.5,stroke:r,fill:null}}:{symbol:"square",style:{r:4,stroke:r,fill:null}}}});var KC=V,sk=Y,fvt=re,hvt=ke,vvt=pr,dvt=mr;function pvt(e){var r=e.x,t=e.y,i=e.y0;return(0,sk.isArray)(t)?t.map(function(n,a){return{x:(0,sk.isArray)(r)?r[a]:r,y:n}}):[{x:r,y:i},{x:r,y:t}]}(0,fvt.registerShape)("interval","line",{getPoints:function(e){return pvt(e)},draw:function(e,r){var t=(0,hvt.getStyle)(e,!0,!1,"lineWidth"),i=(0,dvt.omit)((0,KC.__assign)({},t),["fill"]),n=this.parsePath((0,vvt.getRectPath)(e.points,!1)),a=r.addShape("path",{attrs:(0,KC.__assign)((0,KC.__assign)({},i),{path:n}),name:"interval"});return a},getMarker:function(e){var r=e.color;return{symbol:function(t,i,n){return[["M",t,i-n],["L",t,i+n]]},style:{r:5,stroke:r}}}});var uk=V,gvt=re,yvt=ke,ck=pr;(0,gvt.registerShape)("interval","pyramid",{getPoints:function(e){return e.size=e.size*2,(0,ck.getRectPoints)(e)},draw:function(e,r){var t=(0,yvt.getStyle)(e,!1,!0),i=this.parsePath((0,ck.getFunnelPath)(e.points,e.nextPoints,!0)),n=r.addShape("path",{attrs:(0,uk.__assign)((0,uk.__assign)({},t),{path:i}),name:"interval"});return n},getMarker:function(e){var r=e.color;return{symbol:"square",style:{r:4,fill:r}}}});var fk=V,mvt=Y,xvt=re,_vt=ke;function bvt(e){var r=e.x,t=e.y,i=e.y0,n=e.size,a,o;(0,mvt.isArray)(t)?(a=t[0],o=t[1]):(a=i,o=t);var l=r+n/2,s=r-n/2;return[{x:r,y:a},{x:r,y:o},{x:s,y:a},{x:l,y:a},{x:s,y:o},{x:l,y:o}]}function wvt(e){return[["M",e[0].x,e[0].y],["L",e[1].x,e[1].y],["M",e[2].x,e[2].y],["L",e[3].x,e[3].y],["M",e[4].x,e[4].y],["L",e[5].x,e[5].y]]}(0,xvt.registerShape)("interval","tick",{getPoints:function(e){return bvt(e)},draw:function(e,r){var t=(0,_vt.getStyle)(e,!0,!1),i=this.parsePath(wvt(e.points)),n=r.addShape("path",{attrs:(0,fk.__assign)((0,fk.__assign)({},t),{path:i}),name:"interval"});return n},getMarker:function(e){var r=e.color;return{symbol:function(t,i,n){return[["M",t-n/2,i-n],["L",t+n/2,i-n],["M",t,i-n],["L",t,i+n],["M",t-n/2,i+n],["L",t+n/2,i+n]]},style:{r:5,stroke:r}}}});var hk=V,pF=Y,Cvt=re,Svt=xn,Avt=ke,Tvt=Qp,Mvt=function(e,r,t){var i=e.x,n=e.y,a=r.x,o=r.y,l;switch(t){case"hv":l=[{x:a,y:n}];break;case"vh":l=[{x:i,y:o}];break;case"hvh":var s=(a+i)/2;l=[{x:s,y:n},{x:s,y:o}];break;case"vhv":var u=(n+o)/2;l=[{x:i,y:u},{x:a,y:u}];break}return l};function Evt(e,r){var t=[];return(0,pF.each)(e,function(i,n){var a=e[n+1];if(t.push(i),a){var o=Mvt(i,a,r);t=t.concat(o)}}),t}function Fvt(e){return e.map(function(r,t){return t===0?["M",r.x,r.y]:["L",r.x,r.y]})}function Ovt(e,r){var t=(0,Svt.getPathPoints)(e.points,e.connectNulls,e.showSinglePoint),i=[];return(0,pF.each)(t,function(n){var a=Evt(n,r);i=i.concat(Fvt(a))}),(0,hk.__assign)((0,hk.__assign)({},(0,Avt.getStyle)(e,!0,!1,"lineWidth")),{path:i})}(0,pF.each)(["hv","vh","hvh","vhv"],function(e){(0,Cvt.registerShape)("line",e,{draw:function(r,t){var i=Ovt(r,e),n=t.addShape({type:"path",attrs:i,name:"line"});return n},getMarker:function(r){return(0,Tvt.getLineMarker)(r,e)}})});var Pvt=Y,Ivt=Is,Lvt=re,vk=uo;(0,Pvt.each)(vk.HOLLOW_SHAPES,function(e){(0,Lvt.registerShape)("point",e,{draw:function(r,t){return(0,vk.drawPoints)(this,r,t,e,!0)},getMarker:function(r){var t=r.color;return{symbol:Ivt.MarkerSymbols[e],style:{r:4.5,stroke:t,fill:null}}}})});var Dvt=re,$vt=ke;(0,Dvt.registerShape)("point","image",{draw:function(e,r){var t=(0,$vt.getStyle)(e,!1,!1,"r").r,i=this.parsePoints(e.points),n=i[0];if(e.isStack)n=i[1];else if(i.length>1){for(var a=r.addGroup(),o=0,l=i;o<l.length;o++){var s=l[o];a.addShape("image",{attrs:{x:s.x-t/2,y:s.y-t,width:t,height:t,img:e.shape[1]}})}return a}return r.addShape("image",{attrs:{x:n.x-t/2,y:n.y-t,width:t,height:t,img:e.shape[1]}})},getMarker:function(e){var r=e.color;return{symbol:"circle",style:{r:4.5,fill:r}}}});var kvt=Y,Rvt=Is,Bvt=re,dk=uo;(0,kvt.each)(dk.SHAPES,function(e){(0,Bvt.registerShape)("point",e,{draw:function(r,t){return(0,dk.drawPoints)(this,r,t,e,!1)},getMarker:function(r){var t=r.color;return{symbol:Rvt.MarkerSymbols[e]||e,style:{r:4.5,fill:t}}}})});var pk=V,iT=Y,Nvt=re,Gvt=ke;function gk(e){var r=(0,iT.isArray)(e)?e:[e],t=r[0],i=r[r.length-1],n=r.length>1?r[1]:t,a=r.length>3?r[3]:i,o=r.length>2?r[2]:n;return{min:t,max:i,min1:n,max1:a,median:o}}function yk(e,r,t){var i=t/2,n;if((0,iT.isArray)(r)){var a=gk(r),o=a.min,l=a.max,s=a.median,u=a.min1,c=a.max1,f=e-i,h=e+i;n=[[f,l],[h,l],[e,l],[e,c],[f,u],[f,c],[h,c],[h,u],[e,u],[e,o],[f,o],[h,o],[f,s],[h,s]]}else{r=(0,iT.isNil)(r)?.5:r;var v=gk(e),o=v.min,l=v.max,s=v.median,u=v.min1,c=v.max1,d=r-i,p=r+i;n=[[o,d],[o,p],[o,r],[u,r],[u,d],[u,p],[c,p],[c,d],[c,r],[l,r],[l,d],[l,p],[s,d],[s,p]]}return n.map(function(x){return{x:x[0],y:x[1]}})}function zvt(e){return[["M",e[0].x,e[0].y],["L",e[1].x,e[1].y],["M",e[2].x,e[2].y],["L",e[3].x,e[3].y],["M",e[4].x,e[4].y],["L",e[5].x,e[5].y],["L",e[6].x,e[6].y],["L",e[7].x,e[7].y],["L",e[4].x,e[4].y],["Z"],["M",e[8].x,e[8].y],["L",e[9].x,e[9].y],["M",e[10].x,e[10].y],["L",e[11].x,e[11].y],["M",e[12].x,e[12].y],["L",e[13].x,e[13].y]]}(0,Nvt.registerShape)("schema","box",{getPoints:function(e){var r=e.x,t=e.y,i=e.size;return yk(r,t,i)},draw:function(e,r){var t=(0,Gvt.getStyle)(e,!0,!1),i=this.parsePath(zvt(e.points)),n=r.addShape("path",{attrs:(0,pk.__assign)((0,pk.__assign)({},t),{path:i,name:"schema"})});return n},getMarker:function(e){var r=e.color;return{symbol:function(t,i,n){var a=[i-6,i-3,i,i+3,i+6],o=yk(t,a,n);return[["M",o[0].x+1,o[0].y],["L",o[1].x-1,o[1].y],["M",o[2].x,o[2].y],["L",o[3].x,o[3].y],["M",o[4].x,o[4].y],["L",o[5].x,o[5].y],["L",o[6].x,o[6].y],["L",o[7].x,o[7].y],["L",o[4].x,o[4].y],["Z"],["M",o[8].x,o[8].y],["L",o[9].x,o[9].y],["M",o[10].x+1,o[10].y],["L",o[11].x-1,o[11].y],["M",o[12].x,o[12].y],["L",o[13].x,o[13].y]]},style:{r:6,lineWidth:1,stroke:r}}}});var mk=V,Vvt=Y,jvt=mr,Hvt=re,Yvt=ke;function Wvt(e){var r=(0,Vvt.isArray)(e)?e:[e],t=r.sort(function(i,n){return n-i});return(0,jvt.padEnd)(t,4,t[t.length-1])}function xk(e,r,t){var i=Wvt(r);return[{x:e,y:i[0]},{x:e,y:i[1]},{x:e-t/2,y:i[2]},{x:e-t/2,y:i[1]},{x:e+t/2,y:i[1]},{x:e+t/2,y:i[2]},{x:e,y:i[2]},{x:e,y:i[3]}]}function Xvt(e){return[["M",e[0].x,e[0].y],["L",e[1].x,e[1].y],["M",e[2].x,e[2].y],["L",e[3].x,e[3].y],["L",e[4].x,e[4].y],["L",e[5].x,e[5].y],["Z"],["M",e[6].x,e[6].y],["L",e[7].x,e[7].y]]}(0,Hvt.registerShape)("schema","candle",{getPoints:function(e){var r=e.x,t=e.y,i=e.size;return xk(r,t,i)},draw:function(e,r){var t=(0,Yvt.getStyle)(e,!0,!0),i=this.parsePath(Xvt(e.points)),n=r.addShape("path",{attrs:(0,mk.__assign)((0,mk.__assign)({},t),{path:i,name:"schema"})});return n},getMarker:function(e){var r=e.color;return{symbol:function(t,i,n){var a=[i+7.5,i+3,i-3,i-7.5],o=xk(t,a,n);return[["M",o[0].x,o[0].y],["L",o[1].x,o[1].y],["M",o[2].x,o[2].y],["L",o[3].x,o[3].y],["L",o[4].x,o[4].y],["L",o[5].x,o[5].y],["Z"],["M",o[6].x,o[6].y],["L",o[7].x,o[7].y]]},style:{lineWidth:1,stroke:r,fill:r,r:6}}}});var _k=V,qj=Y,Uvt=re,qvt=ke;function Zvt(e,r){var t=Math.abs(e[0].x-e[2].x),i=Math.abs(e[0].y-e[2].y),n=Math.min(t,i);r&&(n=(0,qj.clamp)(r,0,Math.min(t,i))),n=n/2;var a=(e[0].x+e[2].x)/2,o=(e[0].y+e[2].y)/2;return{x:a-n,y:o-n,width:n*2,height:n*2}}(0,Uvt.registerShape)("polygon","square",{draw:function(e,r){if(!(0,qj.isEmpty)(e.points)){var t=(0,qvt.getStyle)(e,!0,!0),i=this.parsePoints(e.points);return r.addShape("rect",{attrs:(0,_k.__assign)((0,_k.__assign)({},t),Zvt(i,e.size)),name:"polygon"})}},getMarker:function(e){var r=e.color;return{symbol:"square",style:{r:4,fill:r}}}});var bk=V,Qvt=re,Kvt=xn,Jvt=ke;(0,Qvt.registerShape)("violin","smooth",{draw:function(e,r){var t=(0,Jvt.getStyle)(e,!0,!0),i=this.parsePath((0,Kvt.getSmoothViolinPath)(e.points));return r.addShape("path",{attrs:(0,bk.__assign)((0,bk.__assign)({},t),{path:i})})},getMarker:function(e){var r=e.color;return{symbol:"circle",style:{stroke:null,r:4,fill:r}}}});var hx=V,Zj=re,Qj=xn,Kj=ke;(0,Zj.registerShape)("violin","hollow",{draw:function(e,r){var t=(0,Kj.getStyle)(e,!0,!1),i=this.parsePath((0,Qj.getViolinPath)(e.points));return r.addShape("path",{attrs:(0,hx.__assign)((0,hx.__assign)({},t),{path:i})})},getMarker:function(e){var r=e.color;return{symbol:"circle",style:{r:4,fill:null,stroke:r}}}});(0,Zj.registerShape)("violin","hollow-smooth",{draw:function(e,r){var t=(0,Kj.getStyle)(e,!0,!1),i=this.parsePath((0,Qj.getSmoothViolinPath)(e.points));return r.addShape("path",{attrs:(0,hx.__assign)((0,hx.__assign)({},t),{path:i})})},getMarker:function(e){var r=e.color;return{symbol:"circle",style:{r:4,fill:null,stroke:r}}}});var gF={};Object.defineProperty(gF,"__esModule",{value:!0});var $l=V,Rn=Y,tdt=(0,$l.__importDefault)(Oh),edt=function(e){(0,$l.__extends)(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getLabelValueDir=function(t){var i="y",n=t.points;return n[0][i]<=n[2][i]?1:-1},r.prototype.getLabelOffsetPoint=function(t,i,n,a){var o,l=e.prototype.getLabelOffsetPoint.call(this,t,i,n),s=this.getCoordinate(),u=s.isTransposed,c=u?"x":"y",f=this.getLabelValueDir(t.mappingData);return l=(0,$l.__assign)((0,$l.__assign)({},l),(o={},o[c]=l[c]*f,o)),s.isReflect("x")&&(l=(0,$l.__assign)((0,$l.__assign)({},l),{x:l.x*-1})),s.isReflect("y")&&(l=(0,$l.__assign)((0,$l.__assign)({},l),{y:l.y*-1})),l},r.prototype.getThemedLabelCfg=function(t){var i=this.geometry,n=this.getDefaultLabelCfg(),a=i.theme;return(0,Rn.deepMix)({},n,a.labels,t.position==="middle"?{offset:0}:{},t)},r.prototype.setLabelPosition=function(t,i,n,a){var o=this.getCoordinate(),l=o.isTransposed,s=i.points,u=o.convert(s[0]),c=o.convert(s[2]),f=this.getLabelValueDir(i),h,v,d,p,x=(0,Rn.isArray)(i.shape)?i.shape[0]:i.shape;if(x==="funnel"||x==="pyramid"){var m=(0,Rn.get)(i,"nextPoints"),_=(0,Rn.get)(i,"points");if(m){var b=o.convert(_[0]),w=o.convert(_[1]),S=o.convert(m[0]),M=o.convert(m[1]);l?(h=Math.min(S.y,b.y),d=Math.max(S.y,b.y),v=(w.x+M.x)/2,p=(b.x+S.x)/2):(h=Math.min((w.y+M.y)/2,(b.y+S.y)/2),d=Math.max((w.y+M.y)/2,(b.y+S.y)/2),v=M.x,p=b.x)}else h=Math.min(c.y,u.y),d=Math.max(c.y,u.y),v=c.x,p=u.x}else h=Math.min(c.y,u.y),d=Math.max(c.y,u.y),v=c.x,p=u.x;switch(a){case"right":t.x=v,t.y=(h+d)/2,t.textAlign=(0,Rn.get)(t,"textAlign",f>0?"left":"right");break;case"left":t.x=p,t.y=(h+d)/2,t.textAlign=(0,Rn.get)(t,"textAlign",f>0?"left":"right");break;case"bottom":l&&(t.x=(v+p)/2),t.y=d,t.textAlign=(0,Rn.get)(t,"textAlign","center"),t.textBaseline=(0,Rn.get)(t,"textBaseline",f>0?"bottom":"top");break;case"middle":l&&(t.x=(v+p)/2),t.y=(h+d)/2,t.textAlign=(0,Rn.get)(t,"textAlign","center"),t.textBaseline=(0,Rn.get)(t,"textBaseline","middle");break;case"top":l&&(t.x=(v+p)/2),t.y=h,t.textAlign=(0,Rn.get)(t,"textAlign","center"),t.textBaseline=(0,Rn.get)(t,"textBaseline",f>0?"bottom":"top");break}},r}(tdt.default),Jj=gF.default=edt,yF={},Z1={};Object.defineProperty(Z1,"__esModule",{value:!0});var tf=V,Do=Y,rdt=be,idt=be,ndt=(0,tf.__importDefault)(Oh),Cm=Math.PI/2,adt=function(e){(0,tf.__extends)(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getLabelOffset=function(t){var i=this.getCoordinate(),n=0;if((0,Do.isNumber)(t))n=t;else if((0,Do.isString)(t)&&t.indexOf("%")!==-1){var a=i.getRadius();i.innerRadius>0&&(a=a*(1-i.innerRadius)),n=parseFloat(t)*.01*a}return n},r.prototype.getLabelItems=function(t){var i=e.prototype.getLabelItems.call(this,t),n=this.geometry.getYScale();return(0,Do.map)(i,function(a){if(a&&n){var o=n.scale((0,Do.get)(a.data,n.field));return(0,tf.__assign)((0,tf.__assign)({},a),{percent:o})}return a})},r.prototype.getLabelAlign=function(t){var i=this.getCoordinate(),n;if(t.labelEmit)n=t.angle<=Math.PI/2&&t.angle>=-Math.PI/2?"left":"right";else if(!i.isTransposed)n="center";else{var a=i.getCenter(),o=t.offset;Math.abs(t.x-a.x)<1?n="center":t.angle>Math.PI||t.angle<=0?n=o>0?"left":"right":n=o>0?"right":"left"}return n},r.prototype.getLabelPoint=function(t,i,n){var a=1,o,l=t.content[n];this.isToMiddle(i)?o=this.getMiddlePoint(i.points):(t.content.length===1&&n===0?n=1:n===0&&(a=-1),o=this.getArcPoint(i,n));var s=t.offset*a,u=this.getPointAngle(o),c=t.labelEmit,f=this.getCirclePoint(u,s,o,c);return f.r===0?f.content="":(f.content=l,f.angle=u,f.color=i.color),f.rotate=t.autoRotate?this.getLabelRotate(u,s,c):t.rotate,f.start={x:o.x,y:o.y},f},r.prototype.getArcPoint=function(t,i){return i===void 0&&(i=0),!(0,Do.isArray)(t.x)&&!(0,Do.isArray)(t.y)?{x:t.x,y:t.y}:{x:(0,Do.isArray)(t.x)?t.x[i]:t.x,y:(0,Do.isArray)(t.y)?t.y[i]:t.y}},r.prototype.getPointAngle=function(t){return(0,idt.getAngleByPoint)(this.getCoordinate(),t)},r.prototype.getCirclePoint=function(t,i,n,a){var o=this.getCoordinate(),l=o.getCenter(),s=(0,rdt.getDistanceToCenter)(o,n);if(s===0)return(0,tf.__assign)((0,tf.__assign)({},l),{r:s});var u=t;if(o.isTransposed&&s>i&&!a){var c=Math.asin(i/(2*s));u=t+c*2}else s=s+i;return{x:l.x+s*Math.cos(u),y:l.y+s*Math.sin(u),r:s}},r.prototype.getLabelRotate=function(t,i,n){var a=t+Cm;return n&&(a-=Cm),a&&(a>Cm?a=a-Math.PI:a<-Cm&&(a=a+Math.PI)),a},r.prototype.getMiddlePoint=function(t){var i=this.getCoordinate(),n=t.length,a={x:0,y:0};return(0,Do.each)(t,function(o){a.x+=o.x,a.y+=o.y}),a.x/=n,a.y/=n,a=i.convert(a),a},r.prototype.isToMiddle=function(t){return t.x.length>2},r}(ndt.default),odt=Z1.default=adt;Object.defineProperty(yF,"__esModule",{value:!0});var b0=V,Sm=Y,wk=be,ldt=Se,sdt=(0,b0.__importDefault)(Z1),udt=function(e){(0,b0.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.defaultLayout="distribute",t}return r.prototype.getDefaultLabelCfg=function(t,i){var n=e.prototype.getDefaultLabelCfg.call(this,t,i);return(0,Sm.deepMix)({},n,(0,Sm.get)(this.geometry.theme,"pieLabels",{}))},r.prototype.getLabelOffset=function(t){return e.prototype.getLabelOffset.call(this,t)||0},r.prototype.getLabelRotate=function(t,i,n){var a;return i<0&&(a=t,a>Math.PI/2&&(a=a-Math.PI),a<-Math.PI/2&&(a=a+Math.PI)),a},r.prototype.getLabelAlign=function(t){var i=this.getCoordinate(),n=i.getCenter(),a;return t.angle<=Math.PI/2&&t.x>=n.x?a="left":a="right",t.offset<=0&&(a==="right"?a="left":a="right"),a},r.prototype.getArcPoint=function(t){return t},r.prototype.getPointAngle=function(t){var i=this.getCoordinate(),n={x:(0,Sm.isArray)(t.x)?t.x[0]:t.x,y:t.y[0]},a={x:(0,Sm.isArray)(t.x)?t.x[1]:t.x,y:t.y[1]},o,l=(0,wk.getAngleByPoint)(i,n);if(t.points&&t.points[0].y===t.points[1].y)o=l;else{var s=(0,wk.getAngleByPoint)(i,a);l>=s&&(s=s+Math.PI*2),o=l+(s-l)/2}return o},r.prototype.getCirclePoint=function(t,i){var n=this.getCoordinate(),a=n.getCenter(),o=n.getRadius()+i;return(0,b0.__assign)((0,b0.__assign)({},(0,ldt.polarToCartesian)(a.x,a.y,o,t)),{angle:t,r:o})},r}(sdt.default),tH=yF.default=udt,Q1={};Object.defineProperty(Q1,"__esModule",{value:!0});var eH=Q1.distribute=void 0,qv=Y,Ck=Se,Sk=4;function cdt(e,r,t,i,n,a){var o=!0,l=i.start,s=i.end,u=Math.min(l.y,s.y),c=Math.abs(l.y-s.y),f,h=0,v=Number.MIN_VALUE,d=r.map(function(S){return S.y>h&&(h=S.y),S.y<v&&(v=S.y),{size:t,targets:[S.y-u]}});for(v-=u,h-u>c&&(c=h-u);o;)for(d.forEach(function(S){var M=(Math.min.apply(v,S.targets)+Math.max.apply(v,S.targets))/2;S.pos=Math.min(Math.max(v,M-S.size/2),c-S.size)}),o=!1,f=d.length;f--;)if(f>0){var p=d[f-1],x=d[f];p.pos+p.size>x.pos&&(p.size+=x.size,p.targets=p.targets.concat(x.targets),p.pos+p.size>c&&(p.pos=c-p.size),d.splice(f,1),o=!0)}f=0,d.forEach(function(S){var M=u+t/2;S.targets.forEach(function(){r[f].y=S.pos+M,M+=t,f++})});for(var m={},_=0,b=e;_<b.length;_++){var w=b[_];m[w.get("id")]=w}r.forEach(function(S){var M=S.r*S.r,F=Math.pow(Math.abs(S.y-n.y),2);if(M<F)S.x=n.x;else{var O=Math.sqrt(M-F);a?S.x=n.x+O:S.x=n.x-O}var L=m[S.id];L.attr("x",S.x),L.attr("y",S.y);var D=(0,qv.find)(L.getChildren(),function(k){return k.get("type")==="text"});D&&(D.attr("y",S.y),D.attr("x",S.x))})}function fdt(e,r,t,i){if(!(!e.length||!r.length)){var n=e[0]?e[0].offset:0,a=r[0].get("coordinate"),o=a.getRadius(),l=a.getCenter();if(n>0){var s=14,u=o+n,c=u*2+s*2,f={start:a.start,end:a.end},h=[[],[]];e.forEach(function(v){!v||(v.textAlign==="right"?h[0].push(v):h[1].push(v))}),h.forEach(function(v,d){var p=c/s;v.length>p&&(v.sort(function(x,m){return m["..percent"]-x["..percent"]}),v.splice(p,v.length-p)),v.sort(function(x,m){return x.y-m.y}),cdt(r,v,s,f,l,d)})}(0,qv.each)(e,function(v){if(v&&v.labelLine){var d=v.offset,p=v.angle,x=(0,Ck.polarToCartesian)(l.x,l.y,o,p),m=(0,Ck.polarToCartesian)(l.x,l.y,o+d/2,p),_=v.x+(0,qv.get)(v,"offsetX",0),b=v.y+(0,qv.get)(v,"offsetY",0),w={x:_-Math.cos(p)*Sk,y:b-Math.sin(p)*Sk};(0,qv.isObject)(v.labelLine)||(v.labelLine={}),v.labelLine.path=["M "+x.x,x.y+" Q"+m.x,m.y+" "+w.x,w.y].join(",")}})}}eH=Q1.distribute=fdt;var K1={},Kp={};Object.defineProperty(Kp,"__esModule",{value:!0});Kp.antiCollision=void 0;function hdt(e,r,t){var i=e.filter(function(d){return!d.invisible});i.sort(function(d,p){return d.y-p.y});var n=!0,a=t.minY,o=t.maxY,l=Math.abs(a-o),s,u=0,c=Number.MIN_VALUE,f=i.map(function(d){return d.y>u&&(u=d.y),d.y<c&&(c=d.y),{content:d.content,size:r,targets:[d.y-a],pos:null}});for(c-=a,u-a>l&&(l=u-a);n;)for(f.forEach(function(d){var p=(Math.min.apply(c,d.targets)+Math.max.apply(c,d.targets))/2;d.pos=Math.min(Math.max(c,p-d.size/2),l-d.size),d.pos=Math.max(0,d.pos)}),n=!1,s=f.length;s--;)if(s>0){var h=f[s-1],v=f[s];h.pos+h.size>v.pos&&(h.size+=v.size,h.targets=h.targets.concat(v.targets),h.pos+h.size>l&&(h.pos=l-h.size),f.splice(s,1),n=!0)}s=0,f.forEach(function(d){var p=a+r/2;d.targets.forEach(function(){i[s].y=d.pos+p,p+=r,s++})})}Kp.antiCollision=hdt;Object.defineProperty(K1,"__esModule",{value:!0});K1.pieOuterLabelLayout=void 0;var zn=Y,Am=Se,vdt=Kp,Ak=4;function ddt(e,r){var t=r.getCenter(),i=r.getRadius();if(e&&e.labelLine){var n=e.angle,a=e.offset,o=(0,Am.polarToCartesian)(t.x,t.y,i,n),l=e.x+(0,zn.get)(e,"offsetX",0)*(Math.cos(n)>0?1:-1),s=e.y+(0,zn.get)(e,"offsetY",0)*(Math.sin(n)>0?1:-1),u={x:l-Math.cos(n)*Ak,y:s-Math.sin(n)*Ak},c=e.labelLine.smooth,f=[],h=u.x-t.x,v=u.y-t.y,d=Math.atan(v/h);if(h<0&&(d+=Math.PI),c===!1){(0,zn.isObject)(e.labelLine)||(e.labelLine={});var p=0;(n<0&&n>-Math.PI/2||n>Math.PI*1.5)&&u.y>o.y&&(p=1),n>=0&&n<Math.PI/2&&u.y>o.y&&(p=1),n>=Math.PI/2&&n<Math.PI&&o.y>u.y&&(p=1),(n<-Math.PI/2||n>=Math.PI&&n<Math.PI*1.5)&&o.y>u.y&&(p=1);var x=a/2>4?4:Math.max(a/2-1,0),m=(0,Am.polarToCartesian)(t.x,t.y,i+x,n),_=(0,Am.polarToCartesian)(t.x,t.y,i+a/2,d),b=0;f.push("M "+o.x+" "+o.y),f.push("L "+m.x+" "+m.y),f.push("A "+t.x+" "+t.y+" 0 "+b+" "+p+" "+_.x+" "+_.y),f.push("L "+u.x+" "+u.y)}else{var m=(0,Am.polarToCartesian)(t.x,t.y,i+(a/2>4?4:Math.max(a/2-1,0)),n),w=o.x<t.x?1:-1;f.push("M "+u.x+" "+u.y);var S=(o.y-t.y)/(o.x-t.x),M=(u.y-t.y)/(u.x-t.x);Math.abs(S-M)>Math.pow(Math.E,-16)&&f.push.apply(f,["C",u.x+w*4,u.y,2*m.x-o.x,2*m.y-o.y,o.x,o.y]),f.push("L "+o.x+" "+o.y)}e.labelLine.path=f.join(" ")}}function pdt(e,r,t,i){var n=(0,zn.filter)(e,function(M){return!(0,zn.isNil)(M)}),a=r[0]&&r[0].get("coordinate");if(!!a){for(var o=a.getCenter(),l=a.getRadius(),s={},u=0,c=r;u<c.length;u++){var f=c[u];s[f.get("id")]=f}var h=(0,zn.get)(n[0],"labelHeight",14),v=(0,zn.get)(n[0],"offset",0);if(!(v<=0)){var d="left",p="right",x=(0,zn.groupBy)(n,function(M){return M.x<o.x?d:p}),m=a.start,_=a.end,b=Math.min((l+v+h)*2,a.getHeight()),w=b/2,S={minX:m.x,maxX:_.x,minY:o.y-w,maxY:o.y+w};(0,zn.each)(x,function(M,F){var O=Math.floor(b/h);M.length>O&&(M.sort(function(L,D){return D.percent-L.percent}),(0,zn.each)(M,function(L,D){D+1>O&&(s[L.id].set("visible",!1),L.invisible=!0)})),(0,vdt.antiCollision)(M,h,S)}),(0,zn.each)(x,function(M,F){(0,zn.each)(M,function(O){var L=F===p,D=s[O.id],k=D.getChildByIndex(0);if(k){var H=l+v,B=O.y-o.y,j=Math.pow(H,2),U=Math.pow(B,2),R=j-U>0?j-U:0,G=Math.sqrt(R),N=Math.abs(Math.cos(O.angle)*H);L?O.x=o.x+Math.max(G,N):O.x=o.x-Math.max(G,N)}k&&(k.attr("y",O.y),k.attr("x",O.x)),ddt(O,a)})})}}}K1.pieOuterLabelLayout=pdt;var J1={};Object.defineProperty(J1,"__esModule",{value:!0});J1.pieSpiderLabelLayout=void 0;var un=Y,nT=Se,gdt=Kp,ydt=Tr,aT=4,mdt=4,Tk=4;function xdt(e,r,t){var i=r.getCenter(),n=r.getRadius(),a={x:e.x-(t?Tk:-Tk),y:e.y},o=(0,nT.polarToCartesian)(i.x,i.y,n+aT,e.angle),l={x:a.x,y:a.y},s={x:o.x,y:o.y},u=(0,nT.polarToCartesian)(i.x,i.y,n,e.angle),c="";if(a.y!==o.y){var f=t?4:-4;l.y=a.y,e.angle<0&&e.angle>=-Math.PI/2&&(l.x=Math.max(o.x,a.x-f),a.y<o.y?s.y=l.y:(s.y=o.y,s.x=Math.max(s.x,l.x-f))),e.angle>0&&e.angle<Math.PI/2&&(l.x=Math.max(o.x,a.x-f),a.y>o.y?s.y=l.y:(s.y=o.y,s.x=Math.max(s.x,l.x-f))),e.angle>Math.PI/2&&(l.x=Math.min(o.x,a.x-f),a.y>o.y?s.y=l.y:(s.y=o.y,s.x=Math.min(s.x,l.x-f))),e.angle<-Math.PI/2&&(l.x=Math.min(o.x,a.x-f),a.y<o.y?s.y=l.y:(s.y=o.y,s.x=Math.min(s.x,l.x-f)))}c=["M "+a.x+","+a.y,"L "+l.x+","+l.y,"L "+s.x+","+s.y,"L "+o.x+","+o.y,"L "+u.x+","+u.y].join(" "),e.labelLine=(0,un.deepMix)({},e.labelLine,{path:c})}function _dt(e,r,t,i){var n=r[0]&&r[0].get("coordinate");if(!!n){for(var a=n.getCenter(),o=n.getRadius(),l={},s=0,u=r;s<u.length;s++){var c=u[s];l[c.get("id")]=c}var f=(0,un.get)(e[0],"labelHeight",14),h=Math.max((0,un.get)(e[0],"offset",0),aT);(0,un.each)(e,function(M){var F=(0,un.get)(l,[M.id]);if(!!F){var O=M.x>a.x||M.x===a.x&&M.y>a.y,L=(0,un.isNil)(M.offsetX)?mdt:M.offsetX,D=(0,nT.polarToCartesian)(a.x,a.y,o+aT,M.angle),k=h+L;M.x=a.x+(O?1:-1)*(o+k),M.y=D.y}});var v=n.start,d=n.end,p="left",x="right",m=(0,un.groupBy)(e,function(M){return M.x<a.x?p:x}),_=(o+h)*2+f;(0,un.each)(m,function(M){var F=M.length*f;F>_&&(_=Math.min(F,Math.abs(v.y-d.y)))});var b={minX:v.x,maxX:d.x,minY:a.y-_/2,maxY:a.y+_/2};(0,un.each)(m,function(M,F){var O=_/f;M.length>O&&(M.sort(function(L,D){return D.percent-L.percent}),(0,un.each)(M,function(L,D){D>O&&(l[L.id].set("visible",!1),L.invisible=!0)})),(0,gdt.antiCollision)(M,f,b)});var w=b.minY,S=b.maxY;(0,un.each)(m,function(M,F){var O=F===x;(0,un.each)(M,function(L){var D=(0,un.get)(l,L&&[L.id]);if(!!D){if(L.y<w||L.y>S){D.set("visible",!1);return}var k=D.getChildByIndex(0),H=k.getCanvasBBox(),B={x:O?H.x:H.maxX,y:H.y+H.height/2};(0,ydt.translate)(k,L.x-B.x,L.y-B.y),L.labelLine&&xdt(L,n,O)}})})}}J1.pieSpiderLabelLayout=_dt;var t_={};Object.defineProperty(t_,"__esModule",{value:!0});var rH=t_.limitInCanvas=void 0,bdt=Y,wdt=Tr;function Cdt(e,r,t,i){(0,bdt.each)(r,function(n){var a=i.minX,o=i.minY,l=i.maxX,s=i.maxY,u=n.getCanvasBBox(),c=u.minX,f=u.minY,h=u.maxX,v=u.maxY,d=u.x,p=u.y,x=u.width,m=u.height,_=d,b=p;(c<a||h<a)&&(_=a),(f<o||v<o)&&(b=o),c>l?_=l-x:h>l&&(_=_-(h-l)),f>s?b=s-m:v>s&&(b=b-(v-s)),(_!==d||b!==p)&&(0,wdt.translate)(n,_-d,b-p)})}rH=t_.limitInCanvas=Cdt;var e_={};Object.defineProperty(e_,"__esModule",{value:!0});var iH=e_.limitInShape=void 0,Sdt=Y;function Adt(e,r,t,i){(0,Sdt.each)(r,function(n,a){var o=n.getCanvasBBox(),l=t[a].getBBox();(o.minX<l.minX||o.minY<l.minY||o.maxX>l.maxX||o.maxY>l.maxY)&&n.remove(!0)})}iH=e_.limitInShape=Adt;var Uf={};Object.defineProperty(Uf,"__esModule",{value:!0});var nH=Uf.overlap=lH=Uf.fixedOverlap=void 0,aH=Y,Tdt=100,oH=function(){function e(r){r===void 0&&(r={}),this.bitmap={};var t=r.xGap,i=t===void 0?1:t,n=r.yGap,a=n===void 0?8:n;this.xGap=i,this.yGap=a}return e.prototype.hasGap=function(r){for(var t=!0,i=this.bitmap,n=Math.round(r.minX),a=Math.round(r.maxX),o=Math.round(r.minY),l=Math.round(r.maxY),s=n;s<=a;s+=1){if(!i[s]){i[s]={};continue}if(s===n||s===a){for(var u=o;u<=l;u++)if(i[s][u]){t=!1;break}}else if(i[s][o]||i[s][l]){t=!1;break}}return t},e.prototype.fillGap=function(r){for(var t=this.bitmap,i=Math.round(r.minX),n=Math.round(r.maxX),a=Math.round(r.minY),o=Math.round(r.maxY),l=i;l<=n;l+=1)t[l]||(t[l]={});for(var l=i;l<=n;l+=this.xGap){for(var s=a;s<=o;s+=this.yGap)t[l][s]=!0;t[l][o]=!0}if(this.yGap!==1)for(var l=a;l<=o;l+=1)t[i][l]=!0,t[n][l]=!0;if(this.xGap!==1)for(var l=i;l<=n;l+=1)t[l][a]=!0,t[l][o]=!0},e.prototype.destroy=function(){this.bitmap={}},e}();function Mdt(e,r,t){t===void 0&&(t=Tdt);var i=-1,n=e.attr(),a=n.x,o=n.y,l=e.getCanvasBBox(),s=Math.sqrt(l.width*l.width+l.height*l.height),u,c=-i,f=0,h=0,v=function(m){var _=m*.1;return[_*Math.cos(_),_*Math.sin(_)]};if(r.hasGap(l))return r.fillGap(l),!0;for(var d=!1,p=0,x={};Math.min(Math.abs(f),Math.abs(h))<s&&p<t;)if(u=v(c+=i),f=~~u[0],h=~~u[1],!(!f&&!h||x[f+"-"+h])&&(e.attr({x:a+f,y:o+h}),f+h<0&&e.attr("textAlign","right"),p++,r.hasGap(e.getCanvasBBox()))){r.fillGap(e.getCanvasBBox()),d=!0,x[f+"-"+h]=!0;break}return d}function Edt(e,r,t,i){var n=e.getCanvasBBox(),a=n.width,o=n.height,l={x:r,y:t,textAlign:"center"};switch(i){case 0:l.y-=o+1,l.x+=1,l.textAlign="left";break;case 1:l.y-=o+1,l.x-=1,l.textAlign="right";break;case 2:l.y+=o+1,l.x-=1,l.textAlign="right";break;case 3:l.y+=o+1,l.x+=1,l.textAlign="left";break;case 5:l.y-=o*2+2;break;case 6:l.y+=o*2+2;break;case 7:l.x+=a+1,l.textAlign="left";break;case 8:l.x-=a+1,l.textAlign="right";break}return e.attr(l),e.getCanvasBBox()}function Fdt(e,r,t,i){var n=new oH;(0,aH.each)(r,function(a){var o=a.find(function(l){return l.get("type")==="text"});Mdt(o,n)||a.remove(!0)}),n.destroy()}var lH=Uf.fixedOverlap=Fdt;function Odt(e,r,t,i){var n=new oH;(0,aH.each)(r,function(a){for(var o=a.find(function(v){return v.get("type")==="text"}),l=o.attr(),s=l.x,u=l.y,c=!1,f=0;f<=8;f++){var h=Edt(o,s,u,f);if(n.hasGap(h)){n.fillGap(h),c=!0;break}}c||a.remove(!0)}),n.destroy()}nH=Uf.overlap=Odt;var r_={},qf={};Object.defineProperty(qf,"__esModule",{value:!0});qf.isIntersect=qf.isIntersectRect=void 0;var Mk=V,Pdt=Y,Idt=ta,Ldt=Idt.vec2.dot;function Ek(e){if(e.length>4)return[];var r=function(n,a){return[a.x-n.x,a.y-n.y]},t=r(e[0],e[1]),i=r(e[1],e[2]);return[t,i]}function Tm(e,r,t){r===void 0&&(r=0),t===void 0&&(t={x:0,y:0});var i=e.x,n=e.y;return{x:(i-t.x)*Math.cos(-r)+(n-t.y)*Math.sin(-r)+t.x,y:(t.x-i)*Math.sin(-r)+(n-t.y)*Math.cos(-r)+t.y}}function Fk(e){var r=[{x:e.x,y:e.y},{x:e.x+e.width,y:e.y},{x:e.x+e.width,y:e.y+e.height},{x:e.x,y:e.y+e.height}],t=e.rotation;return t?[Tm(r[0],t,r[0]),Tm(r[1],t,r[0]),Tm(r[2],t,r[0]),Tm(r[3],t,r[0])]:r}function Ok(e,r){if(e.length>4)return{min:0,max:0};var t=[];return e.forEach(function(i){t.push(Ldt([i.x,i.y],r))}),{min:Math.min.apply(Math,t),max:Math.max.apply(Math,t)}}function Ddt(e,r){return e.max>r.min&&e.min<r.max}function $dt(e){return(0,Pdt.isNumber)(e)&&!Number.isNaN(e)&&e!==1/0&&e!==-1/0}function Pk(e){return Object.values(e).every($dt)}function sH(e,r,t){return t===void 0&&(t=0),!(r.x>e.x+e.width+t||r.x+r.width<e.x-t||r.y>e.y+e.height+t||r.y+r.height<e.y-t)}qf.isIntersectRect=sH;function kdt(e,r){if(!Pk(e)||!Pk(r))return!1;if(!e.rotation&&!r.rotation)return sH(e,r);for(var t=Fk(e),i=Fk(r),n=(0,Mk.__spreadArray)((0,Mk.__spreadArray)([],Ek(t),!0),Ek(i),!0),a=0;a<n.length;a++){var o=n[a],l=Ok(t,o),s=Ok(i,o);if(!Ddt(l,s))return!1}return!0}qf.isIntersect=kdt;Object.defineProperty(r_,"__esModule",{value:!0});r_.hideOverlap=void 0;var Ik=Y,Rdt=qf,Lk=Ti;function Bdt(e,r,t,i){for(var n=0;n<r.length;n++){var a=r[n];if(r[n].get("visible"))for(var o=n+1;o<r.length;o++){var l=r[o];if(a&&l&&a!==l&&l.get("visible")){var s=(0,Lk.getlLabelBackgroundInfo)(a,e[n],(0,Ik.get)(e[n],"background.padding")),u=(0,Lk.getlLabelBackgroundInfo)(l,e[o],(0,Ik.get)(e[o],"background.padding"));(0,Rdt.isIntersect)(s,u)&&r[o].set("visible",!1)}}}}r_.hideOverlap=Bdt;var i_={},n_={};Object.defineProperty(n_,"__esModule",{value:!0});n_.isContrastColorWhite=void 0;var Ndt=V,Dk=(0,Ndt.__importDefault)(Lj),$k={"#5B8FF9":!0},Gdt=function(e){var r=Dk.default.toRGB(e).toUpperCase();if($k[r])return $k[r];var t=Dk.default.rgb2arr(r),i=t[0],n=t[1],a=t[2],o=(i*299+n*587+a*114)/1e3<128;return o};n_.isContrastColorWhite=Gdt;Object.defineProperty(i_,"__esModule",{value:!0});i_.adjustColor=void 0;var kk=ti,zdt=n_;function Vdt(e,r,t){if(t.length!==0){var i=t[0].get("element"),n=i.geometry.theme,a=n.labels||{},o=a.fillColorLight,l=a.fillColorDark;t.forEach(function(s,u){var c=r[u],f=c.find(function(m){return m.get("type")==="text"}),h=kk.BBox.fromObject(s.getBBox()),v=kk.BBox.fromObject(f.getCanvasBBox()),d=!h.contains(v),p=s.attr("fill"),x=(0,zdt.isContrastColorWhite)(p);d?f.attr(n.overflowLabels.style):x?o&&f.attr("fill",o):l&&f.attr("fill",l)})}}i_.adjustColor=Vdt;var a_={};Object.defineProperty(a_,"__esModule",{value:!0});a_.intervalAdjustPosition=void 0;var oT=ti,uH=Ti;function jdt(e,r,t){var i=e.coordinate,n=(0,uH.findLabelTextShape)(r),a=oT.BBox.fromObject(n.getCanvasBBox()),o=oT.BBox.fromObject(t.getBBox());return i.isTransposed?o.height>=a.height:o.width>=a.width}function Hdt(e,r,t){var i=!!e.getAdjust("stack");return i||r.every(function(n,a){var o=t[a];return jdt(e,n,o)})}function Ydt(e,r,t){var i=e.coordinate,n=oT.BBox.fromObject(t.getBBox()),a=(0,uH.findLabelTextShape)(r);i.isTransposed?a.attr({x:n.minX+n.width/2,textAlign:"center"}):a.attr({y:n.minY+n.height/2,textBaseline:"middle"})}function Wdt(e,r,t){var i;if(t.length!==0){var n=(i=t[0])===null||i===void 0?void 0:i.get("element"),a=n==null?void 0:n.geometry;if(!(!a||a.type!=="interval")){var o=Hdt(a,r,t);o&&t.forEach(function(l,s){var u=r[s];Ydt(a,u,l)})}}}a_.intervalAdjustPosition=Wdt;var o_={};Object.defineProperty(o_,"__esModule",{value:!0});o_.intervalHideOverlap=void 0;var pu=Y,Xdt=Ti;function Udt(e){var r=500,t=[],i=Math.max(Math.floor(e.length/r),1);return(0,pu.each)(e,function(n,a){a%i===0?t.push(n):n.set("visible",!1)}),t}function qdt(e,r,t){var i;if(t.length!==0){var n=(i=t[0])===null||i===void 0?void 0:i.get("element"),a=n==null?void 0:n.geometry;if(!(!a||a.type!=="interval")){var o=Udt(r),l=a.getXYFields()[0],s=[],u=[],c=(0,pu.groupBy)(o,function(p){return p.get("data")[l]}),f=(0,pu.uniq)((0,pu.map)(o,function(p){return p.get("data")[l]})),h;o.forEach(function(p){p.set("visible",!0)});var v=function(p){p&&(p.length&&u.push(p.pop()),u.push.apply(u,p))};for((0,pu.size)(f)>0&&(h=f.shift(),v(c[h])),(0,pu.size)(f)>0&&(h=f.pop(),v(c[h])),(0,pu.each)(f.reverse(),function(p){v(c[p])});u.length>0;){var d=u.shift();d.get("visible")&&((0,Xdt.checkShapeOverlap)(d,s)?d.set("visible",!1):s.push(d))}}}}o_.intervalHideOverlap=qdt;var l_={};Object.defineProperty(l_,"__esModule",{value:!0});l_.pointAdjustPosition=void 0;var JC=Y,lT=Ti;function Zdt(e,r){var t=e.getXYFields()[1],i=[],n=r.sort(function(a,o){return a.get("data")[t]-a.get("data")[t]});return n.length>0&&i.push(n.shift()),n.length>0&&i.push(n.pop()),i.push.apply(i,n),i}function cH(e,r,t){return e.some(function(i){return t(i,r)})}function Qdt(e,r,t){t===void 0&&(t=0);var i=Math.max(0,Math.min(e.x+e.width+t,r.x+r.width+t)-Math.max(e.x-t,r.x-t)),n=Math.max(0,Math.min(e.y+e.height+t,r.y+r.height+t)-Math.max(e.y-t,r.y-t));return i*n}function Rk(e,r){return cH(e,r,function(t,i){var n=(0,lT.findLabelTextShape)(t),a=(0,lT.findLabelTextShape)(i);return Qdt(n.getCanvasBBox(),a.getCanvasBBox(),2)>0})}function Kdt(e,r,t,i,n){var a,o;if(t.length!==0){var l=(a=t[0])===null||a===void 0?void 0:a.get("element"),s=l==null?void 0:l.geometry;if(!(!s||s.type!=="point")){var u=s.getXYFields(),c=u[0],f=u[1],h=(0,JC.groupBy)(r,function(p){return p.get("data")[c]}),v=[],d=n&&n.offset||((o=e[0])===null||o===void 0?void 0:o.offset)||12;(0,JC.map)((0,JC.keys)(h).reverse(),function(p){for(var x=Zdt(s,h[p]);x.length;){var m=x.shift(),_=(0,lT.findLabelTextShape)(m);if(cH(v,m,function(S,M){return S.get("data")[c]===M.get("data")[c]&&S.get("data")[f]===M.get("data")[f]})){_.set("visible",!1);continue}var b=Rk(v,m),w=!1;if(b&&(_.attr("y",_.attr("y")+2*d),w=Rk(v,m)),w){_.set("visible",!1);continue}v.push(m)}})}}}l_.pointAdjustPosition=Kdt;var s_={};Object.defineProperty(s_,"__esModule",{value:!0});s_.pathAdjustPosition=void 0;var tS=Y,sT=Ti;function Jdt(e,r){var t=e.getXYFields()[1],i=[],n=r.sort(function(a,o){return a.get("data")[t]-a.get("data")[t]});return n.length>0&&i.push(n.shift()),n.length>0&&i.push(n.pop()),i.push.apply(i,n),i}function fH(e,r,t){return e.some(function(i){return t(i,r)})}function tpt(e,r,t){t===void 0&&(t=0);var i=Math.max(0,Math.min(e.x+e.width+t,r.x+r.width+t)-Math.max(e.x-t,r.x-t)),n=Math.max(0,Math.min(e.y+e.height+t,r.y+r.height+t)-Math.max(e.y-t,r.y-t));return i*n}function Bk(e,r){return fH(e,r,function(t,i){var n=(0,sT.findLabelTextShape)(t),a=(0,sT.findLabelTextShape)(i);return tpt(n.getCanvasBBox(),a.getCanvasBBox(),2)>0})}function ept(e,r,t,i,n){var a,o;if(t.length!==0){var l=(a=t[0])===null||a===void 0?void 0:a.get("element"),s=l==null?void 0:l.geometry;if(!(!s||["path","line","area"].indexOf(s.type)<0)){var u=s.getXYFields(),c=u[0],f=u[1],h=(0,tS.groupBy)(r,function(p){return p.get("data")[c]}),v=[],d=n&&n.offset||((o=e[0])===null||o===void 0?void 0:o.offset)||12;(0,tS.map)((0,tS.keys)(h).reverse(),function(p){for(var x=Jdt(s,h[p]);x.length;){var m=x.shift(),_=(0,sT.findLabelTextShape)(m);if(fH(v,m,function(S,M){return S.get("data")[c]===M.get("data")[c]&&S.get("data")[f]===M.get("data")[f]})){_.set("visible",!1);continue}var b=Bk(v,m),w=!1;if(b&&(_.attr("y",_.attr("y")+2*d),w=Bk(v,m)),w){_.set("visible",!1);continue}v.push(m)}})}}}s_.pathAdjustPosition=ept;var u_={},hH={},c_={};Object.defineProperty(c_,"__esModule",{value:!0});c_.getCanvasContext=void 0;var eS;function rpt(){return eS||(eS=document.createElement("canvas").getContext("2d")),eS}c_.getCanvasContext=rpt;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.getEllipsisText=e.measureTextWidth=void 0;var r=V,t=Y,i=c_;e.measureTextWidth=(0,t.memoize)(function(a,o){o===void 0&&(o={});var l=o.fontSize,s=o.fontFamily,u=o.fontWeight,c=o.fontStyle,f=o.fontVariant,h=(0,i.getCanvasContext)();return h.font=[c,f,u,l+"px",s].join(" "),h.measureText((0,t.isString)(a)?a:"").width},function(a,o){return o===void 0&&(o={}),(0,r.__spreadArray)([a],(0,t.values)(o),!0).join("")});var n=function(a,o,l){var s=16,u=(0,e.measureTextWidth)("...",l),c;(0,t.isString)(a)?c=a:c=(0,t.toString)(a);var f=o,h=[],v,d;if((0,e.measureTextWidth)(a,l)<=o)return a;for(;v=c.substr(0,s),d=(0,e.measureTextWidth)(v,l),!(d+u>f&&d>f);)if(h.push(v),f-=d,c=c.substr(s),!c)return h.join("");for(;v=c.substr(0,1),d=(0,e.measureTextWidth)(v,l),!(d+u>f);)if(h.push(v),f-=d,c=c.substr(1),!c)return h.join("");return h.join("")+"..."};e.getEllipsisText=n})(hH);Object.defineProperty(u_,"__esModule",{value:!0});u_.limitInPlot=void 0;var Nk=Y,ipt=be,npt=hH,apt=Tr;function opt(e,r,t,i,n){if(!(r.length<=0)){var a=(n==null?void 0:n.direction)||["top","right","bottom","left"],o=(n==null?void 0:n.action)||"translate",l=(n==null?void 0:n.margin)||0,s=r[0].get("coordinate");if(!!s){var u=(0,ipt.getCoordinateBBox)(s,l),c=u.minX,f=u.minY,h=u.maxX,v=u.maxY;(0,Nk.each)(r,function(d){var p=d.getCanvasBBox(),x=p.minX,m=p.minY,_=p.maxX,b=p.maxY,w=p.x,S=p.y,M=p.width,F=p.height,O=w,L=S;if(a.indexOf("left")>=0&&(x<c||_<c)&&(O=c),a.indexOf("top")>=0&&(m<f||b<f)&&(L=f),a.indexOf("right")>=0&&(x>h?O=h-M:_>h&&(O=O-(_-h))),a.indexOf("bottom")>=0&&(m>v?L=v-F:b>v&&(L=L-(b-v))),O!==w||L!==S){var D=O-w;if(o==="translate")(0,apt.translate)(d,D,L-S);else if(o==="ellipsis"){var k=d.findAll(function(H){return H.get("type")==="text"});k.forEach(function(H){var B=(0,Nk.pick)(H.attr(),["fontSize","fontFamily","fontWeight","fontStyle","fontVariant"]),j=H.getCanvasBBox(),U=(0,npt.getEllipsisText)(H.attr("text"),j.width-Math.abs(D),B);H.attr("text",U)})}else d.hide()}})}}}u_.limitInPlot=opt;var mF={},Ma={};Object.defineProperty(Ma,"__esModule",{value:!0});Ma.getAnglePoint=Ma.getFactTitleConfig=void 0;var El=Jt;function lpt(e){return[El.DIRECTION.TOP,El.DIRECTION.BOTTOM].includes(e)?{offsetX:0,offsetY:e===El.DIRECTION.TOP?-8:8,style:{textAlign:"center",textBaseline:e===El.DIRECTION.TOP?"bottom":"top"}}:[El.DIRECTION.LEFT,El.DIRECTION.RIGHT].includes(e)?{offsetX:e===El.DIRECTION.LEFT?-8:8,offsetY:0,style:{textAlign:e===El.DIRECTION.LEFT?"right":"left",textBaseline:"middle",rotate:Math.PI/2}}:{}}Ma.getFactTitleConfig=lpt;function spt(e,r,t){return{x:e.x+r*Math.cos(t),y:e.y+r*Math.sin(t)}}Ma.getAnglePoint=spt;Object.defineProperty(mF,"__esModule",{value:!0});var upt=V,wv=Y,cpt=Jt,Mm=Ma,fpt=_o,hpt=function(e){(0,upt.__extends)(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){return(0,wv.deepMix)({},e.prototype.getDefaultCfg.call(this),{type:"circle",showTitle:!0,title:e.prototype.getDefaultTitleCfg.call(this)})},r.prototype.render=function(){e.prototype.render.call(this),this.cfg.showTitle&&this.renderTitle()},r.prototype.getRegion=function(t,i){var n=.5,a={x:.5,y:.5},o=Math.PI*2/t,l=-1*Math.PI/2+o*i,s=n/(1+1/Math.sin(o/2)),u=(0,Mm.getAnglePoint)(a,n-s,l),c=Math.PI*5/4,f=Math.PI*1/4;return{start:(0,Mm.getAnglePoint)(u,s,c),end:(0,Mm.getAnglePoint)(u,s,f)}},r.prototype.afterEachView=function(t,i){this.processAxis(t,i)},r.prototype.beforeEachView=function(t,i){},r.prototype.generateFacets=function(t){var i=this,n=this.cfg,a=n.fields,o=n.type,l=a[0];if(!l)throw new Error("No `fields` specified!");var s=this.getFieldValues(t,l),u=s.length,c=[];return s.forEach(function(f,h){var v=[{field:l,value:f,values:s}],d=(0,wv.filter)(t,i.getFacetDataFilter(v)),p={type:o,data:d,region:i.getRegion(u,h),columnValue:f,columnField:l,columnIndex:h,columnValuesLength:u,rowValue:null,rowField:null,rowIndex:0,rowValuesLength:1};c.push(p)}),c},r.prototype.getXAxisOption=function(t,i,n,a){return n},r.prototype.getYAxisOption=function(t,i,n,a){return n},r.prototype.renderTitle=function(){var t=this;(0,wv.each)(this.facets,function(i){var n=i.columnValue,a=i.view,o=(0,wv.get)(t.cfg.title,"formatter"),l=(0,wv.deepMix)({position:["50%","0%"],content:o?o(n):n},(0,Mm.getFactTitleConfig)(cpt.DIRECTION.TOP),t.cfg.title);a.annotation().text(l)})},r}(fpt.Facet),vpt=mF.default=hpt,xF={};Object.defineProperty(xF,"__esModule",{value:!0});var Cv=V,Sv=Y,dpt=Jt,ppt=Ma,gpt=_o,ypt=function(e){(0,Cv.__extends)(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){return(0,Sv.deepMix)({},e.prototype.getDefaultCfg.call(this),{type:"list",cols:null,showTitle:!0,title:e.prototype.getDefaultTitleCfg.call(this)})},r.prototype.render=function(){e.prototype.render.call(this),this.cfg.showTitle&&this.renderTitle()},r.prototype.afterEachView=function(t,i){this.processAxis(t,i)},r.prototype.beforeEachView=function(t,i){},r.prototype.generateFacets=function(t){var i=this,n=this.cfg.fields,a=this.cfg.cols,o=n[0];if(!o)throw new Error("No `fields` specified!");var l=this.getFieldValues(t,o),s=l.length;a=a||s;var u=this.getPageCount(s,a),c=[];return l.forEach(function(f,h){var v=i.getRowCol(h,a),d=v.row,p=v.col,x=[{field:o,value:f,values:l}],m=(0,Sv.filter)(t,i.getFacetDataFilter(x)),_={type:i.cfg.type,data:m,region:i.getRegion(u,a,p,d),columnValue:f,rowValue:f,columnField:o,rowField:null,columnIndex:p,rowIndex:d,columnValuesLength:a,rowValuesLength:u,total:s};c.push(_)}),c},r.prototype.getXAxisOption=function(t,i,n,a){return a.rowIndex!==a.rowValuesLength-1&&a.columnValuesLength*a.rowIndex+a.columnIndex+1+a.columnValuesLength<=a.total?(0,Cv.__assign)((0,Cv.__assign)({},n),{label:null,title:null}):n},r.prototype.getYAxisOption=function(t,i,n,a){return a.columnIndex!==0?(0,Cv.__assign)((0,Cv.__assign)({},n),{title:null,label:null}):n},r.prototype.renderTitle=function(){var t=this;(0,Sv.each)(this.facets,function(i){var n=i.columnValue,a=i.view,o=(0,Sv.get)(t.cfg.title,"formatter"),l=(0,Sv.deepMix)({position:["50%","0%"],content:o?o(n):n},(0,ppt.getFactTitleConfig)(dpt.DIRECTION.TOP),t.cfg.title);a.annotation().text(l)})},r.prototype.getPageCount=function(t,i){return Math.floor((t+i-1)/i)},r.prototype.getRowCol=function(t,i){var n=Math.floor(t/i),a=t%i;return{row:n,col:a}},r}(gpt.Facet),mpt=xF.default=ypt,_F={};Object.defineProperty(_F,"__esModule",{value:!0});var ru=V,zc=Y,Gk=Jt,zk=Ma,xpt=_o,_pt=function(e){(0,ru.__extends)(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){return(0,zc.deepMix)({},e.prototype.getDefaultCfg.call(this),{type:"matrix",showTitle:!1,columnTitle:(0,ru.__assign)({},e.prototype.getDefaultTitleCfg.call(this)),rowTitle:(0,ru.__assign)({},e.prototype.getDefaultTitleCfg.call(this))})},r.prototype.render=function(){e.prototype.render.call(this),this.cfg.showTitle&&this.renderTitle()},r.prototype.afterEachView=function(t,i){this.processAxis(t,i)},r.prototype.beforeEachView=function(t,i){},r.prototype.generateFacets=function(t){for(var i=this.cfg,n=i.fields,a=i.type,o=n.length,l=o,s=[],u=0;u<l;u++)for(var c=n[u],f=0;f<o;f++){var h=n[f],v={type:a,data:t,region:this.getRegion(o,l,u,f),columnValue:c,rowValue:h,columnField:c,rowField:h,columnIndex:u,rowIndex:f,columnValuesLength:l,rowValuesLength:o};s.push(v)}return s},r.prototype.getXAxisOption=function(t,i,n,a){return a.rowIndex!==a.rowValuesLength-1?(0,ru.__assign)((0,ru.__assign)({},n),{label:null,title:null}):n},r.prototype.getYAxisOption=function(t,i,n,a){return a.columnIndex!==0?(0,ru.__assign)((0,ru.__assign)({},n),{title:null,label:null}):n},r.prototype.renderTitle=function(){var t=this;(0,zc.each)(this.facets,function(i,n){var a=i.columnIndex,o=i.rowIndex,l=i.columnValuesLength;i.rowValuesLength;var s=i.columnValue,u=i.rowValue,c=i.view;if(o===0){var f=(0,zc.get)(t.cfg.columnTitle,"formatter"),h=(0,zc.deepMix)({position:["50%","0%"],content:f?f(s):s},(0,zk.getFactTitleConfig)(Gk.DIRECTION.TOP),t.cfg.columnTitle);c.annotation().text(h)}if(a===l-1){var f=(0,zc.get)(t.cfg.rowTitle,"formatter"),h=(0,zc.deepMix)({position:["100%","50%"],content:f?f(u):u},(0,zk.getFactTitleConfig)(Gk.DIRECTION.RIGHT),t.cfg.rowTitle);c.annotation().text(h)}})},r}(xpt.Facet),bpt=_F.default=_pt,bF={};Object.defineProperty(bF,"__esModule",{value:!0});var rS=V,Vc=Y,Vk=Jt,jk=Ma,wpt=_o,Cpt=function(e){(0,rS.__extends)(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){return(0,Vc.deepMix)({},e.prototype.getDefaultCfg.call(this),{type:"mirror",showTitle:!0,title:e.prototype.getDefaultTitleCfg.call(this),transpose:!1})},r.prototype.render=function(){e.prototype.render.call(this),this.cfg.showTitle&&this.renderTitle()},r.prototype.beforeEachView=function(t,i){this.cfg.transpose?i.columnIndex%2===0?t.coordinate().transpose().reflect("x"):t.coordinate().transpose():i.rowIndex%2!==0&&t.coordinate().reflect("y")},r.prototype.afterEachView=function(t,i){this.processAxis(t,i)},r.prototype.generateFacets=function(t){var i=this,n=this.cfg.fields[0],a=[],o=1,l=1,s=[""],u=[""],c,f;return this.cfg.transpose?(c=n,s=this.getFieldValues(t,c).slice(0,2),o=s.length):(f=n,u=this.getFieldValues(t,f).slice(0,2),l=u.length),s.forEach(function(h,v){u.forEach(function(d,p){var x=[{field:c,value:h,values:s},{field:f,value:d,values:u}],m=(0,Vc.filter)(t,i.getFacetDataFilter(x)),_={type:i.cfg.type,data:m,region:i.getRegion(l,o,v,p),columnValue:h,rowValue:d,columnField:c,rowField:f,columnIndex:v,rowIndex:p,columnValuesLength:o,rowValuesLength:l};a.push(_)})}),a},r.prototype.getXAxisOption=function(t,i,n,a){return a.columnIndex===1||a.rowIndex===1?(0,rS.__assign)((0,rS.__assign)({},n),{label:null,title:null}):n},r.prototype.getYAxisOption=function(t,i,n,a){return n},r.prototype.renderTitle=function(){var t=this;(0,Vc.each)(this.facets,function(i,n){var a=i.columnValue,o=i.rowValue,l=i.view,s=(0,Vc.get)(t.cfg.title,"formatter");if(t.cfg.transpose){var u=(0,Vc.deepMix)({position:["50%","0%"],content:s?s(a):a},(0,jk.getFactTitleConfig)(Vk.DIRECTION.TOP),t.cfg.title);l.annotation().text(u)}else{var u=(0,Vc.deepMix)({position:["100%","50%"],content:s?s(o):o},(0,jk.getFactTitleConfig)(Vk.DIRECTION.RIGHT),t.cfg.title);l.annotation().text(u)}})},r}(wpt.Facet),Spt=bF.default=Cpt,wF={};Object.defineProperty(wF,"__esModule",{value:!0});var sa=V,iu=Y,Hk=Jt,Yk=Ma,Apt=_o,Tpt=function(e){(0,sa.__extends)(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.afterEachView=function(t,i){this.processAxis(t,i)},r.prototype.beforeEachView=function(t,i){},r.prototype.getDefaultCfg=function(){return(0,iu.deepMix)({},e.prototype.getDefaultCfg.call(this),{type:"rect",columnTitle:(0,sa.__assign)({},e.prototype.getDefaultTitleCfg.call(this)),rowTitle:(0,sa.__assign)({},e.prototype.getDefaultTitleCfg.call(this))})},r.prototype.render=function(){e.prototype.render.call(this),this.cfg.showTitle&&this.renderTitle()},r.prototype.generateFacets=function(t){var i=this,n=this.cfg.fields,a=n[0],o=n[1],l=[],s=1,u=1,c=[""],f=[""];return a&&(c=this.getFieldValues(t,a),s=c.length),o&&(f=this.getFieldValues(t,o),u=f.length),c.forEach(function(h,v){f.forEach(function(d,p){var x=[{field:a,value:h,values:c},{field:o,value:d,values:f}],m=(0,iu.filter)(t,i.getFacetDataFilter(x)),_={type:i.cfg.type,data:m,region:i.getRegion(u,s,v,p),columnValue:h,rowValue:d,columnField:a,rowField:o,columnIndex:v,rowIndex:p,columnValuesLength:s,rowValuesLength:u};l.push(_)})}),l},r.prototype.renderTitle=function(){var t=this;(0,iu.each)(this.facets,function(i,n){var a=i.columnIndex,o=i.rowIndex,l=i.columnValuesLength,s=i.columnValue,u=i.rowValue,c=i.view;if(o===0){var f=(0,iu.get)(t.cfg.columnTitle,"formatter"),h=(0,iu.deepMix)({position:["50%","0%"],content:f?f(s):s},(0,Yk.getFactTitleConfig)(Hk.DIRECTION.TOP),t.cfg.columnTitle);c.annotation().text(h)}if(a===l-1){var f=(0,iu.get)(t.cfg.rowTitle,"formatter"),h=(0,iu.deepMix)({position:["100%","50%"],content:f?f(u):u},(0,Yk.getFactTitleConfig)(Hk.DIRECTION.RIGHT),t.cfg.rowTitle);c.annotation().text(h)}})},r.prototype.getXAxisOption=function(t,i,n,a){return a.rowIndex!==a.rowValuesLength-1?(0,sa.__assign)((0,sa.__assign)({},n),{title:null,label:null}):a.columnIndex!==Math.floor((a.columnValuesLength-1)/2)?(0,sa.__assign)((0,sa.__assign)({},n),{title:null}):n},r.prototype.getYAxisOption=function(t,i,n,a){return a.columnIndex!==0?(0,sa.__assign)((0,sa.__assign)({},n),{title:null,label:null}):a.rowIndex!==Math.floor((a.rowValuesLength-1)/2)?(0,sa.__assign)((0,sa.__assign)({},n),{title:null}):n},r}(Apt.Facet),Mpt=wF.default=Tpt,CF={};Object.defineProperty(CF,"__esModule",{value:!0});var Av=V,Tv=Y,Wk=Jt,Ept=Ma,Fpt=_o,Opt=function(e){(0,Av.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.afterChartRender=function(){t.facets&&t.cfg.line&&(t.container.clear(),t.drawLines(t.facets))},t}return r.prototype.afterEachView=function(t,i){this.processAxis(t,i)},r.prototype.beforeEachView=function(t,i){},r.prototype.init=function(){e.prototype.init.call(this),this.view.on(Wk.VIEW_LIFE_CIRCLE.AFTER_RENDER,this.afterChartRender)},r.prototype.getDefaultCfg=function(){return(0,Tv.deepMix)({},e.prototype.getDefaultCfg.call(this),{type:"tree",line:{style:{lineWidth:1,stroke:"#ddd"},smooth:!1},showTitle:!0,title:e.prototype.getDefaultTitleCfg.call(this)})},r.prototype.generateFacets=function(t){var i=this.cfg.fields;if(!i.length)throw new Error("Please specify for the fields for rootFacet!");var n=[],a={type:this.cfg.type,data:t,region:null,rowValuesLength:this.getRows(),columnValuesLength:1,rowIndex:0,columnIndex:0,rowField:"",columnField:"",rowValue:"",columnValue:""};return n.push(a),a.children=this.getChildFacets(t,1,n),this.setRegion(n),n},r.prototype.setRegion=function(t){var i=this;this.forceColIndex(t),t.forEach(function(n){n.region=i.getRegion(n.rowValuesLength,n.columnValuesLength,n.columnIndex,n.rowIndex)})},r.prototype.getRegion=function(t,i,n,a){var o=1/i,l=1/t,s={x:o*n,y:l*a},u={x:s.x+o,y:s.y+l*2/3};return{start:s,end:u}},r.prototype.forceColIndex=function(t){var i=this,n=[],a=0;t.forEach(function(h){i.isLeaf(h)&&(n.push(h),h.columnIndex=a,a++)}),n.forEach(function(h){h.columnValuesLength=n.length});for(var o=this.cfg.fields.length,l=o-1;l>=0;l--)for(var s=this.getFacetsByLevel(t,l),u=0,c=s;u<c.length;u++){var f=c[u];this.isLeaf(f)||(f.originColIndex=f.columnIndex,f.columnIndex=this.getRegionIndex(f.children),f.columnValuesLength=n.length)}},r.prototype.getFacetsByLevel=function(t,i){var n=[];return t.forEach(function(a){a.rowIndex===i&&n.push(a)}),n},r.prototype.getRegionIndex=function(t){var i=t[0],n=t[t.length-1];return(n.columnIndex-i.columnIndex)/2+i.columnIndex},r.prototype.isLeaf=function(t){return!t.children||!t.children.length},r.prototype.getRows=function(){return this.cfg.fields.length+1},r.prototype.getChildFacets=function(t,i,n){var a=this,o=this.cfg.fields,l=o.length;if(!(l<i)){var s=[],u=o[i-1],c=this.getFieldValues(t,u);return c.forEach(function(f,h){var v=[{field:u,value:f,values:c}],d=t.filter(a.getFacetDataFilter(v));if(d.length){var p={type:a.cfg.type,data:d,region:null,columnValue:f,rowValue:"",columnField:u,rowField:"",columnIndex:h,rowValuesLength:a.getRows(),columnValuesLength:1,rowIndex:i,children:a.getChildFacets(d,i+1,n)};s.push(p),n.push(p)}}),s}},r.prototype.render=function(){e.prototype.render.call(this),this.cfg.showTitle&&this.renderTitle()},r.prototype.renderTitle=function(){var t=this;(0,Tv.each)(this.facets,function(i){var n=i.columnValue,a=i.view,o=(0,Tv.get)(t.cfg.title,"formatter"),l=(0,Tv.deepMix)({position:["50%","0%"],content:o?o(n):n},(0,Ept.getFactTitleConfig)(Wk.DIRECTION.TOP),t.cfg.title);a.annotation().text(l)})},r.prototype.drawLines=function(t){var i=this;t.forEach(function(n){if(!i.isLeaf(n)){var a=n.children;i.addFacetLines(n,a)}})},r.prototype.addFacetLines=function(t,i){var n=this,a=t.view,o=a.coordinateBBox,l={x:o.x+o.width/2,y:o.y+o.height};i.forEach(function(s){var u=s.view.coordinateBBox,c={x:u.bl.x+(u.tr.x-u.bl.x)/2,y:u.tr.y},f={x:l.x,y:l.y+(c.y-l.y)/2},h={x:c.x,y:f.y};n.drawLine([l,f,h,c])})},r.prototype.getPath=function(t){var i=[],n=this.cfg.line.smooth;return n?(i.push(["M",t[0].x,t[0].y]),i.push(["C",t[1].x,t[1].y,t[2].x,t[2].y,t[3].x,t[3].y])):t.forEach(function(a,o){o===0?i.push(["M",a.x,a.y]):i.push(["L",a.x,a.y])}),i},r.prototype.drawLine=function(t){var i=this.getPath(t),n=this.cfg.line.style;this.container.addShape("path",{attrs:(0,Tv.assign)({path:i},n)})},r.prototype.getXAxisOption=function(t,i,n,a){return a.rowIndex!==a.rowValuesLength-1?(0,Av.__assign)((0,Av.__assign)({},n),{title:null,label:null}):n},r.prototype.getYAxisOption=function(t,i,n,a){return a.originColIndex!==0&&a.columnIndex!==0?(0,Av.__assign)((0,Av.__assign)({},n),{title:null,label:null}):n},r}(Fpt.Facet),Ppt=CF.default=Opt,SF={},no={};Object.defineProperty(no,"__esModule",{value:!0});no.showGrid=no.getCircleGridItems=no.getLineGridItems=no.getGridThemeCfg=void 0;var Eu=Y;function Ipt(e,r){var t=(0,Eu.deepMix)({},(0,Eu.get)(e,["components","axis","common"]),(0,Eu.get)(e,["components","axis",r]));return(0,Eu.get)(t,["grid"],{})}no.getGridThemeCfg=Ipt;function Lpt(e,r,t,i){var n=[],a=r.getTicks();return e.isPolar&&a.push({value:1,text:"",tickValue:""}),a.reduce(function(o,l,s){var u=l.value;if(i)n.push({points:[e.convert(t==="y"?{x:0,y:u}:{x:u,y:0}),e.convert(t==="y"?{x:1,y:u}:{x:u,y:1})]});else if(s){var c=o.value,f=(c+u)/2;n.push({points:[e.convert(t==="y"?{x:0,y:f}:{x:f,y:0}),e.convert(t==="y"?{x:1,y:f}:{x:f,y:1})]})}return l},a[0]),n}no.getLineGridItems=Lpt;function Dpt(e,r,t,i,n){var a=r.values.length,o=[],l=t.getTicks();return l.reduce(function(s,u){var c=s?s.value:u.value,f=u.value,h=(c+f)/2;return n==="x"?o.push({points:[e.convert({x:i?f:h,y:0}),e.convert({x:i?f:h,y:1})]}):o.push({points:(0,Eu.map)(Array(a+1),function(v,d){return e.convert({x:d/a,y:i?f:h})})}),u},l[0]),o}no.getCircleGridItems=Dpt;function $pt(e,r){var t=(0,Eu.get)(r,"grid");if(t===null)return!1;var i=(0,Eu.get)(e,"grid");return!(t===void 0&&i===null)}no.showGrid=$pt;Object.defineProperty(SF,"__esModule",{value:!0});var bu=V,De=Y,ne=Jt,Em=Qn,kpt=cl,dr=Oe,Xk=Oe,ua=no,Fl=mr,Rpt=mo,Ol=["container"],Uk=(0,bu.__assign)((0,bu.__assign)({},kpt.DEFAULT_ANIMATE_CFG),{appear:null}),Bpt=function(e){(0,bu.__extends)(r,e);function r(t){var i=e.call(this,t)||this;return i.cache=new Map,i.gridContainer=i.view.getLayer(ne.LAYER.BG).addGroup(),i.gridForeContainer=i.view.getLayer(ne.LAYER.FORE).addGroup(),i.axisContainer=i.view.getLayer(ne.LAYER.BG).addGroup(),i.axisForeContainer=i.view.getLayer(ne.LAYER.FORE).addGroup(),i}return Object.defineProperty(r.prototype,"name",{get:function(){return"axis"},enumerable:!1,configurable:!0}),r.prototype.init=function(){},r.prototype.render=function(){this.update()},r.prototype.layout=function(){var t=this,i=this.view.getCoordinate();(0,De.each)(this.getComponents(),function(n){var a=n.component,o=n.direction,l=n.type,s=n.extra,u=s.dim,c=s.scale,f=s.alignTick,h;if(l===ne.COMPONENT_TYPE.AXIS)i.isPolar?u==="x"?h=i.isTransposed?(0,dr.getAxisRegion)(i,o):(0,dr.getCircleAxisCenterRadius)(i):u==="y"&&(h=i.isTransposed?(0,dr.getCircleAxisCenterRadius)(i):(0,dr.getAxisRegion)(i,o)):h=(0,dr.getAxisRegion)(i,o);else if(l===ne.COMPONENT_TYPE.GRID)if(i.isPolar){var v=void 0;i.isTransposed?v=u==="x"?(0,ua.getCircleGridItems)(i,t.view.getYScales()[0],c,f,u):(0,ua.getLineGridItems)(i,c,u,f):v=u==="x"?(0,ua.getLineGridItems)(i,c,u,f):(0,ua.getCircleGridItems)(i,t.view.getXScale(),c,f,u),h={items:v,center:t.view.getCoordinate().getCenter()}}else h={items:(0,ua.getLineGridItems)(i,c,u,f)};a.update(h)})},r.prototype.update=function(){this.option=this.view.getOptions().axes;var t=new Map;this.updateXAxes(t),this.updateYAxes(t);var i=new Map;this.cache.forEach(function(n,a){t.has(a)?i.set(a,n):n.component.destroy()}),this.cache=i},r.prototype.clear=function(){e.prototype.clear.call(this),this.cache.clear(),this.gridContainer.clear(),this.gridForeContainer.clear(),this.axisContainer.clear(),this.axisForeContainer.clear()},r.prototype.destroy=function(){e.prototype.destroy.call(this),this.gridContainer.remove(!0),this.gridForeContainer.remove(!0),this.axisContainer.remove(!0),this.axisForeContainer.remove(!0)},r.prototype.getComponents=function(){var t=[];return this.cache.forEach(function(i){t.push(i)}),t},r.prototype.updateXAxes=function(t){var i=this.view.getXScale();if(!(!i||i.isIdentity)){var n=(0,Xk.getAxisOption)(this.option,i.field);if(n!==!1){var a=(0,dr.getAxisDirection)(n,ne.DIRECTION.BOTTOM),o=ne.LAYER.BG,l="x",s=this.view.getCoordinate(),u=this.getId("axis",i.field),c=this.getId("grid",i.field);if(s.isRect){var f=this.cache.get(u);if(f){var h=this.getLineAxisCfg(i,n,a);(0,Fl.omit)(h,Ol),f.component.update(h),t.set(u,f)}else f=this.createLineAxis(i,n,o,a,l),this.cache.set(u,f),t.set(u,f);var v=this.cache.get(c);if(v){var h=this.getLineGridCfg(i,n,a,l);(0,Fl.omit)(h,Ol),v.component.update(h),t.set(c,v)}else v=this.createLineGrid(i,n,o,a,l),v&&(this.cache.set(c,v),t.set(c,v))}else if(s.isPolar){var f=this.cache.get(u);if(f){var h=s.isTransposed?this.getLineAxisCfg(i,n,ne.DIRECTION.RADIUS):this.getCircleAxisCfg(i,n,a);(0,Fl.omit)(h,Ol),f.component.update(h),t.set(u,f)}else{if(s.isTransposed){if((0,De.isUndefined)(n))return;f=this.createLineAxis(i,n,o,ne.DIRECTION.RADIUS,l)}else f=this.createCircleAxis(i,n,o,a,l);this.cache.set(u,f),t.set(u,f)}var v=this.cache.get(c);if(v){var h=s.isTransposed?this.getCircleGridCfg(i,n,ne.DIRECTION.RADIUS,l):this.getLineGridCfg(i,n,ne.DIRECTION.CIRCLE,l);(0,Fl.omit)(h,Ol),v.component.update(h),t.set(c,v)}else{if(s.isTransposed){if((0,De.isUndefined)(n))return;v=this.createCircleGrid(i,n,o,ne.DIRECTION.RADIUS,l)}else v=this.createLineGrid(i,n,o,ne.DIRECTION.CIRCLE,l);v&&(this.cache.set(c,v),t.set(c,v))}}}}},r.prototype.updateYAxes=function(t){var i=this,n=this.view.getYScales();(0,De.each)(n,function(a,o){if(!(!a||a.isIdentity)){var l=a.field,s=(0,Xk.getAxisOption)(i.option,l);if(s!==!1){var u=ne.LAYER.BG,c="y",f=i.getId("axis",l),h=i.getId("grid",l),v=i.view.getCoordinate();if(v.isRect){var d=(0,dr.getAxisDirection)(s,o===0?ne.DIRECTION.LEFT:ne.DIRECTION.RIGHT),p=i.cache.get(f);if(p){var x=i.getLineAxisCfg(a,s,d);(0,Fl.omit)(x,Ol),p.component.update(x),t.set(f,p)}else p=i.createLineAxis(a,s,u,d,c),i.cache.set(f,p),t.set(f,p);var m=i.cache.get(h);if(m){var x=i.getLineGridCfg(a,s,d,c);(0,Fl.omit)(x,Ol),m.component.update(x),t.set(h,m)}else m=i.createLineGrid(a,s,u,d,c),m&&(i.cache.set(h,m),t.set(h,m))}else if(v.isPolar){var p=i.cache.get(f);if(p){var x=v.isTransposed?i.getCircleAxisCfg(a,s,ne.DIRECTION.CIRCLE):i.getLineAxisCfg(a,s,ne.DIRECTION.RADIUS);(0,Fl.omit)(x,Ol),p.component.update(x),t.set(f,p)}else{if(v.isTransposed){if((0,De.isUndefined)(s))return;p=i.createCircleAxis(a,s,u,ne.DIRECTION.CIRCLE,c)}else p=i.createLineAxis(a,s,u,ne.DIRECTION.RADIUS,c);i.cache.set(f,p),t.set(f,p)}var m=i.cache.get(h);if(m){var x=v.isTransposed?i.getLineGridCfg(a,s,ne.DIRECTION.CIRCLE,c):i.getCircleGridCfg(a,s,ne.DIRECTION.RADIUS,c);(0,Fl.omit)(x,Ol),m.component.update(x),t.set(h,m)}else{if(v.isTransposed){if((0,De.isUndefined)(s))return;m=i.createLineGrid(a,s,u,ne.DIRECTION.CIRCLE,c)}else m=i.createCircleGrid(a,s,u,ne.DIRECTION.RADIUS,c);m&&(i.cache.set(h,m),t.set(h,m))}}}}})},r.prototype.createLineAxis=function(t,i,n,a,o){var l={component:new Em.LineAxis(this.getLineAxisCfg(t,i,a)),layer:n,direction:a===ne.DIRECTION.RADIUS?ne.DIRECTION.NONE:a,type:ne.COMPONENT_TYPE.AXIS,extra:{dim:o,scale:t}};return l.component.set("field",t.field),l.component.init(),l},r.prototype.createLineGrid=function(t,i,n,a,o){var l=this.getLineGridCfg(t,i,a,o);if(l){var s={component:new Em.LineGrid(l),layer:n,direction:ne.DIRECTION.NONE,type:ne.COMPONENT_TYPE.GRID,extra:{dim:o,scale:t,alignTick:(0,De.get)(l,"alignTick",!0)}};return s.component.init(),s}},r.prototype.createCircleAxis=function(t,i,n,a,o){var l={component:new Em.CircleAxis(this.getCircleAxisCfg(t,i,a)),layer:n,direction:a,type:ne.COMPONENT_TYPE.AXIS,extra:{dim:o,scale:t}};return l.component.set("field",t.field),l.component.init(),l},r.prototype.createCircleGrid=function(t,i,n,a,o){var l=this.getCircleGridCfg(t,i,a,o);if(l){var s={component:new Em.CircleGrid(l),layer:n,direction:ne.DIRECTION.NONE,type:ne.COMPONENT_TYPE.GRID,extra:{dim:o,scale:t,alignTick:(0,De.get)(l,"alignTick",!0)}};return s.component.init(),s}},r.prototype.getLineAxisCfg=function(t,i,n){var a=(0,De.get)(i,["top"])?this.axisForeContainer:this.axisContainer,o=this.view.getCoordinate(),l=(0,dr.getAxisRegion)(o,n),s=(0,dr.getAxisTitleText)(t,i),u=(0,dr.getAxisThemeCfg)(this.view.getTheme(),n),c=(0,De.get)(i,["title"])?(0,De.deepMix)({title:{style:{text:s}}},{title:(0,dr.getAxisTitleOptions)(this.view.getTheme(),n,i.title)},i):i,f=(0,De.deepMix)((0,bu.__assign)((0,bu.__assign)({container:a},l),{ticks:t.getTicks().map(function(b){return{id:""+b.tickValue,name:b.text,value:b.value}}),verticalFactor:o.isPolar?(0,dr.getAxisFactorByRegion)(l,o.getCenter())*-1:(0,dr.getAxisFactorByRegion)(l,o.getCenter()),theme:u}),u,c),h=this.getAnimateCfg(f),v=h.animate,d=h.animateOption;f.animateOption=d,f.animate=v;var p=(0,dr.isVertical)(l),x=(0,De.get)(f,"verticalLimitLength",p?1/3:1/2);if(x<=1){var m=this.view.getCanvas().get("width"),_=this.view.getCanvas().get("height");f.verticalLimitLength=x*(p?m:_)}return f},r.prototype.getLineGridCfg=function(t,i,n,a){if(!!(0,ua.showGrid)((0,dr.getAxisThemeCfg)(this.view.getTheme(),n),i)){var o=(0,ua.getGridThemeCfg)(this.view.getTheme(),n),l=(0,De.deepMix)({container:(0,De.get)(i,["top"])?this.gridForeContainer:this.gridContainer},o,(0,De.get)(i,"grid"),this.getAnimateCfg(i));return l.items=(0,ua.getLineGridItems)(this.view.getCoordinate(),t,a,(0,De.get)(l,"alignTick",!0)),l}},r.prototype.getCircleAxisCfg=function(t,i,n){var a=(0,De.get)(i,["top"])?this.axisForeContainer:this.axisContainer,o=this.view.getCoordinate(),l=t.getTicks().map(function(p){return{id:""+p.tickValue,name:p.text,value:p.value}});!t.isCategory&&Math.abs(o.endAngle-o.startAngle)===Math.PI*2&&l.pop();var s=(0,dr.getAxisTitleText)(t,i),u=(0,dr.getAxisThemeCfg)(this.view.getTheme(),ne.DIRECTION.CIRCLE),c=(0,De.get)(i,["title"])?(0,De.deepMix)({title:{style:{text:s}}},{title:(0,dr.getAxisTitleOptions)(this.view.getTheme(),n,i.title)},i):i,f=(0,De.deepMix)((0,bu.__assign)((0,bu.__assign)({container:a},(0,dr.getCircleAxisCenterRadius)(this.view.getCoordinate())),{ticks:l,verticalFactor:1,theme:u}),u,c),h=this.getAnimateCfg(f),v=h.animate,d=h.animateOption;return f.animate=v,f.animateOption=d,f},r.prototype.getCircleGridCfg=function(t,i,n,a){if(!!(0,ua.showGrid)((0,dr.getAxisThemeCfg)(this.view.getTheme(),n),i)){var o=(0,ua.getGridThemeCfg)(this.view.getTheme(),ne.DIRECTION.RADIUS),l=(0,De.deepMix)({container:(0,De.get)(i,["top"])?this.gridForeContainer:this.gridContainer,center:this.view.getCoordinate().getCenter()},o,(0,De.get)(i,"grid"),this.getAnimateCfg(i)),s=(0,De.get)(l,"alignTick",!0),u=a==="x"?this.view.getYScales()[0]:this.view.getXScale();return l.items=(0,ua.getCircleGridItems)(this.view.getCoordinate(),u,t,s,a),l}},r.prototype.getId=function(t,i){var n=this.view.getCoordinate();return t+"-"+i+"-"+n.type},r.prototype.getAnimateCfg=function(t){return{animate:this.view.getOptions().animate&&(0,De.get)(t,"animate"),animateOption:t&&t.animateOption?(0,De.deepMix)({},Uk,t.animateOption):Uk}},r}(Rpt.Controller),Npt=SF.default=Bpt,AF={},ys={};Object.defineProperty(ys,"__esModule",{value:!0});ys.getTranslateDirection=ys.directionToPosition=void 0;var Pe=Jt;function Gpt(e,r,t){return t===Pe.DIRECTION.TOP?[e.minX+e.width/2-r.width/2,e.minY]:t===Pe.DIRECTION.BOTTOM?[e.minX+e.width/2-r.width/2,e.maxY-r.height]:t===Pe.DIRECTION.LEFT?[e.minX,e.minY+e.height/2-r.height/2]:t===Pe.DIRECTION.RIGHT?[e.maxX-r.width,e.minY+e.height/2-r.height/2]:t===Pe.DIRECTION.TOP_LEFT||t===Pe.DIRECTION.LEFT_TOP?[e.tl.x,e.tl.y]:t===Pe.DIRECTION.TOP_RIGHT||t===Pe.DIRECTION.RIGHT_TOP?[e.tr.x-r.width,e.tr.y]:t===Pe.DIRECTION.BOTTOM_LEFT||t===Pe.DIRECTION.LEFT_BOTTOM?[e.bl.x,e.bl.y-r.height]:t===Pe.DIRECTION.BOTTOM_RIGHT||t===Pe.DIRECTION.RIGHT_BOTTOM?[e.br.x-r.width,e.br.y-r.height]:[0,0]}ys.directionToPosition=Gpt;function zpt(e,r){if(r.isTransposed)switch(e){case Pe.DIRECTION.BOTTOM:return Pe.DIRECTION.LEFT;case Pe.DIRECTION.LEFT:return Pe.DIRECTION.BOTTOM;case Pe.DIRECTION.RIGHT:return Pe.DIRECTION.TOP;case Pe.DIRECTION.TOP:return Pe.DIRECTION.RIGHT}return e}function vH(e){return e===Pe.DIRECTION.LEFT?Pe.DIRECTION.RIGHT:e===Pe.DIRECTION.RIGHT?Pe.DIRECTION.LEFT:e}function dH(e){return e===Pe.DIRECTION.TOP?Pe.DIRECTION.BOTTOM:e===Pe.DIRECTION.BOTTOM?Pe.DIRECTION.TOP:e}function Vpt(e,r){var t=r.matrix[0],i=r.matrix[4],n=e;return t<0&&(n=vH(n)),i<0&&(n=dH(n)),n}function jpt(e,r){var t=e;return r.isReflect("x")&&(t=vH(t)),r.isReflect("y")&&(t=dH(t)),t}function Hpt(e,r){var t=e;return t=zpt(t,r),t=Vpt(t,r),t=jpt(t,r),t}ys.getTranslateDirection=Hpt;Object.defineProperty(AF,"__esModule",{value:!0});var Ypt=V,_e=Y,Bo=Jt,iS=Qn,qk=cl,Wpt=ti,Zk=ys,nS=mr,nu=_a,Qk=Zr,Xpt=mo;function Kk(e,r){return(0,_e.isBoolean)(e)?e===!1?!1:{}:(0,_e.get)(e,[r],e)}function Fm(e){return(0,_e.get)(e,"position",Bo.DIRECTION.BOTTOM)}var Upt=function(e){(0,Ypt.__extends)(r,e);function r(t){var i=e.call(this,t)||this;return i.container=i.view.getLayer(Bo.LAYER.FORE).addGroup(),i}return Object.defineProperty(r.prototype,"name",{get:function(){return"legend"},enumerable:!1,configurable:!0}),r.prototype.init=function(){},r.prototype.render=function(){this.update()},r.prototype.layout=function(){var t=this;this.layoutBBox=this.view.viewBBox,(0,_e.each)(this.components,function(i){var n=i.component,a=i.direction,o=(0,nu.getLegendLayout)(a),l=n.get("maxWidthRatio"),s=n.get("maxHeightRatio"),u=t.getCategoryLegendSizeCfg(o,l,s),c=n.get("maxWidth"),f=n.get("maxHeight");n.update({maxWidth:Math.min(u.maxWidth,c||0),maxHeight:Math.min(u.maxHeight,f||0)});var h=n.get("padding"),v=n.getLayoutBBox(),d=new Wpt.BBox(v.x,v.y,v.width,v.height).expand(h),p=(0,Zk.directionToPosition)(t.view.viewBBox,d,a),x=p[0],m=p[1],_=(0,Zk.directionToPosition)(t.layoutBBox,d,a),b=_[0],w=_[1],S=0,M=0;a.startsWith("top")||a.startsWith("bottom")?(S=x,M=w):(S=b,M=m),n.setLocation({x:S+h[3],y:M+h[0]}),t.layoutBBox=t.layoutBBox.cut(d,a)})},r.prototype.update=function(){var t=this;this.option=this.view.getOptions().legends;var i={},n=function(h,v,d){var p=t.getId(d.field),x=t.getComponentById(p);if(x){var m=void 0,_=Kk(t.option,d.field);_!==!1&&((0,_e.get)(_,"custom")?m=t.getCategoryCfg(h,v,d,_,!0):d.isLinear?m=t.getContinuousCfg(h,v,d,_):d.isCategory&&(m=t.getCategoryCfg(h,v,d,_))),m&&((0,nS.omit)(m,["container"]),x.direction=Fm(_),x.component.update(m),i[p]=!0)}else{var b=t.createFieldLegend(h,v,d);b&&(b.component.init(),t.components.push(b),i[p]=!0)}};if((0,_e.get)(this.option,"custom")){var a="global-custom",o=this.getComponentById(a);if(o){var l=this.getCategoryCfg(void 0,void 0,void 0,this.option,!0);(0,nS.omit)(l,["container"]),o.component.update(l),i[a]=!0}else{var s=this.createCustomLegend(void 0,void 0,void 0,this.option);if(s){s.init();var u=Bo.LAYER.FORE,c=Fm(this.option);this.components.push({id:a,component:s,layer:u,direction:c,type:Bo.COMPONENT_TYPE.LEGEND,extra:void 0}),i[a]=!0}}}else this.loopLegends(n);var f=[];(0,_e.each)(this.getComponents(),function(h){i[h.id]?f.push(h):h.component.destroy()}),this.components=f},r.prototype.clear=function(){e.prototype.clear.call(this),this.container.clear()},r.prototype.destroy=function(){e.prototype.destroy.call(this),this.container.remove(!0)},r.prototype.getGeometries=function(t){var i=this,n=t.geometries;return(0,_e.each)(t.views,function(a){n=n.concat(i.getGeometries(a))}),n},r.prototype.loopLegends=function(t){var i=this.view.getRootView()===this.view;if(!!i){var n=this.getGeometries(this.view),a={};(0,_e.each)(n,function(o){var l=o.getGroupAttributes();(0,_e.each)(l,function(s){var u=s.getScale(s.type);!u||u.type==="identity"||a[u.field]||(t(o,s,u),a[u.field]=!0)})})}},r.prototype.createFieldLegend=function(t,i,n){var a,o=Kk(this.option,n.field),l=Bo.LAYER.FORE,s=Fm(o);if(o!==!1&&((0,_e.get)(o,"custom")?a=this.createCustomLegend(t,i,n,o):n.isLinear?a=this.createContinuousLegend(t,i,n,o):n.isCategory&&(a=this.createCategoryLegend(t,i,n,o))),a)return a.set("field",n.field),{id:this.getId(n.field),component:a,layer:l,direction:s,type:Bo.COMPONENT_TYPE.LEGEND,extra:{scale:n}}},r.prototype.createCustomLegend=function(t,i,n,a){var o=this.getCategoryCfg(t,i,n,a,!0);return new iS.CategoryLegend(o)},r.prototype.createContinuousLegend=function(t,i,n,a){var o=this.getContinuousCfg(t,i,n,(0,nS.omit)(a,["value"]));return new iS.ContinuousLegend(o)},r.prototype.createCategoryLegend=function(t,i,n,a){var o=this.getCategoryCfg(t,i,n,a);return new iS.CategoryLegend(o)},r.prototype.getContinuousCfg=function(t,i,n,a){var o=n.getTicks(),l=(0,_e.find)(o,function(p){return p.value===0}),s=(0,_e.find)(o,function(p){return p.value===1}),u=o.map(function(p){var x=p.value,m=p.tickValue,_=i.mapping(n.invert(x)).join("");return{value:m,attrValue:_,color:_,scaleValue:x}});l||u.push({value:n.min,attrValue:i.mapping(n.invert(0)).join(""),color:i.mapping(n.invert(0)).join(""),scaleValue:0}),s||u.push({value:n.max,attrValue:i.mapping(n.invert(1)).join(""),color:i.mapping(n.invert(1)).join(""),scaleValue:1}),u.sort(function(p,x){return p.value-x.value});var c={min:(0,_e.head)(u).value,max:(0,_e.last)(u).value,colors:[],rail:{type:i.type},track:{}};i.type==="size"&&(c.track={style:{fill:i.type==="size"?this.view.getTheme().defaultColor:void 0}}),i.type==="color"&&(c.colors=u.map(function(p){return p.attrValue}));var f=this.container,h=Fm(a),v=(0,nu.getLegendLayout)(h),d=(0,_e.get)(a,"title");return d&&(d=(0,_e.deepMix)({text:(0,Qk.getName)(n)},d)),c.container=f,c.layout=v,c.title=d,c.animateOption=qk.DEFAULT_ANIMATE_CFG,this.mergeLegendCfg(c,a,"continuous")},r.prototype.getCategoryCfg=function(t,i,n,a,o){var l=this.container,s=(0,_e.get)(a,"position",Bo.DIRECTION.BOTTOM),u=(0,nu.getLegendThemeCfg)(this.view.getTheme(),s),c=(0,_e.get)(u,["marker"]),f=(0,_e.get)(a,"marker"),h=(0,nu.getLegendLayout)(s),v=(0,_e.get)(u,["pageNavigator"]),d=(0,_e.get)(a,"pageNavigator"),p=o?(0,nu.getCustomLegendItems)(c,f,a.items):(0,nu.getLegendItems)(this.view,t,i,c,f),x=(0,_e.get)(a,"title");x&&(x=(0,_e.deepMix)({text:n?(0,Qk.getName)(n):""},x));var m=(0,_e.get)(a,"maxWidthRatio"),_=(0,_e.get)(a,"maxHeightRatio"),b=this.getCategoryLegendSizeCfg(h,m,_);b.container=l,b.layout=h,b.items=p,b.title=x,b.animateOption=qk.DEFAULT_ANIMATE_CFG,b.pageNavigator=(0,_e.deepMix)({},v,d);var w=this.mergeLegendCfg(b,a,s);w.reversed&&w.items.reverse();var S=(0,_e.get)(w,"maxItemWidth");return S&&S<=1&&(w.maxItemWidth=this.view.viewBBox.width*S),w},r.prototype.mergeLegendCfg=function(t,i,n){var a=n.split("-")[0],o=(0,nu.getLegendThemeCfg)(this.view.getTheme(),a);return(0,_e.deepMix)({},o,t,i)},r.prototype.getId=function(t){return this.name+"-"+t},r.prototype.getComponentById=function(t){return(0,_e.find)(this.components,function(i){return i.id===t})},r.prototype.getCategoryLegendSizeCfg=function(t,i,n){i===void 0&&(i=Bo.COMPONENT_MAX_VIEW_PERCENTAGE),n===void 0&&(n=Bo.COMPONENT_MAX_VIEW_PERCENTAGE);var a=this.view.viewBBox,o=a.width,l=a.height;return t==="vertical"?{maxWidth:o*i,maxHeight:l}:{maxWidth:o,maxHeight:l*n}},r}(Xpt.Controller),qpt=AF.default=Upt,TF={};Object.defineProperty(TF,"__esModule",{value:!0});var $o=V,er=Y,ca=Jt,Zpt=Qn,Qpt=ti,Jk=ys,Kpt=mr,Jpt=mo,tgt=function(e){(0,$o.__extends)(r,e);function r(t){var i=e.call(this,t)||this;return i.onChangeFn=er.noop,i.resetMeasure=function(){i.clear()},i.onValueChange=function(n){var a=n[0],o=n[1];i.start=a,i.end=o,i.changeViewData(a,o)},i.container=i.view.getLayer(ca.LAYER.FORE).addGroup(),i.onChangeFn=(0,er.throttle)(i.onValueChange,20,{leading:!0}),i.width=0,i.view.on(ca.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_DATA,i.resetMeasure),i.view.on(ca.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_SIZE,i.resetMeasure),i}return Object.defineProperty(r.prototype,"name",{get:function(){return"slider"},enumerable:!1,configurable:!0}),r.prototype.destroy=function(){e.prototype.destroy.call(this),this.view.off(ca.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_DATA,this.resetMeasure),this.view.off(ca.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_SIZE,this.resetMeasure)},r.prototype.init=function(){},r.prototype.render=function(){this.option=this.view.getOptions().slider;var t=this.getSliderCfg(),i=t.start,n=t.end;(0,er.isNil)(this.start)&&(this.start=i,this.end=n);var a=this.view.getOptions().data;this.option&&!(0,er.isEmpty)(a)?this.slider?this.slider=this.updateSlider():(this.slider=this.createSlider(),this.slider.component.on("sliderchange",this.onChangeFn)):this.slider&&(this.slider.component.destroy(),this.slider=void 0)},r.prototype.layout=function(){var t=this;if(this.option&&!this.width&&(this.measureSlider(),setTimeout(function(){t.view.destroyed||t.changeViewData(t.start,t.end)},0)),this.slider){var i=this.view.coordinateBBox.width,n=this.slider.component.get("padding"),a=n[0];n[1],n[2];var o=n[3],l=this.slider.component.getLayoutBBox(),s=new Qpt.BBox(l.x,l.y,Math.min(l.width,i),l.height).expand(n),u=this.getMinMaxText(this.start,this.end),c=u.minText,f=u.maxText,h=(0,Jk.directionToPosition)(this.view.viewBBox,s,ca.DIRECTION.BOTTOM);h[0];var v=h[1],d=(0,Jk.directionToPosition)(this.view.coordinateBBox,s,ca.DIRECTION.BOTTOM),p=d[0];d[1],this.slider.component.update((0,$o.__assign)((0,$o.__assign)({},this.getSliderCfg()),{x:p+o,y:v+a,width:this.width,start:this.start,end:this.end,minText:c,maxText:f})),this.view.viewBBox=this.view.viewBBox.cut(s,ca.DIRECTION.BOTTOM)}},r.prototype.update=function(){this.render()},r.prototype.createSlider=function(){var t=this.getSliderCfg(),i=new Zpt.Slider((0,$o.__assign)({container:this.container},t));return i.init(),{component:i,layer:ca.LAYER.FORE,direction:ca.DIRECTION.BOTTOM,type:ca.COMPONENT_TYPE.SLIDER}},r.prototype.updateSlider=function(){var t=this.getSliderCfg();if(this.width){var i=this.getMinMaxText(this.start,this.end),n=i.minText,a=i.maxText;t=(0,$o.__assign)((0,$o.__assign)({},t),{width:this.width,start:this.start,end:this.end,minText:n,maxText:a})}return this.slider.component.update(t),this.slider},r.prototype.measureSlider=function(){var t=this.getSliderCfg().width;this.width=t},r.prototype.getSliderCfg=function(){var t={height:16,start:0,end:1,minText:"",maxText:"",x:0,y:0,width:this.view.coordinateBBox.width};if((0,er.isObject)(this.option)){var i=(0,$o.__assign)({data:this.getData()},(0,er.get)(this.option,"trendCfg",{}));t=(0,er.deepMix)({},t,this.getThemeOptions(),this.option),t=(0,$o.__assign)((0,$o.__assign)({},t),{trendCfg:i})}return t.start=(0,er.clamp)(Math.min((0,er.isNil)(t.start)?0:t.start,(0,er.isNil)(t.end)?1:t.end),0,1),t.end=(0,er.clamp)(Math.max((0,er.isNil)(t.start)?0:t.start,(0,er.isNil)(t.end)?1:t.end),0,1),t},r.prototype.getData=function(){var t=this.view.getOptions().data,i=this.view.getYScales()[0],n=this.view.getGroupScales();if(n.length){var a=n[0],o=a.field,l=a.ticks;return t.reduce(function(s,u){return u[o]===l[0]&&s.push(u[i.field]),s},[])}return t.map(function(s){return s[i.field]||0})},r.prototype.getThemeOptions=function(){var t=this.view.getTheme();return(0,er.get)(t,["components","slider","common"],{})},r.prototype.getMinMaxText=function(t,i){var n=this.view.getOptions().data,a=this.view.getXScale(),o=(0,er.valuesOfKey)(n,a.field),l=o,s=(0,er.size)(n);if(!a||!s)return{};var u=(0,er.size)(l),c=Math.floor(t*(u-1)),f=Math.floor(i*(u-1)),h=(0,er.get)(l,[c]),v=(0,er.get)(l,[f]),d=this.getSliderCfg().formatter;return d&&(h=d(h,n[c],c),v=d(v,n[f],f)),{minText:h,maxText:v}},r.prototype.changeViewData=function(t,i){var n=this.view.getOptions().data,a=this.view.getXScale(),o=(0,er.size)(n);if(!(!a||!o)){var l=(0,er.valuesOfKey)(n,a.field),s=l,u=(0,er.size)(s),c=Math.floor(t*(u-1)),f=Math.floor(i*(u-1));this.view.filter(a.field,function(h,v){var d=s.indexOf(h);return d>-1?(0,Kpt.isBetween)(d,c,f):!0}),this.view.render(!0)}},r.prototype.getComponents=function(){return this.slider?[this.slider]:[]},r.prototype.clear=function(){this.slider&&(this.slider.component.destroy(),this.slider=void 0),this.width=0,this.start=void 0,this.end=void 0},r}(Jpt.Controller),egt=TF.default=tgt,MF={};Object.defineProperty(MF,"__esModule",{value:!0});var ui=V,rgt=mo,igt=Qn,ngt=ti,Om=ys,xi=Jt,ci=Y,agt=mr,Pm=0,tR=8,ogt=32,lgt=20,sgt=function(e){(0,ui.__extends)(r,e);function r(t){var i=e.call(this,t)||this;return i.onChangeFn=ci.noop,i.resetMeasure=function(){i.clear()},i.onValueChange=function(n){var a=n.ratio,o=i.getValidScrollbarCfg().animate;i.ratio=(0,ci.clamp)(a,0,1);var l=i.view.getOptions().animate;o||i.view.animate(!1),i.changeViewData(i.getScrollRange(),!0),i.view.animate(l)},i.container=i.view.getLayer(xi.LAYER.FORE).addGroup(),i.onChangeFn=(0,ci.throttle)(i.onValueChange,20,{leading:!0}),i.trackLen=0,i.thumbLen=0,i.ratio=0,i.view.on(xi.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_DATA,i.resetMeasure),i.view.on(xi.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_SIZE,i.resetMeasure),i}return Object.defineProperty(r.prototype,"name",{get:function(){return"scrollbar"},enumerable:!1,configurable:!0}),r.prototype.destroy=function(){e.prototype.destroy.call(this),this.view.off(xi.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_DATA,this.resetMeasure),this.view.off(xi.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_SIZE,this.resetMeasure)},r.prototype.init=function(){},r.prototype.render=function(){this.option=this.view.getOptions().scrollbar,this.option?this.scrollbar?this.scrollbar=this.updateScrollbar():(this.scrollbar=this.createScrollbar(),this.scrollbar.component.on("scrollchange",this.onChangeFn)):this.scrollbar&&(this.scrollbar.component.destroy(),this.scrollbar=void 0)},r.prototype.layout=function(){var t=this;if(this.option&&!this.trackLen&&(this.measureScrollbar(),setTimeout(function(){t.view.destroyed||t.changeViewData(t.getScrollRange(),!0)})),this.scrollbar){var i=this.view.coordinateBBox.width,n=this.scrollbar.component.get("padding"),a=this.scrollbar.component.getLayoutBBox(),o=new ngt.BBox(a.x,a.y,Math.min(a.width,i),a.height).expand(n),l=this.getScrollbarComponentCfg(),s=void 0,u=void 0;if(l.isHorizontal){var c=(0,Om.directionToPosition)(this.view.viewBBox,o,xi.DIRECTION.BOTTOM);c[0];var f=c[1],h=(0,Om.directionToPosition)(this.view.coordinateBBox,o,xi.DIRECTION.BOTTOM),v=h[0];h[1],s=v,u=f}else{var d=(0,Om.directionToPosition)(this.view.viewBBox,o,xi.DIRECTION.RIGHT);d[0];var f=d[1],p=(0,Om.directionToPosition)(this.view.viewBBox,o,xi.DIRECTION.RIGHT),v=p[0];p[1],s=v,u=f}s+=n[3],u+=n[0],this.trackLen?this.scrollbar.component.update((0,ui.__assign)((0,ui.__assign)({},l),{x:s,y:u,trackLen:this.trackLen,thumbLen:this.thumbLen,thumbOffset:(this.trackLen-this.thumbLen)*this.ratio})):this.scrollbar.component.update((0,ui.__assign)((0,ui.__assign)({},l),{x:s,y:u})),this.view.viewBBox=this.view.viewBBox.cut(o,l.isHorizontal?xi.DIRECTION.BOTTOM:xi.DIRECTION.RIGHT)}},r.prototype.update=function(){this.render()},r.prototype.getComponents=function(){return this.scrollbar?[this.scrollbar]:[]},r.prototype.clear=function(){this.scrollbar&&(this.scrollbar.component.destroy(),this.scrollbar=void 0),this.trackLen=0,this.thumbLen=0,this.ratio=0,this.cnt=0,this.step=0,this.data=void 0,this.xScaleCfg=void 0,this.yScalesCfg=[]},r.prototype.setValue=function(t){this.onValueChange({ratio:t})},r.prototype.getValue=function(){return this.ratio},r.prototype.getThemeOptions=function(){var t=this.view.getTheme();return(0,ci.get)(t,["components","scrollbar","common"],{})},r.prototype.getScrollbarTheme=function(t){var i=(0,ci.get)(this.view.getTheme(),["components","scrollbar"]),n=t||{},a=n.thumbHighlightColor,o=(0,ui.__rest)(n,["thumbHighlightColor"]);return{default:(0,ci.deepMix)({},(0,ci.get)(i,["default","style"],{}),o),hover:(0,ci.deepMix)({},(0,ci.get)(i,["hover","style"],{}),{thumbColor:a})}},r.prototype.measureScrollbar=function(){var t=this.view.getXScale(),i=this.view.getYScales().slice();this.data=this.getScrollbarData(),this.step=this.getStep(),this.cnt=this.getCnt();var n=this.getScrollbarComponentCfg(),a=n.trackLen,o=n.thumbLen;this.trackLen=a,this.thumbLen=o,this.xScaleCfg={field:t.field,values:t.values||[]},this.yScalesCfg=i},r.prototype.getScrollRange=function(){var t=Math.floor((this.cnt-this.step)*(0,ci.clamp)(this.ratio,0,1)),i=Math.min(t+this.step-1,this.cnt-1);return[t,i]},r.prototype.changeViewData=function(t,i){var n=this,a=t[0],o=t[1],l=this.getValidScrollbarCfg().type,s=l!=="vertical",u=(0,ci.valuesOfKey)(this.data,this.xScaleCfg.field),c=s?u:u.reverse();this.yScalesCfg.forEach(function(f){n.view.scale(f.field,{formatter:f.formatter,type:f.type,min:f.min,max:f.max})}),this.view.filter(this.xScaleCfg.field,function(f){var h=c.indexOf(f);return h>-1?(0,agt.isBetween)(h,a,o):!0}),this.view.render(!0)},r.prototype.createScrollbar=function(){var t=this.getValidScrollbarCfg().type,i=t!=="vertical",n=new igt.Scrollbar((0,ui.__assign)((0,ui.__assign)({container:this.container},this.getScrollbarComponentCfg()),{x:0,y:0}));return n.init(),{component:n,layer:xi.LAYER.FORE,direction:i?xi.DIRECTION.BOTTOM:xi.DIRECTION.RIGHT,type:xi.COMPONENT_TYPE.SCROLLBAR}},r.prototype.updateScrollbar=function(){var t=this.getScrollbarComponentCfg(),i=this.trackLen?(0,ui.__assign)((0,ui.__assign)({},t),{trackLen:this.trackLen,thumbLen:this.thumbLen,thumbOffset:(this.trackLen-this.thumbLen)*this.ratio}):(0,ui.__assign)({},t);return this.scrollbar.component.update(i),this.scrollbar},r.prototype.getStep=function(){if(this.step)return this.step;var t=this.view.coordinateBBox,i=this.getValidScrollbarCfg(),n=i.type,a=i.categorySize,o=n!=="vertical";return Math.floor((o?t.width:t.height)/a)},r.prototype.getCnt=function(){if(this.cnt)return this.cnt;var t=this.view.getXScale(),i=this.getScrollbarData(),n=(0,ci.valuesOfKey)(i,t.field);return(0,ci.size)(n)},r.prototype.getScrollbarComponentCfg=function(){var t=this.view,i=t.coordinateBBox,n=t.viewBBox,a=this.getValidScrollbarCfg(),o=a.type,l=a.padding,s=a.width,u=a.height,c=a.style,f=o!=="vertical",h=l[0],v=l[1],d=l[2],p=l[3],x=f?{x:i.minX+p,y:n.maxY-u-d}:{x:n.maxX-s-v,y:i.minY+h},m=this.getStep(),_=this.getCnt(),b=f?i.width-p-v:i.height-h-d,w=Math.max(b*(0,ci.clamp)(m/_,0,1),lgt);return(0,ui.__assign)((0,ui.__assign)({},this.getThemeOptions()),{x:x.x,y:x.y,size:f?u:s,isHorizontal:f,trackLen:b,thumbLen:w,thumbOffset:0,theme:this.getScrollbarTheme(c)})},r.prototype.getValidScrollbarCfg=function(){var t={type:"horizontal",categorySize:ogt,width:tR,height:tR,padding:[0,0,0,0],animate:!0,style:{}};return(0,ci.isObject)(this.option)&&(t=(0,ui.__assign)((0,ui.__assign)({},t),this.option)),(!(0,ci.isObject)(this.option)||!this.option.padding)&&(t.padding=t.type==="horizontal"?[Pm,0,Pm,0]:[0,Pm,0,Pm]),t},r.prototype.getScrollbarData=function(){var t=this.view.getCoordinate(),i=this.getValidScrollbarCfg(),n=this.view.getOptions().data||[];return t.isReflect("y")&&i.type==="vertical"&&(n=(0,ui.__spreadArray)([],n,!0).reverse()),n},r}(rgt.Controller);MF.default=sgt;var Jp={};Object.defineProperty(Jp,"__esModule",{value:!0});Jp.getItemsOfView=void 0;var w0=V,fn=Y,ugt=mn,aS=Se,cgt=(0,w0.__importDefault)(Ir),fgt={fill:"#CCD6EC",opacity:.3};function pH(e,r,t){var i=(0,ugt.findItemsFromViewRecurisive)(e,r,t);if(i.length){i=(0,fn.flatten)(i);for(var n=0,a=i;n<a.length;n++)for(var o=a[n],l=0,s=o;l<s.length;l++){var u=s[l],c=u.mappingData,f=c.x,h=c.y;u.x=(0,fn.isArray)(f)?f[f.length-1]:f,u.y=(0,fn.isArray)(h)?h[h.length-1]:h}var v=t.shared;if(v===!1&&i.length>1){for(var d=i[0],p=Math.abs(r.y-d[0].y),x=0,m=i;x<m.length;x++){var _=m[x],b=Math.abs(r.y-_[0].y);b<=p&&(d=_,p=b)}i=[d]}return(0,fn.uniq)((0,fn.flatten)(i))}return[]}Jp.getItemsOfView=pH;var hgt=function(e){(0,w0.__extends)(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.show=function(t){var i=this.context.view,n=this.context.event,a=i.getController("tooltip").getTooltipCfg(),o=pH(i,{x:n.x,y:n.y},a);if(!(0,fn.isEqual)(o,this.items)&&(this.items=o,o.length)){var l=i.getXScale().field,s=o[0].data[l],u=[],c=i.geometries;if((0,fn.each)(c,function(N){if(N.type==="interval"||N.type==="schema"){var W=N.getElementsBy(function(q){var tt=q.getData();return tt[l]===s});u=u.concat(W)}}),u.length){var f=i.getCoordinate(),h=u[0].shape.getCanvasBBox(),v=u[0].shape.getCanvasBBox(),d=h;(0,fn.each)(u,function(N){var W=N.shape.getCanvasBBox();f.isTransposed?(W.minY<h.minY&&(h=W),W.maxY>v.maxY&&(v=W)):(W.minX<h.minX&&(h=W),W.maxX>v.maxX&&(v=W)),d.x=Math.min(W.minX,d.minX),d.y=Math.min(W.minY,d.minY),d.width=Math.max(W.maxX,d.maxX)-d.x,d.height=Math.max(W.maxY,d.maxY)-d.y});var p=i.backgroundGroup,x=i.coordinateBBox,m=void 0;if(f.isRect){var _=i.getXScale(),b=t||{},w=b.appendRatio,S=b.appendWidth;(0,fn.isNil)(S)&&(w=(0,fn.isNil)(w)?_.isLinear?0:.25:w,S=f.isTransposed?w*v.height:w*h.width);var M=void 0,F=void 0,O=void 0,L=void 0;f.isTransposed?(M=x.minX,F=Math.min(v.minY,h.minY)-S,O=x.width,L=d.height+S*2):(M=Math.min(h.minX,v.minX)-S,F=x.minY,O=d.width+S*2,L=x.height),m=[["M",M,F],["L",M+O,F],["L",M+O,F+L],["L",M,F+L],["Z"]]}else{var D=(0,fn.head)(u),k=(0,fn.last)(u),H=(0,aS.getAngle)(D.getModel(),f).startAngle,B=(0,aS.getAngle)(k.getModel(),f).endAngle,j=f.getCenter(),U=f.getRadius(),R=f.innerRadius*U;m=(0,aS.getSectorPath)(j.x,j.y,U,H,B,R)}if(this.regionPath)this.regionPath.attr("path",m),this.regionPath.show();else{var G=(0,fn.get)(t,"style",fgt);this.regionPath=p.addShape({type:"path",name:"active-region",capture:!1,attrs:(0,w0.__assign)((0,w0.__assign)({},G),{path:m})})}}}},r.prototype.hide=function(){this.regionPath&&this.regionPath.hide(),this.items=null},r.prototype.destroy=function(){this.hide(),this.regionPath&&this.regionPath.remove(!0),e.prototype.destroy.call(this)},r}(cgt.default),vgt=Jp.default=hgt,EF={},f_={};Object.defineProperty(f_,"__esModule",{value:!0});var gH=V,eR=Y,dgt=(0,gH.__importDefault)(Ir),pgt=function(e){(0,gH.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.timeStamp=0,t}return r.prototype.show=function(){var t=this.context,i=t.event,n=t.view,a=n.isTooltipLocked();if(!a){var o=this.timeStamp,l=+new Date,s=(0,eR.get)(t.view.getOptions(),"tooltip.showDelay",16);if(l-o>s){var u=this.location,c={x:i.x,y:i.y};(!u||!(0,eR.isEqual)(u,c))&&this.showTooltip(n,c),this.timeStamp=l,this.location=c}}},r.prototype.hide=function(){var t=this.context.view,i=t.getController("tooltip"),n=this.context.event,a=n.clientX,o=n.clientY;i.isCursorEntered({x:a,y:o})||t.isTooltipLocked()||(this.hideTooltip(t),this.location=null)},r.prototype.showTooltip=function(t,i){t.showTooltip(i)},r.prototype.hideTooltip=function(t){t.hideTooltip()},r}(dgt.default),yH=f_.default=pgt;Object.defineProperty(EF,"__esModule",{value:!0});var mH=V,rR=Y,oS=xt,ggt=(0,mH.__importDefault)(f_),ygt=function(e){(0,mH.__extends)(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.showTooltip=function(t,i){var n=(0,oS.getSilbings)(t);(0,rR.each)(n,function(a){var o=(0,oS.getSiblingPoint)(t,a,i);a.showTooltip(o)})},r.prototype.hideTooltip=function(t){var i=(0,oS.getSilbings)(t);(0,rR.each)(i,function(n){n.hideTooltip()})},r}(ggt.default),mgt=EF.default=ygt,FF={};Object.defineProperty(FF,"__esModule",{value:!0});var C0=V,lS=Y,iR=w1,xgt=(0,C0.__importDefault)(Ir),_gt=Qn,bgt=function(e){(0,C0.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.timeStamp=0,t}return r.prototype.destroy=function(){e.prototype.destroy.call(this),this.tooltip&&this.tooltip.destroy()},r.prototype.show=function(){var t=this.context,i=t.event,n=this.timeStamp,a=+new Date;if(a-n>16){var o=this.location,l={x:i.x,y:i.y};(!o||!(0,lS.isEqual)(o,l))&&this.showTooltip(l),this.timeStamp=a,this.location=l}},r.prototype.hide=function(){this.hideTooltip(),this.location=null},r.prototype.showTooltip=function(t){var i=this.context,n=i.event,a=n.target;if(a&&a.get("tip")){this.tooltip||this.renderTooltip();var o=a.get("tip");this.tooltip.update((0,C0.__assign)({title:o},t)),this.tooltip.show()}},r.prototype.hideTooltip=function(){this.tooltip&&this.tooltip.hide()},r.prototype.renderTooltip=function(){var t,i=this.context.view,n=i.canvas,a={start:{x:0,y:0},end:{x:n.get("width"),y:n.get("height")}},o=i.getTheme(),l=(0,lS.get)(o,["components","tooltip","domStyles"],{}),s=new _gt.HtmlTooltip({parent:n.get("el").parentNode,region:a,visible:!1,crosshairs:null,domStyles:(0,C0.__assign)({},(0,lS.deepMix)({},l,(t={},t[iR.TOOLTIP_CSS_CONST.CONTAINER_CLASS]={"max-width":"50%"},t[iR.TOOLTIP_CSS_CONST.TITLE_CLASS]={"word-break":"break-all"},t)))});s.init(),s.setCapture(!1),this.tooltip=s},r}(xgt.default),wgt=FF.default=bgt,OF={},tg={},eg={};Object.defineProperty(eg,"__esModule",{value:!0});var xH=V,Cgt=Y,Sgt=(0,xH.__importDefault)(Ir),Agt=xt,Tgt=function(e){(0,xH.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="",t}return r.prototype.hasState=function(t){return t.hasState(this.stateName)},r.prototype.setElementState=function(t,i){t.setState(this.stateName,i)},r.prototype.setState=function(){this.setStateEnable(!0)},r.prototype.clear=function(){var t=this.context.view;this.clearViewState(t)},r.prototype.clearViewState=function(t){var i=this,n=(0,Agt.getElementsByState)(t,this.stateName);(0,Cgt.each)(n,function(a){i.setElementState(a,!1)})},r}(Sgt.default);eg.default=Tgt;Object.defineProperty(tg,"__esModule",{value:!0});var _H=V,uT=Y,Pl=xt,Mgt=(0,_H.__importDefault)(eg);function nR(e){return(0,uT.get)(e.get("delegateObject"),"item")}var Egt=function(e){(0,_H.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.ignoreListItemStates=["unchecked"],t}return r.prototype.isItemIgnore=function(t,i){var n=this.ignoreListItemStates,a=n.filter(function(o){return i.hasState(t,o)});return!!a.length},r.prototype.setStateByComponent=function(t,i,n){var a=this.context.view,o=t.get("field"),l=(0,Pl.getElements)(a);this.setElementsStateByItem(l,o,i,n)},r.prototype.setStateByElement=function(t,i){this.setElementState(t,i)},r.prototype.isMathItem=function(t,i,n){var a=this.context.view,o=(0,Pl.getScaleByField)(a,i),l=(0,Pl.getElementValue)(t,i);return!(0,uT.isNil)(l)&&n.name===o.getText(l)},r.prototype.setElementsStateByItem=function(t,i,n,a){var o=this;(0,uT.each)(t,function(l){o.isMathItem(l,i,n)&&l.setState(o.stateName,a)})},r.prototype.setStateEnable=function(t){var i=(0,Pl.getCurrentElement)(this.context);if(i)(0,Pl.isElementChange)(this.context)&&this.setStateByElement(i,t);else{var n=(0,Pl.getDelegationObject)(this.context);if((0,Pl.isList)(n)){var a=n.item,o=n.component;if(a&&o&&!this.isItemIgnore(a,o)){var l=this.context.event.gEvent;if(l&&l.fromShape&&l.toShape&&nR(l.fromShape)===nR(l.toShape))return;this.setStateByComponent(o,a,t)}}}},r.prototype.toggle=function(){var t=(0,Pl.getCurrentElement)(this.context);if(t){var i=t.hasState(this.stateName);this.setElementState(t,!i)}},r.prototype.reset=function(){this.setStateEnable(!1)},r}(Mgt.default);tg.default=Egt;Object.defineProperty(OF,"__esModule",{value:!0});var bH=V,Fgt=(0,bH.__importDefault)(tg),Ogt=function(e){(0,bH.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="active",t}return r.prototype.active=function(){this.setState()},r}(Fgt.default),Pgt=OF.default=Ogt,PF={};Object.defineProperty(PF,"__esModule",{value:!0});var S0=V,Igt=(0,S0.__importDefault)(Ir),Mv=xt,sS=Y,Lgt=function(e){(0,S0.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.cache={},t}return r.prototype.getColorScale=function(t,i){var n=i.geometry.getAttribute("color");if(!n)return null;var a=t.getScaleByField(n.getFields()[0]);return a},r.prototype.getLinkPath=function(t,i){var n=this.context.view,a=n.getCoordinate().isTransposed,o=t.shape.getCanvasBBox(),l=i.shape.getCanvasBBox(),s=a?[["M",o.minX,o.minY],["L",l.minX,l.maxY],["L",l.maxX,l.maxY],["L",o.maxX,o.minY],["Z"]]:[["M",o.maxX,o.minY],["L",l.minX,l.minY],["L",l.minX,l.maxY],["L",o.maxX,o.maxY],["Z"]];return s},r.prototype.addLinkShape=function(t,i,n,a){var o={opacity:.4,fill:i.shape.attr("fill")};t.addShape({type:"path",attrs:(0,S0.__assign)((0,S0.__assign)({},(0,sS.deepMix)({},o,(0,sS.isFunction)(a)?a(o,i):a)),{path:this.getLinkPath(i,n)})})},r.prototype.linkByElement=function(t,i){var n=this,a=this.context.view,o=this.getColorScale(a,t);if(!!o){var l=(0,Mv.getElementValue)(t,o.field);if(!this.cache[l]){var s=(0,Mv.getElementsByField)(a,o.field,l),u=this.linkGroup,c=u.addGroup();this.cache[l]=c;var f=s.length;(0,sS.each)(s,function(h,v){if(v<f-1){var d=s[v+1];n.addLinkShape(c,h,d,i)}})}}},r.prototype.removeLink=function(t){var i=this.getColorScale(this.context.view,t);if(!!i){var n=(0,Mv.getElementValue)(t,i.field);this.cache[n]&&(this.cache[n].remove(),this.cache[n]=null)}},r.prototype.link=function(t){var i=this.context;this.linkGroup||(this.linkGroup=i.view.foregroundGroup.addGroup({id:"link-by-color-group",capture:!1}));var n=(0,Mv.getCurrentElement)(i);n&&this.linkByElement(n,t==null?void 0:t.style)},r.prototype.unlink=function(){var t=(0,Mv.getCurrentElement)(this.context);t&&this.removeLink(t)},r.prototype.clear=function(){this.linkGroup&&this.linkGroup.clear(),this.cache={}},r.prototype.destroy=function(){e.prototype.destroy.call(this),this.linkGroup&&this.linkGroup.remove()},r}(Igt.default),Dgt=PF.default=Lgt,IF={},rg={};Object.defineProperty(rg,"__esModule",{value:!0});var wH=V,Im=Y,Bn=xt,$gt=(0,wH.__importDefault)(eg),kgt=function(e){(0,wH.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.startPoint=null,t.endPoint=null,t.isStarted=!1,t.effectSiblings=!1,t.effectByRecord=!1,t}return r.prototype.getCurrentPoint=function(){var t=this.context.event;return{x:t.x,y:t.y}},r.prototype.start=function(){this.clear(),this.startPoint=this.getCurrentPoint(),this.isStarted=!0},r.prototype.getIntersectElements=function(){var t=null;if((0,Bn.isMask)(this.context))t=(0,Bn.getMaskedElements)(this.context,10);else{var i=this.startPoint,n=this.isStarted?this.getCurrentPoint():this.endPoint;if(!i||!n)return;var a={minX:Math.min(i.x,n.x),minY:Math.min(i.y,n.y),maxX:Math.max(i.x,n.x),maxY:Math.max(i.y,n.y)},o=this.context.view;t=(0,Bn.getIntersectElements)(o,a)}return t},r.prototype.setStateEnable=function(t){if(this.effectSiblings&&!this.effectByRecord)this.setSiblingsState(t);else{var i=(0,Bn.getElements)(this.context.view),n=this.getIntersectElements();n&&n.length?this.effectByRecord?this.setSiblingsStateByRecord(n,t):this.setElementsState(n,t,i):this.clear()}},r.prototype.setSiblingsStateByRecord=function(t,i){var n=this,a=this.context.view,o=(0,Bn.getSilbings)(a),l=t.map(function(c){return c.getModel().data}),s=a.getXScale().field,u=a.getYScales()[0].field;(0,Im.each)(o,function(c){var f=(0,Bn.getElements)(c),h=f.filter(function(v){var d=v.getModel().data;return(0,Bn.isInRecords)(l,d,s,u)});n.setElementsState(h,i,f)})},r.prototype.setSiblingsState=function(t){var i=this,n=this.context.view,a=(0,Bn.getSilbings)(n);(0,Bn.isMask)(this.context)&&(0,Im.each)(a,function(o){var l=(0,Bn.getElements)(o),s=(0,Bn.getSiblingMaskElements)(i.context,o,10);s&&s.length?i.setElementsState(s,t,l):i.clearViewState(o)})},r.prototype.setElementsState=function(t,i,n){var a=this;(0,Im.each)(n,function(o){t.includes(o)?a.setElementState(o,i):a.setElementState(o,!1)})},r.prototype.end=function(){this.isStarted=!1,this.endPoint=this.getCurrentPoint()},r.prototype.clear=function(){var t=this,i=this.context.view;if(this.effectSiblings){var n=(0,Bn.getSilbings)(i);(0,Im.each)(n,function(a){t.clearViewState(a)})}else this.clearViewState(i)},r}($gt.default);rg.default=kgt;Object.defineProperty(IF,"__esModule",{value:!0});var CH=V,Rgt=(0,CH.__importDefault)(rg),Bgt=function(e){(0,CH.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="active",t}return r.prototype.active=function(){this.setState()},r}(Rgt.default),Ngt=IF.default=Bgt,LF={},ig={};Object.defineProperty(ig,"__esModule",{value:!0});var SH=V,uS=xt,Ggt=(0,SH.__importDefault)(eg),zgt=function(e){(0,SH.__extends)(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.setStateEnable=function(t){var i=(0,uS.getCurrentElement)(this.context);if(i){if(!(0,uS.isElementChange)(this.context))return;t?(this.clear(),this.setElementState(i,!0)):this.hasState(i)&&this.setElementState(i,!1)}},r.prototype.toggle=function(){var t=(0,uS.getCurrentElement)(this.context);if(t){var i=this.hasState(t);i||this.clear(),this.setElementState(t,!i)}},r.prototype.reset=function(){this.setStateEnable(!1)},r}(Ggt.default);ig.default=zgt;Object.defineProperty(LF,"__esModule",{value:!0});var AH=V,Vgt=(0,AH.__importDefault)(ig),jgt=function(e){(0,AH.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="active",t}return r.prototype.active=function(){this.setState()},r}(Vgt.default),Hgt=LF.default=jgt,ng={},ms={};Object.defineProperty(ms,"__esModule",{value:!0});ms.setHighlightBy=ms.clearHighlight=void 0;var TH=Y,Ygt=xt,_d="inactive",bd="active";function Wgt(e){var r=(0,Ygt.getElements)(e);(0,TH.each)(r,function(t){t.hasState(bd)&&t.setState(bd,!1),t.hasState(_d)&&t.setState(_d,!1)})}ms.clearHighlight=Wgt;function Xgt(e,r,t){(0,TH.each)(e,function(i){r(i)?(i.hasState(_d)&&i.setState(_d,!1),i.setState(bd,t)):(i.hasState(bd)&&i.setState(bd,!1),i.setState(_d,t))})}ms.setHighlightBy=Xgt;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.STATUS_ACTIVE=e.STATUS_UNACTIVE=void 0;var r=V,t=Y,i=xt,n=ms,a=(0,r.__importDefault)(tg),o=Jt;e.STATUS_UNACTIVE=o.ELEMENT_STATE.INACTIVE,e.STATUS_ACTIVE=o.ELEMENT_STATE.ACTIVE;var l=function(s){(0,r.__extends)(u,s);function u(){var c=s!==null&&s.apply(this,arguments)||this;return c.stateName=e.STATUS_ACTIVE,c}return u.prototype.setElementsStateByItem=function(c,f,h,v){var d=this,p=function(x){return d.isMathItem(x,f,h)};this.setHighlightBy(c,p,v)},u.prototype.setElementHighlight=function(c,f){f(c)?(c.hasState(e.STATUS_UNACTIVE)&&c.setState(e.STATUS_UNACTIVE,!1),c.setState(e.STATUS_ACTIVE,!0)):c.hasState(e.STATUS_ACTIVE)||c.setState(e.STATUS_UNACTIVE,!0)},u.prototype.setHighlightBy=function(c,f,h){var v=this;if(h)(0,t.each)(c,function(x){v.setElementHighlight(x,f)});else{var d=(0,i.getElementsByState)(this.context.view,e.STATUS_ACTIVE),p=!0;(0,t.each)(d,function(x){if(!f(x))return p=!1,!1}),p?this.clear():(0,t.each)(c,function(x){f(x)&&(x.hasState(e.STATUS_ACTIVE)&&x.setState(e.STATUS_ACTIVE,!1),x.setState(e.STATUS_UNACTIVE,!0))})}},u.prototype.setElementState=function(c,f){var h=this.context.view,v=(0,i.getElements)(h);this.setHighlightBy(v,function(d){return c===d},f)},u.prototype.highlight=function(){this.setState()},u.prototype.clear=function(){var c=this.context.view;(0,n.clearHighlight)(c)},u}(a.default);e.default=l})(ng);var Ugt=aM(ng),DF={};Object.defineProperty(DF,"__esModule",{value:!0});var MH=V,cS=xt,qgt=(0,MH.__importDefault)(ng),Zgt=function(e){(0,MH.__extends)(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.setStateByElement=function(t,i){var n=this.context.view,a=t.geometry.getAttribute("color");if(!!a){var o=n.getScaleByField(a.getFields()[0]),l=(0,cS.getElementValue)(t,o.field),s=(0,cS.getElements)(n),u=s.filter(function(c){return(0,cS.getElementValue)(c,o.field)===l});this.setHighlightBy(s,function(c){return u.includes(c)},i)}},r}(qgt.default),Qgt=DF.default=Zgt,$F={};Object.defineProperty($F,"__esModule",{value:!0});var EH=V,Lm=xt,au=(0,EH.__importStar)(ng),Kgt=function(e){(0,EH.__extends)(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.setElementHighlight=function(t,i){i(t)?(t.hasState(au.STATUS_UNACTIVE)&&t.setState(au.STATUS_UNACTIVE,!1),t.setState(au.STATUS_ACTIVE,!0)):(t.setState(au.STATUS_UNACTIVE,!0),t.hasState(au.STATUS_ACTIVE)&&t.setState(au.STATUS_ACTIVE,!1))},r.prototype.setStateByElement=function(t,i){var n=this.context.view,a=n.getXScale(),o=(0,Lm.getElementValue)(t,a.field),l=(0,Lm.getElements)(n),s=l.filter(function(u){return(0,Lm.getElementValue)(u,a.field)===o});this.setHighlightBy(l,function(u){return s.includes(u)},i)},r.prototype.toggle=function(){var t=(0,Lm.getCurrentElement)(this.context);if(t){var i=t.hasState(this.stateName);this.setStateByElement(t,!i)}},r}(au.default),Jgt=$F.default=Kgt,ag={};Object.defineProperty(ag,"__esModule",{value:!0});ag.ELEMENT_RANGE_HIGHLIGHT_EVENTS=void 0;var FH=V,Dm=Af,aR=ms,tyt=(0,FH.__importDefault)(rg),va;(function(e){e.BEFORE_HIGHLIGHT="element-range-highlight:beforehighlight",e.AFTER_HIGHLIGHT="element-range-highlight:afterhighlight",e.BEFORE_CLEAR="element-range-highlight:beforeclear",e.AFTER_CLEAR="element-range-highlight:afterclear"})(va||(va={}));ag.ELEMENT_RANGE_HIGHLIGHT_EVENTS=va;var eyt=function(e){(0,FH.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="active",t}return r.prototype.clearViewState=function(t){(0,aR.clearHighlight)(t)},r.prototype.highlight=function(){var t=this.context,i=t.view,n=t.event,a=this.getIntersectElements(),o={view:i,event:n,highlightElements:a};i.emit(va.BEFORE_HIGHLIGHT,Dm.Event.fromData(i,va.BEFORE_HIGHLIGHT,o)),this.setState(),i.emit(va.AFTER_HIGHLIGHT,Dm.Event.fromData(i,va.AFTER_HIGHLIGHT,o))},r.prototype.clear=function(){var t=this.context.view;t.emit(va.BEFORE_CLEAR,Dm.Event.fromData(t,va.BEFORE_CLEAR,{})),e.prototype.clear.call(this),t.emit(va.AFTER_CLEAR,Dm.Event.fromData(t,va.AFTER_CLEAR,{}))},r.prototype.setElementsState=function(t,i,n){(0,aR.setHighlightBy)(n,function(a){return t.indexOf(a)>=0},i)},r}(tyt.default),OH=ag.default=eyt,kF={};Object.defineProperty(kF,"__esModule",{value:!0});var PH=V,ryt=xt,oR=ms,iyt=(0,PH.__importDefault)(ig),nyt=function(e){(0,PH.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="active",t}return r.prototype.highlight=function(){this.setState()},r.prototype.setElementState=function(t,i){var n=this.context.view,a=(0,ryt.getElements)(n);(0,oR.setHighlightBy)(a,function(o){return t===o},i)},r.prototype.clear=function(){var t=this.context.view;(0,oR.clearHighlight)(t)},r}(iyt.default),ayt=kF.default=nyt,RF={};Object.defineProperty(RF,"__esModule",{value:!0});var IH=V,oyt=(0,IH.__importDefault)(rg),lyt=function(e){(0,IH.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="selected",t}return r.prototype.selected=function(){this.setState()},r}(oyt.default),syt=RF.default=lyt,BF={};Object.defineProperty(BF,"__esModule",{value:!0});var LH=V,uyt=(0,LH.__importDefault)(tg),cyt=function(e){(0,LH.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="selected",t}return r.prototype.selected=function(){this.setState()},r}(uyt.default),fyt=BF.default=cyt,NF={};Object.defineProperty(NF,"__esModule",{value:!0});var DH=V,hyt=(0,DH.__importDefault)(ig),vyt=function(e){(0,DH.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="selected",t}return r.prototype.selected=function(){this.setState()},r}(hyt.default),dyt=NF.default=vyt,GF={},hc={};Object.defineProperty(hc,"__esModule",{value:!0});var $H=V,$m=Y,pyt=(0,$H.__importDefault)(Ir),gyt=xt,Il=xt,yyt=function(e){(0,$H.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="",t.ignoreItemStates=[],t}return r.prototype.getTriggerListInfo=function(){var t=(0,Il.getDelegationObject)(this.context),i=null;return(0,Il.isList)(t)&&(i={item:t.item,list:t.component}),i},r.prototype.getAllowComponents=function(){var t=this,i=this.context.view,n=(0,gyt.getComponents)(i),a=[];return(0,$m.each)(n,function(o){o.isList()&&t.allowSetStateByElement(o)&&a.push(o)}),a},r.prototype.hasState=function(t,i){return t.hasState(i,this.stateName)},r.prototype.clearAllComponentsState=function(){var t=this,i=this.getAllowComponents();(0,$m.each)(i,function(n){n.clearItemsState(t.stateName)})},r.prototype.allowSetStateByElement=function(t){var i=t.get("field");if(!i)return!1;if(this.cfg&&this.cfg.componentNames){var n=t.get("name");if(this.cfg.componentNames.indexOf(n)===-1)return!1}var a=this.context.view,o=(0,Il.getScaleByField)(a,i);return o&&o.isCategory},r.prototype.allowSetStateByItem=function(t,i){var n=this.ignoreItemStates;if(n.length){var a=n.filter(function(o){return i.hasState(t,o)});return a.length===0}return!0},r.prototype.setStateByElement=function(t,i,n){var a=t.get("field"),o=this.context.view,l=(0,Il.getScaleByField)(o,a),s=(0,Il.getElementValue)(i,a),u=l.getText(s);this.setItemsState(t,u,n)},r.prototype.setStateEnable=function(t){var i=this,n=(0,Il.getCurrentElement)(this.context);if(n){var a=this.getAllowComponents();(0,$m.each)(a,function(u){i.setStateByElement(u,n,t)})}else{var o=(0,Il.getDelegationObject)(this.context);if((0,Il.isList)(o)){var l=o.item,s=o.component;this.allowSetStateByElement(s)&&this.allowSetStateByItem(l,s)&&this.setItemState(s,l,t)}}},r.prototype.setItemsState=function(t,i,n){var a=this,o=t.getItems();(0,$m.each)(o,function(l){l.name===i&&a.setItemState(t,l,n)})},r.prototype.setItemState=function(t,i,n){t.setItemState(i,this.stateName,n)},r.prototype.setState=function(){this.setStateEnable(!0)},r.prototype.reset=function(){this.setStateEnable(!1)},r.prototype.toggle=function(){var t=this.getTriggerListInfo();if(t&&t.item){var i=t.list,n=t.item,a=this.hasState(i,n);this.setItemState(i,n,!a)}},r.prototype.clear=function(){var t=this.getTriggerListInfo();t?t.list.clearItemsState(this.stateName):this.clearAllComponentsState()},r}(pyt.default);hc.default=yyt;Object.defineProperty(GF,"__esModule",{value:!0});var kH=V,myt=(0,kH.__importDefault)(hc),xyt=function(e){(0,kH.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="active",t}return r.prototype.active=function(){this.setState()},r}(myt.default),_yt=GF.default=xyt,zF={},h_={};Object.defineProperty(h_,"__esModule",{value:!0});h_.clearList=void 0;var byt=Y,lR="inactive",sR="active";function wyt(e){var r=e.getItems();(0,byt.each)(r,function(t){e.hasState(t,sR)&&e.setItemState(t,sR,!1),e.hasState(t,lR)&&e.setItemState(t,lR,!1)})}h_.clearList=wyt;Object.defineProperty(zF,"__esModule",{value:!0});var RH=V,km=Y,Cyt=h_,Syt=(0,RH.__importDefault)(hc),Ev="inactive",ou="active",Ayt=function(e){(0,RH.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName=ou,t.ignoreItemStates=["unchecked"],t}return r.prototype.setItemsState=function(t,i,n){this.setHighlightBy(t,function(a){return a.name===i},n)},r.prototype.setItemState=function(t,i,n){t.getItems(),this.setHighlightBy(t,function(a){return a===i},n)},r.prototype.setHighlightBy=function(t,i,n){var a=t.getItems();if(n)(0,km.each)(a,function(s){i(s)?(t.hasState(s,Ev)&&t.setItemState(s,Ev,!1),t.setItemState(s,ou,!0)):t.hasState(s,ou)||t.setItemState(s,Ev,!0)});else{var o=t.getItemsByState(ou),l=!0;(0,km.each)(o,function(s){if(!i(s))return l=!1,!1}),l?this.clear():(0,km.each)(a,function(s){i(s)&&(t.hasState(s,ou)&&t.setItemState(s,ou,!1),t.setItemState(s,Ev,!0))})}},r.prototype.highlight=function(){this.setState()},r.prototype.clear=function(){var t=this.getTriggerListInfo();if(t)(0,Cyt.clearList)(t.list);else{var i=this.getAllowComponents();(0,km.each)(i,function(n){n.clearItemsState(ou),n.clearItemsState(Ev)})}},r}(Syt.default),BH=zF.default=Ayt,VF={};Object.defineProperty(VF,"__esModule",{value:!0});var NH=V,Tyt=(0,NH.__importDefault)(hc),Myt=function(e){(0,NH.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="selected",t}return r.prototype.selected=function(){this.setState()},r}(Tyt.default),Eyt=VF.default=Myt,jF={};Object.defineProperty(jF,"__esModule",{value:!0});var GH=V,Fyt=(0,GH.__importDefault)(hc),Oyt=function(e){(0,GH.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="unchecked",t}return r.prototype.unchecked=function(){this.setState()},r}(Fyt.default),Pyt=jF.default=Oyt,HF={};Object.defineProperty(HF,"__esModule",{value:!0});var zH=V,fS=Y,Iyt=(0,zH.__importDefault)(hc),jc="unchecked",Rm="checked",Lyt=function(e){(0,zH.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName=Rm,t}return r.prototype.setItemState=function(t,i,n){this.setCheckedBy(t,function(a){return a===i},n)},r.prototype.setCheckedBy=function(t,i,n){var a=t.getItems();n&&(0,fS.each)(a,function(o){i(o)?(t.hasState(o,jc)&&t.setItemState(o,jc,!1),t.setItemState(o,Rm,!0)):t.hasState(o,Rm)||t.setItemState(o,jc,!0)})},r.prototype.toggle=function(){var t=this.getTriggerListInfo();if(t&&t.item){var i=t.list,n=t.item,a=!(0,fS.some)(i.getItems(),function(o){return i.hasState(o,jc)});a||i.hasState(n,jc)?this.setItemState(i,n,!0):this.reset()}},r.prototype.checked=function(){this.setState()},r.prototype.reset=function(){var t=this.getAllowComponents();(0,fS.each)(t,function(i){i.clearItemsState(Rm),i.clearItemsState(jc)})},r}(Iyt.default);HF.default=Lyt;var YF={},og={};Object.defineProperty(og,"__esModule",{value:!0});var cT=V,uR=Y,Dyt=(0,cT.__importDefault)(Ir),$yt=function(e){(0,cT.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.maskShape=null,t.points=[],t.starting=!1,t.moving=!1,t.preMovePoint=null,t.shapeType="path",t}return r.prototype.getCurrentPoint=function(){var t=this.context.event;return{x:t.x,y:t.y}},r.prototype.emitEvent=function(t){var i="mask:"+t,n=this.context.view,a=this.context.event;n.emit(i,{target:this.maskShape,shape:this.maskShape,points:this.points,x:a.x,y:a.y})},r.prototype.createMask=function(){var t=this.context.view,i=this.getMaskAttrs(),n=t.foregroundGroup.addShape({type:this.shapeType,name:"mask",draggable:!0,attrs:(0,cT.__assign)({fill:"#C5D4EB",opacity:.3},i)});return n},r.prototype.getMaskPath=function(){return[]},r.prototype.show=function(){this.maskShape&&(this.maskShape.show(),this.emitEvent("show"))},r.prototype.start=function(t){this.starting=!0,this.moving=!1,this.points=[this.getCurrentPoint()],this.maskShape||(this.maskShape=this.createMask(),this.maskShape.set("capture",!1)),this.updateMask(t==null?void 0:t.maskStyle),this.emitEvent("start")},r.prototype.moveStart=function(){this.moving=!0,this.preMovePoint=this.getCurrentPoint()},r.prototype.move=function(){if(!(!this.moving||!this.maskShape)){var t=this.getCurrentPoint(),i=this.preMovePoint,n=t.x-i.x,a=t.y-i.y,o=this.points;(0,uR.each)(o,function(l){l.x+=n,l.y+=a}),this.updateMask(),this.emitEvent("change"),this.preMovePoint=t}},r.prototype.updateMask=function(t){var i=(0,uR.deepMix)({},this.getMaskAttrs(),t);this.maskShape.attr(i)},r.prototype.moveEnd=function(){this.moving=!1,this.preMovePoint=null},r.prototype.end=function(){this.starting=!1,this.emitEvent("end"),this.maskShape&&this.maskShape.set("capture",!0)},r.prototype.hide=function(){this.maskShape&&(this.maskShape.hide(),this.emitEvent("hide"))},r.prototype.resize=function(){this.starting&&this.maskShape&&(this.points.push(this.getCurrentPoint()),this.updateMask(),this.emitEvent("change"))},r.prototype.destroy=function(){this.points=[],this.maskShape&&this.maskShape.remove(),this.maskShape=null,this.preMovePoint=null,e.prototype.destroy.call(this)},r}(Dyt.default);og.default=$yt;Object.defineProperty(YF,"__esModule",{value:!0});var VH=V,kyt=Y,Ryt=xt,Byt=(0,VH.__importDefault)(og),Nyt=function(e){(0,VH.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.shapeType="circle",t}return r.prototype.getMaskAttrs=function(){var t=this.points,i=(0,kyt.last)(this.points),n=0,a=0,o=0;if(t.length){var l=t[0];n=(0,Ryt.distance)(l,i)/2,a=(i.x+l.x)/2,o=(i.y+l.y)/2}return{x:a,y:o,r:n}},r}(Byt.default);YF.default=Nyt;var WF={},v_={};Object.defineProperty(v_,"__esModule",{value:!0});var jH=V,cR=Y,Gyt=(0,jH.__importDefault)(og),zyt=function(e){(0,jH.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.shapeType="rect",t}return r.prototype.getRegion=function(){var t=this.points;return{start:(0,cR.head)(t),end:(0,cR.last)(t)}},r.prototype.getMaskAttrs=function(){var t=this.getRegion(),i=t.start,n=t.end,a=Math.min(i.x,n.x),o=Math.min(i.y,n.y),l=Math.abs(n.x-i.x),s=Math.abs(n.y-i.y);return{x:a,y:o,width:l,height:s}},r}(Gyt.default);v_.default=zyt;Object.defineProperty(WF,"__esModule",{value:!0});var HH=V,vx=Y,Vyt=(0,HH.__importDefault)(v_);function fR(e){e.x=(0,vx.clamp)(e.x,0,1),e.y=(0,vx.clamp)(e.y,0,1)}var jyt=function(e){(0,HH.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.dim="x",t.inPlot=!0,t}return r.prototype.getRegion=function(){var t=null,i=null,n=this.points,a=this.dim,o=this.context.view.getCoordinate(),l=o.invert((0,vx.head)(n)),s=o.invert((0,vx.last)(n));return this.inPlot&&(fR(l),fR(s)),a==="x"?(t=o.convert({x:l.x,y:0}),i=o.convert({x:s.x,y:1})):(t=o.convert({x:0,y:l.y}),i=o.convert({x:1,y:s.y})),{start:t,end:i}},r}(Vyt.default);WF.default=jyt;var d_={};Object.defineProperty(d_,"__esModule",{value:!0});var YH=V,Hyt=Y,Yyt=(0,YH.__importDefault)(og),Wyt=function(e){(0,YH.__extends)(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getMaskPath=function(){var t=this.points,i=[];return t.length&&((0,Hyt.each)(t,function(n,a){a===0?i.push(["M",n.x,n.y]):i.push(["L",n.x,n.y])}),i.push(["L",t[0].x,t[0].y])),i},r.prototype.getMaskAttrs=function(){return{path:this.getMaskPath()}},r.prototype.addPoint=function(){this.resize()},r}(Yyt.default);d_.default=Wyt;var XF={};Object.defineProperty(XF,"__esModule",{value:!0});var WH=V,Xyt=xt,Uyt=(0,WH.__importDefault)(d_),qyt=function(e){(0,WH.__extends)(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getMaskPath=function(){var t=this.points;return(0,Xyt.getSpline)(t,!0)},r}(Uyt.default);XF.default=qyt;var UF={};Object.defineProperty(UF,"__esModule",{value:!0});var XH=V,Zyt=(0,XH.__importDefault)(Ir),Qyt=function(e){(0,XH.__extends)(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.setCursor=function(t){var i=this.context.view;i.getCanvas().setCursor(t)},r.prototype.default=function(){this.setCursor("default")},r.prototype.pointer=function(){this.setCursor("pointer")},r.prototype.move=function(){this.setCursor("move")},r.prototype.crosshair=function(){this.setCursor("crosshair")},r.prototype.wait=function(){this.setCursor("wait")},r.prototype.help=function(){this.setCursor("help")},r.prototype.text=function(){this.setCursor("text")},r.prototype.eResize=function(){this.setCursor("e-resize")},r.prototype.wResize=function(){this.setCursor("w-resize")},r.prototype.nResize=function(){this.setCursor("n-resize")},r.prototype.sResize=function(){this.setCursor("s-resize")},r.prototype.neResize=function(){this.setCursor("ne-resize")},r.prototype.nwResize=function(){this.setCursor("nw-resize")},r.prototype.seResize=function(){this.setCursor("se-resize")},r.prototype.swResize=function(){this.setCursor("sw-resize")},r.prototype.nsResize=function(){this.setCursor("ns-resize")},r.prototype.ewResize=function(){this.setCursor("ew-resize")},r}(Zyt.default),Kyt=UF.default=Qyt,qF={};Object.defineProperty(qF,"__esModule",{value:!0});var UH=V,Jyt=Y,tmt=(0,UH.__importDefault)(Ir),Bm=xt,emt=function(e){(0,UH.__extends)(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.filterView=function(t,i,n){var a=this;t.getScaleByField(i)&&t.filter(i,n),t.views&&t.views.length&&(0,Jyt.each)(t.views,function(o){a.filterView(o,i,n)})},r.prototype.filter=function(){var t=(0,Bm.getDelegationObject)(this.context);if(t){var i=this.context.view,n=t.component,a=n.get("field");if((0,Bm.isList)(t)){if(a){var o=n.getItemsByState("unchecked"),l=(0,Bm.getScaleByField)(i,a),s=o.map(function(h){return h.name});s.length?this.filterView(i,a,function(h){var v=l.getText(h);return!s.includes(v)}):this.filterView(i,a,null),i.render(!0)}}else if((0,Bm.isSlider)(t)){var u=n.getValue(),c=u[0],f=u[1];this.filterView(i,a,function(h){return h>=c&&h<=f}),i.render(!0)}}},r}(tmt.default),rmt=qF.default=emt,Lh={};Object.defineProperty(Lh,"__esModule",{value:!0});Lh.BRUSH_FILTER_EVENTS=void 0;var qH=V,Nm=Af,imt=(0,qH.__importDefault)(Ir),nmt=xt;function hR(e,r,t,i){var n=Math.min(t[r],i[r]),a=Math.max(t[r],i[r]),o=e.range,l=o[0],s=o[1];if(n<l&&(n=l),a>s&&(a=s),n===s&&a===s)return null;var u=e.invert(n),c=e.invert(a);if(e.isCategory){var f=e.values.indexOf(u),h=e.values.indexOf(c),v=e.values.slice(f,h+1);return function(d){return v.includes(d)}}else return function(d){return d>=u&&d<=c}}var cn;(function(e){e.FILTER="brush-filter-processing",e.RESET="brush-filter-reset",e.BEFORE_FILTER="brush-filter:beforefilter",e.AFTER_FILTER="brush-filter:afterfilter",e.BEFORE_RESET="brush-filter:beforereset",e.AFTER_RESET="brush-filter:afterreset"})(cn||(cn={}));Lh.BRUSH_FILTER_EVENTS=cn;var amt=function(e){(0,qH.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.dims=["x","y"],t.startPoint=null,t.isStarted=!1,t}return r.prototype.hasDim=function(t){return this.dims.includes(t)},r.prototype.start=function(){var t=this.context;this.isStarted=!0,this.startPoint=t.getCurrentPoint()},r.prototype.filter=function(){var t,i;if((0,nmt.isMask)(this.context)){var n=this.context.event.target,a=n.getCanvasBBox();t={x:a.x,y:a.y},i={x:a.maxX,y:a.maxY}}else{if(!this.isStarted)return;t=this.startPoint,i=this.context.getCurrentPoint()}if(!(Math.abs(t.x-i.x)<5||Math.abs(t.x-i.y)<5)){var o=this.context,l=o.view,s=o.event,u={view:l,event:s,dims:this.dims};l.emit(cn.BEFORE_FILTER,Nm.Event.fromData(l,cn.BEFORE_FILTER,u));var c=l.getCoordinate(),f=c.invert(i),h=c.invert(t);if(this.hasDim("x")){var v=l.getXScale(),d=hR(v,"x",f,h);this.filterView(l,v.field,d)}if(this.hasDim("y")){var p=l.getYScales()[0],d=hR(p,"y",f,h);this.filterView(l,p.field,d)}this.reRender(l,{source:cn.FILTER}),l.emit(cn.AFTER_FILTER,Nm.Event.fromData(l,cn.AFTER_FILTER,u))}},r.prototype.end=function(){this.isStarted=!1},r.prototype.reset=function(){var t=this.context.view;if(t.emit(cn.BEFORE_RESET,Nm.Event.fromData(t,cn.BEFORE_RESET,{})),this.isStarted=!1,this.hasDim("x")){var i=t.getXScale();this.filterView(t,i.field,null)}if(this.hasDim("y")){var n=t.getYScales()[0];this.filterView(t,n.field,null)}this.reRender(t,{source:cn.RESET}),t.emit(cn.AFTER_RESET,Nm.Event.fromData(t,cn.AFTER_RESET,{}))},r.prototype.filterView=function(t,i,n){t.filter(i,n)},r.prototype.reRender=function(t,i){t.render(!0,i)},r}(imt.default);Lh.default=amt;var ZF={};Object.defineProperty(ZF,"__esModule",{value:!0});var ZH=V,vR=Y,omt=(0,ZH.__importDefault)(Lh),dR=xt,lmt=function(e){(0,ZH.__extends)(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.filterView=function(t,i,n){var a=(0,dR.getSilbings)(t);(0,vR.each)(a,function(o){o.filter(i,n)})},r.prototype.reRender=function(t){var i=(0,dR.getSilbings)(t);(0,vR.each)(i,function(n){n.render(!0)})},r}(omt.default);ZF.default=lmt;var QF={};Object.defineProperty(QF,"__esModule",{value:!0});var QH=V,Gm=Y,smt=(0,QH.__importDefault)(Ir),Ya=xt,umt=function(e){(0,QH.__extends)(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.filter=function(){var t=(0,Ya.getDelegationObject)(this.context),i=this.context.view,n=(0,Ya.getElements)(i);if((0,Ya.isMask)(this.context)){var a=(0,Ya.getMaskedElements)(this.context,10);a&&(0,Gm.each)(n,function(d){a.includes(d)?d.show():d.hide()})}else if(t){var o=t.component,l=o.get("field");if((0,Ya.isList)(t)){if(l){var s=o.getItemsByState("unchecked"),u=(0,Ya.getScaleByField)(i,l),c=s.map(function(d){return d.name});(0,Gm.each)(n,function(d){var p=(0,Ya.getElementValue)(d,l),x=u.getText(p);c.indexOf(x)>=0?d.hide():d.show()})}}else if((0,Ya.isSlider)(t)){var f=o.getValue(),h=f[0],v=f[1];(0,Gm.each)(n,function(d){var p=(0,Ya.getElementValue)(d,l);p>=h&&p<=v?d.show():d.hide()})}}},r.prototype.clear=function(){var t=(0,Ya.getElements)(this.context.view);(0,Gm.each)(t,function(i){i.show()})},r.prototype.reset=function(){this.clear()},r}(smt.default);QF.default=umt;var KF={};Object.defineProperty(KF,"__esModule",{value:!0});var KH=V,Hc=Y,cmt=(0,KH.__importDefault)(Ir),Wa=xt,fmt=function(e){(0,KH.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.byRecord=!1,t}return r.prototype.filter=function(){(0,Wa.isMask)(this.context)&&(this.byRecord?this.filterByRecord():this.filterByBBox())},r.prototype.filterByRecord=function(){var t=this.context.view,i=(0,Wa.getMaskedElements)(this.context,10);if(!!i){var n=t.getXScale().field,a=t.getYScales()[0].field,o=i.map(function(s){return s.getModel().data}),l=(0,Wa.getSilbings)(t);(0,Hc.each)(l,function(s){var u=(0,Wa.getElements)(s);(0,Hc.each)(u,function(c){var f=c.getModel().data;(0,Wa.isInRecords)(o,f,n,a)?c.show():c.hide()})})}},r.prototype.filterByBBox=function(){var t=this,i=this.context.view,n=(0,Wa.getSilbings)(i);(0,Hc.each)(n,function(a){var o=(0,Wa.getSiblingMaskElements)(t.context,a,10),l=(0,Wa.getElements)(a);o&&(0,Hc.each)(l,function(s){o.includes(s)?s.show():s.hide()})})},r.prototype.reset=function(){var t=(0,Wa.getSilbings)(this.context.view);(0,Hc.each)(t,function(i){var n=(0,Wa.getElements)(i);(0,Hc.each)(n,function(a){a.show()})})},r}(cmt.default);KF.default=fmt;var JF={};Object.defineProperty(JF,"__esModule",{value:!0});var A0=V,hmt=ta,vmt=Y,dmt=gs,pmt=(0,A0.__importDefault)(Ir),gmt=10,ymt=5,mmt=function(e){(0,A0.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.buttonGroup=null,t.buttonCfg={name:"button",text:"button",textStyle:{x:0,y:0,fontSize:12,fill:"#333333",cursor:"pointer"},padding:[8,10],style:{fill:"#f7f7f7",stroke:"#cccccc",cursor:"pointer"},activeStyle:{fill:"#e6e6e6"}},t}return r.prototype.getButtonCfg=function(){return(0,vmt.deepMix)(this.buttonCfg,this.cfg)},r.prototype.drawButton=function(){var t=this.getButtonCfg(),i=this.context.view.foregroundGroup.addGroup({name:t.name}),n=i.addShape({type:"text",name:"button-text",attrs:(0,A0.__assign)({text:t.text},t.textStyle)}),a=n.getBBox(),o=(0,dmt.parsePadding)(t.padding),l=i.addShape({type:"rect",name:"button-rect",attrs:(0,A0.__assign)({x:a.x-o[3],y:a.y-o[0],width:a.width+o[1]+o[3],height:a.height+o[0]+o[2]},t.style)});l.toBack(),i.on("mouseenter",function(){l.attr(t.activeStyle)}),i.on("mouseleave",function(){l.attr(t.style)}),this.buttonGroup=i},r.prototype.resetPosition=function(){var t=this.context.view,i=t.getCoordinate(),n=i.convert({x:1,y:1}),a=this.buttonGroup,o=a.getBBox(),l=hmt.ext.transform(null,[["t",n.x-o.width-gmt,n.y+o.height+ymt]]);a.setMatrix(l)},r.prototype.show=function(){this.buttonGroup||this.drawButton(),this.resetPosition(),this.buttonGroup.show()},r.prototype.hide=function(){this.buttonGroup&&this.buttonGroup.hide()},r.prototype.destroy=function(){var t=this.buttonGroup;t&&t.remove(),e.prototype.destroy.call(this)},r}(pmt.default);JF.default=mmt;var tO={};Object.defineProperty(tO,"__esModule",{value:!0});var JH=V,xmt=(0,JH.__importDefault)(Ir),_mt=xt,bmt=4,wmt=function(e){(0,JH.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.starting=!1,t.dragStart=!1,t}return r.prototype.start=function(){this.starting=!0,this.startPoint=this.context.getCurrentPoint()},r.prototype.drag=function(){if(!!this.startPoint){var t=this.context.getCurrentPoint(),i=this.context.view,n=this.context.event;this.dragStart?i.emit("drag",{target:n.target,x:n.x,y:n.y}):(0,_mt.distance)(t,this.startPoint)>bmt&&(i.emit("dragstart",{target:n.target,x:n.x,y:n.y}),this.dragStart=!0)}},r.prototype.end=function(){if(this.dragStart){var t=this.context.view,i=this.context.event;t.emit("dragend",{target:i.target,x:i.x,y:i.y})}this.starting=!1,this.dragStart=!1},r}(xmt.default);tO.default=wmt;var eO={};Object.defineProperty(eO,"__esModule",{value:!0});var Cmt=V,Smt=ta,Amt=zp,Tmt=xt,Mmt=5,Emt=function(e){(0,Cmt.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.starting=!1,t.isMoving=!1,t.startPoint=null,t.startMatrix=null,t}return r.prototype.start=function(){this.starting=!0,this.startPoint=this.context.getCurrentPoint(),this.startMatrix=this.context.view.middleGroup.getMatrix()},r.prototype.move=function(){if(!!this.starting){var t=this.startPoint,i=this.context.getCurrentPoint(),n=(0,Tmt.distance)(t,i);if(n>Mmt&&!this.isMoving&&(this.isMoving=!0),this.isMoving){var a=this.context.view,o=Smt.ext.transform(this.startMatrix,[["t",i.x-t.x,i.y-t.y]]);a.backgroundGroup.setMatrix(o),a.foregroundGroup.setMatrix(o),a.middleGroup.setMatrix(o)}}},r.prototype.end=function(){this.isMoving&&(this.isMoving=!1),this.startMatrix=null,this.starting=!1,this.startPoint=null},r.prototype.reset=function(){this.starting=!1,this.startPoint=null,this.isMoving=!1;var t=this.context.view;t.backgroundGroup.resetMatrix(),t.foregroundGroup.resetMatrix(),t.middleGroup.resetMatrix(),this.isMoving=!1},r}(Amt.Action);eO.default=Emt;var rO={},p_={};Object.defineProperty(p_,"__esModule",{value:!0});var Fmt=V,Omt=zp,pR="x",gR="y",Pmt=function(e){(0,Fmt.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.dims=[pR,gR],t.cfgFields=["dims"],t.cacheScaleDefs={},t}return r.prototype.hasDim=function(t){return this.dims.includes(t)},r.prototype.getScale=function(t){var i=this.context.view;return t==="x"?i.getXScale():i.getYScales()[0]},r.prototype.resetDim=function(t){var i=this.context.view;if(this.hasDim(t)&&this.cacheScaleDefs[t]){var n=this.getScale(t);i.scale(n.field,this.cacheScaleDefs[t]),this.cacheScaleDefs[t]=null}},r.prototype.reset=function(){this.resetDim(pR),this.resetDim(gR);var t=this.context.view;t.render(!0)},r}(Omt.Action);p_.default=Pmt;Object.defineProperty(rO,"__esModule",{value:!0});var tY=V,yR=Y,Imt=(0,tY.__importDefault)(p_),Lmt=function(e){(0,tY.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.startPoint=null,t.starting=!1,t.startCache={},t}return r.prototype.start=function(){var t=this;this.startPoint=this.context.getCurrentPoint(),this.starting=!0;var i=this.dims;(0,yR.each)(i,function(n){var a=t.getScale(n),o=a.min,l=a.max,s=a.values;t.startCache[n]={min:o,max:l,values:s}})},r.prototype.end=function(){this.startPoint=null,this.starting=!1,this.startCache={}},r.prototype.translate=function(){var t=this;if(!!this.starting){var i=this.startPoint,n=this.context.view.getCoordinate(),a=this.context.getCurrentPoint(),o=n.invert(i),l=n.invert(a),s=l.x-o.x,u=l.y-o.y,c=this.context.view,f=this.dims;(0,yR.each)(f,function(h){t.translateDim(h,{x:s*-1,y:u*-1})}),c.render(!0)}},r.prototype.translateDim=function(t,i){if(this.hasDim(t)){var n=this.getScale(t);n.isLinear&&this.translateLinear(t,n,i)}},r.prototype.translateLinear=function(t,i,n){var a=this.context.view,o=this.startCache[t],l=o.min,s=o.max,u=s-l,c=n[t]*u;this.cacheScaleDefs[t]||(this.cacheScaleDefs[t]={nice:i.nice,min:l,max:s}),a.scale(i.field,{nice:!1,min:l+c,max:s+c})},r.prototype.reset=function(){e.prototype.reset.call(this),this.startPoint=null,this.starting=!1},r}(Imt.default);rO.default=Lmt;var iO={};Object.defineProperty(iO,"__esModule",{value:!0});var eY=V,Dmt=Y,$mt=(0,eY.__importDefault)(p_),kmt=function(e){(0,eY.__extends)(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.zoomRatio=.05,t}return r.prototype.zoomIn=function(){this.zoom(this.zoomRatio)},r.prototype.zoom=function(t){var i=this,n=this.dims;(0,Dmt.each)(n,function(a){i.zoomDim(a,t)}),this.context.view.render(!0)},r.prototype.zoomOut=function(){this.zoom(-1*this.zoomRatio)},r.prototype.zoomDim=function(t,i){if(this.hasDim(t)){var n=this.getScale(t);n.isLinear&&this.zoomLinear(t,n,i)}},r.prototype.zoomLinear=function(t,i,n){var a=this.context.view;this.cacheScaleDefs[t]||(this.cacheScaleDefs[t]={nice:i.nice,min:i.min,max:i.max});var o=this.cacheScaleDefs[t],l=o.max-o.min,s=i.min,u=i.max,c=n*l,f=s-c,h=u+c,v=h-f,d=v/l;h>f&&d<100&&d>.01&&a.scale(i.field,{nice:!1,min:s-c,max:u+c})},r}($mt.default);iO.default=kmt;var nO={};Object.defineProperty(nO,"__esModule",{value:!0});var Rmt=V,zm=Y,Bmt=zp;function Nmt(e){var r=e.gEvent.originalEvent;return r.deltaY>0}var Gmt=1,zmt=function(e){(0,Rmt.__extends)(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.scroll=function(t){var i=this.context,n=i.view,a=i.event;if(!!n.getOptions().scrollbar){var o=(t==null?void 0:t.wheelDelta)||Gmt,l=n.getController("scrollbar"),s=n.getXScale(),u=n.getOptions().data,c=(0,zm.size)((0,zm.valuesOfKey)(u,s.field)),f=(0,zm.size)(s.values),h=l.getValue(),v=Math.floor((c-f)*h),d=v+(Nmt(a)?o:-o),p=o/(c-f)/1e4,x=(0,zm.clamp)(d/(c-f)+p,0,1);l.setValue(x)}},r}(Bmt.Action);nO.default=zmt;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ELEMENT_RANGE_HIGHLIGHT_EVENTS=e.BRUSH_FILTER_EVENTS=e.VIEW_LIFE_CIRCLE=void 0;var r=V,t=ut,i=eF,n=Vp;(0,t.registerTheme)("dark",(0,n.createThemeByStyleSheet)(i.antvDark));var a=(0,r.__importStar)(cj),o=(0,r.__importStar)(qct),l=ut;(0,l.registerEngine)("canvas",a),(0,l.registerEngine)("svg",o);var s=ut,u=(0,r.__importDefault)(iF),c=(0,r.__importDefault)(lF),f=(0,r.__importDefault)(sF),h=(0,r.__importDefault)(uF),v=(0,r.__importDefault)(cF),d=(0,r.__importDefault)(Zp),p=(0,r.__importDefault)(fF),x=(0,r.__importDefault)(hF),m=(0,r.__importDefault)(vF),_=(0,r.__importDefault)(dF);(0,s.registerGeometry)("Polygon",x.default),(0,s.registerGeometry)("Interval",h.default),(0,s.registerGeometry)("Schema",m.default),(0,s.registerGeometry)("Path",d.default),(0,s.registerGeometry)("Point",p.default),(0,s.registerGeometry)("Line",v.default),(0,s.registerGeometry)("Area",u.default),(0,s.registerGeometry)("Edge",c.default),(0,s.registerGeometry)("Heatmap",f.default),(0,s.registerGeometry)("Violin",_.default);var b=ut,w=(0,r.__importDefault)(Oh),S=(0,r.__importDefault)(gF),M=(0,r.__importDefault)(yF),F=(0,r.__importDefault)(Z1);(0,b.registerGeometryLabel)("base",w.default),(0,b.registerGeometryLabel)("interval",S.default),(0,b.registerGeometryLabel)("pie",M.default),(0,b.registerGeometryLabel)("polar",F.default);var O=ut,L=Q1,D=K1,k=J1,H=t_,B=e_,j=Uf,U=r_,R=i_,G=a_,N=o_,W=l_,q=s_,tt=u_;(0,O.registerGeometryLabelLayout)("overlap",j.overlap),(0,O.registerGeometryLabelLayout)("distribute",L.distribute),(0,O.registerGeometryLabelLayout)("fixed-overlap",j.fixedOverlap),(0,O.registerGeometryLabelLayout)("hide-overlap",U.hideOverlap),(0,O.registerGeometryLabelLayout)("limit-in-shape",B.limitInShape),(0,O.registerGeometryLabelLayout)("limit-in-canvas",H.limitInCanvas),(0,O.registerGeometryLabelLayout)("limit-in-plot",tt.limitInPlot),(0,O.registerGeometryLabelLayout)("pie-outer",D.pieOuterLabelLayout),(0,O.registerGeometryLabelLayout)("adjust-color",R.adjustColor),(0,O.registerGeometryLabelLayout)("interval-adjust-position",G.intervalAdjustPosition),(0,O.registerGeometryLabelLayout)("interval-hide-overlap",N.intervalHideOverlap),(0,O.registerGeometryLabelLayout)("point-adjust-position",W.pointAdjustPosition),(0,O.registerGeometryLabelLayout)("pie-spider",k.pieSpiderLabelLayout),(0,O.registerGeometryLabelLayout)("path-adjust-position",q.pathAdjustPosition);var ot=jf,st=Jl,Z=W1,et=X1,lt=Yf,dt=U1,ht=q1,wt=Xf,gt=ut;(0,gt.registerAnimation)("fade-in",ot.fadeIn),(0,gt.registerAnimation)("fade-out",ot.fadeOut),(0,gt.registerAnimation)("grow-in-x",st.growInX),(0,gt.registerAnimation)("grow-in-xy",st.growInXY),(0,gt.registerAnimation)("grow-in-y",st.growInY),(0,gt.registerAnimation)("scale-in-x",lt.scaleInX),(0,gt.registerAnimation)("scale-in-y",lt.scaleInY),(0,gt.registerAnimation)("wave-in",ht.waveIn),(0,gt.registerAnimation)("zoom-in",wt.zoomIn),(0,gt.registerAnimation)("zoom-out",wt.zoomOut),(0,gt.registerAnimation)("position-update",et.positionUpdate),(0,gt.registerAnimation)("sector-path-update",dt.sectorPathUpdate),(0,gt.registerAnimation)("path-in",Z.pathIn);var vt=ut,_t=(0,r.__importDefault)(mF),Bt=(0,r.__importDefault)(xF),qt=(0,r.__importDefault)(_F),Nt=(0,r.__importDefault)(bF),pe=(0,r.__importDefault)(wF),cr=(0,r.__importDefault)(CF);(0,vt.registerFacet)("rect",pe.default),(0,vt.registerFacet)("mirror",Nt.default),(0,vt.registerFacet)("list",Bt.default),(0,vt.registerFacet)("matrix",qt.default),(0,vt.registerFacet)("circle",_t.default),(0,vt.registerFacet)("tree",cr.default);var ar=ut,Ji=(0,r.__importDefault)(IM),$r=(0,r.__importDefault)(SF),tn=(0,r.__importDefault)(AF),Yr=(0,r.__importDefault)(TF),Wr=(0,r.__importDefault)(z1),Ke=(0,r.__importDefault)(MF);(0,ar.registerComponentController)("axis",$r.default),(0,ar.registerComponentController)("legend",tn.default),(0,ar.registerComponentController)("tooltip",Wr.default),(0,ar.registerComponentController)("annotation",Ji.default),(0,ar.registerComponentController)("slider",Yr.default),(0,ar.registerComponentController)("scrollbar",Ke.default);var At=ut,yi=(0,r.__importDefault)(Jp),Hh=(0,r.__importDefault)(EF),_c=(0,r.__importDefault)(f_),Yh=(0,r.__importDefault)(FF),bc=(0,r.__importDefault)(OF),Bs=(0,r.__importDefault)(PF),dl=(0,r.__importDefault)(IF),So=(0,r.__importDefault)(LF),Ns=(0,r.__importDefault)(ng),Ig=(0,r.__importDefault)(DF),kb=(0,r.__importDefault)($F),Wh=(0,r.__importStar)(ag);Object.defineProperty(e,"ELEMENT_RANGE_HIGHLIGHT_EVENTS",{enumerable:!0,get:function(){return Wh.ELEMENT_RANGE_HIGHLIGHT_EVENTS}});var Rb=(0,r.__importDefault)(kF),Bb=(0,r.__importDefault)(RF),Xh=(0,r.__importDefault)(BF),Lg=(0,r.__importDefault)(NF),Nb=(0,r.__importDefault)(GF),Uh=(0,r.__importDefault)(zF),Gb=(0,r.__importDefault)(VF),Dg=(0,r.__importDefault)(jF),zb=(0,r.__importDefault)(HF),Vb=(0,r.__importDefault)(YF),wc=(0,r.__importDefault)(WF),qh=(0,r.__importDefault)(d_),pl=(0,r.__importDefault)(v_),Re=(0,r.__importDefault)(XF),Ue=(0,r.__importDefault)(UF),Ra=(0,r.__importDefault)(qF),or=(0,r.__importStar)(Lh);Object.defineProperty(e,"BRUSH_FILTER_EVENTS",{enumerable:!0,get:function(){return or.BRUSH_FILTER_EVENTS}});var kr=(0,r.__importDefault)(ZF),Ao=(0,r.__importDefault)(QF),To=(0,r.__importDefault)(KF),ni=(0,r.__importDefault)(JF),Cc=(0,r.__importDefault)(tO),$g=(0,r.__importDefault)(eO),kg=(0,r.__importDefault)(rO),Sc=(0,r.__importDefault)(iO),Rg=(0,r.__importDefault)(nO);(0,At.registerAction)("tooltip",_c.default),(0,At.registerAction)("sibling-tooltip",Hh.default),(0,At.registerAction)("ellipsis-text",Yh.default),(0,At.registerAction)("element-active",bc.default),(0,At.registerAction)("element-single-active",So.default),(0,At.registerAction)("element-range-active",dl.default),(0,At.registerAction)("element-highlight",Ns.default),(0,At.registerAction)("element-highlight-by-x",kb.default),(0,At.registerAction)("element-highlight-by-color",Ig.default),(0,At.registerAction)("element-single-highlight",Rb.default),(0,At.registerAction)("element-range-highlight",Wh.default),(0,At.registerAction)("element-sibling-highlight",Wh.default,{effectSiblings:!0,effectByRecord:!0}),(0,At.registerAction)("element-selected",Xh.default),(0,At.registerAction)("element-single-selected",Lg.default),(0,At.registerAction)("element-range-selected",Bb.default),(0,At.registerAction)("element-link-by-color",Bs.default),(0,At.registerAction)("active-region",yi.default),(0,At.registerAction)("list-active",Nb.default),(0,At.registerAction)("list-selected",Gb.default),(0,At.registerAction)("list-highlight",Uh.default),(0,At.registerAction)("list-unchecked",Dg.default),(0,At.registerAction)("list-checked",zb.default),(0,At.registerAction)("legend-item-highlight",Uh.default,{componentNames:["legend"]}),(0,At.registerAction)("axis-label-highlight",Uh.default,{componentNames:["axis"]}),(0,At.registerAction)("rect-mask",pl.default),(0,At.registerAction)("x-rect-mask",wc.default,{dim:"x"}),(0,At.registerAction)("y-rect-mask",wc.default,{dim:"y"}),(0,At.registerAction)("circle-mask",Vb.default),(0,At.registerAction)("path-mask",qh.default),(0,At.registerAction)("smooth-path-mask",Re.default),(0,At.registerAction)("cursor",Ue.default),(0,At.registerAction)("data-filter",Ra.default),(0,At.registerAction)("brush",or.default),(0,At.registerAction)("brush-x",or.default,{dims:["x"]}),(0,At.registerAction)("brush-y",or.default,{dims:["y"]}),(0,At.registerAction)("sibling-filter",kr.default),(0,At.registerAction)("sibling-x-filter",kr.default),(0,At.registerAction)("sibling-y-filter",kr.default),(0,At.registerAction)("element-filter",Ao.default),(0,At.registerAction)("element-sibling-filter",To.default),(0,At.registerAction)("element-sibling-filter-record",To.default,{byRecord:!0}),(0,At.registerAction)("view-drag",Cc.default),(0,At.registerAction)("view-move",$g.default),(0,At.registerAction)("scale-translate",kg.default),(0,At.registerAction)("scale-zoom",Sc.default),(0,At.registerAction)("reset-button",ni.default,{name:"reset-button",text:"reset"}),(0,At.registerAction)("mousewheel-scroll",Rg.default);var Le=ut;function En(ai){return ai.isInPlot()}(0,Le.registerInteraction)("tooltip",{start:[{trigger:"plot:mousemove",action:"tooltip:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"plot:touchmove",action:"tooltip:show",throttle:{wait:50,leading:!0,trailing:!1}}],end:[{trigger:"plot:mouseleave",action:"tooltip:hide"},{trigger:"plot:leave",action:"tooltip:hide"},{trigger:"plot:touchend",action:"tooltip:hide"}]}),(0,Le.registerInteraction)("ellipsis-text",{start:[{trigger:"legend-item-name:mousemove",action:"ellipsis-text:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"legend-item-name:touchstart",action:"ellipsis-text:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"axis-label:mousemove",action:"ellipsis-text:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"axis-label:touchstart",action:"ellipsis-text:show",throttle:{wait:50,leading:!0,trailing:!1}}],end:[{trigger:"legend-item-name:mouseleave",action:"ellipsis-text:hide"},{trigger:"legend-item-name:touchend",action:"ellipsis-text:hide"},{trigger:"axis-label:mouseleave",action:"ellipsis-text:hide"},{trigger:"axis-label:touchend",action:"ellipsis-text:hide"}]}),(0,Le.registerInteraction)("element-active",{start:[{trigger:"element:mouseenter",action:"element-active:active"}],end:[{trigger:"element:mouseleave",action:"element-active:reset"}]}),(0,Le.registerInteraction)("element-selected",{start:[{trigger:"element:click",action:"element-selected:toggle"}]}),(0,Le.registerInteraction)("element-highlight",{start:[{trigger:"element:mouseenter",action:"element-highlight:highlight"}],end:[{trigger:"element:mouseleave",action:"element-highlight:reset"}]}),(0,Le.registerInteraction)("element-highlight-by-x",{start:[{trigger:"element:mouseenter",action:"element-highlight-by-x:highlight"}],end:[{trigger:"element:mouseleave",action:"element-highlight-by-x:reset"}]}),(0,Le.registerInteraction)("element-highlight-by-color",{start:[{trigger:"element:mouseenter",action:"element-highlight-by-color:highlight"}],end:[{trigger:"element:mouseleave",action:"element-highlight-by-color:reset"}]}),(0,Le.registerInteraction)("legend-active",{start:[{trigger:"legend-item:mouseenter",action:["list-active:active","element-active:active"]}],end:[{trigger:"legend-item:mouseleave",action:["list-active:reset","element-active:reset"]}]}),(0,Le.registerInteraction)("legend-highlight",{start:[{trigger:"legend-item:mouseenter",action:["legend-item-highlight:highlight","element-highlight:highlight"]}],end:[{trigger:"legend-item:mouseleave",action:["legend-item-highlight:reset","element-highlight:reset"]}]}),(0,Le.registerInteraction)("axis-label-highlight",{start:[{trigger:"axis-label:mouseenter",action:["axis-label-highlight:highlight","element-highlight:highlight"]}],end:[{trigger:"axis-label:mouseleave",action:["axis-label-highlight:reset","element-highlight:reset"]}]}),(0,Le.registerInteraction)("element-list-highlight",{start:[{trigger:"element:mouseenter",action:["list-highlight:highlight","element-highlight:highlight"]}],end:[{trigger:"element:mouseleave",action:["list-highlight:reset","element-highlight:reset"]}]}),(0,Le.registerInteraction)("element-range-highlight",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"mask:mouseenter",action:"cursor:move"},{trigger:"plot:mouseleave",action:"cursor:default"},{trigger:"mask:mouseleave",action:"cursor:crosshair"}],start:[{trigger:"plot:mousedown",isEnable:function(ai){return!ai.isInShape("mask")},action:["rect-mask:start","rect-mask:show"]},{trigger:"mask:dragstart",action:["rect-mask:moveStart"]}],processing:[{trigger:"plot:mousemove",action:["rect-mask:resize"]},{trigger:"mask:drag",action:["rect-mask:move"]},{trigger:"mask:change",action:["element-range-highlight:highlight"]}],end:[{trigger:"plot:mouseup",action:["rect-mask:end"]},{trigger:"mask:dragend",action:["rect-mask:moveEnd"]},{trigger:"document:mouseup",isEnable:function(ai){return!ai.isInPlot()},action:["element-range-highlight:clear","rect-mask:end","rect-mask:hide"]}],rollback:[{trigger:"dblclick",action:["element-range-highlight:clear","rect-mask:hide"]}]}),(0,Le.registerInteraction)("brush",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"mousedown",isEnable:En,action:["brush:start","rect-mask:start","rect-mask:show"]}],processing:[{trigger:"mousemove",isEnable:En,action:["rect-mask:resize"]}],end:[{trigger:"mouseup",isEnable:En,action:["brush:filter","brush:end","rect-mask:end","rect-mask:hide","reset-button:show"]}],rollback:[{trigger:"reset-button:click",action:["brush:reset","reset-button:hide","cursor:crosshair"]}]}),(0,Le.registerInteraction)("brush-visible",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"plot:mousedown",action:["rect-mask:start","rect-mask:show"]}],processing:[{trigger:"plot:mousemove",action:["rect-mask:resize"]},{trigger:"mask:change",action:["element-range-highlight:highlight"]}],end:[{trigger:"plot:mouseup",action:["rect-mask:end","rect-mask:hide","element-filter:filter","element-range-highlight:clear"]}],rollback:[{trigger:"dblclick",action:["element-filter:clear"]}]}),(0,Le.registerInteraction)("brush-x",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"mousedown",isEnable:En,action:["brush-x:start","x-rect-mask:start","x-rect-mask:show"]}],processing:[{trigger:"mousemove",isEnable:En,action:["x-rect-mask:resize"]}],end:[{trigger:"mouseup",isEnable:En,action:["brush-x:filter","brush-x:end","x-rect-mask:end","x-rect-mask:hide"]}],rollback:[{trigger:"dblclick",action:["brush-x:reset"]}]}),(0,Le.registerInteraction)("element-path-highlight",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"mousedown",isEnable:En,action:"path-mask:start"},{trigger:"mousedown",isEnable:En,action:"path-mask:show"}],processing:[{trigger:"mousemove",action:"path-mask:addPoint"}],end:[{trigger:"mouseup",action:"path-mask:end"}],rollback:[{trigger:"dblclick",action:"path-mask:hide"}]}),(0,Le.registerInteraction)("element-single-selected",{start:[{trigger:"element:click",action:"element-single-selected:toggle"}]}),(0,Le.registerInteraction)("legend-filter",{showEnable:[{trigger:"legend-item:mouseenter",action:"cursor:pointer"},{trigger:"legend-item:mouseleave",action:"cursor:default"}],start:[{trigger:"legend-item:click",action:["list-unchecked:toggle","data-filter:filter"]}]}),(0,Le.registerInteraction)("continuous-filter",{start:[{trigger:"legend:valuechanged",action:"data-filter:filter"}]}),(0,Le.registerInteraction)("continuous-visible-filter",{start:[{trigger:"legend:valuechanged",action:"element-filter:filter"}]}),(0,Le.registerInteraction)("legend-visible-filter",{showEnable:[{trigger:"legend-item:mouseenter",action:"cursor:pointer"},{trigger:"legend-item:mouseleave",action:"cursor:default"}],start:[{trigger:"legend-item:click",action:["list-unchecked:toggle","element-filter:filter"]}]}),(0,Le.registerInteraction)("active-region",{start:[{trigger:"plot:mousemove",action:"active-region:show"}],end:[{trigger:"plot:mouseleave",action:"active-region:hide"}]});function Zh(ai){return ai.gEvent.preventDefault(),ai.gEvent.originalEvent.deltaY>0}(0,Le.registerInteraction)("view-zoom",{start:[{trigger:"plot:mousewheel",isEnable:function(ai){return Zh(ai.event)},action:"scale-zoom:zoomOut",throttle:{wait:100,leading:!0,trailing:!1}},{trigger:"plot:mousewheel",isEnable:function(ai){return!Zh(ai.event)},action:"scale-zoom:zoomIn",throttle:{wait:100,leading:!0,trailing:!1}}]}),(0,Le.registerInteraction)("sibling-tooltip",{start:[{trigger:"plot:mousemove",action:"sibling-tooltip:show"}],end:[{trigger:"plot:mouseleave",action:"sibling-tooltip:hide"}]}),(0,Le.registerInteraction)("plot-mousewheel-scroll",{start:[{trigger:"plot:mousewheel",action:"mousewheel-scroll:scroll"}]});var Bg=Jt;Object.defineProperty(e,"VIEW_LIFE_CIRCLE",{enumerable:!0,get:function(){return Bg.VIEW_LIFE_CIRCLE}}),(0,r.__exportStar)(ut,e)})(gj);var rY={exports:{}},iY={exports:{}},nY={exports:{}},aY={};/** @license React v0.19.1
|
|
* scheduler.production.min.js
|
|
*
|
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
*
|
|
* This source code is licensed under the MIT license found in the
|
|
* LICENSE file in the root directory of this source tree.
|
|
*/(function(e){var r,t,i,n,a;if(typeof window=="undefined"||typeof MessageChannel!="function"){var o=null,l=null,s=function(){if(o!==null)try{var Z=e.unstable_now();o(!0,Z),o=null}catch(et){throw setTimeout(s,0),et}},u=Date.now();e.unstable_now=function(){return Date.now()-u},r=function(Z){o!==null?setTimeout(r,0,Z):(o=Z,setTimeout(s,0))},t=function(Z,et){l=setTimeout(Z,et)},i=function(){clearTimeout(l)},n=function(){return!1},a=e.unstable_forceFrameRate=function(){}}else{var c=window.performance,f=window.Date,h=window.setTimeout,v=window.clearTimeout;if(typeof console!="undefined"){var d=window.cancelAnimationFrame;typeof window.requestAnimationFrame!="function"&&console.error("This browser doesn't support requestAnimationFrame. Make sure that you load a polyfill in older browsers. https://fb.me/react-polyfills"),typeof d!="function"&&console.error("This browser doesn't support cancelAnimationFrame. Make sure that you load a polyfill in older browsers. https://fb.me/react-polyfills")}if(typeof c=="object"&&typeof c.now=="function")e.unstable_now=function(){return c.now()};else{var p=f.now();e.unstable_now=function(){return f.now()-p}}var x=!1,m=null,_=-1,b=5,w=0;n=function(){return e.unstable_now()>=w},a=function(){},e.unstable_forceFrameRate=function(Z){0>Z||125<Z?console.error("forceFrameRate takes a positive int between 0 and 125, forcing framerates higher than 125 fps is not unsupported"):b=0<Z?Math.floor(1e3/Z):5};var S=new MessageChannel,M=S.port2;S.port1.onmessage=function(){if(m!==null){var Z=e.unstable_now();w=Z+b;try{m(!0,Z)?M.postMessage(null):(x=!1,m=null)}catch(et){throw M.postMessage(null),et}}else x=!1},r=function(Z){m=Z,x||(x=!0,M.postMessage(null))},t=function(Z,et){_=h(function(){Z(e.unstable_now())},et)},i=function(){v(_),_=-1}}function F(Z,et){var lt=Z.length;Z.push(et);t:for(;;){var dt=lt-1>>>1,ht=Z[dt];if(ht!==void 0&&0<D(ht,et))Z[dt]=et,Z[lt]=ht,lt=dt;else break t}}function O(Z){return Z=Z[0],Z===void 0?null:Z}function L(Z){var et=Z[0];if(et!==void 0){var lt=Z.pop();if(lt!==et){Z[0]=lt;t:for(var dt=0,ht=Z.length;dt<ht;){var wt=2*(dt+1)-1,gt=Z[wt],vt=wt+1,_t=Z[vt];if(gt!==void 0&&0>D(gt,lt))_t!==void 0&&0>D(_t,gt)?(Z[dt]=_t,Z[vt]=lt,dt=vt):(Z[dt]=gt,Z[wt]=lt,dt=wt);else if(_t!==void 0&&0>D(_t,lt))Z[dt]=_t,Z[vt]=lt,dt=vt;else break t}}return et}return null}function D(Z,et){var lt=Z.sortIndex-et.sortIndex;return lt!==0?lt:Z.id-et.id}var k=[],H=[],B=1,j=null,U=3,R=!1,G=!1,N=!1;function W(Z){for(var et=O(H);et!==null;){if(et.callback===null)L(H);else if(et.startTime<=Z)L(H),et.sortIndex=et.expirationTime,F(k,et);else break;et=O(H)}}function q(Z){if(N=!1,W(Z),!G)if(O(k)!==null)G=!0,r(tt);else{var et=O(H);et!==null&&t(q,et.startTime-Z)}}function tt(Z,et){G=!1,N&&(N=!1,i()),R=!0;var lt=U;try{for(W(et),j=O(k);j!==null&&(!(j.expirationTime>et)||Z&&!n());){var dt=j.callback;if(dt!==null){j.callback=null,U=j.priorityLevel;var ht=dt(j.expirationTime<=et);et=e.unstable_now(),typeof ht=="function"?j.callback=ht:j===O(k)&&L(k),W(et)}else L(k);j=O(k)}if(j!==null)var wt=!0;else{var gt=O(H);gt!==null&&t(q,gt.startTime-et),wt=!1}return wt}finally{j=null,U=lt,R=!1}}function ot(Z){switch(Z){case 1:return-1;case 2:return 250;case 5:return 1073741823;case 4:return 1e4;default:return 5e3}}var st=a;e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(Z){Z.callback=null},e.unstable_continueExecution=function(){G||R||(G=!0,r(tt))},e.unstable_getCurrentPriorityLevel=function(){return U},e.unstable_getFirstCallbackNode=function(){return O(k)},e.unstable_next=function(Z){switch(U){case 1:case 2:case 3:var et=3;break;default:et=U}var lt=U;U=et;try{return Z()}finally{U=lt}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=st,e.unstable_runWithPriority=function(Z,et){switch(Z){case 1:case 2:case 3:case 4:case 5:break;default:Z=3}var lt=U;U=Z;try{return et()}finally{U=lt}},e.unstable_scheduleCallback=function(Z,et,lt){var dt=e.unstable_now();if(typeof lt=="object"&<!==null){var ht=lt.delay;ht=typeof ht=="number"&&0<ht?dt+ht:dt,lt=typeof lt.timeout=="number"?lt.timeout:ot(Z)}else lt=ot(Z),ht=dt;return lt=ht+lt,Z={id:B++,callback:et,priorityLevel:Z,startTime:ht,expirationTime:lt,sortIndex:-1},ht>dt?(Z.sortIndex=ht,F(H,Z),O(k)===null&&Z===O(H)&&(N?i():N=!0,t(q,ht-dt))):(Z.sortIndex=lt,F(k,Z),G||R||(G=!0,r(tt))),Z},e.unstable_shouldYield=function(){var Z=e.unstable_now();W(Z);var et=O(k);return et!==j&&j!==null&&et!==null&&et.callback!==null&&et.startTime<=Z&&et.expirationTime<j.expirationTime||n()},e.unstable_wrapCallback=function(Z){var et=U;return function(){var lt=U;U=et;try{return Z.apply(this,arguments)}finally{U=lt}}}})(aY);nY.exports=aY;/** @license React v0.25.1
|
|
* react-reconciler.production.min.js
|
|
*
|
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
*
|
|
* This source code is licensed under the MIT license found in the
|
|
* LICENSE file in the root directory of this source tree.
|
|
*/(function(e){e.exports=function r(t){var i=d8,n=Ur.exports,a=nY.exports;function o(g){for(var y="https://reactjs.org/docs/error-decoder.html?invariant="+g,C=1;C<arguments.length;C++)y+="&args[]="+encodeURIComponent(arguments[C]);return"Minified React error #"+g+"; visit "+y+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var l=n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;l.hasOwnProperty("ReactCurrentDispatcher")||(l.ReactCurrentDispatcher={current:null}),l.hasOwnProperty("ReactCurrentBatchConfig")||(l.ReactCurrentBatchConfig={suspense:null});var s=typeof Symbol=="function"&&Symbol.for,u=s?Symbol.for("react.element"):60103,c=s?Symbol.for("react.portal"):60106,f=s?Symbol.for("react.fragment"):60107,h=s?Symbol.for("react.strict_mode"):60108,v=s?Symbol.for("react.profiler"):60114,d=s?Symbol.for("react.provider"):60109,p=s?Symbol.for("react.context"):60110,x=s?Symbol.for("react.concurrent_mode"):60111,m=s?Symbol.for("react.forward_ref"):60112,_=s?Symbol.for("react.suspense"):60113,b=s?Symbol.for("react.suspense_list"):60120,w=s?Symbol.for("react.memo"):60115,S=s?Symbol.for("react.lazy"):60116,M=s?Symbol.for("react.block"):60121,F=typeof Symbol=="function"&&Symbol.iterator;function O(g){return g===null||typeof g!="object"?null:(g=F&&g[F]||g["@@iterator"],typeof g=="function"?g:null)}function L(g){if(g._status===-1){g._status=0;var y=g._ctor;y=y(),g._result=y,y.then(function(C){g._status===0&&(C=C.default,g._status=1,g._result=C)},function(C){g._status===0&&(g._status=2,g._result=C)})}}function D(g){if(g==null)return null;if(typeof g=="function")return g.displayName||g.name||null;if(typeof g=="string")return g;switch(g){case f:return"Fragment";case c:return"Portal";case v:return"Profiler";case h:return"StrictMode";case _:return"Suspense";case b:return"SuspenseList"}if(typeof g=="object")switch(g.$$typeof){case p:return"Context.Consumer";case d:return"Context.Provider";case m:var y=g.render;return y=y.displayName||y.name||"",g.displayName||(y!==""?"ForwardRef("+y+")":"ForwardRef");case w:return D(g.type);case M:return D(g.render);case S:if(g=g._status===1?g._result:null)return D(g)}return null}function k(g){var y=g,C=g;if(g.alternate)for(;y.return;)y=y.return;else{g=y;do y=g,(y.effectTag&1026)!==0&&(C=y.return),g=y.return;while(g)}return y.tag===3?C:null}function H(g){if(k(g)!==g)throw Error(o(188))}function B(g){var y=g.alternate;if(!y){if(y=k(g),y===null)throw Error(o(188));return y!==g?null:g}for(var C=g,T=y;;){var E=C.return;if(E===null)break;var $=E.alternate;if($===null){if(T=E.return,T!==null){C=T;continue}break}if(E.child===$.child){for($=E.child;$;){if($===C)return H(E),g;if($===T)return H(E),y;$=$.sibling}throw Error(o(188))}if(C.return!==T.return)C=E,T=$;else{for(var z=!1,nt=E.child;nt;){if(nt===C){z=!0,C=E,T=$;break}if(nt===T){z=!0,T=E,C=$;break}nt=nt.sibling}if(!z){for(nt=$.child;nt;){if(nt===C){z=!0,C=$,T=E;break}if(nt===T){z=!0,T=$,C=E;break}nt=nt.sibling}if(!z)throw Error(o(189))}}if(C.alternate!==T)throw Error(o(190))}if(C.tag!==3)throw Error(o(188));return C.stateNode.current===C?g:y}function j(g){if(g=B(g),!g)return null;for(var y=g;;){if(y.tag===5||y.tag===6)return y;if(y.child)y.child.return=y,y=y.child;else{if(y===g)break;for(;!y.sibling;){if(!y.return||y.return===g)return null;y=y.return}y.sibling.return=y.return,y=y.sibling}}return null}function U(g){if(g=B(g),!g)return null;for(var y=g;;){if(y.tag===5||y.tag===6)return y;if(y.child&&y.tag!==4)y.child.return=y,y=y.child;else{if(y===g)break;for(;!y.sibling;){if(!y.return||y.return===g)return null;y=y.return}y.sibling.return=y.return,y=y.sibling}}return null}var R=t.getPublicInstance,G=t.getRootHostContext,N=t.getChildHostContext,W=t.prepareForCommit,q=t.resetAfterCommit,tt=t.createInstance,ot=t.appendInitialChild,st=t.finalizeInitialChildren,Z=t.prepareUpdate,et=t.shouldSetTextContent,lt=t.shouldDeprioritizeSubtree,dt=t.createTextInstance,ht=t.setTimeout,wt=t.clearTimeout,gt=t.noTimeout,vt=t.isPrimaryRenderer,_t=t.supportsMutation,Bt=t.supportsPersistence,qt=t.supportsHydration,Nt=t.appendChild,pe=t.appendChildToContainer,cr=t.commitTextUpdate,ar=t.commitMount,Ji=t.commitUpdate,$r=t.insertBefore,tn=t.insertInContainerBefore,Yr=t.removeChild,Wr=t.removeChildFromContainer,Ke=t.resetTextContent,At=t.hideInstance,yi=t.hideTextInstance,Hh=t.unhideInstance,_c=t.unhideTextInstance,Yh=t.cloneInstance,bc=t.createContainerChildSet,Bs=t.appendChildToContainerChildSet,dl=t.finalizeContainerChildren,So=t.replaceContainerChildren,Ns=t.cloneHiddenInstance,Ig=t.cloneHiddenTextInstance,kb=t.canHydrateInstance,Wh=t.canHydrateTextInstance,Rb=t.isSuspenseInstancePending,Bb=t.isSuspenseInstanceFallback,Xh=t.getNextHydratableSibling,Lg=t.getFirstHydratableChild,Nb=t.hydrateInstance,Uh=t.hydrateTextInstance,Gb=t.getNextHydratableInstanceAfterSuspenseInstance,Dg=t.commitHydratedContainer,zb=t.commitHydratedSuspenseInstance,Vb=/^(.*)[\\\/]/;function wc(g){var y="";do{t:switch(g.tag){case 3:case 4:case 6:case 7:case 10:case 9:var C="";break t;default:var T=g._debugOwner,E=g._debugSource,$=D(g.type);C=null,T&&(C=D(T.type)),T=$,$="",E?$=" (at "+E.fileName.replace(Vb,"")+":"+E.lineNumber+")":C&&($=" (created by "+C+")"),C=`
|
|
in `+(T||"Unknown")+$}y+=C,g=g.return}while(g);return y}var qh=[],pl=-1;function Re(g){0>pl||(g.current=qh[pl],qh[pl]=null,pl--)}function Ue(g,y){pl++,qh[pl]=g.current,g.current=y}var Ra={},or={current:Ra},kr={current:!1},Ao=Ra;function To(g,y){var C=g.type.contextTypes;if(!C)return Ra;var T=g.stateNode;if(T&&T.__reactInternalMemoizedUnmaskedChildContext===y)return T.__reactInternalMemoizedMaskedChildContext;var E={},$;for($ in C)E[$]=y[$];return T&&(g=g.stateNode,g.__reactInternalMemoizedUnmaskedChildContext=y,g.__reactInternalMemoizedMaskedChildContext=E),E}function ni(g){return g=g.childContextTypes,g!=null}function Cc(){Re(kr),Re(or)}function $g(g,y,C){if(or.current!==Ra)throw Error(o(168));Ue(or,y),Ue(kr,C)}function kg(g,y,C){var T=g.stateNode;if(g=y.childContextTypes,typeof T.getChildContext!="function")return C;T=T.getChildContext();for(var E in T)if(!(E in g))throw Error(o(108,D(y)||"Unknown",E));return i({},C,{},T)}function Sc(g){return g=(g=g.stateNode)&&g.__reactInternalMemoizedMergedChildContext||Ra,Ao=or.current,Ue(or,g),Ue(kr,kr.current),!0}function Rg(g,y,C){var T=g.stateNode;if(!T)throw Error(o(169));C?(g=kg(g,y,Ao),T.__reactInternalMemoizedMergedChildContext=g,Re(kr),Re(or),Ue(or,g)):Re(kr),Ue(kr,C)}var Le=a.unstable_runWithPriority,En=a.unstable_scheduleCallback,Zh=a.unstable_cancelCallback,Bg=a.unstable_requestPaint,ai=a.unstable_now,IU=a.unstable_getCurrentPriorityLevel,Ng=a.unstable_ImmediatePriority,hI=a.unstable_UserBlockingPriority,vI=a.unstable_NormalPriority,dI=a.unstable_LowPriority,pI=a.unstable_IdlePriority,gI={},LU=a.unstable_shouldYield,DU=Bg!==void 0?Bg:function(){},Mo=null,Gg=null,jb=!1,yI=ai(),Fn=1e4>yI?ai:function(){return ai()-yI};function zg(){switch(IU()){case Ng:return 99;case hI:return 98;case vI:return 97;case dI:return 96;case pI:return 95;default:throw Error(o(332))}}function mI(g){switch(g){case 99:return Ng;case 98:return hI;case 97:return vI;case 96:return dI;case 95:return pI;default:throw Error(o(332))}}function ia(g,y){return g=mI(g),Le(g,y)}function xI(g,y,C){return g=mI(g),En(g,y,C)}function _I(g){return Mo===null?(Mo=[g],Gg=En(Ng,bI)):Mo.push(g),gI}function On(){if(Gg!==null){var g=Gg;Gg=null,Zh(g)}bI()}function bI(){if(!jb&&Mo!==null){jb=!0;var g=0;try{var y=Mo;ia(99,function(){for(;g<y.length;g++){var C=y[g];do C=C(!0);while(C!==null)}}),Mo=null}catch(C){throw Mo!==null&&(Mo=Mo.slice(g+1)),En(Ng,On),C}finally{jb=!1}}}function Qh(g,y,C){return C/=10,1073741821-(((1073741821-g+y/10)/C|0)+1)*C}function $U(g,y){return g===y&&(g!==0||1/g===1/y)||g!==g&&y!==y}var Gs=typeof Object.is=="function"?Object.is:$U,kU=Object.prototype.hasOwnProperty;function Vg(g,y){if(Gs(g,y))return!0;if(typeof g!="object"||g===null||typeof y!="object"||y===null)return!1;var C=Object.keys(g),T=Object.keys(y);if(C.length!==T.length)return!1;for(T=0;T<C.length;T++)if(!kU.call(y,C[T])||!Gs(g[C[T]],y[C[T]]))return!1;return!0}function na(g,y){if(g&&g.defaultProps){y=i({},y),g=g.defaultProps;for(var C in g)y[C]===void 0&&(y[C]=g[C])}return y}var jg={current:null},Hg=null,Ac=null,Yg=null;function Hb(){Yg=Ac=Hg=null}function wI(g,y){g=g.type._context,vt?(Ue(jg,g._currentValue),g._currentValue=y):(Ue(jg,g._currentValue2),g._currentValue2=y)}function Yb(g){var y=jg.current;Re(jg),g=g.type._context,vt?g._currentValue=y:g._currentValue2=y}function CI(g,y){for(;g!==null;){var C=g.alternate;if(g.childExpirationTime<y)g.childExpirationTime=y,C!==null&&C.childExpirationTime<y&&(C.childExpirationTime=y);else if(C!==null&&C.childExpirationTime<y)C.childExpirationTime=y;else break;g=g.return}}function Tc(g,y){Hg=g,Yg=Ac=null,g=g.dependencies,g!==null&&g.firstContext!==null&&(g.expirationTime>=y&&(Na=!0),g.firstContext=null)}function Pn(g,y){if(Yg!==g&&y!==!1&&y!==0)if((typeof y!="number"||y===1073741823)&&(Yg=g,y=1073741823),y={context:g,observedBits:y,next:null},Ac===null){if(Hg===null)throw Error(o(308));Ac=y,Hg.dependencies={expirationTime:0,firstContext:y,responders:null}}else Ac=Ac.next=y;return vt?g._currentValue:g._currentValue2}var gl=!1;function Wb(g){g.updateQueue={baseState:g.memoizedState,baseQueue:null,shared:{pending:null},effects:null}}function Xb(g,y){g=g.updateQueue,y.updateQueue===g&&(y.updateQueue={baseState:g.baseState,baseQueue:g.baseQueue,shared:g.shared,effects:g.effects})}function yl(g,y){return g={expirationTime:g,suspenseConfig:y,tag:0,payload:null,callback:null,next:null},g.next=g}function ml(g,y){if(g=g.updateQueue,g!==null){g=g.shared;var C=g.pending;C===null?y.next=y:(y.next=C.next,C.next=y),g.pending=y}}function SI(g,y){var C=g.alternate;C!==null&&Xb(C,g),g=g.updateQueue,C=g.baseQueue,C===null?(g.baseQueue=y.next=y,y.next=y):(y.next=C.next,C.next=y)}function Kh(g,y,C,T){var E=g.updateQueue;gl=!1;var $=E.baseQueue,z=E.shared.pending;if(z!==null){if($!==null){var nt=$.next;$.next=z.next,z.next=nt}$=z,E.shared.pending=null,nt=g.alternate,nt!==null&&(nt=nt.updateQueue,nt!==null&&(nt.baseQueue=z))}if($!==null){nt=$.next;var yt=E.baseState,bt=0,Te=null,Wt=null,oe=null;if(nt!==null){var we=nt;do{if(z=we.expirationTime,z<T){var an={expirationTime:we.expirationTime,suspenseConfig:we.suspenseConfig,tag:we.tag,payload:we.payload,callback:we.callback,next:null};oe===null?(Wt=oe=an,Te=yt):oe=oe.next=an,z>bt&&(bt=z)}else{oe!==null&&(oe=oe.next={expirationTime:1073741823,suspenseConfig:we.suspenseConfig,tag:we.tag,payload:we.payload,callback:we.callback,next:null}),m2(z,we.suspenseConfig);t:{var hr=g,rt=we;switch(z=y,an=C,rt.tag){case 1:if(hr=rt.payload,typeof hr=="function"){yt=hr.call(an,yt,z);break t}yt=hr;break t;case 3:hr.effectTag=hr.effectTag&-4097|64;case 0:if(hr=rt.payload,z=typeof hr=="function"?hr.call(an,yt,z):hr,z==null)break t;yt=i({},yt,z);break t;case 2:gl=!0}}we.callback!==null&&(g.effectTag|=32,z=E.effects,z===null?E.effects=[we]:z.push(we))}if(we=we.next,we===null||we===nt){if(z=E.shared.pending,z===null)break;we=$.next=z.next,z.next=nt,E.baseQueue=$=z,E.shared.pending=null}}while(1)}oe===null?Te=yt:oe.next=Wt,E.baseState=Te,E.baseQueue=oe,by(bt),g.expirationTime=bt,g.memoizedState=yt}}function AI(g,y,C){if(g=y.effects,y.effects=null,g!==null)for(y=0;y<g.length;y++){var T=g[y],E=T.callback;if(E!==null){if(T.callback=null,T=E,E=C,typeof T!="function")throw Error(o(191,T));T.call(E)}}}var Jh=l.ReactCurrentBatchConfig,TI=new n.Component().refs;function Wg(g,y,C,T){y=g.memoizedState,C=C(T,y),C=C==null?y:i({},y,C),g.memoizedState=C,g.expirationTime===0&&(g.updateQueue.baseState=C)}var Xg={isMounted:function(g){return(g=g._reactInternalFiber)?k(g)===g:!1},enqueueSetState:function(g,y,C){g=g._reactInternalFiber;var T=oa(),E=Jh.suspense;T=Ws(T,g,E),E=yl(T,E),E.payload=y,C!=null&&(E.callback=C),ml(g,E),Po(g,T)},enqueueReplaceState:function(g,y,C){g=g._reactInternalFiber;var T=oa(),E=Jh.suspense;T=Ws(T,g,E),E=yl(T,E),E.tag=1,E.payload=y,C!=null&&(E.callback=C),ml(g,E),Po(g,T)},enqueueForceUpdate:function(g,y){g=g._reactInternalFiber;var C=oa(),T=Jh.suspense;C=Ws(C,g,T),T=yl(C,T),T.tag=2,y!=null&&(T.callback=y),ml(g,T),Po(g,C)}};function MI(g,y,C,T,E,$,z){return g=g.stateNode,typeof g.shouldComponentUpdate=="function"?g.shouldComponentUpdate(T,$,z):y.prototype&&y.prototype.isPureReactComponent?!Vg(C,T)||!Vg(E,$):!0}function EI(g,y,C){var T=!1,E=Ra,$=y.contextType;return typeof $=="object"&&$!==null?$=Pn($):(E=ni(y)?Ao:or.current,T=y.contextTypes,$=(T=T!=null)?To(g,E):Ra),y=new y(C,$),g.memoizedState=y.state!==null&&y.state!==void 0?y.state:null,y.updater=Xg,g.stateNode=y,y._reactInternalFiber=g,T&&(g=g.stateNode,g.__reactInternalMemoizedUnmaskedChildContext=E,g.__reactInternalMemoizedMaskedChildContext=$),y}function FI(g,y,C,T){g=y.state,typeof y.componentWillReceiveProps=="function"&&y.componentWillReceiveProps(C,T),typeof y.UNSAFE_componentWillReceiveProps=="function"&&y.UNSAFE_componentWillReceiveProps(C,T),y.state!==g&&Xg.enqueueReplaceState(y,y.state,null)}function Ub(g,y,C,T){var E=g.stateNode;E.props=C,E.state=g.memoizedState,E.refs=TI,Wb(g);var $=y.contextType;typeof $=="object"&&$!==null?E.context=Pn($):($=ni(y)?Ao:or.current,E.context=To(g,$)),Kh(g,C,E,T),E.state=g.memoizedState,$=y.getDerivedStateFromProps,typeof $=="function"&&(Wg(g,y,$,C),E.state=g.memoizedState),typeof y.getDerivedStateFromProps=="function"||typeof E.getSnapshotBeforeUpdate=="function"||typeof E.UNSAFE_componentWillMount!="function"&&typeof E.componentWillMount!="function"||(y=E.state,typeof E.componentWillMount=="function"&&E.componentWillMount(),typeof E.UNSAFE_componentWillMount=="function"&&E.UNSAFE_componentWillMount(),y!==E.state&&Xg.enqueueReplaceState(E,E.state,null),Kh(g,C,E,T),E.state=g.memoizedState),typeof E.componentDidMount=="function"&&(g.effectTag|=4)}var Ug=Array.isArray;function tv(g,y,C){if(g=C.ref,g!==null&&typeof g!="function"&&typeof g!="object"){if(C._owner){if(C=C._owner,C){if(C.tag!==1)throw Error(o(309));var T=C.stateNode}if(!T)throw Error(o(147,g));var E=""+g;return y!==null&&y.ref!==null&&typeof y.ref=="function"&&y.ref._stringRef===E?y.ref:(y=function($){var z=T.refs;z===TI&&(z=T.refs={}),$===null?delete z[E]:z[E]=$},y._stringRef=E,y)}if(typeof g!="string")throw Error(o(284));if(!C._owner)throw Error(o(290,g))}return g}function qg(g,y){if(g.type!=="textarea")throw Error(o(31,Object.prototype.toString.call(y)==="[object Object]"?"object with keys {"+Object.keys(y).join(", ")+"}":y,""))}function OI(g){function y(rt,Q){if(g){var at=rt.lastEffect;at!==null?(at.nextEffect=Q,rt.lastEffect=Q):rt.firstEffect=rt.lastEffect=Q,Q.nextEffect=null,Q.effectTag=8}}function C(rt,Q){if(!g)return null;for(;Q!==null;)y(rt,Q),Q=Q.sibling;return null}function T(rt,Q){for(rt=new Map;Q!==null;)Q.key!==null?rt.set(Q.key,Q):rt.set(Q.index,Q),Q=Q.sibling;return rt}function E(rt,Q){return rt=Qs(rt,Q),rt.index=0,rt.sibling=null,rt}function $(rt,Q,at){return rt.index=at,g?(at=rt.alternate,at!==null?(at=at.index,at<Q?(rt.effectTag=2,Q):at):(rt.effectTag=2,Q)):Q}function z(rt){return g&&rt.alternate===null&&(rt.effectTag=2),rt}function nt(rt,Q,at,St){return Q===null||Q.tag!==6?(Q=Fw(at,rt.mode,St),Q.return=rt,Q):(Q=E(Q,at),Q.return=rt,Q)}function yt(rt,Q,at,St){return Q!==null&&Q.elementType===at.type?(St=E(Q,at.props),St.ref=tv(rt,Q,at),St.return=rt,St):(St=Cy(at.type,at.key,at.props,null,rt.mode,St),St.ref=tv(rt,Q,at),St.return=rt,St)}function bt(rt,Q,at,St){return Q===null||Q.tag!==4||Q.stateNode.containerInfo!==at.containerInfo||Q.stateNode.implementation!==at.implementation?(Q=Ow(at,rt.mode,St),Q.return=rt,Q):(Q=E(Q,at.children||[]),Q.return=rt,Q)}function Te(rt,Q,at,St,$t){return Q===null||Q.tag!==7?(Q=bl(at,rt.mode,St,$t),Q.return=rt,Q):(Q=E(Q,at),Q.return=rt,Q)}function Wt(rt,Q,at){if(typeof Q=="string"||typeof Q=="number")return Q=Fw(""+Q,rt.mode,at),Q.return=rt,Q;if(typeof Q=="object"&&Q!==null){switch(Q.$$typeof){case u:return at=Cy(Q.type,Q.key,Q.props,null,rt.mode,at),at.ref=tv(rt,null,Q),at.return=rt,at;case c:return Q=Ow(Q,rt.mode,at),Q.return=rt,Q}if(Ug(Q)||O(Q))return Q=bl(Q,rt.mode,at,null),Q.return=rt,Q;qg(rt,Q)}return null}function oe(rt,Q,at,St){var $t=Q!==null?Q.key:null;if(typeof at=="string"||typeof at=="number")return $t!==null?null:nt(rt,Q,""+at,St);if(typeof at=="object"&&at!==null){switch(at.$$typeof){case u:return at.key===$t?at.type===f?Te(rt,Q,at.props.children,St,$t):yt(rt,Q,at,St):null;case c:return at.key===$t?bt(rt,Q,at,St):null}if(Ug(at)||O(at))return $t!==null?null:Te(rt,Q,at,St,null);qg(rt,at)}return null}function we(rt,Q,at,St,$t){if(typeof St=="string"||typeof St=="number")return rt=rt.get(at)||null,nt(Q,rt,""+St,$t);if(typeof St=="object"&&St!==null){switch(St.$$typeof){case u:return rt=rt.get(St.key===null?at:St.key)||null,St.type===f?Te(Q,rt,St.props.children,$t,St.key):yt(Q,rt,St,$t);case c:return rt=rt.get(St.key===null?at:St.key)||null,bt(Q,rt,St,$t)}if(Ug(St)||O(St))return rt=rt.get(at)||null,Te(Q,rt,St,$t,null);qg(Q,St)}return null}function an(rt,Q,at,St){for(var $t=null,Be=null,zt=Q,Me=Q=0,vr=null;zt!==null&&Me<at.length;Me++){zt.index>Me?(vr=zt,zt=null):vr=zt.sibling;var fe=oe(rt,zt,at[Me],St);if(fe===null){zt===null&&(zt=vr);break}g&&zt&&fe.alternate===null&&y(rt,zt),Q=$(fe,Q,Me),Be===null?$t=fe:Be.sibling=fe,Be=fe,zt=vr}if(Me===at.length)return C(rt,zt),$t;if(zt===null){for(;Me<at.length;Me++)zt=Wt(rt,at[Me],St),zt!==null&&(Q=$(zt,Q,Me),Be===null?$t=zt:Be.sibling=zt,Be=zt);return $t}for(zt=T(rt,zt);Me<at.length;Me++)vr=we(zt,rt,Me,at[Me],St),vr!==null&&(g&&vr.alternate!==null&&zt.delete(vr.key===null?Me:vr.key),Q=$(vr,Q,Me),Be===null?$t=vr:Be.sibling=vr,Be=vr);return g&&zt.forEach(function(wl){return y(rt,wl)}),$t}function hr(rt,Q,at,St){var $t=O(at);if(typeof $t!="function")throw Error(o(150));if(at=$t.call(at),at==null)throw Error(o(151));for(var Be=$t=null,zt=Q,Me=Q=0,vr=null,fe=at.next();zt!==null&&!fe.done;Me++,fe=at.next()){zt.index>Me?(vr=zt,zt=null):vr=zt.sibling;var wl=oe(rt,zt,fe.value,St);if(wl===null){zt===null&&(zt=vr);break}g&&zt&&wl.alternate===null&&y(rt,zt),Q=$(wl,Q,Me),Be===null?$t=wl:Be.sibling=wl,Be=wl,zt=vr}if(fe.done)return C(rt,zt),$t;if(zt===null){for(;!fe.done;Me++,fe=at.next())fe=Wt(rt,fe.value,St),fe!==null&&(Q=$(fe,Q,Me),Be===null?$t=fe:Be.sibling=fe,Be=fe);return $t}for(zt=T(rt,zt);!fe.done;Me++,fe=at.next())fe=we(zt,rt,Me,fe.value,St),fe!==null&&(g&&fe.alternate!==null&&zt.delete(fe.key===null?Me:fe.key),Q=$(fe,Q,Me),Be===null?$t=fe:Be.sibling=fe,Be=fe);return g&&zt.forEach(function(f8){return y(rt,f8)}),$t}return function(rt,Q,at,St){var $t=typeof at=="object"&&at!==null&&at.type===f&&at.key===null;$t&&(at=at.props.children);var Be=typeof at=="object"&&at!==null;if(Be)switch(at.$$typeof){case u:t:{for(Be=at.key,$t=Q;$t!==null;){if($t.key===Be){switch($t.tag){case 7:if(at.type===f){C(rt,$t.sibling),Q=E($t,at.props.children),Q.return=rt,rt=Q;break t}break;default:if($t.elementType===at.type){C(rt,$t.sibling),Q=E($t,at.props),Q.ref=tv(rt,$t,at),Q.return=rt,rt=Q;break t}}C(rt,$t);break}else y(rt,$t);$t=$t.sibling}at.type===f?(Q=bl(at.props.children,rt.mode,St,at.key),Q.return=rt,rt=Q):(St=Cy(at.type,at.key,at.props,null,rt.mode,St),St.ref=tv(rt,Q,at),St.return=rt,rt=St)}return z(rt);case c:t:{for($t=at.key;Q!==null;){if(Q.key===$t)if(Q.tag===4&&Q.stateNode.containerInfo===at.containerInfo&&Q.stateNode.implementation===at.implementation){C(rt,Q.sibling),Q=E(Q,at.children||[]),Q.return=rt,rt=Q;break t}else{C(rt,Q);break}else y(rt,Q);Q=Q.sibling}Q=Ow(at,rt.mode,St),Q.return=rt,rt=Q}return z(rt)}if(typeof at=="string"||typeof at=="number")return at=""+at,Q!==null&&Q.tag===6?(C(rt,Q.sibling),Q=E(Q,at),Q.return=rt,rt=Q):(C(rt,Q),Q=Fw(at,rt.mode,St),Q.return=rt,rt=Q),z(rt);if(Ug(at))return an(rt,Q,at,St);if(O(at))return hr(rt,Q,at,St);if(Be&&qg(rt,at),typeof at=="undefined"&&!$t)switch(rt.tag){case 1:case 0:throw rt=rt.type,Error(o(152,rt.displayName||rt.name||"Component"))}return C(rt,Q)}}var Mc=OI(!0),qb=OI(!1),ev={},In={current:ev},rv={current:ev},Ec={current:ev};function Ba(g){if(g===ev)throw Error(o(174));return g}function Zb(g,y){Ue(Ec,y),Ue(rv,g),Ue(In,ev),g=G(y),Re(In),Ue(In,g)}function Fc(){Re(In),Re(rv),Re(Ec)}function PI(g){var y=Ba(Ec.current),C=Ba(In.current);y=N(C,g.type,y),C!==y&&(Ue(rv,g),Ue(In,y))}function Qb(g){rv.current===g&&(Re(In),Re(rv))}var Je={current:0};function Zg(g){for(var y=g;y!==null;){if(y.tag===13){var C=y.memoizedState;if(C!==null&&(C=C.dehydrated,C===null||Rb(C)||Bb(C)))return y}else if(y.tag===19&&y.memoizedProps.revealOrder!==void 0){if((y.effectTag&64)!==0)return y}else if(y.child!==null){y.child.return=y,y=y.child;continue}if(y===g)break;for(;y.sibling===null;){if(y.return===null||y.return===g)return null;y=y.return}y.sibling.return=y.return,y=y.sibling}return null}function Kb(g,y){return{responder:g,props:y}}var Qg=l.ReactCurrentDispatcher,Ln=l.ReactCurrentBatchConfig,xl=0,wr=null,oi=null,li=null,Kg=!1;function en(){throw Error(o(321))}function Jb(g,y){if(y===null)return!1;for(var C=0;C<y.length&&C<g.length;C++)if(!Gs(g[C],y[C]))return!1;return!0}function tw(g,y,C,T,E,$){if(xl=$,wr=y,y.memoizedState=null,y.updateQueue=null,y.expirationTime=0,Qg.current=g===null||g.memoizedState===null?RU:BU,g=C(T,E),y.expirationTime===xl){$=0;do{if(y.expirationTime=0,!(25>$))throw Error(o(301));$+=1,li=oi=null,y.updateQueue=null,Qg.current=NU,g=C(T,E)}while(y.expirationTime===xl)}if(Qg.current=iy,y=oi!==null&&oi.next!==null,xl=0,li=oi=wr=null,Kg=!1,y)throw Error(o(300));return g}function Oc(){var g={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return li===null?wr.memoizedState=li=g:li=li.next=g,li}function Pc(){if(oi===null){var g=wr.alternate;g=g!==null?g.memoizedState:null}else g=oi.next;var y=li===null?wr.memoizedState:li.next;if(y!==null)li=y,oi=g;else{if(g===null)throw Error(o(310));oi=g,g={memoizedState:oi.memoizedState,baseState:oi.baseState,baseQueue:oi.baseQueue,queue:oi.queue,next:null},li===null?wr.memoizedState=li=g:li=li.next=g}return li}function zs(g,y){return typeof y=="function"?y(g):y}function Jg(g){var y=Pc(),C=y.queue;if(C===null)throw Error(o(311));C.lastRenderedReducer=g;var T=oi,E=T.baseQueue,$=C.pending;if($!==null){if(E!==null){var z=E.next;E.next=$.next,$.next=z}T.baseQueue=E=$,C.pending=null}if(E!==null){E=E.next,T=T.baseState;var nt=z=$=null,yt=E;do{var bt=yt.expirationTime;if(bt<xl){var Te={expirationTime:yt.expirationTime,suspenseConfig:yt.suspenseConfig,action:yt.action,eagerReducer:yt.eagerReducer,eagerState:yt.eagerState,next:null};nt===null?(z=nt=Te,$=T):nt=nt.next=Te,bt>wr.expirationTime&&(wr.expirationTime=bt,by(bt))}else nt!==null&&(nt=nt.next={expirationTime:1073741823,suspenseConfig:yt.suspenseConfig,action:yt.action,eagerReducer:yt.eagerReducer,eagerState:yt.eagerState,next:null}),m2(bt,yt.suspenseConfig),T=yt.eagerReducer===g?yt.eagerState:g(T,yt.action);yt=yt.next}while(yt!==null&&yt!==E);nt===null?$=T:nt.next=z,Gs(T,y.memoizedState)||(Na=!0),y.memoizedState=T,y.baseState=$,y.baseQueue=nt,C.lastRenderedState=T}return[y.memoizedState,C.dispatch]}function ty(g){var y=Pc(),C=y.queue;if(C===null)throw Error(o(311));C.lastRenderedReducer=g;var T=C.dispatch,E=C.pending,$=y.memoizedState;if(E!==null){C.pending=null;var z=E=E.next;do $=g($,z.action),z=z.next;while(z!==E);Gs($,y.memoizedState)||(Na=!0),y.memoizedState=$,y.baseQueue===null&&(y.baseState=$),C.lastRenderedState=$}return[$,T]}function ew(g){var y=Oc();return typeof g=="function"&&(g=g()),y.memoizedState=y.baseState=g,g=y.queue={pending:null,dispatch:null,lastRenderedReducer:zs,lastRenderedState:g},g=g.dispatch=NI.bind(null,wr,g),[y.memoizedState,g]}function rw(g,y,C,T){return g={tag:g,create:y,destroy:C,deps:T,next:null},y=wr.updateQueue,y===null?(y={lastEffect:null},wr.updateQueue=y,y.lastEffect=g.next=g):(C=y.lastEffect,C===null?y.lastEffect=g.next=g:(T=C.next,C.next=g,g.next=T,y.lastEffect=g)),g}function II(){return Pc().memoizedState}function iw(g,y,C,T){var E=Oc();wr.effectTag|=g,E.memoizedState=rw(1|y,C,void 0,T===void 0?null:T)}function nw(g,y,C,T){var E=Pc();T=T===void 0?null:T;var $=void 0;if(oi!==null){var z=oi.memoizedState;if($=z.destroy,T!==null&&Jb(T,z.deps)){rw(y,C,$,T);return}}wr.effectTag|=g,E.memoizedState=rw(1|y,C,$,T)}function LI(g,y){return iw(516,4,g,y)}function ey(g,y){return nw(516,4,g,y)}function DI(g,y){return nw(4,2,g,y)}function $I(g,y){if(typeof y=="function")return g=g(),y(g),function(){y(null)};if(y!=null)return g=g(),y.current=g,function(){y.current=null}}function kI(g,y,C){return C=C!=null?C.concat([g]):null,nw(4,2,$I.bind(null,y,g),C)}function aw(){}function RI(g,y){return Oc().memoizedState=[g,y===void 0?null:y],g}function ry(g,y){var C=Pc();y=y===void 0?null:y;var T=C.memoizedState;return T!==null&&y!==null&&Jb(y,T[1])?T[0]:(C.memoizedState=[g,y],g)}function BI(g,y){var C=Pc();y=y===void 0?null:y;var T=C.memoizedState;return T!==null&&y!==null&&Jb(y,T[1])?T[0]:(g=g(),C.memoizedState=[g,y],g)}function ow(g,y,C){var T=zg();ia(98>T?98:T,function(){g(!0)}),ia(97<T?97:T,function(){var E=Ln.suspense;Ln.suspense=y===void 0?null:y;try{g(!1),C()}finally{Ln.suspense=E}})}function NI(g,y,C){var T=oa(),E=Jh.suspense;T=Ws(T,g,E),E={expirationTime:T,suspenseConfig:E,action:C,eagerReducer:null,eagerState:null,next:null};var $=y.pending;if($===null?E.next=E:(E.next=$.next,$.next=E),y.pending=E,$=g.alternate,g===wr||$!==null&&$===wr)Kg=!0,E.expirationTime=xl,wr.expirationTime=xl;else{if(g.expirationTime===0&&($===null||$.expirationTime===0)&&($=y.lastRenderedReducer,$!==null))try{var z=y.lastRenderedState,nt=$(z,C);if(E.eagerReducer=$,E.eagerState=nt,Gs(nt,z))return}catch{}finally{}Po(g,T)}}var iy={readContext:Pn,useCallback:en,useContext:en,useEffect:en,useImperativeHandle:en,useLayoutEffect:en,useMemo:en,useReducer:en,useRef:en,useState:en,useDebugValue:en,useResponder:en,useDeferredValue:en,useTransition:en},RU={readContext:Pn,useCallback:RI,useContext:Pn,useEffect:LI,useImperativeHandle:function(g,y,C){return C=C!=null?C.concat([g]):null,iw(4,2,$I.bind(null,y,g),C)},useLayoutEffect:function(g,y){return iw(4,2,g,y)},useMemo:function(g,y){var C=Oc();return y=y===void 0?null:y,g=g(),C.memoizedState=[g,y],g},useReducer:function(g,y,C){var T=Oc();return y=C!==void 0?C(y):y,T.memoizedState=T.baseState=y,g=T.queue={pending:null,dispatch:null,lastRenderedReducer:g,lastRenderedState:y},g=g.dispatch=NI.bind(null,wr,g),[T.memoizedState,g]},useRef:function(g){var y=Oc();return g={current:g},y.memoizedState=g},useState:ew,useDebugValue:aw,useResponder:Kb,useDeferredValue:function(g,y){var C=ew(g),T=C[0],E=C[1];return LI(function(){var $=Ln.suspense;Ln.suspense=y===void 0?null:y;try{E(g)}finally{Ln.suspense=$}},[g,y]),T},useTransition:function(g){var y=ew(!1),C=y[0];return y=y[1],[RI(ow.bind(null,y,g),[y,g]),C]}},BU={readContext:Pn,useCallback:ry,useContext:Pn,useEffect:ey,useImperativeHandle:kI,useLayoutEffect:DI,useMemo:BI,useReducer:Jg,useRef:II,useState:function(){return Jg(zs)},useDebugValue:aw,useResponder:Kb,useDeferredValue:function(g,y){var C=Jg(zs),T=C[0],E=C[1];return ey(function(){var $=Ln.suspense;Ln.suspense=y===void 0?null:y;try{E(g)}finally{Ln.suspense=$}},[g,y]),T},useTransition:function(g){var y=Jg(zs),C=y[0];return y=y[1],[ry(ow.bind(null,y,g),[y,g]),C]}},NU={readContext:Pn,useCallback:ry,useContext:Pn,useEffect:ey,useImperativeHandle:kI,useLayoutEffect:DI,useMemo:BI,useReducer:ty,useRef:II,useState:function(){return ty(zs)},useDebugValue:aw,useResponder:Kb,useDeferredValue:function(g,y){var C=ty(zs),T=C[0],E=C[1];return ey(function(){var $=Ln.suspense;Ln.suspense=y===void 0?null:y;try{E(g)}finally{Ln.suspense=$}},[g,y]),T},useTransition:function(g){var y=ty(zs),C=y[0];return y=y[1],[ry(ow.bind(null,y,g),[y,g]),C]}},Eo=null,Vs=null,js=!1;function GI(g,y){var C=za(5,null,null,0);C.elementType="DELETED",C.type="DELETED",C.stateNode=y,C.return=g,C.effectTag=8,g.lastEffect!==null?(g.lastEffect.nextEffect=C,g.lastEffect=C):g.firstEffect=g.lastEffect=C}function zI(g,y){switch(g.tag){case 5:return y=kb(y,g.type,g.pendingProps),y!==null?(g.stateNode=y,!0):!1;case 6:return y=Wh(y,g.pendingProps),y!==null?(g.stateNode=y,!0):!1;case 13:return!1;default:return!1}}function lw(g){if(js){var y=Vs;if(y){var C=y;if(!zI(g,y)){if(y=Xh(C),!y||!zI(g,y)){g.effectTag=g.effectTag&-1025|2,js=!1,Eo=g;return}GI(Eo,C)}Eo=g,Vs=Lg(y)}else g.effectTag=g.effectTag&-1025|2,js=!1,Eo=g}}function VI(g){for(g=g.return;g!==null&&g.tag!==5&&g.tag!==3&&g.tag!==13;)g=g.return;Eo=g}function ny(g){if(!qt||g!==Eo)return!1;if(!js)return VI(g),js=!0,!1;var y=g.type;if(g.tag!==5||y!=="head"&&y!=="body"&&!et(y,g.memoizedProps))for(y=Vs;y;)GI(g,y),y=Xh(y);if(VI(g),g.tag===13){if(!qt)throw Error(o(316));if(g=g.memoizedState,g=g!==null?g.dehydrated:null,!g)throw Error(o(317));Vs=Gb(g)}else Vs=Eo?Xh(g.stateNode):null;return!0}function sw(){qt&&(Vs=Eo=null,js=!1)}var GU=l.ReactCurrentOwner,Na=!1;function rn(g,y,C,T){y.child=g===null?qb(y,null,C,T):Mc(y,g.child,C,T)}function jI(g,y,C,T,E){C=C.render;var $=y.ref;return Tc(y,E),T=tw(g,y,C,T,$,E),g!==null&&!Na?(y.updateQueue=g.updateQueue,y.effectTag&=-517,g.expirationTime<=E&&(g.expirationTime=0),Fo(g,y,E)):(y.effectTag|=1,rn(g,y,T,E),y.child)}function HI(g,y,C,T,E,$){if(g===null){var z=C.type;return typeof z=="function"&&!Ew(z)&&z.defaultProps===void 0&&C.compare===null&&C.defaultProps===void 0?(y.tag=15,y.type=z,YI(g,y,z,T,E,$)):(g=Cy(C.type,null,T,null,y.mode,$),g.ref=y.ref,g.return=y,y.child=g)}return z=g.child,E<$&&(E=z.memoizedProps,C=C.compare,C=C!==null?C:Vg,C(E,T)&&g.ref===y.ref)?Fo(g,y,$):(y.effectTag|=1,g=Qs(z,T),g.ref=y.ref,g.return=y,y.child=g)}function YI(g,y,C,T,E,$){return g!==null&&Vg(g.memoizedProps,T)&&g.ref===y.ref&&(Na=!1,E<$)?(y.expirationTime=g.expirationTime,Fo(g,y,$)):uw(g,y,C,T,$)}function WI(g,y){var C=y.ref;(g===null&&C!==null||g!==null&&g.ref!==C)&&(y.effectTag|=128)}function uw(g,y,C,T,E){var $=ni(C)?Ao:or.current;return $=To(y,$),Tc(y,E),C=tw(g,y,C,T,$,E),g!==null&&!Na?(y.updateQueue=g.updateQueue,y.effectTag&=-517,g.expirationTime<=E&&(g.expirationTime=0),Fo(g,y,E)):(y.effectTag|=1,rn(g,y,C,E),y.child)}function XI(g,y,C,T,E){if(ni(C)){var $=!0;Sc(y)}else $=!1;if(Tc(y,E),y.stateNode===null)g!==null&&(g.alternate=null,y.alternate=null,y.effectTag|=2),EI(y,C,T),Ub(y,C,T,E),T=!0;else if(g===null){var z=y.stateNode,nt=y.memoizedProps;z.props=nt;var yt=z.context,bt=C.contextType;typeof bt=="object"&&bt!==null?bt=Pn(bt):(bt=ni(C)?Ao:or.current,bt=To(y,bt));var Te=C.getDerivedStateFromProps,Wt=typeof Te=="function"||typeof z.getSnapshotBeforeUpdate=="function";Wt||typeof z.UNSAFE_componentWillReceiveProps!="function"&&typeof z.componentWillReceiveProps!="function"||(nt!==T||yt!==bt)&&FI(y,z,T,bt),gl=!1;var oe=y.memoizedState;z.state=oe,Kh(y,T,z,E),yt=y.memoizedState,nt!==T||oe!==yt||kr.current||gl?(typeof Te=="function"&&(Wg(y,C,Te,T),yt=y.memoizedState),(nt=gl||MI(y,C,nt,T,oe,yt,bt))?(Wt||typeof z.UNSAFE_componentWillMount!="function"&&typeof z.componentWillMount!="function"||(typeof z.componentWillMount=="function"&&z.componentWillMount(),typeof z.UNSAFE_componentWillMount=="function"&&z.UNSAFE_componentWillMount()),typeof z.componentDidMount=="function"&&(y.effectTag|=4)):(typeof z.componentDidMount=="function"&&(y.effectTag|=4),y.memoizedProps=T,y.memoizedState=yt),z.props=T,z.state=yt,z.context=bt,T=nt):(typeof z.componentDidMount=="function"&&(y.effectTag|=4),T=!1)}else z=y.stateNode,Xb(g,y),nt=y.memoizedProps,z.props=y.type===y.elementType?nt:na(y.type,nt),yt=z.context,bt=C.contextType,typeof bt=="object"&&bt!==null?bt=Pn(bt):(bt=ni(C)?Ao:or.current,bt=To(y,bt)),Te=C.getDerivedStateFromProps,(Wt=typeof Te=="function"||typeof z.getSnapshotBeforeUpdate=="function")||typeof z.UNSAFE_componentWillReceiveProps!="function"&&typeof z.componentWillReceiveProps!="function"||(nt!==T||yt!==bt)&&FI(y,z,T,bt),gl=!1,yt=y.memoizedState,z.state=yt,Kh(y,T,z,E),oe=y.memoizedState,nt!==T||yt!==oe||kr.current||gl?(typeof Te=="function"&&(Wg(y,C,Te,T),oe=y.memoizedState),(Te=gl||MI(y,C,nt,T,yt,oe,bt))?(Wt||typeof z.UNSAFE_componentWillUpdate!="function"&&typeof z.componentWillUpdate!="function"||(typeof z.componentWillUpdate=="function"&&z.componentWillUpdate(T,oe,bt),typeof z.UNSAFE_componentWillUpdate=="function"&&z.UNSAFE_componentWillUpdate(T,oe,bt)),typeof z.componentDidUpdate=="function"&&(y.effectTag|=4),typeof z.getSnapshotBeforeUpdate=="function"&&(y.effectTag|=256)):(typeof z.componentDidUpdate!="function"||nt===g.memoizedProps&&yt===g.memoizedState||(y.effectTag|=4),typeof z.getSnapshotBeforeUpdate!="function"||nt===g.memoizedProps&&yt===g.memoizedState||(y.effectTag|=256),y.memoizedProps=T,y.memoizedState=oe),z.props=T,z.state=oe,z.context=bt,T=Te):(typeof z.componentDidUpdate!="function"||nt===g.memoizedProps&&yt===g.memoizedState||(y.effectTag|=4),typeof z.getSnapshotBeforeUpdate!="function"||nt===g.memoizedProps&&yt===g.memoizedState||(y.effectTag|=256),T=!1);return cw(g,y,C,T,$,E)}function cw(g,y,C,T,E,$){WI(g,y);var z=(y.effectTag&64)!==0;if(!T&&!z)return E&&Rg(y,C,!1),Fo(g,y,$);T=y.stateNode,GU.current=y;var nt=z&&typeof C.getDerivedStateFromError!="function"?null:T.render();return y.effectTag|=1,g!==null&&z?(y.child=Mc(y,g.child,null,$),y.child=Mc(y,null,nt,$)):rn(g,y,nt,$),y.memoizedState=T.state,E&&Rg(y,C,!0),y.child}function UI(g){var y=g.stateNode;y.pendingContext?$g(g,y.pendingContext,y.pendingContext!==y.context):y.context&&$g(g,y.context,!1),Zb(g,y.containerInfo)}var fw={dehydrated:null,retryTime:0};function qI(g,y,C){var T=y.mode,E=y.pendingProps,$=Je.current,z=!1,nt;if((nt=(y.effectTag&64)!==0)||(nt=($&2)!==0&&(g===null||g.memoizedState!==null)),nt?(z=!0,y.effectTag&=-65):g!==null&&g.memoizedState===null||E.fallback===void 0||E.unstable_avoidThisFallback===!0||($|=1),Ue(Je,$&1),g===null){if(E.fallback!==void 0&&lw(y),z){if(z=E.fallback,E=bl(null,T,0,null),E.return=y,(y.mode&2)===0)for(g=y.memoizedState!==null?y.child.child:y.child,E.child=g;g!==null;)g.return=E,g=g.sibling;return C=bl(z,T,C,null),C.return=y,E.sibling=C,y.memoizedState=fw,y.child=E,C}return T=E.children,y.memoizedState=null,y.child=qb(y,null,T,C)}if(g.memoizedState!==null){if(g=g.child,T=g.sibling,z){if(E=E.fallback,C=Qs(g,g.pendingProps),C.return=y,(y.mode&2)===0&&(z=y.memoizedState!==null?y.child.child:y.child,z!==g.child))for(C.child=z;z!==null;)z.return=C,z=z.sibling;return T=Qs(T,E),T.return=y,C.sibling=T,C.childExpirationTime=0,y.memoizedState=fw,y.child=C,T}return C=Mc(y,g.child,E.children,C),y.memoizedState=null,y.child=C}if(g=g.child,z){if(z=E.fallback,E=bl(null,T,0,null),E.return=y,E.child=g,g!==null&&(g.return=E),(y.mode&2)===0)for(g=y.memoizedState!==null?y.child.child:y.child,E.child=g;g!==null;)g.return=E,g=g.sibling;return C=bl(z,T,C,null),C.return=y,E.sibling=C,C.effectTag|=2,E.childExpirationTime=0,y.memoizedState=fw,y.child=E,C}return y.memoizedState=null,y.child=Mc(y,g,E.children,C)}function ZI(g,y){g.expirationTime<y&&(g.expirationTime=y);var C=g.alternate;C!==null&&C.expirationTime<y&&(C.expirationTime=y),CI(g.return,y)}function hw(g,y,C,T,E,$){var z=g.memoizedState;z===null?g.memoizedState={isBackwards:y,rendering:null,renderingStartTime:0,last:T,tail:C,tailExpiration:0,tailMode:E,lastEffect:$}:(z.isBackwards=y,z.rendering=null,z.renderingStartTime=0,z.last=T,z.tail=C,z.tailExpiration=0,z.tailMode=E,z.lastEffect=$)}function QI(g,y,C){var T=y.pendingProps,E=T.revealOrder,$=T.tail;if(rn(g,y,T.children,C),T=Je.current,(T&2)!==0)T=T&1|2,y.effectTag|=64;else{if(g!==null&&(g.effectTag&64)!==0)t:for(g=y.child;g!==null;){if(g.tag===13)g.memoizedState!==null&&ZI(g,C);else if(g.tag===19)ZI(g,C);else if(g.child!==null){g.child.return=g,g=g.child;continue}if(g===y)break t;for(;g.sibling===null;){if(g.return===null||g.return===y)break t;g=g.return}g.sibling.return=g.return,g=g.sibling}T&=1}if(Ue(Je,T),(y.mode&2)===0)y.memoizedState=null;else switch(E){case"forwards":for(C=y.child,E=null;C!==null;)g=C.alternate,g!==null&&Zg(g)===null&&(E=C),C=C.sibling;C=E,C===null?(E=y.child,y.child=null):(E=C.sibling,C.sibling=null),hw(y,!1,E,C,$,y.lastEffect);break;case"backwards":for(C=null,E=y.child,y.child=null;E!==null;){if(g=E.alternate,g!==null&&Zg(g)===null){y.child=E;break}g=E.sibling,E.sibling=C,C=E,E=g}hw(y,!0,C,null,$,y.lastEffect);break;case"together":hw(y,!1,null,null,void 0,y.lastEffect);break;default:y.memoizedState=null}return y.child}function Fo(g,y,C){g!==null&&(y.dependencies=g.dependencies);var T=y.expirationTime;if(T!==0&&by(T),y.childExpirationTime<C)return null;if(g!==null&&y.child!==g.child)throw Error(o(153));if(y.child!==null){for(g=y.child,C=Qs(g,g.pendingProps),y.child=C,C.return=y;g.sibling!==null;)g=g.sibling,C=C.sibling=Qs(g,g.pendingProps),C.return=y;C.sibling=null}return y.child}function Ga(g){g.effectTag|=4}var iv,nv,ay,oy;if(_t)iv=function(g,y){for(var C=y.child;C!==null;){if(C.tag===5||C.tag===6)ot(g,C.stateNode);else if(C.tag!==4&&C.child!==null){C.child.return=C,C=C.child;continue}if(C===y)break;for(;C.sibling===null;){if(C.return===null||C.return===y)return;C=C.return}C.sibling.return=C.return,C=C.sibling}},nv=function(){},ay=function(g,y,C,T,E){if(g=g.memoizedProps,g!==T){var $=y.stateNode,z=Ba(In.current);C=Z($,C,g,T,E,z),(y.updateQueue=C)&&Ga(y)}},oy=function(g,y,C,T){C!==T&&Ga(y)};else if(Bt){iv=function(g,y,C,T){for(var E=y.child;E!==null;){if(E.tag===5){var $=E.stateNode;C&&T&&($=Ns($,E.type,E.memoizedProps,E)),ot(g,$)}else if(E.tag===6)$=E.stateNode,C&&T&&($=Ig($,E.memoizedProps,E)),ot(g,$);else if(E.tag!==4){if(E.tag===13&&(E.effectTag&4)!==0&&($=E.memoizedState!==null)){var z=E.child;if(z!==null&&(z.child!==null&&(z.child.return=z,iv(g,z,!0,$)),$=z.sibling,$!==null)){$.return=E,E=$;continue}}if(E.child!==null){E.child.return=E,E=E.child;continue}}if(E===y)break;for(;E.sibling===null;){if(E.return===null||E.return===y)return;E=E.return}E.sibling.return=E.return,E=E.sibling}};var KI=function(g,y,C,T){for(var E=y.child;E!==null;){if(E.tag===5){var $=E.stateNode;C&&T&&($=Ns($,E.type,E.memoizedProps,E)),Bs(g,$)}else if(E.tag===6)$=E.stateNode,C&&T&&($=Ig($,E.memoizedProps,E)),Bs(g,$);else if(E.tag!==4){if(E.tag===13&&(E.effectTag&4)!==0&&($=E.memoizedState!==null)){var z=E.child;if(z!==null&&(z.child!==null&&(z.child.return=z,KI(g,z,!0,$)),$=z.sibling,$!==null)){$.return=E,E=$;continue}}if(E.child!==null){E.child.return=E,E=E.child;continue}}if(E===y)break;for(;E.sibling===null;){if(E.return===null||E.return===y)return;E=E.return}E.sibling.return=E.return,E=E.sibling}};nv=function(g){var y=g.stateNode;if(g.firstEffect!==null){var C=y.containerInfo,T=bc(C);KI(T,g,!1,!1),y.pendingChildren=T,Ga(g),dl(C,T)}},ay=function(g,y,C,T,E){var $=g.stateNode,z=g.memoizedProps;if((g=y.firstEffect===null)&&z===T)y.stateNode=$;else{var nt=y.stateNode,yt=Ba(In.current),bt=null;z!==T&&(bt=Z(nt,C,z,T,E,yt)),g&&bt===null?y.stateNode=$:($=Yh($,bt,C,z,T,y,g,nt),st($,C,T,E,yt)&&Ga(y),y.stateNode=$,g?Ga(y):iv($,y,!1,!1))}},oy=function(g,y,C,T){C!==T?(g=Ba(Ec.current),C=Ba(In.current),y.stateNode=dt(T,g,C,y),Ga(y)):y.stateNode=g.stateNode}}else nv=function(){},ay=function(){},oy=function(){};function ly(g,y){switch(g.tailMode){case"hidden":y=g.tail;for(var C=null;y!==null;)y.alternate!==null&&(C=y),y=y.sibling;C===null?g.tail=null:C.sibling=null;break;case"collapsed":C=g.tail;for(var T=null;C!==null;)C.alternate!==null&&(T=C),C=C.sibling;T===null?y||g.tail===null?g.tail=null:g.tail.sibling=null:T.sibling=null}}function zU(g,y,C){var T=y.pendingProps;switch(y.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return null;case 1:return ni(y.type)&&Cc(),null;case 3:return Fc(),Re(kr),Re(or),T=y.stateNode,T.pendingContext&&(T.context=T.pendingContext,T.pendingContext=null),(g===null||g.child===null)&&ny(y)&&Ga(y),nv(y),null;case 5:Qb(y);var E=Ba(Ec.current);if(C=y.type,g!==null&&y.stateNode!=null)ay(g,y,C,T,E),g.ref!==y.ref&&(y.effectTag|=128);else{if(!T){if(y.stateNode===null)throw Error(o(166));return null}if(g=Ba(In.current),ny(y)){if(!qt)throw Error(o(175));g=Nb(y.stateNode,y.type,y.memoizedProps,E,g,y),y.updateQueue=g,g!==null&&Ga(y)}else{var $=tt(C,T,E,g,y);iv($,y,!1,!1),y.stateNode=$,st($,C,T,E,g)&&Ga(y)}y.ref!==null&&(y.effectTag|=128)}return null;case 6:if(g&&y.stateNode!=null)oy(g,y,g.memoizedProps,T);else{if(typeof T!="string"&&y.stateNode===null)throw Error(o(166));if(g=Ba(Ec.current),E=Ba(In.current),ny(y)){if(!qt)throw Error(o(176));Uh(y.stateNode,y.memoizedProps,y)&&Ga(y)}else y.stateNode=dt(T,g,E,y)}return null;case 13:return Re(Je),T=y.memoizedState,(y.effectTag&64)!==0?(y.expirationTime=C,y):(T=T!==null,E=!1,g===null?y.memoizedProps.fallback!==void 0&&ny(y):(C=g.memoizedState,E=C!==null,T||C===null||(C=g.child.sibling,C!==null&&($=y.firstEffect,$!==null?(y.firstEffect=C,C.nextEffect=$):(y.firstEffect=y.lastEffect=C,C.nextEffect=null),C.effectTag=8))),T&&!E&&(y.mode&2)!==0&&(g===null&&y.memoizedProps.unstable_avoidThisFallback!==!0||(Je.current&1)!==0?Rr===Hs&&(Rr=fy):((Rr===Hs||Rr===fy)&&(Rr=hy),ov!==0&&nn!==null&&(Ks(nn,Di),S2(nn,ov)))),Bt&&T&&(y.effectTag|=4),_t&&(T||E)&&(y.effectTag|=4),null);case 4:return Fc(),nv(y),null;case 10:return Yb(y),null;case 17:return ni(y.type)&&Cc(),null;case 19:if(Re(Je),T=y.memoizedState,T===null)return null;if(E=(y.effectTag&64)!==0,$=T.rendering,$===null){if(E)ly(T,!1);else if(Rr!==Hs||g!==null&&(g.effectTag&64)!==0)for(g=y.child;g!==null;){if($=Zg(g),$!==null){for(y.effectTag|=64,ly(T,!1),g=$.updateQueue,g!==null&&(y.updateQueue=g,y.effectTag|=4),T.lastEffect===null&&(y.firstEffect=null),y.lastEffect=T.lastEffect,g=C,T=y.child;T!==null;)E=T,C=g,E.effectTag&=2,E.nextEffect=null,E.firstEffect=null,E.lastEffect=null,$=E.alternate,$===null?(E.childExpirationTime=0,E.expirationTime=C,E.child=null,E.memoizedProps=null,E.memoizedState=null,E.updateQueue=null,E.dependencies=null):(E.childExpirationTime=$.childExpirationTime,E.expirationTime=$.expirationTime,E.child=$.child,E.memoizedProps=$.memoizedProps,E.memoizedState=$.memoizedState,E.updateQueue=$.updateQueue,C=$.dependencies,E.dependencies=C===null?null:{expirationTime:C.expirationTime,firstContext:C.firstContext,responders:C.responders}),T=T.sibling;return Ue(Je,Je.current&1|2),y.child}g=g.sibling}}else{if(!E)if(g=Zg($),g!==null){if(y.effectTag|=64,E=!0,g=g.updateQueue,g!==null&&(y.updateQueue=g,y.effectTag|=4),ly(T,!0),T.tail===null&&T.tailMode==="hidden"&&!$.alternate)return y=y.lastEffect=T.lastEffect,y!==null&&(y.nextEffect=null),null}else 2*Fn()-T.renderingStartTime>T.tailExpiration&&1<C&&(y.effectTag|=64,E=!0,ly(T,!1),y.expirationTime=y.childExpirationTime=C-1);T.isBackwards?($.sibling=y.child,y.child=$):(g=T.last,g!==null?g.sibling=$:y.child=$,T.last=$)}return T.tail!==null?(T.tailExpiration===0&&(T.tailExpiration=Fn()+500),g=T.tail,T.rendering=g,T.tail=g.sibling,T.lastEffect=y.lastEffect,T.renderingStartTime=Fn(),g.sibling=null,y=Je.current,Ue(Je,E?y&1|2:y&1),g):null}throw Error(o(156,y.tag))}function VU(g){switch(g.tag){case 1:ni(g.type)&&Cc();var y=g.effectTag;return y&4096?(g.effectTag=y&-4097|64,g):null;case 3:if(Fc(),Re(kr),Re(or),y=g.effectTag,(y&64)!==0)throw Error(o(285));return g.effectTag=y&-4097|64,g;case 5:return Qb(g),null;case 13:return Re(Je),y=g.effectTag,y&4096?(g.effectTag=y&-4097|64,g):null;case 19:return Re(Je),null;case 4:return Fc(),null;case 10:return Yb(g),null;default:return null}}function vw(g,y){return{value:g,source:y,stack:wc(y)}}var jU=typeof WeakSet=="function"?WeakSet:Set;function dw(g,y){var C=y.source,T=y.stack;T===null&&C!==null&&(T=wc(C)),C!==null&&D(C.type),y=y.value,g!==null&&g.tag===1&&D(g.type);try{console.error(y)}catch(E){setTimeout(function(){throw E})}}function HU(g,y){try{y.props=g.memoizedProps,y.state=g.memoizedState,y.componentWillUnmount()}catch(C){Zs(g,C)}}function JI(g){var y=g.ref;if(y!==null)if(typeof y=="function")try{y(null)}catch(C){Zs(g,C)}else y.current=null}function YU(g,y){switch(y.tag){case 0:case 11:case 15:case 22:return;case 1:if(y.effectTag&256&&g!==null){var C=g.memoizedProps,T=g.memoizedState;g=y.stateNode,y=g.getSnapshotBeforeUpdate(y.elementType===y.type?C:na(y.type,C),T),g.__reactInternalSnapshotBeforeUpdate=y}return;case 3:case 5:case 6:case 4:case 17:return}throw Error(o(163))}function pw(g,y){if(y=y.updateQueue,y=y!==null?y.lastEffect:null,y!==null){var C=y=y.next;do{if((C.tag&g)===g){var T=C.destroy;C.destroy=void 0,T!==void 0&&T()}C=C.next}while(C!==y)}}function t2(g,y){if(y=y.updateQueue,y=y!==null?y.lastEffect:null,y!==null){var C=y=y.next;do{if((C.tag&g)===g){var T=C.create;C.destroy=T()}C=C.next}while(C!==y)}}function WU(g,y,C){switch(C.tag){case 0:case 11:case 15:case 22:t2(3,C);return;case 1:if(g=C.stateNode,C.effectTag&4)if(y===null)g.componentDidMount();else{var T=C.elementType===C.type?y.memoizedProps:na(C.type,y.memoizedProps);g.componentDidUpdate(T,y.memoizedState,g.__reactInternalSnapshotBeforeUpdate)}y=C.updateQueue,y!==null&&AI(C,y,g);return;case 3:if(y=C.updateQueue,y!==null){if(g=null,C.child!==null)switch(C.child.tag){case 5:g=R(C.child.stateNode);break;case 1:g=C.child.stateNode}AI(C,y,g)}return;case 5:g=C.stateNode,y===null&&C.effectTag&4&&ar(g,C.type,C.memoizedProps,C);return;case 6:return;case 4:return;case 12:return;case 13:qt&&C.memoizedState===null&&(C=C.alternate,C!==null&&(C=C.memoizedState,C!==null&&(C=C.dehydrated,C!==null&&zb(C))));return;case 19:case 17:case 20:case 21:return}throw Error(o(163))}function e2(g,y,C){switch(typeof Mw=="function"&&Mw(y),y.tag){case 0:case 11:case 14:case 15:case 22:if(g=y.updateQueue,g!==null&&(g=g.lastEffect,g!==null)){var T=g.next;ia(97<C?97:C,function(){var E=T;do{var $=E.destroy;if($!==void 0){var z=y;try{$()}catch(nt){Zs(z,nt)}}E=E.next}while(E!==T)})}break;case 1:JI(y),C=y.stateNode,typeof C.componentWillUnmount=="function"&&HU(y,C);break;case 5:JI(y);break;case 4:_t?o2(g,y,C):Bt&&XU(y)}}function r2(g,y,C){for(var T=y;;)if(e2(g,T,C),T.child===null||_t&&T.tag===4){if(T===y)break;for(;T.sibling===null;){if(T.return===null||T.return===y)return;T=T.return}T.sibling.return=T.return,T=T.sibling}else T.child.return=T,T=T.child}function i2(g){var y=g.alternate;g.return=null,g.child=null,g.memoizedState=null,g.updateQueue=null,g.dependencies=null,g.alternate=null,g.firstEffect=null,g.lastEffect=null,g.pendingProps=null,g.memoizedProps=null,g.stateNode=null,y!==null&&i2(y)}function XU(g){if(Bt){g=g.stateNode.containerInfo;var y=bc(g);So(g,y)}}function n2(g){return g.tag===5||g.tag===3||g.tag===4}function a2(g){if(_t){t:{for(var y=g.return;y!==null;){if(n2(y)){var C=y;break t}y=y.return}throw Error(o(160))}switch(y=C.stateNode,C.tag){case 5:var T=!1;break;case 3:y=y.containerInfo,T=!0;break;case 4:y=y.containerInfo,T=!0;break;default:throw Error(o(161))}C.effectTag&16&&(Ke(y),C.effectTag&=-17);t:e:for(C=g;;){for(;C.sibling===null;){if(C.return===null||n2(C.return)){C=null;break t}C=C.return}for(C.sibling.return=C.return,C=C.sibling;C.tag!==5&&C.tag!==6&&C.tag!==18;){if(C.effectTag&2||C.child===null||C.tag===4)continue e;C.child.return=C,C=C.child}if(!(C.effectTag&2)){C=C.stateNode;break t}}T?gw(g,C,y):yw(g,C,y)}}function gw(g,y,C){var T=g.tag,E=T===5||T===6;if(E)g=E?g.stateNode:g.stateNode.instance,y?tn(C,g,y):pe(C,g);else if(T!==4&&(g=g.child,g!==null))for(gw(g,y,C),g=g.sibling;g!==null;)gw(g,y,C),g=g.sibling}function yw(g,y,C){var T=g.tag,E=T===5||T===6;if(E)g=E?g.stateNode:g.stateNode.instance,y?$r(C,g,y):Nt(C,g);else if(T!==4&&(g=g.child,g!==null))for(yw(g,y,C),g=g.sibling;g!==null;)yw(g,y,C),g=g.sibling}function o2(g,y,C){for(var T=y,E=!1,$,z;;){if(!E){E=T.return;t:for(;;){if(E===null)throw Error(o(160));switch($=E.stateNode,E.tag){case 5:z=!1;break t;case 3:$=$.containerInfo,z=!0;break t;case 4:$=$.containerInfo,z=!0;break t}E=E.return}E=!0}if(T.tag===5||T.tag===6)r2(g,T,C),z?Wr($,T.stateNode):Yr($,T.stateNode);else if(T.tag===4){if(T.child!==null){$=T.stateNode.containerInfo,z=!0,T.child.return=T,T=T.child;continue}}else if(e2(g,T,C),T.child!==null){T.child.return=T,T=T.child;continue}if(T===y)break;for(;T.sibling===null;){if(T.return===null||T.return===y)return;T=T.return,T.tag===4&&(E=!1)}T.sibling.return=T.return,T=T.sibling}}function mw(g,y){if(_t){switch(y.tag){case 0:case 11:case 14:case 15:case 22:pw(3,y);return;case 1:return;case 5:var C=y.stateNode;if(C!=null){var T=y.memoizedProps;g=g!==null?g.memoizedProps:T;var E=y.type,$=y.updateQueue;y.updateQueue=null,$!==null&&Ji(C,$,E,g,T,y)}return;case 6:if(y.stateNode===null)throw Error(o(162));C=y.memoizedProps,cr(y.stateNode,g!==null?g.memoizedProps:C,C);return;case 3:qt&&(y=y.stateNode,y.hydrate&&(y.hydrate=!1,Dg(y.containerInfo)));return;case 12:return;case 13:l2(y),sy(y);return;case 19:sy(y);return;case 17:return}throw Error(o(163))}switch(y.tag){case 0:case 11:case 14:case 15:case 22:pw(3,y);return;case 12:return;case 13:l2(y),sy(y);return;case 19:sy(y);return;case 3:qt&&(C=y.stateNode,C.hydrate&&(C.hydrate=!1,Dg(C.containerInfo)))}t:if(Bt){switch(y.tag){case 1:case 5:case 6:case 20:break t;case 3:case 4:y=y.stateNode,So(y.containerInfo,y.pendingChildren);break t}throw Error(o(163))}}function l2(g){var y=g;if(g.memoizedState===null)var C=!1;else C=!0,y=g.child,bw=Fn();if(_t&&y!==null){t:if(g=y,_t)for(y=g;;){if(y.tag===5){var T=y.stateNode;C?At(T):Hh(y.stateNode,y.memoizedProps)}else if(y.tag===6)T=y.stateNode,C?yi(T):_c(T,y.memoizedProps);else if(y.tag===13&&y.memoizedState!==null&&y.memoizedState.dehydrated===null){T=y.child.sibling,T.return=y,y=T;continue}else if(y.child!==null){y.child.return=y,y=y.child;continue}if(y===g)break t;for(;y.sibling===null;){if(y.return===null||y.return===g)break t;y=y.return}y.sibling.return=y.return,y=y.sibling}}}function sy(g){var y=g.updateQueue;if(y!==null){g.updateQueue=null;var C=g.stateNode;C===null&&(C=g.stateNode=new jU),y.forEach(function(T){var E=n8.bind(null,g,T);C.has(T)||(C.add(T),T.then(E,E))})}}var UU=typeof WeakMap=="function"?WeakMap:Map;function s2(g,y,C){C=yl(C,null),C.tag=3,C.payload={element:null};var T=y.value;return C.callback=function(){gy||(gy=!0,ww=T),dw(g,y)},C}function u2(g,y,C){C=yl(C,null),C.tag=3;var T=g.type.getDerivedStateFromError;if(typeof T=="function"){var E=y.value;C.payload=function(){return dw(g,y),T(E)}}var $=g.stateNode;return $!==null&&typeof $.componentDidCatch=="function"&&(C.callback=function(){typeof T!="function"&&(_l===null?_l=new Set([this]):_l.add(this),dw(g,y));var z=y.stack;this.componentDidCatch(y.value,{componentStack:z!==null?z:""})}),C}var qU=Math.ceil,uy=l.ReactCurrentDispatcher,c2=l.ReactCurrentOwner,fr=0,xw=8,Dn=16,aa=32,Hs=0,cy=1,f2=2,fy=3,hy=4,_w=5,Rt=fr,nn=null,Xt=null,Di=0,Rr=Hs,vy=null,Oo=1073741823,av=1073741823,dy=null,ov=0,py=!1,bw=0,h2=500,Ft=null,gy=!1,ww=null,_l=null,yy=!1,lv=null,sv=90,Ys=null,uv=0,Cw=null,my=0;function oa(){return(Rt&(Dn|aa))!==fr?1073741821-(Fn()/10|0):my!==0?my:my=1073741821-(Fn()/10|0)}function Ws(g,y,C){if(y=y.mode,(y&2)===0)return 1073741823;var T=zg();if((y&4)===0)return T===99?1073741823:1073741822;if((Rt&Dn)!==fr)return Di;if(C!==null)g=Qh(g,C.timeoutMs|0||5e3,250);else switch(T){case 99:g=1073741823;break;case 98:g=Qh(g,150,100);break;case 97:case 96:g=Qh(g,5e3,250);break;case 95:g=2;break;default:throw Error(o(326))}return nn!==null&&g===Di&&--g,g}function Po(g,y){if(50<uv)throw uv=0,Cw=null,Error(o(185));if(g=xy(g,y),g!==null){var C=zg();y===1073741823?(Rt&xw)!==fr&&(Rt&(Dn|aa))===fr?Sw(g):($i(g),Rt===fr&&On()):$i(g),(Rt&4)===fr||C!==98&&C!==99||(Ys===null?Ys=new Map([[g,y]]):(C=Ys.get(g),(C===void 0||C>y)&&Ys.set(g,y)))}}function xy(g,y){g.expirationTime<y&&(g.expirationTime=y);var C=g.alternate;C!==null&&C.expirationTime<y&&(C.expirationTime=y);var T=g.return,E=null;if(T===null&&g.tag===3)E=g.stateNode;else for(;T!==null;){if(C=T.alternate,T.childExpirationTime<y&&(T.childExpirationTime=y),C!==null&&C.childExpirationTime<y&&(C.childExpirationTime=y),T.return===null&&T.tag===3){E=T.stateNode;break}T=T.return}return E!==null&&(nn===E&&(by(y),Rr===hy&&Ks(E,Di)),S2(E,y)),E}function _y(g){var y=g.lastExpiredTime;if(y!==0||(y=g.firstPendingTime,!C2(g,y)))return y;var C=g.lastPingedTime;return g=g.nextKnownPendingLevel,g=C>g?C:g,2>=g&&y!==g?0:g}function $i(g){if(g.lastExpiredTime!==0)g.callbackExpirationTime=1073741823,g.callbackPriority=99,g.callbackNode=_I(Sw.bind(null,g));else{var y=_y(g),C=g.callbackNode;if(y===0)C!==null&&(g.callbackNode=null,g.callbackExpirationTime=0,g.callbackPriority=90);else{var T=oa();if(y===1073741823?T=99:y===1||y===2?T=95:(T=10*(1073741821-y)-10*(1073741821-T),T=0>=T?99:250>=T?98:5250>=T?97:95),C!==null){var E=g.callbackPriority;if(g.callbackExpirationTime===y&&E>=T)return;C!==gI&&Zh(C)}g.callbackExpirationTime=y,g.callbackPriority=T,y=y===1073741823?_I(Sw.bind(null,g)):xI(T,v2.bind(null,g),{timeout:10*(1073741821-y)-Fn()}),g.callbackNode=y}}}function v2(g,y){if(my=0,y)return y=oa(),Sy(g,y),$i(g),null;var C=_y(g);if(C!==0){if(y=g.callbackNode,(Rt&(Dn|aa))!==fr)throw Error(o(327));if(qs(),g===nn&&C===Di||Xs(g,C),Xt!==null){var T=Rt;Rt|=Dn;var E=y2();do try{JU();break}catch(nt){g2(g,nt)}while(1);if(Hb(),Rt=T,uy.current=E,Rr===cy)throw y=vy,Xs(g,C),Ks(g,C),$i(g),y;if(Xt===null)switch(E=g.finishedWork=g.current.alternate,g.finishedExpirationTime=C,T=Rr,nn=null,T){case Hs:case cy:throw Error(o(345));case f2:Sy(g,2<C?2:C);break;case fy:if(Ks(g,C),T=g.lastSuspendedTime,C===T&&(g.nextKnownPendingLevel=Aw(E)),Oo===1073741823&&(E=bw+h2-Fn(),10<E)){if(py){var $=g.lastPingedTime;if($===0||$>=C){g.lastPingedTime=C,Xs(g,C);break}}if($=_y(g),$!==0&&$!==C)break;if(T!==0&&T!==C){g.lastPingedTime=T;break}g.timeoutHandle=ht(Us.bind(null,g),E);break}Us(g);break;case hy:if(Ks(g,C),T=g.lastSuspendedTime,C===T&&(g.nextKnownPendingLevel=Aw(E)),py&&(E=g.lastPingedTime,E===0||E>=C)){g.lastPingedTime=C,Xs(g,C);break}if(E=_y(g),E!==0&&E!==C)break;if(T!==0&&T!==C){g.lastPingedTime=T;break}if(av!==1073741823?T=10*(1073741821-av)-Fn():Oo===1073741823?T=0:(T=10*(1073741821-Oo)-5e3,E=Fn(),C=10*(1073741821-C)-E,T=E-T,0>T&&(T=0),T=(120>T?120:480>T?480:1080>T?1080:1920>T?1920:3e3>T?3e3:4320>T?4320:1960*qU(T/1960))-T,C<T&&(T=C)),10<T){g.timeoutHandle=ht(Us.bind(null,g),T);break}Us(g);break;case _w:if(Oo!==1073741823&&dy!==null){$=Oo;var z=dy;if(T=z.busyMinDurationMs|0,0>=T?T=0:(E=z.busyDelayMs|0,$=Fn()-(10*(1073741821-$)-(z.timeoutMs|0||5e3)),T=$<=E?0:E+T-$),10<T){Ks(g,C),g.timeoutHandle=ht(Us.bind(null,g),T);break}}Us(g);break;default:throw Error(o(329))}if($i(g),g.callbackNode===y)return v2.bind(null,g)}}return null}function Sw(g){var y=g.lastExpiredTime;if(y=y!==0?y:1073741823,(Rt&(Dn|aa))!==fr)throw Error(o(327));if(qs(),g===nn&&y===Di||Xs(g,y),Xt!==null){var C=Rt;Rt|=Dn;var T=y2();do try{KU();break}catch(E){g2(g,E)}while(1);if(Hb(),Rt=C,uy.current=T,Rr===cy)throw C=vy,Xs(g,y),Ks(g,y),$i(g),C;if(Xt!==null)throw Error(o(261));g.finishedWork=g.current.alternate,g.finishedExpirationTime=y,nn=null,Us(g),$i(g)}return null}function ZU(g,y){Sy(g,y),$i(g),(Rt&(Dn|aa))===fr&&On()}function QU(){if(Ys!==null){var g=Ys;Ys=null,g.forEach(function(y,C){Sy(C,y),$i(C)}),On()}}function d2(g,y){var C=Rt;Rt|=1;try{return g(y)}finally{Rt=C,Rt===fr&&On()}}function p2(g,y){if((Rt&(Dn|aa))!==fr)throw Error(o(187));var C=Rt;Rt|=1;try{return ia(99,g.bind(null,y))}finally{Rt=C,On()}}function Xs(g,y){g.finishedWork=null,g.finishedExpirationTime=0;var C=g.timeoutHandle;if(C!==gt&&(g.timeoutHandle=gt,wt(C)),Xt!==null)for(C=Xt.return;C!==null;){var T=C;switch(T.tag){case 1:T=T.type.childContextTypes,T!=null&&Cc();break;case 3:Fc(),Re(kr),Re(or);break;case 5:Qb(T);break;case 4:Fc();break;case 13:Re(Je);break;case 19:Re(Je);break;case 10:Yb(T)}C=C.return}nn=g,Xt=Qs(g.current,null),Di=y,Rr=Hs,vy=null,av=Oo=1073741823,dy=null,ov=0,py=!1}function g2(g,y){do{try{if(Hb(),Qg.current=iy,Kg)for(var C=wr.memoizedState;C!==null;){var T=C.queue;T!==null&&(T.pending=null),C=C.next}if(xl=0,li=oi=wr=null,Kg=!1,Xt===null||Xt.return===null)return Rr=cy,vy=y,Xt=null;t:{var E=g,$=Xt.return,z=Xt,nt=y;if(y=Di,z.effectTag|=2048,z.firstEffect=z.lastEffect=null,nt!==null&&typeof nt=="object"&&typeof nt.then=="function"){var yt=nt;if((z.mode&2)===0){var bt=z.alternate;bt?(z.updateQueue=bt.updateQueue,z.memoizedState=bt.memoizedState,z.expirationTime=bt.expirationTime):(z.updateQueue=null,z.memoizedState=null)}var Te=(Je.current&1)!==0,Wt=$;do{var oe;if(oe=Wt.tag===13){var we=Wt.memoizedState;if(we!==null)oe=we.dehydrated!==null;else{var an=Wt.memoizedProps;oe=an.fallback===void 0?!1:an.unstable_avoidThisFallback!==!0?!0:!Te}}if(oe){var hr=Wt.updateQueue;if(hr===null){var rt=new Set;rt.add(yt),Wt.updateQueue=rt}else hr.add(yt);if((Wt.mode&2)===0){if(Wt.effectTag|=64,z.effectTag&=-2981,z.tag===1)if(z.alternate===null)z.tag=17;else{var Q=yl(1073741823,null);Q.tag=2,ml(z,Q)}z.expirationTime=1073741823;break t}nt=void 0,z=y;var at=E.pingCache;if(at===null?(at=E.pingCache=new UU,nt=new Set,at.set(yt,nt)):(nt=at.get(yt),nt===void 0&&(nt=new Set,at.set(yt,nt))),!nt.has(z)){nt.add(z);var St=i8.bind(null,E,yt,z);yt.then(St,St)}Wt.effectTag|=4096,Wt.expirationTime=y;break t}Wt=Wt.return}while(Wt!==null);nt=Error((D(z.type)||"A React component")+` suspended while rendering, but no fallback UI was specified.
|
|
|
|
Add a <Suspense fallback=...> component higher in the tree to provide a loading indicator or placeholder to display.`+wc(z))}Rr!==_w&&(Rr=f2),nt=vw(nt,z),Wt=$;do{switch(Wt.tag){case 3:yt=nt,Wt.effectTag|=4096,Wt.expirationTime=y;var $t=s2(Wt,yt,y);SI(Wt,$t);break t;case 1:yt=nt;var Be=Wt.type,zt=Wt.stateNode;if((Wt.effectTag&64)===0&&(typeof Be.getDerivedStateFromError=="function"||zt!==null&&typeof zt.componentDidCatch=="function"&&(_l===null||!_l.has(zt)))){Wt.effectTag|=4096,Wt.expirationTime=y;var Me=u2(Wt,yt,y);SI(Wt,Me);break t}}Wt=Wt.return}while(Wt!==null)}Xt=_2(Xt)}catch(vr){y=vr;continue}break}while(1)}function y2(){var g=uy.current;return uy.current=iy,g===null?iy:g}function m2(g,y){g<Oo&&2<g&&(Oo=g),y!==null&&g<av&&2<g&&(av=g,dy=y)}function by(g){g>ov&&(ov=g)}function KU(){for(;Xt!==null;)Xt=x2(Xt)}function JU(){for(;Xt!==null&&!LU();)Xt=x2(Xt)}function x2(g){var y=w2(g.alternate,g,Di);return g.memoizedProps=g.pendingProps,y===null&&(y=_2(g)),c2.current=null,y}function _2(g){Xt=g;do{var y=Xt.alternate;if(g=Xt.return,(Xt.effectTag&2048)===0){if(y=zU(y,Xt,Di),Di===1||Xt.childExpirationTime!==1){for(var C=0,T=Xt.child;T!==null;){var E=T.expirationTime,$=T.childExpirationTime;E>C&&(C=E),$>C&&(C=$),T=T.sibling}Xt.childExpirationTime=C}if(y!==null)return y;g!==null&&(g.effectTag&2048)===0&&(g.firstEffect===null&&(g.firstEffect=Xt.firstEffect),Xt.lastEffect!==null&&(g.lastEffect!==null&&(g.lastEffect.nextEffect=Xt.firstEffect),g.lastEffect=Xt.lastEffect),1<Xt.effectTag&&(g.lastEffect!==null?g.lastEffect.nextEffect=Xt:g.firstEffect=Xt,g.lastEffect=Xt))}else{if(y=VU(Xt),y!==null)return y.effectTag&=2047,y;g!==null&&(g.firstEffect=g.lastEffect=null,g.effectTag|=2048)}if(y=Xt.sibling,y!==null)return y;Xt=g}while(Xt!==null);return Rr===Hs&&(Rr=_w),null}function Aw(g){var y=g.expirationTime;return g=g.childExpirationTime,y>g?y:g}function Us(g){var y=zg();return ia(99,t8.bind(null,g,y)),null}function t8(g,y){do qs();while(lv!==null);if((Rt&(Dn|aa))!==fr)throw Error(o(327));var C=g.finishedWork,T=g.finishedExpirationTime;if(C===null)return null;if(g.finishedWork=null,g.finishedExpirationTime=0,C===g.current)throw Error(o(177));g.callbackNode=null,g.callbackExpirationTime=0,g.callbackPriority=90,g.nextKnownPendingLevel=0;var E=Aw(C);if(g.firstPendingTime=E,T<=g.lastSuspendedTime?g.firstSuspendedTime=g.lastSuspendedTime=g.nextKnownPendingLevel=0:T<=g.firstSuspendedTime&&(g.firstSuspendedTime=T-1),T<=g.lastPingedTime&&(g.lastPingedTime=0),T<=g.lastExpiredTime&&(g.lastExpiredTime=0),g===nn&&(Xt=nn=null,Di=0),1<C.effectTag?C.lastEffect!==null?(C.lastEffect.nextEffect=C,E=C.firstEffect):E=C:E=C.firstEffect,E!==null){var $=Rt;Rt|=aa,c2.current=null,W(g.containerInfo),Ft=E;do try{e8()}catch(Q){if(Ft===null)throw Error(o(330));Zs(Ft,Q),Ft=Ft.nextEffect}while(Ft!==null);Ft=E;do try{for(var z=g,nt=y;Ft!==null;){var yt=Ft.effectTag;if(yt&16&&_t&&Ke(Ft.stateNode),yt&128){var bt=Ft.alternate;if(bt!==null){var Te=bt.ref;Te!==null&&(typeof Te=="function"?Te(null):Te.current=null)}}switch(yt&1038){case 2:a2(Ft),Ft.effectTag&=-3;break;case 6:a2(Ft),Ft.effectTag&=-3,mw(Ft.alternate,Ft);break;case 1024:Ft.effectTag&=-1025;break;case 1028:Ft.effectTag&=-1025,mw(Ft.alternate,Ft);break;case 4:mw(Ft.alternate,Ft);break;case 8:var Wt=z,oe=Ft,we=nt;_t?o2(Wt,oe,we):r2(Wt,oe,we),i2(oe)}Ft=Ft.nextEffect}}catch(Q){if(Ft===null)throw Error(o(330));Zs(Ft,Q),Ft=Ft.nextEffect}while(Ft!==null);q(g.containerInfo),g.current=C,Ft=E;do try{for(yt=g;Ft!==null;){var an=Ft.effectTag;if(an&36&&WU(yt,Ft.alternate,Ft),an&128){bt=void 0;var hr=Ft.ref;if(hr!==null){var rt=Ft.stateNode;switch(Ft.tag){case 5:bt=R(rt);break;default:bt=rt}typeof hr=="function"?hr(bt):hr.current=bt}}Ft=Ft.nextEffect}}catch(Q){if(Ft===null)throw Error(o(330));Zs(Ft,Q),Ft=Ft.nextEffect}while(Ft!==null);Ft=null,DU(),Rt=$}else g.current=C;if(yy)yy=!1,lv=g,sv=y;else for(Ft=E;Ft!==null;)y=Ft.nextEffect,Ft.nextEffect=null,Ft=y;if(y=g.firstPendingTime,y===0&&(_l=null),y===1073741823?g===Cw?uv++:(uv=0,Cw=g):uv=0,typeof Tw=="function"&&Tw(C.stateNode,T),$i(g),gy)throw gy=!1,g=ww,ww=null,g;return(Rt&xw)!==fr||On(),null}function e8(){for(;Ft!==null;){var g=Ft.effectTag;(g&256)!==0&&YU(Ft.alternate,Ft),(g&512)===0||yy||(yy=!0,xI(97,function(){return qs(),null})),Ft=Ft.nextEffect}}function qs(){if(sv!==90){var g=97<sv?97:sv;return sv=90,ia(g,r8)}}function r8(){if(lv===null)return!1;var g=lv;if(lv=null,(Rt&(Dn|aa))!==fr)throw Error(o(331));var y=Rt;for(Rt|=aa,g=g.current.firstEffect;g!==null;){try{var C=g;if((C.effectTag&512)!==0)switch(C.tag){case 0:case 11:case 15:case 22:pw(5,C),t2(5,C)}}catch(T){if(g===null)throw Error(o(330));Zs(g,T)}C=g.nextEffect,g.nextEffect=null,g=C}return Rt=y,On(),!0}function b2(g,y,C){y=vw(C,y),y=s2(g,y,1073741823),ml(g,y),g=xy(g,1073741823),g!==null&&$i(g)}function Zs(g,y){if(g.tag===3)b2(g,g,y);else for(var C=g.return;C!==null;){if(C.tag===3){b2(C,g,y);break}else if(C.tag===1){var T=C.stateNode;if(typeof C.type.getDerivedStateFromError=="function"||typeof T.componentDidCatch=="function"&&(_l===null||!_l.has(T))){g=vw(y,g),g=u2(C,g,1073741823),ml(C,g),C=xy(C,1073741823),C!==null&&$i(C);break}}C=C.return}}function i8(g,y,C){var T=g.pingCache;T!==null&&T.delete(y),nn===g&&Di===C?Rr===hy||Rr===fy&&Oo===1073741823&&Fn()-bw<h2?Xs(g,Di):py=!0:C2(g,C)&&(y=g.lastPingedTime,y!==0&&y<C||(g.lastPingedTime=C,$i(g)))}function n8(g,y){var C=g.stateNode;C!==null&&C.delete(y),y=0,y===0&&(y=oa(),y=Ws(y,g,null)),g=xy(g,y),g!==null&&$i(g)}var w2;w2=function(g,y,C){var T=y.expirationTime;if(g!==null){var E=y.pendingProps;if(g.memoizedProps!==E||kr.current)Na=!0;else{if(T<C){switch(Na=!1,y.tag){case 3:UI(y),sw();break;case 5:if(PI(y),y.mode&4&&C!==1&<(y.type,E))return y.expirationTime=y.childExpirationTime=1,null;break;case 1:ni(y.type)&&Sc(y);break;case 4:Zb(y,y.stateNode.containerInfo);break;case 10:wI(y,y.memoizedProps.value);break;case 13:if(y.memoizedState!==null)return T=y.child.childExpirationTime,T!==0&&T>=C?qI(g,y,C):(Ue(Je,Je.current&1),y=Fo(g,y,C),y!==null?y.sibling:null);Ue(Je,Je.current&1);break;case 19:if(T=y.childExpirationTime>=C,(g.effectTag&64)!==0){if(T)return QI(g,y,C);y.effectTag|=64}if(E=y.memoizedState,E!==null&&(E.rendering=null,E.tail=null),Ue(Je,Je.current),!T)return null}return Fo(g,y,C)}Na=!1}}else Na=!1;switch(y.expirationTime=0,y.tag){case 2:if(T=y.type,g!==null&&(g.alternate=null,y.alternate=null,y.effectTag|=2),g=y.pendingProps,E=To(y,or.current),Tc(y,C),E=tw(null,y,T,g,E,C),y.effectTag|=1,typeof E=="object"&&E!==null&&typeof E.render=="function"&&E.$$typeof===void 0){if(y.tag=1,y.memoizedState=null,y.updateQueue=null,ni(T)){var $=!0;Sc(y)}else $=!1;y.memoizedState=E.state!==null&&E.state!==void 0?E.state:null,Wb(y);var z=T.getDerivedStateFromProps;typeof z=="function"&&Wg(y,T,z,g),E.updater=Xg,y.stateNode=E,E._reactInternalFiber=y,Ub(y,T,g,C),y=cw(null,y,T,!0,$,C)}else y.tag=0,rn(null,y,E,C),y=y.child;return y;case 16:t:{if(E=y.elementType,g!==null&&(g.alternate=null,y.alternate=null,y.effectTag|=2),g=y.pendingProps,L(E),E._status!==1)throw E._result;switch(E=E._result,y.type=E,$=y.tag=l8(E),g=na(E,g),$){case 0:y=uw(null,y,E,g,C);break t;case 1:y=XI(null,y,E,g,C);break t;case 11:y=jI(null,y,E,g,C);break t;case 14:y=HI(null,y,E,na(E.type,g),T,C);break t}throw Error(o(306,E,""))}return y;case 0:return T=y.type,E=y.pendingProps,E=y.elementType===T?E:na(T,E),uw(g,y,T,E,C);case 1:return T=y.type,E=y.pendingProps,E=y.elementType===T?E:na(T,E),XI(g,y,T,E,C);case 3:if(UI(y),T=y.updateQueue,g===null||T===null)throw Error(o(282));if(T=y.pendingProps,E=y.memoizedState,E=E!==null?E.element:null,Xb(g,y),Kh(y,T,null,C),T=y.memoizedState.element,T===E)sw(),y=Fo(g,y,C);else{if((E=y.stateNode.hydrate)&&(qt?(Vs=Lg(y.stateNode.containerInfo),Eo=y,E=js=!0):E=!1),E)for(C=qb(y,null,T,C),y.child=C;C;)C.effectTag=C.effectTag&-3|1024,C=C.sibling;else rn(g,y,T,C),sw();y=y.child}return y;case 5:return PI(y),g===null&&lw(y),T=y.type,E=y.pendingProps,$=g!==null?g.memoizedProps:null,z=E.children,et(T,E)?z=null:$!==null&&et(T,$)&&(y.effectTag|=16),WI(g,y),y.mode&4&&C!==1&<(T,E)?(y.expirationTime=y.childExpirationTime=1,y=null):(rn(g,y,z,C),y=y.child),y;case 6:return g===null&&lw(y),null;case 13:return qI(g,y,C);case 4:return Zb(y,y.stateNode.containerInfo),T=y.pendingProps,g===null?y.child=Mc(y,null,T,C):rn(g,y,T,C),y.child;case 11:return T=y.type,E=y.pendingProps,E=y.elementType===T?E:na(T,E),jI(g,y,T,E,C);case 7:return rn(g,y,y.pendingProps,C),y.child;case 8:return rn(g,y,y.pendingProps.children,C),y.child;case 12:return rn(g,y,y.pendingProps.children,C),y.child;case 10:t:{if(T=y.type._context,E=y.pendingProps,z=y.memoizedProps,$=E.value,wI(y,$),z!==null){var nt=z.value;if($=Gs(nt,$)?0:(typeof T._calculateChangedBits=="function"?T._calculateChangedBits(nt,$):1073741823)|0,$===0){if(z.children===E.children&&!kr.current){y=Fo(g,y,C);break t}}else for(nt=y.child,nt!==null&&(nt.return=y);nt!==null;){var yt=nt.dependencies;if(yt!==null){z=nt.child;for(var bt=yt.firstContext;bt!==null;){if(bt.context===T&&(bt.observedBits&$)!==0){nt.tag===1&&(bt=yl(C,null),bt.tag=2,ml(nt,bt)),nt.expirationTime<C&&(nt.expirationTime=C),bt=nt.alternate,bt!==null&&bt.expirationTime<C&&(bt.expirationTime=C),CI(nt.return,C),yt.expirationTime<C&&(yt.expirationTime=C);break}bt=bt.next}}else z=nt.tag===10&&nt.type===y.type?null:nt.child;if(z!==null)z.return=nt;else for(z=nt;z!==null;){if(z===y){z=null;break}if(nt=z.sibling,nt!==null){nt.return=z.return,z=nt;break}z=z.return}nt=z}}rn(g,y,E.children,C),y=y.child}return y;case 9:return E=y.type,$=y.pendingProps,T=$.children,Tc(y,C),E=Pn(E,$.unstable_observedBits),T=T(E),y.effectTag|=1,rn(g,y,T,C),y.child;case 14:return E=y.type,$=na(E,y.pendingProps),$=na(E.type,$),HI(g,y,E,$,T,C);case 15:return YI(g,y,y.type,y.pendingProps,T,C);case 17:return T=y.type,E=y.pendingProps,E=y.elementType===T?E:na(T,E),g!==null&&(g.alternate=null,y.alternate=null,y.effectTag|=2),y.tag=1,ni(T)?(g=!0,Sc(y)):g=!1,Tc(y,C),EI(y,T,E),Ub(y,T,E,C),cw(null,y,T,!0,g,C);case 19:return QI(g,y,C)}throw Error(o(156,y.tag))};var wy={current:!1},Tw=null,Mw=null;function a8(g){if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__=="undefined")return!1;var y=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(y.isDisabled||!y.supportsFiber)return!0;try{var C=y.inject(g);Tw=function(T){try{y.onCommitFiberRoot(C,T,void 0,(T.current.effectTag&64)===64)}catch{}},Mw=function(T){try{y.onCommitFiberUnmount(C,T)}catch{}}}catch{}return!0}function o8(g,y,C,T){this.tag=g,this.key=C,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=y,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=T,this.effectTag=0,this.lastEffect=this.firstEffect=this.nextEffect=null,this.childExpirationTime=this.expirationTime=0,this.alternate=null}function za(g,y,C,T){return new o8(g,y,C,T)}function Ew(g){return g=g.prototype,!(!g||!g.isReactComponent)}function l8(g){if(typeof g=="function")return Ew(g)?1:0;if(g!=null){if(g=g.$$typeof,g===m)return 11;if(g===w)return 14}return 2}function Qs(g,y){var C=g.alternate;return C===null?(C=za(g.tag,y,g.key,g.mode),C.elementType=g.elementType,C.type=g.type,C.stateNode=g.stateNode,C.alternate=g,g.alternate=C):(C.pendingProps=y,C.effectTag=0,C.nextEffect=null,C.firstEffect=null,C.lastEffect=null),C.childExpirationTime=g.childExpirationTime,C.expirationTime=g.expirationTime,C.child=g.child,C.memoizedProps=g.memoizedProps,C.memoizedState=g.memoizedState,C.updateQueue=g.updateQueue,y=g.dependencies,C.dependencies=y===null?null:{expirationTime:y.expirationTime,firstContext:y.firstContext,responders:y.responders},C.sibling=g.sibling,C.index=g.index,C.ref=g.ref,C}function Cy(g,y,C,T,E,$){var z=2;if(T=g,typeof g=="function")Ew(g)&&(z=1);else if(typeof g=="string")z=5;else t:switch(g){case f:return bl(C.children,E,$,y);case x:z=8,E|=7;break;case h:z=8,E|=1;break;case v:return g=za(12,C,y,E|8),g.elementType=v,g.type=v,g.expirationTime=$,g;case _:return g=za(13,C,y,E),g.type=_,g.elementType=_,g.expirationTime=$,g;case b:return g=za(19,C,y,E),g.elementType=b,g.expirationTime=$,g;default:if(typeof g=="object"&&g!==null)switch(g.$$typeof){case d:z=10;break t;case p:z=9;break t;case m:z=11;break t;case w:z=14;break t;case S:z=16,T=null;break t;case M:z=22;break t}throw Error(o(130,g==null?g:typeof g,""))}return y=za(z,C,y,E),y.elementType=g,y.type=T,y.expirationTime=$,y}function bl(g,y,C,T){return g=za(7,g,T,y),g.expirationTime=C,g}function Fw(g,y,C){return g=za(6,g,null,y),g.expirationTime=C,g}function Ow(g,y,C){return y=za(4,g.children!==null?g.children:[],g.key,y),y.expirationTime=C,y.stateNode={containerInfo:g.containerInfo,pendingChildren:null,implementation:g.implementation},y}function s8(g,y,C){this.tag=y,this.current=null,this.containerInfo=g,this.pingCache=this.pendingChildren=null,this.finishedExpirationTime=0,this.finishedWork=null,this.timeoutHandle=gt,this.pendingContext=this.context=null,this.hydrate=C,this.callbackNode=null,this.callbackPriority=90,this.lastExpiredTime=this.lastPingedTime=this.nextKnownPendingLevel=this.lastSuspendedTime=this.firstSuspendedTime=this.firstPendingTime=0}function C2(g,y){var C=g.firstSuspendedTime;return g=g.lastSuspendedTime,C!==0&&C>=y&&g<=y}function Ks(g,y){var C=g.firstSuspendedTime,T=g.lastSuspendedTime;C<y&&(g.firstSuspendedTime=y),(T>y||C===0)&&(g.lastSuspendedTime=y),y<=g.lastPingedTime&&(g.lastPingedTime=0),y<=g.lastExpiredTime&&(g.lastExpiredTime=0)}function S2(g,y){y>g.firstPendingTime&&(g.firstPendingTime=y);var C=g.firstSuspendedTime;C!==0&&(y>=C?g.firstSuspendedTime=g.lastSuspendedTime=g.nextKnownPendingLevel=0:y>=g.lastSuspendedTime&&(g.lastSuspendedTime=y+1),y>g.nextKnownPendingLevel&&(g.nextKnownPendingLevel=y))}function Sy(g,y){var C=g.lastExpiredTime;(C===0||C>y)&&(g.lastExpiredTime=y)}var Ay=null;function u8(g){if(Ay===null)try{var y=("require"+Math.random()).slice(0,7);Ay=(e&&e[y])("timers").setImmediate}catch{Ay=function(T){var E=new MessageChannel;E.port1.onmessage=T,E.port2.postMessage(void 0)}}return Ay(g)}function A2(g){var y=g._reactInternalFiber;if(y===void 0)throw typeof g.render=="function"?Error(o(188)):Error(o(268,Object.keys(g)));return g=j(y),g===null?null:g.stateNode}function T2(g,y){g=g.memoizedState,g!==null&&g.dehydrated!==null&&g.retryTime<y&&(g.retryTime=y)}function Ty(g,y){T2(g,y),(g=g.alternate)&&T2(g,y)}var Pw=l.IsSomeRendererActing,M2=typeof a.unstable_flushAllWithoutAsserting=="function",Iw=a.unstable_flushAllWithoutAsserting||function(){for(var g=!1;qs();)g=!0;return g};function E2(g){try{Iw(),u8(function(){Iw()?E2(g):g()})}catch(y){g(y)}}var My=0,F2=!1,Lw={__proto__:null,createContainer:function(g,y,C){return g=new s8(g,y,C),y=za(3,null,null,y===2?7:y===1?3:0),g.current=y,y.stateNode=g,Wb(y),g},updateContainer:function(g,y,C,T){var E=y.current,$=oa(),z=Jh.suspense;$=Ws($,E,z);t:if(C){C=C._reactInternalFiber;e:{if(k(C)!==C||C.tag!==1)throw Error(o(170));var nt=C;do{switch(nt.tag){case 3:nt=nt.stateNode.context;break e;case 1:if(ni(nt.type)){nt=nt.stateNode.__reactInternalMemoizedMergedChildContext;break e}}nt=nt.return}while(nt!==null);throw Error(o(171))}if(C.tag===1){var yt=C.type;if(ni(yt)){C=kg(C,yt,nt);break t}}C=nt}else C=Ra;return y.context===null?y.context=C:y.pendingContext=C,y=yl($,z),y.payload={element:g},T=T===void 0?null:T,T!==null&&(y.callback=T),ml(E,y),Po(E,$),$},batchedEventUpdates:function(g,y){var C=Rt;Rt|=2;try{return g(y)}finally{Rt=C,Rt===fr&&On()}},batchedUpdates:d2,unbatchedUpdates:function(g,y){var C=Rt;Rt&=-2,Rt|=xw;try{return g(y)}finally{Rt=C,Rt===fr&&On()}},deferredUpdates:function(g){return ia(97,g)},syncUpdates:function(g,y,C,T){return ia(99,g.bind(null,y,C,T))},discreteUpdates:function(g,y,C,T,E){var $=Rt;Rt|=4;try{return ia(98,g.bind(null,y,C,T,E))}finally{Rt=$,Rt===fr&&On()}},flushDiscreteUpdates:function(){(Rt&(1|Dn|aa))===fr&&(QU(),qs())},flushControlled:function(g){var y=Rt;Rt|=1;try{ia(99,g)}finally{Rt=y,Rt===fr&&On()}},flushSync:p2,flushPassiveEffects:qs,IsThisRendererActing:wy,getPublicRootInstance:function(g){if(g=g.current,!g.child)return null;switch(g.child.tag){case 5:return R(g.child.stateNode);default:return g.child.stateNode}},attemptSynchronousHydration:function(g){switch(g.tag){case 3:var y=g.stateNode;y.hydrate&&ZU(y,y.firstPendingTime);break;case 13:p2(function(){return Po(g,1073741823)}),y=Qh(oa(),150,100),Ty(g,y)}},attemptUserBlockingHydration:function(g){if(g.tag===13){var y=Qh(oa(),150,100);Po(g,y),Ty(g,y)}},attemptContinuousHydration:function(g){g.tag===13&&(Po(g,3),Ty(g,3))},attemptHydrationAtCurrentPriority:function(g){if(g.tag===13){var y=oa();y=Ws(y,g,null),Po(g,y),Ty(g,y)}},findHostInstance:A2,findHostInstanceWithWarning:function(g){return A2(g)},findHostInstanceWithNoPortals:function(g){return g=U(g),g===null?null:g.tag===20?g.stateNode.instance:g.stateNode},shouldSuspend:function(){return!1},injectIntoDevTools:function(g){var y=g.findFiberByHostInstance;return a8(i({},g,{overrideHookState:null,overrideProps:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:l.ReactCurrentDispatcher,findHostInstanceByFiber:function(C){return C=j(C),C===null?null:C.stateNode},findFiberByHostInstance:function(C){return y?y(C):null},findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null}))},act:function(g){function y(){My--,Pw.current=C,wy.current=T}F2===!1&&(F2=!0,console.error("act(...) is not supported in production builds of React, and might not behave as expected.")),My++;var C=Pw.current,T=wy.current;Pw.current=!0,wy.current=!0;try{var E=d2(g)}catch($){throw y(),$}if(E!==null&&typeof E=="object"&&typeof E.then=="function")return{then:function($,z){E.then(function(){1<My||M2===!0&&C===!0?(y(),$()):E2(function(nt){y(),nt?z(nt):$()})},function(nt){y(),z(nt)})}};try{My!==1||M2!==!1&&C!==!1||Iw(),y()}catch($){throw y(),$}return{then:function($){$()}}}},O2=Lw&&Lw.default||Lw;e.exports=O2.default||O2;var c8=e.exports;return e.exports=r,c8}})(iY);rY.exports=iY.exports;var Vmt=rY.exports,fT=globalThis&&globalThis.__assign||function(){return fT=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},fT.apply(this,arguments)},lg=Pt.createContext(null);lg.displayName="GroupContext";function Da(e){var r=Pt.forwardRef(function(t,i){return Pt.createElement(lg.Consumer,null,function(n){return Pt.createElement(e,fT({ref:i,group:n},t))})});return r.displayName=e.name,r}var jmt={},Hmt={getRootHostContext:function(){},getChildHostContext:function(){},createInstance:function(){},finalizeInitialChildren:function(){return!1},hideTextInstance:function(){},getPublicInstance:function(e){return e},hideInstance:function(){},unhideInstance:function(){},createTextInstance:function(){},prepareUpdate:function(){return jmt},shouldDeprioritizeSubtree:function(){return!1},appendInitialChild:function(){},appendChildToContainer:function(){},removeChildFromContainer:function(){},prepareForCommit:function(){},resetAfterCommit:function(){},shouldSetTextContent:function(){return!1},supportsMutation:!0,appendChild:function(){}};Vmt(Hmt);var dx=globalThis&&globalThis.__assign||function(){return dx=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},dx.apply(this,arguments)},Ymt=globalThis&&globalThis.__rest||function(e,r){var t={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&r.indexOf(i)<0&&(t[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,i=Object.getOwnPropertySymbols(e);n<i.length;n++)r.indexOf(i[n])<0&&Object.prototype.propertyIsEnumerable.call(e,i[n])&&(t[i[n]]=e[i[n]]);return t};function aO(e,r){r===void 0&&(r="ChartContainer");var t=Pt.forwardRef(function(i,n){var a=Ur.exports.useRef(),o=Ur.exports.useState(!1),l=o[0],s=o[1],u=i,c=u.className,f=c===void 0?"bizcharts":c,h=u.containerStyle,v=Ymt(u,["className","containerStyle"]);return Ur.exports.useEffect(function(){s(!0)},[]),Ci("div",{ref:a,className:f,style:dx({position:"relative",height:i.height||"100%",width:i.width||"100%"},h),children:l?Ci(e,{...dx({ref:n,container:a.current},v)}):Ci(p8,{})})});return t.displayName=r||e.name,t}var mR=globalThis&&globalThis.__assign||function(){return mR=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},mR.apply(this,arguments)},oY=Pt.createContext(null);oY.displayName="CanvasContext";var Wmt=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}(),Qd=globalThis&&globalThis.__assign||function(){return Qd=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Qd.apply(this,arguments)},Xmt=globalThis&&globalThis.__rest||function(e,r){var t={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&r.indexOf(i)<0&&(t[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,i=Object.getOwnPropertySymbols(e);n<i.length;n++)r.indexOf(i[n])<0&&Object.prototype.propertyIsEnumerable.call(e,i[n])&&(t[i[n]]=e[i[n]]);return t},Umt=function(){function e(){}return e.prototype.createInstance=function(r){r.children;var t=r.renderer,i=Xmt(r,["children","renderer"]);t==="svg"?this.instance=new wj(Qd({},i)):this.instance=new sj(Qd({},i))},e.prototype.update=function(r){this.instance||this.createInstance(r)},e.prototype.draw=function(){!this.instance||this.instance.draw()},e.prototype.destory=function(){this.instance&&(this.instance.remove(),this.instance=null)},e}(),qmt=function(e){Wmt(r,e);function r(t){var i=e.call(this,t)||this;return i.helper=new Umt,i}return r.prototype.componentDidMount=function(){this.helper.draw()},r.prototype.componentWillUnmount=function(){this.helper.destory()},r.prototype.getInstance=function(){return this.helper.instance},r.prototype.render=function(){return this.helper.update(this.props),Pt.createElement(Xd,Qd({},this.props.ErrorBoundaryProps),Pt.createElement(oY.Provider,{value:this.helper},Pt.createElement(lg.Provider,{value:this.helper.instance},Pt.createElement(Pt.Fragment,null,this.props.children))))},r}(Pt.Component);aO(qmt);var lY={},oO={},Dh={},Ls={};Object.defineProperty(Ls,"__esModule",{value:!0});var Zmt={}.toString,Qmt=function(e,r){return Zmt.call(e)==="[object "+r+"]"};Ls.default=Qmt;Object.defineProperty(Dh,"__esModule",{value:!0});var Kmt=Ls,sr=Dh.default=function(e){return Array.isArray?Array.isArray(e):Kmt.default(e,"Array")},g_={};Object.defineProperty(g_,"__esModule",{value:!0});var px=g_.default=function(e){var r=typeof e;return e!==null&&r==="object"||r==="function"};Object.defineProperty(oO,"__esModule",{value:!0});var Jmt=Dh,t0t=g_;function e0t(e,r){if(!!e){var t;if(Jmt.default(e))for(var i=0,n=e.length;i<n&&(t=r(e[i],i),t!==!1);i++);else if(t0t.default(e)){for(var a in e)if(e.hasOwnProperty(a)&&(t=r(e[a],a),t===!1))break}}}var xs=oO.default=e0t;Object.defineProperty(lY,"__esModule",{value:!0});var r0t=oO,Zf=lY.default=r0t.default,lO={};Object.defineProperty(lO,"__esModule",{value:!0});var i0t=Ls,Sa=lO.default=function(e){return i0t.default(e,"Function")},sY={};Object.defineProperty(sY,"__esModule",{value:!0});function n0t(e,r,t){var i;return function(){var n=this,a=arguments,o=function(){i=null,t||e.apply(n,a)},l=t&&!i;clearTimeout(i),i=setTimeout(o,r),l&&e.apply(n,a)}}var uY=sY.default=n0t,cY={};Object.defineProperty(cY,"__esModule",{value:!0});var Vm={},Kd=cY.default=function(e){return e=e||"g",Vm[e]?Vm[e]+=1:Vm[e]=1,e+Vm[e]},fY={onClick:"click",onMousedown:"mousedown",onMouseup:"mouseup",onDblclick:"dblclick",onMouseout:"mouseout",onMouseover:"mouseover",onMousemove:"mousemove",onMouseleave:"mouseleave",onMouseenter:"mouseenter",onTouchstart:"touchstart",onTouchmove:"touchmove",onTouchend:"touchend",onDragenter:"dragenter",onDragover:"dragover",onDragleave:"dragleave",onDrop:"drop",onContextmenu:"contextmenu"},a0t=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}(),o0t=globalThis&&globalThis.__rest||function(e,r){var t={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&r.indexOf(i)<0&&(t[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,i=Object.getOwnPropertySymbols(e);n<i.length;n++)r.indexOf(i[n])<0&&Object.prototype.propertyIsEnumerable.call(e,i[n])&&(t[i[n]]=e[i[n]]);return t},l0t=function(e){a0t(r,e);function r(t){var i=e.call(this,t)||this;i.state={isReady:!1},i.handleRender=uY(function(){if(i.instance)i.forceUpdate();else{var l=i.props,s=l.group,u=l.zIndex,c=l.name;i.instance=s.chart.canvas.addGroup({zIndex:u,name:c}),s.chart.canvas.sort(),i.setState({isReady:!0})}},300),i.configGroup=function(l){var s,u=l.rotate,c=l.animate,f=l.rotateAtPoint,h=l.scale,v=l.translate,d=l.move;if(u&&i.instance.rotate(u),sr(f)&&(s=i.instance).rotateAtPoint.apply(s,f),h&&i.instance.rotate(h),v&&i.instance.translate(v[0],v[1]),d&&i.instance.move(d.x,d.y),c){var p=c.toAttrs,x=o0t(c,["toAttrs"]);i.instance.animate(p,x)}},i.bindEvents=function(){i.instance.off(),Zf(fY,function(l,s){Sa(i.props[s])&&i.instance.on(l,i.props[s])})};var n=t.group,a=t.zIndex,o=t.name;return i.id=Kd("group"),n.isChartCanvas?n.chart.on("afterrender",i.handleRender):(i.instance=n.addGroup({zIndex:a,name:o}),i.configGroup(t)),i}return r.prototype.componentWillUnmount=function(){var t=this.props.group;t.isChartCanvas&&t.chart.off("afterrender",this.handleRender),this.instance&&this.instance.remove(!0)},r.prototype.getInstance=function(){return this.instance},r.prototype.render=function(){var t=this.props.group;return this.instance&&(this.instance.clear(),this.bindEvents()),t.isChartCanvas&&this.state.isReady||!t.isChartCanvas?Pt.createElement(lg.Provider,{value:this.instance},Pt.createElement(Pt.Fragment,{key:Kd(this.id)},this.props.children)):Pt.createElement(Pt.Fragment,null)},r.defaultProps={zIndex:3},r}(Pt.Component);Da(l0t);var sg={};Object.defineProperty(sg,"__esModule",{value:!0});var s0t=Ls,$h=sg.default=function(e){return s0t.default(e,"String")},ts=function(e,r){var t={};return xs(e,function(i,n){var a=!1;r.forEach(function(o){($h(o)&&o===n||o instanceof RegExp&&n.match(o))&&(a=!0)}),a||(t[n]=i)}),t},Mf=["children","hooks","ref"],Qf=function(e){var r=[],t=function(i){if(r.push(i),r.includes(i)||typeof i!="object"||i===null)return i;var n;if(sr(i)){n=[];for(var a=0,o=i.length;a<o;a++)typeof i[a]=="object"&&i[a]!=null?n[a]=t(i[a]):n[a]=i[a]}else n={},Zf(i,function(l,s){typeof l=="object"&&l!=null?n[s]=t(l):n[s]=l});return n};return t(e)},xR=globalThis&&globalThis.__rest||function(e,r){var t={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&r.indexOf(i)<0&&(t[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,i=Object.getOwnPropertySymbols(e);n<i.length;n++)r.indexOf(i[n])<0&&Object.prototype.propertyIsEnumerable.call(e,i[n])&&(t[i[n]]=e[i[n]]);return t},u0t=globalThis&&globalThis.__spreadArrays||function(){for(var e=0,r=0,t=arguments.length;r<t;r++)e+=arguments[r].length;for(var i=Array(e),n=0,r=0;r<t;r++)for(var a=arguments[r],o=0,l=a.length;o<l;o++,n++)i[n]=a[o];return i},bo=function(){function e(r){this.shape=r}return e.prototype.createInstance=function(r){this.instance=r.group.addShape(this.shape,ts(r,["group","ctx"]))},e.prototype.destroy=function(){this.instance&&(this.instance.remove(!0),this.instance=null)},e.prototype.update=function(r){var t=this,i=ts(r,u0t(Mf));this.destroy(),this.createInstance(i);var n=i.attrs,a=i.animate,o=i.isClipShape,l=i.visible,s=i.matrix,u=xR(i,["attrs","animate","isClipShape","visible","matrix"]);if(this.instance.attr(n),a){var c=a.toAttrs,f=xR(a,["toAttrs"]);this.instance.animate(c,f)}o&&this.instance.isClipShape(),l===!1&&this.instance.hide(),s&&this.instance.setMatrix(s),Zf(fY,function(h,v){Sa(u[v])&&t.instance.on(h,u[v])}),this.config=Qf(i)},e}(),c0t=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}(),wo=function(e){c0t(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.componentWillUnmount=function(){this.helper.destroy()},r.prototype.getInstance=function(){return this.helper.instance},r.prototype.render=function(){return this.helper.update(this.props),null},r}(Pt.Component),f0t=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}(),h0t=function(e){f0t(r,e);function r(t){var i=e.call(this,t)||this;return i.helper=new bo("circle"),i}return r}(wo);Da(h0t);var v0t=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}(),d0t=function(e){v0t(r,e);function r(t){var i=e.call(this,t)||this;return i.helper=new bo("ellipse"),i}return r}(wo);Da(d0t);var p0t=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}(),g0t=function(e){p0t(r,e);function r(t){var i=e.call(this,t)||this;return i.helper=new bo("image"),i}return r}(wo);Da(g0t);var y0t=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}(),m0t=function(e){y0t(r,e);function r(t){var i=e.call(this,t)||this;return i.helper=new bo("line"),i}return r}(wo);Da(m0t);var x0t=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}(),_0t=function(e){x0t(r,e);function r(t){var i=e.call(this,t)||this;return i.helper=new bo("marker"),i}return r}(wo);Da(_0t);var b0t=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}(),w0t=function(e){b0t(r,e);function r(t){var i=e.call(this,t)||this;return i.helper=new bo("path"),i}return r}(wo);Da(w0t);var C0t=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}(),S0t=function(e){C0t(r,e);function r(t){var i=e.call(this,t)||this;return i.helper=new bo("polygon"),i}return r}(wo);Da(S0t);var A0t=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}(),T0t=function(e){A0t(r,e);function r(t){var i=e.call(this,t)||this;return i.helper=new bo("polyline"),i}return r}(wo);Da(T0t);var M0t=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}(),E0t=function(e){M0t(r,e);function r(t){var i=e.call(this,t)||this;return i.helper=new bo("rect"),i}return r}(wo);Da(E0t);var F0t=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}(),O0t=function(e){F0t(r,e);function r(t){var i=e.call(this,t)||this;return i.helper=new bo("text"),i}return r}(wo);Da(O0t);var gx=globalThis&&globalThis.__assign||function(){return gx=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},gx.apply(this,arguments)},P0t=function(e,r,t,i){var n=[];return e.forEach(function(a){r.forEach(function(o){var l;n.push(gx(gx({},a),(l={},l[t]=o,l[i]=a[o],l)))})}),n};function hY(e){if(e.length===0)return 0;for(var r=e[0],t=0,i,n=1;n<e.length;n++)i=r+e[n],Math.abs(r)>=Math.abs(e[n])?t+=r-i+e[n]:t+=e[n]-i+r,r=i;return r+t}var vY={};Object.defineProperty(vY,"__esModule",{value:!0});var I0t=Dh,L0t=lO,D0t=Object.prototype.hasOwnProperty;function $0t(e,r){if(!r||!I0t.default(e))return{};for(var t={},i=L0t.default(r)?r:function(l){return l[r]},n,a=0;a<e.length;a++){var o=e[a];n=i(o),D0t.call(t,n)?t[n].push(o):t[n]=[o]}return t}var k0t=vY.default=$0t;function R0t(e,r){r===void 0&&(r=[]);var t;return Sa(r)?t=r:sr(r)?t=function(i,n){for(var a=0;a<r.length;a++){var o=r[a];if(i[o]<n[o])return-1;if(i[o]>n[o])return 1}return 0}:$h(r)&&(t=function(i,n){return i[r]<n[r]?-1:i[r]>n[r]?1:0}),e.sort(t)}function B0t(e,r,t){t===void 0&&(t=[]);var i=e;t&&t.length&&(i=R0t(e,t));var n;Sa(r)?n=r:sr(r)?n=function(o){return"_"+r.map(function(l){return o[l]}).join("-")}:$h(r)&&(n=function(o){return"_"+o[r]});var a=k0t(i,n);return a}var hT=globalThis&&globalThis.__assign||function(){return hT=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},hT.apply(this,arguments)},N0t=function(e,r,t,i){var n=[],a=i?B0t(e,i):{_data:e};return Zf(a,function(o){var l=hY(o.map(function(s){return s[r]}));Zf(o,function(s){var u=hT({},s);l===0?u[t]=0:u[t]=s[r]/l,n.push(u)})}),n},G0t=function(e,r){r===void 0&&(r=2);var t=1e4,i=1e8;return e>=i?(e/i).toFixed(r).replace(/\.?0*$/,"")+"\u4EBF":e>=t?(e/t).toFixed(r).replace(/\.?0*$/,"")+"\u4E07":e.toFixed(r).replace(/\.?0*$/,"")},z0t=function(e,r){return r===void 0&&(r=","),typeof e=="number"?e.toString().replace(/\B(?=(\d{3})+(?!\d))/g,r):e},dY={};Object.defineProperty(dY,"__esModule",{value:!0});var V0t=Ls,j0t=function(e){return V0t.default(e,"Boolean")},H0t=dY.default=j0t,vT=globalThis&&globalThis.__assign||function(){return vT=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},vT.apply(this,arguments)},dT=function(e,r){return r===void 0&&(r=!0),$h(e)||Pt.isValidElement(e)?{visible:!0,text:e}:H0t(e)?{visible:e}:px(e)?vT({visible:!0},e):{visible:r}};function _R(e,r){return e===r?e!==0||r!==0||1/e===1/r:e!==e&&r!==r}function bR(e){return sr(e)?e.length:px(e)?Object.keys(e).length:0}function ug(e,r){if(_R(e,r))return!0;if(typeof e!="object"||e===null||typeof r!="object"||r===null||sr(e)!==sr(r)||bR(e)!==bR(r))return!1;var t=!0;return xs(e,function(i,n){return _R(i,r[n])?!0:(t=!1,t)}),t}var Y0t=Object.freeze(Object.defineProperty({__proto__:null,fold:P0t,percentage:N0t,minifyNum:G0t,splitBySeparator:z0t,visibleHelper:dT,cloneDeep:Qf,shallowEqual:ug},Symbol.toStringTag,{value:"Module"})),Gu=[],W0t=function(){return Gu.some(function(e){return e.activeTargets.length>0})},X0t=function(){return Gu.some(function(e){return e.skippedTargets.length>0})},wR="ResizeObserver loop completed with undelivered notifications.",U0t=function(){var e;typeof ErrorEvent=="function"?e=new ErrorEvent("error",{message:wR}):(e=document.createEvent("Event"),e.initEvent("error",!1,!1),e.message=wR),window.dispatchEvent(e)},Jd;(function(e){e.BORDER_BOX="border-box",e.CONTENT_BOX="content-box",e.DEVICE_PIXEL_CONTENT_BOX="device-pixel-content-box"})(Jd||(Jd={}));var zu=function(e){return Object.freeze(e)},q0t=function(){function e(r,t){this.inlineSize=r,this.blockSize=t,zu(this)}return e}(),pY=function(){function e(r,t,i,n){return this.x=r,this.y=t,this.width=i,this.height=n,this.top=this.y,this.left=this.x,this.bottom=this.top+this.height,this.right=this.left+this.width,zu(this)}return e.prototype.toJSON=function(){var r=this,t=r.x,i=r.y,n=r.top,a=r.right,o=r.bottom,l=r.left,s=r.width,u=r.height;return{x:t,y:i,top:n,right:a,bottom:o,left:l,width:s,height:u}},e.fromRect=function(r){return new e(r.x,r.y,r.width,r.height)},e}(),sO=function(e){return e instanceof SVGElement&&"getBBox"in e},gY=function(e){if(sO(e)){var r=e.getBBox(),t=r.width,i=r.height;return!t&&!i}var n=e,a=n.offsetWidth,o=n.offsetHeight;return!(a||o||e.getClientRects().length)},CR=function(e){var r;if(e instanceof Element)return!0;var t=(r=e==null?void 0:e.ownerDocument)===null||r===void 0?void 0:r.defaultView;return!!(t&&e instanceof t.Element)},Z0t=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},wd=typeof window!="undefined"?window:{},jm=new WeakMap,SR=/auto|scroll/,Q0t=/^tb|vertical/,K0t=/msie|trident/i.test(wd.navigator&&wd.navigator.userAgent),Xa=function(e){return parseFloat(e||"0")},Ef=function(e,r,t){return e===void 0&&(e=0),r===void 0&&(r=0),t===void 0&&(t=!1),new q0t((t?r:e)||0,(t?e:r)||0)},AR=zu({devicePixelContentBoxSize:Ef(),borderBoxSize:Ef(),contentBoxSize:Ef(),contentRect:new pY(0,0,0,0)}),yY=function(e,r){if(r===void 0&&(r=!1),jm.has(e)&&!r)return jm.get(e);if(gY(e))return jm.set(e,AR),AR;var t=getComputedStyle(e),i=sO(e)&&e.ownerSVGElement&&e.getBBox(),n=!K0t&&t.boxSizing==="border-box",a=Q0t.test(t.writingMode||""),o=!i&&SR.test(t.overflowY||""),l=!i&&SR.test(t.overflowX||""),s=i?0:Xa(t.paddingTop),u=i?0:Xa(t.paddingRight),c=i?0:Xa(t.paddingBottom),f=i?0:Xa(t.paddingLeft),h=i?0:Xa(t.borderTopWidth),v=i?0:Xa(t.borderRightWidth),d=i?0:Xa(t.borderBottomWidth),p=i?0:Xa(t.borderLeftWidth),x=f+u,m=s+c,_=p+v,b=h+d,w=l?e.offsetHeight-b-e.clientHeight:0,S=o?e.offsetWidth-_-e.clientWidth:0,M=n?x+_:0,F=n?m+b:0,O=i?i.width:Xa(t.width)-M-S,L=i?i.height:Xa(t.height)-F-w,D=O+x+S+_,k=L+m+w+b,H=zu({devicePixelContentBoxSize:Ef(Math.round(O*devicePixelRatio),Math.round(L*devicePixelRatio),a),borderBoxSize:Ef(D,k,a),contentBoxSize:Ef(O,L,a),contentRect:new pY(f,s,O,L)});return jm.set(e,H),H},mY=function(e,r,t){var i=yY(e,t),n=i.borderBoxSize,a=i.contentBoxSize,o=i.devicePixelContentBoxSize;switch(r){case Jd.DEVICE_PIXEL_CONTENT_BOX:return o;case Jd.BORDER_BOX:return n;default:return a}},J0t=function(){function e(r){var t=yY(r);this.target=r,this.contentRect=t.contentRect,this.borderBoxSize=zu([t.borderBoxSize]),this.contentBoxSize=zu([t.contentBoxSize]),this.devicePixelContentBoxSize=zu([t.devicePixelContentBoxSize])}return e}(),xY=function(e){if(gY(e))return 1/0;for(var r=0,t=e.parentNode;t;)r+=1,t=t.parentNode;return r},txt=function(){var e=1/0,r=[];Gu.forEach(function(o){if(o.activeTargets.length!==0){var l=[];o.activeTargets.forEach(function(u){var c=new J0t(u.target),f=xY(u.target);l.push(c),u.lastReportedSize=mY(u.target,u.observedBox),f<e&&(e=f)}),r.push(function(){o.callback.call(o.observer,l,o.observer)}),o.activeTargets.splice(0,o.activeTargets.length)}});for(var t=0,i=r;t<i.length;t++){var n=i[t];n()}return e},TR=function(e){Gu.forEach(function(t){t.activeTargets.splice(0,t.activeTargets.length),t.skippedTargets.splice(0,t.skippedTargets.length),t.observationTargets.forEach(function(n){n.isActive()&&(xY(n.target)>e?t.activeTargets.push(n):t.skippedTargets.push(n))})})},ext=function(){var e=0;for(TR(e);W0t();)e=txt(),TR(e);return X0t()&&U0t(),e>0},hS,_Y=[],rxt=function(){return _Y.splice(0).forEach(function(e){return e()})},ixt=function(e){if(!hS){var r=0,t=document.createTextNode(""),i={characterData:!0};new MutationObserver(function(){return rxt()}).observe(t,i),hS=function(){t.textContent="".concat(r?r--:r++)}}_Y.push(e),hS()},nxt=function(e){ixt(function(){requestAnimationFrame(e)})},T0=0,axt=function(){return!!T0},oxt=250,lxt={attributes:!0,characterData:!0,childList:!0,subtree:!0},MR=["resize","load","transitionend","animationend","animationstart","animationiteration","keyup","keydown","mouseup","mousedown","mouseover","mouseout","blur","focus"],ER=function(e){return e===void 0&&(e=0),Date.now()+e},vS=!1,sxt=function(){function e(){var r=this;this.stopped=!0,this.listener=function(){return r.schedule()}}return e.prototype.run=function(r){var t=this;if(r===void 0&&(r=oxt),!vS){vS=!0;var i=ER(r);nxt(function(){var n=!1;try{n=ext()}finally{if(vS=!1,r=i-ER(),!axt())return;n?t.run(1e3):r>0?t.run(r):t.start()}})}},e.prototype.schedule=function(){this.stop(),this.run()},e.prototype.observe=function(){var r=this,t=function(){return r.observer&&r.observer.observe(document.body,lxt)};document.body?t():wd.addEventListener("DOMContentLoaded",t)},e.prototype.start=function(){var r=this;this.stopped&&(this.stopped=!1,this.observer=new MutationObserver(this.listener),this.observe(),MR.forEach(function(t){return wd.addEventListener(t,r.listener,!0)}))},e.prototype.stop=function(){var r=this;this.stopped||(this.observer&&this.observer.disconnect(),MR.forEach(function(t){return wd.removeEventListener(t,r.listener,!0)}),this.stopped=!0)},e}(),pT=new sxt,FR=function(e){!T0&&e>0&&pT.start(),T0+=e,!T0&&pT.stop()},uxt=function(e){return!sO(e)&&!Z0t(e)&&getComputedStyle(e).display==="inline"},cxt=function(){function e(r,t){this.target=r,this.observedBox=t||Jd.CONTENT_BOX,this.lastReportedSize={inlineSize:0,blockSize:0}}return e.prototype.isActive=function(){var r=mY(this.target,this.observedBox,!0);return uxt(this.target)&&(this.lastReportedSize=r),this.lastReportedSize.inlineSize!==r.inlineSize||this.lastReportedSize.blockSize!==r.blockSize},e}(),fxt=function(){function e(r,t){this.activeTargets=[],this.skippedTargets=[],this.observationTargets=[],this.observer=r,this.callback=t}return e}(),Hm=new WeakMap,OR=function(e,r){for(var t=0;t<e.length;t+=1)if(e[t].target===r)return t;return-1},Ym=function(){function e(){}return e.connect=function(r,t){var i=new fxt(r,t);Hm.set(r,i)},e.observe=function(r,t,i){var n=Hm.get(r),a=n.observationTargets.length===0;OR(n.observationTargets,t)<0&&(a&&Gu.push(n),n.observationTargets.push(new cxt(t,i&&i.box)),FR(1),pT.schedule())},e.unobserve=function(r,t){var i=Hm.get(r),n=OR(i.observationTargets,t),a=i.observationTargets.length===1;n>=0&&(a&&Gu.splice(Gu.indexOf(i),1),i.observationTargets.splice(n,1),FR(-1))},e.disconnect=function(r){var t=this,i=Hm.get(r);i.observationTargets.slice().forEach(function(n){return t.unobserve(r,n.target)}),i.activeTargets.splice(0,i.activeTargets.length)},e}(),bY=function(){function e(r){if(arguments.length===0)throw new TypeError("Failed to construct 'ResizeObserver': 1 argument required, but only 0 present.");if(typeof r!="function")throw new TypeError("Failed to construct 'ResizeObserver': The callback provided as parameter 1 is not a function.");Ym.connect(this,r)}return e.prototype.observe=function(r,t){if(arguments.length===0)throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!CR(r))throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': parameter 1 is not of type 'Element");Ym.observe(this,r,t)},e.prototype.unobserve=function(r){if(arguments.length===0)throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!CR(r))throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': parameter 1 is not of type 'Element");Ym.unobserve(this,r)},e.prototype.disconnect=function(){Ym.disconnect(this)},e.toString=function(){return"function ResizeObserver () { [polyfill code] }"},e}(),PR=globalThis&&globalThis.__assign||function(){return PR=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},PR.apply(this,arguments)},y_=Pt.createContext(null);y_.displayName="RootChartContext";var wY={},m_={};Object.defineProperty(m_,"__esModule",{value:!0});var hxt=function(e){return typeof e=="object"&&e!==null};m_.default=hxt;var uO={};Object.defineProperty(uO,"__esModule",{value:!0});var vxt=function(e){return e!==null&&typeof e!="function"&&isFinite(e.length)};uO.default=vxt;Object.defineProperty(wY,"__esModule",{value:!0});var IR=m_,LR=uO,DR=sg,gT=function(e,r){if(e===r)return!0;if(!e||!r||DR.default(e)||DR.default(r))return!1;if(LR.default(e)||LR.default(r)){if(e.length!==r.length)return!1;for(var t=!0,i=0;i<e.length&&(t=gT(e[i],r[i]),!!t);i++);return t}if(IR.default(e)||IR.default(r)){var n=Object.keys(e),a=Object.keys(r);if(n.length!==a.length)return!1;for(var t=!0,i=0;i<n.length&&(t=gT(e[n[i]],r[n[i]]),!!t);i++);return t}return!1},dxt=wY.default=gT,pxt=["mousedown","mouseup","dblclick","mouseenter","mouseout","mouseover","mousemove","mouseleave","contextmenu","click","show","hide","change"],gxt=new RegExp("^on(.*)(?=("+pxt.map(function(e){return e.replace(/^\S/,function(r){return r.toUpperCase()})}).join("|")+"))"),yx=function(e){var r=[];return Zf(e,function(t,i){var n=i.match(/^on(.*)/);if(n){var a=i.match(gxt);if(a){var o=a[1].replace(/([A-Z])/g,"-$1").toLowerCase();o=o.replace("column","interval"),o?r.push([i,o.replace("-","")+":"+a[2].toLowerCase()]):r.push([i,a[2].toLowerCase()])}else r.push([i,n[1].toLowerCase()])}}),r},yxt=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}(),yT=globalThis&&globalThis.__assign||function(){return yT=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},yT.apply(this,arguments)},Wm=globalThis&&globalThis.__rest||function(e,r){var t={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&r.indexOf(i)<0&&(t[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,i=Object.getOwnPropertySymbols(e);n<i.length;n++)r.indexOf(i[n])<0&&Object.prototype.propertyIsEnumerable.call(e,i[n])&&(t[i[n]]=e[i[n]]);return t},Xm=globalThis&&globalThis.__spreadArrays||function(){for(var e=0,r=0,t=arguments.length;r<t;r++)e+=arguments[r].length;for(var i=Array(e),n=0,r=0;r<t;r++)for(var a=arguments[r],o=0,l=a.length;o<l;o++,n++)i[n]=a[o];return i},mxt=function(e){return e&&e.rows?e.rows:e},xxt=function(e){yxt(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.config={},t}return r.prototype.createInstance=function(t){this.chart=new ut.Chart(yT({},t)),this.key=Kd("bx-chart"),this.chart.emit("initialed"),this.isNewInstance=!0,this.extendGroup={isChartCanvas:!0,chart:this.chart}},r.prototype.render=function(){if(!!this.chart)try{this.isNewInstance?(this.chart.render(),this.onGetG2Instance(),this.chart.unbindAutoFit(),this.isNewInstance=!1):this.chart.forceReRender?this.chart.render():this.chart.render(!0),this.chart.emit("processElemens")}catch(t){this.emit("renderError",t),this.destory(),console&&console.error(t==null?void 0:t.stack)}},r.prototype.onGetG2Instance=function(){Sa(this.config.onGetG2Instance)&&this.config.onGetG2Instance(this.chart)},r.prototype.shouldReCreateInstance=function(t){if(!this.chart||t.forceUpdate)return!0;var i=this.config,n=i.data,a=Wm(i,["data"]),o=t.data,l=Wm(t,["data"]);if(sr(this.config.data)&&n.length===0&&sr(o)&&o.length!==0)return!0;var s=Xm(Mf,["scale","width","height","container","_container","_interactions","placeholder",/^on/,/^\_on/]);return!dxt(ts(a,Xm(s)),ts(l,Xm(s)))},r.prototype.update=function(t){var i=this,n=Qf(this.adapterOptions(t));this.shouldReCreateInstance(n)&&(this.destory(),this.createInstance(n)),n.pure&&(this.chart.axis(!1),this.chart.tooltip(!1),this.chart.legend(!1),this.chart.isPure=!0);var a=yx(this.config),o=yx(n),l=n.data,s=n.interactions,u=Wm(n,["data","interactions"]),c=this.config,f=c.data,h=c.interactions,v=h===void 0?[]:h;if(this.isNewInstance||a.forEach(function(b){i.chart.off(b[1],i.config["_"+b[0]])}),o.forEach(function(b){n["_"+b[0]]=function(w){n[b[0]](w,i.chart)},i.chart.on(b[1],n["_"+b[0]])}),sr(f)&&f.length){var d=!0;if(n.notCompareData&&(d=!1),f.length!==l.length?d=!1:f.forEach(function(b,w){ug(b,l[w])||(d=!1)}),!d){this.chart.isDataChanged=!0,this.chart.emit(Jt.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_DATA),this.chart.data(l);for(var p=this.chart.views,x=0,m=p.length;x<m;x++){var _=p[x];_.changeData(l)}this.chart.emit(Jt.VIEW_LIFE_CIRCLE.AFTER_CHANGE_DATA)}}else this.chart.data(l);this.chart.scale(u.scale),u.animate===!1?this.chart.animate(!1):this.chart.animate(!0),v.forEach(function(b){i.chart.removeInteraction(b)}),s.forEach(function(b){i.chart.interaction(b)}),xs(this.config.filter,function(b,w){sr(b)?i.chart.filter(b[0],null):i.chart.filter(w,null)}),xs(n.filter,function(b,w){sr(b)?i.chart.filter(b[0],b[1]):i.chart.filter(w,b)}),this.chart.theme(n.theme),this.config=n},r.prototype.adapterOptions=function(t){var i=t.data,n=Wm(t,["data"]),a=ts(n,Xm(Mf));return a.forceFit,a.data=mxt(i)||[],a},r.prototype.destory=function(){if(!!this.chart){this.extendGroup=null;var t=this.chart;t.destroy(),t=null,this.chart=null,this.config={}}},r}(yp),_xt=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}(),Cd=globalThis&&globalThis.__assign||function(){return Cd=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Cd.apply(this,arguments)},bxt=function(e){_xt(r,e);function r(t){var i=e.call(this,t)||this;return i.isRootView=!0,i.resize=uY(function(){var n=i.chartHelper.chart;if(i.props.autoFit&&i.chartHelper.chart){var a=v1.getChartSize(i.props.container,i.props.autoFit,n.width,n.height),o=a.width,l=a.height;(n.width!==o||n.height!==l)&&(n.changeSize(o,l),n.emit("resize"))}},300),i.resizeObserver=new bY(i.resize),i.resizeObserver.observe(t.container),i.chartHelper=new xxt,i}return r.prototype.componentDidMount=function(){this.isError?this.chartHelper.destory():this.chartHelper.render()},r.prototype.componentDidUpdate=function(){if(this.isError){this.chartHelper.destory();return}var t=this.props,i=t.width,n=t.height,a=t.autoFit;if(!a&&this.chartHelper.chart)if(i>=0&&i!==this.chartHelper.chart.width||n>=0&&n!==this.chartHelper.chart.height){var o=i||this.chartHelper.chart.width,l=n||this.chartHelper.chart.height;this.chartHelper.chart.changeSize(o,l),this.chartHelper.chart.emit("resize")}else this.chartHelper.render();else this.chartHelper.render()},r.prototype.componentWillUnmount=function(){this.chartHelper.destory(),this.resizeObserver.unobserve(this.props.container)},r.prototype.getG2Instance=function(){return this.chartHelper.chart},r.prototype.render=function(){var t=this,i=this.props,n=i.placeholder,a=i.data,o=i.errorContent,l=this.props.ErrorBoundaryProps;if((a===void 0||a.length===0)&&n){this.chartHelper.destory();var s=n===!0?Pt.createElement("div",{style:{position:"relative",top:"48%",color:"#aaa",textAlign:"center"}},"\u6682\u65E0\u6570\u636E"):n;return Pt.createElement(Xd,Cd({},l),s)}return this.chartHelper.update(this.props),o?l=Cd({fallback:o},l):l={FallbackComponent:pj},Pt.createElement(Xd,Cd({},l,{key:this.chartHelper.key,onError:function(){for(var u=[],c=0;c<arguments.length;c++)u[c]=arguments[c];t.isError=!0,pt(l.onError)&&l.onError.apply(l,u)},onReset:function(){for(var u=[],c=0;c<arguments.length;c++)u[c]=arguments[c];t.isError=!1,pt(l.onReset)&&l.onReset.apply(l,u)},resetKeys:[this.chartHelper.key],fallback:o}),Pt.createElement(y_.Provider,{value:this.chartHelper},Pt.createElement(Ps.Provider,{value:this.chartHelper.chart},Pt.createElement(lg.Provider,{value:this.chartHelper.extendGroup},this.props.children))))},r.defaultProps={placeholder:!1,visible:!0,interactions:[],filter:[]},r}(Pt.Component),NVt=aO(bxt),CY={},cO={};Object.defineProperty(cO,"__esModule",{value:!0});var wxt=m_,Cxt=Ls,Sxt=function(e){if(!wxt.default(e)||!Cxt.default(e,"Object"))return!1;if(Object.getPrototypeOf(e)===null)return!0;for(var r=e;Object.getPrototypeOf(r)!==null;)r=Object.getPrototypeOf(r);return Object.getPrototypeOf(e)===r};cO.default=Sxt;Object.defineProperty(CY,"__esModule",{value:!0});var Axt=Dh,$R=cO,Txt=5;function SY(e,r,t,i){t=t||0,i=i||Txt;for(var n in r)if(r.hasOwnProperty(n)){var a=r[n];a!==null&&$R.default(a)?($R.default(e[n])||(e[n]={}),t<i?SY(e[n],a,t+1,i):e[n]=r[n]):Axt.default(a)?(e[n]=[],e[n]=e[n].concat(a)):a!==void 0&&(e[n]=a)}}var Mxt=function(e){for(var r=[],t=1;t<arguments.length;t++)r[t-1]=arguments[t];for(var i=0;i<r.length;i+=1)SY(e,r[i]);return e},Ext=CY.default=Mxt,gf=globalThis&&globalThis.__assign||function(){return gf=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},gf.apply(this,arguments)},Fxt=globalThis&&globalThis.__rest||function(e,r){var t={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&r.indexOf(i)<0&&(t[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,i=Object.getOwnPropertySymbols(e);n<i.length;n++)r.indexOf(i[n])<0&&Object.prototype.propertyIsEnumerable.call(e,i[n])&&(t[i[n]]=e[i[n]]);return t},Oxt=function(){function e(r){this.config={},this.isRootView=!1,this.chart=r}return e.prototype.creatViewInstance=function(r){this.view=this.chart.createView(this.processOptions(r)),this.view.rootChart=this.chart},e.prototype.getView=function(){return this.view},e.prototype.update=function(r){var t=this,i=this.config.data,n=r.scale,a=r.animate,o=r.filter,l=r.visible,s=r.data,u=s===void 0?[]:s;if(u.rows&&(Df(!u.rows),u=u.rows),(!this.view||sr(i)&&i.length===0)&&(this.destroy(),this.creatViewInstance(r)),sr(i)){this.view.changeData(u);var c=!0;i.length!==u.length?c=!1:i.forEach(function(f,h){ug(f,u[h])||(c=!1)}),c||this.view.changeData(u)}else this.view.data(u);this.view.scale(n),this.view.animate(a),xs(this.config.filter,function(f,h){sr(f)?t.view.filter(f[0],null):t.view.filter(h,null)}),xs(o,function(f,h){sr(f)?t.view.filter(f[0],f[1]):t.view.filter(h,f)}),l?this.view.show():this.view.hide(),this.config=gf(gf({},r),{data:u})},e.prototype.destroy=function(){this.view&&(this.view.destroy(),this.view=null),this.config={}},e.prototype.processOptions=function(r){var t=r.region,i=r.start,n=r.end,a=Fxt(r,["region","start","end"]),o=Ext({start:{x:0,y:0},end:{x:1,y:1}},{start:i,end:n},t);return gf(gf({},a),{region:o})},e}(),Pxt=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}(),Ixt=function(e){Pxt(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.name="view",t}return r.prototype.componentWillUnmount=function(){this.viewHelper.destroy(),this.viewHelper=null},r.prototype.render=function(){return this.viewHelper||(this.viewHelper=new Oxt(this.context.chart)),this.viewHelper.update(this.props),Pt.createElement(Ps.Provider,{value:this.viewHelper.view},Pt.createElement(Pt.Fragment,null,this.props.children))},r.defaultProps={visible:!0,preInteractions:[],filter:[]},r}(Pt.Component);Ixt.contextType=y_;function fO(){return Pt.useContext(Ps)}var AY={};Object.defineProperty(AY,"__esModule",{value:!0});var Lxt=sg,kt=AY.default=function(e,r,t){for(var i=0,n=Lxt.default(r)?r.split("."):r;e&&i<n.length;)e=e[n[i++]];return e===void 0||i<n.length?t:e},TY={};Object.defineProperty(TY,"__esModule",{value:!0});function Dxt(e,r){if(e)for(var t in r)r.hasOwnProperty(t)&&(e.style[t]=r[t]);return e}var $xt=TY.default=Dxt,kxt=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}(),yf=globalThis&&globalThis.__assign||function(){return yf=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},yf.apply(this,arguments)},Rxt=globalThis&&globalThis.__rest||function(e,r){var t={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&r.indexOf(i)<0&&(t[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,i=Object.getOwnPropertySymbols(e);n<i.length;n++)r.indexOf(i[n])<0&&Object.prototype.propertyIsEnumerable.call(e,i[n])&&(t[i[n]]=e[i[n]]);return t},kR="g2-tooltip",Bxt=function(e){kxt(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.renderInnder=function(i){var n=i.data,a=n.title,o=n.items,l=n.x,s=n.y;VG.render(t.props.children(a,o,l,s,i),t.getElement())},t}return r.prototype.componentWillUnmount=function(){var t=this.props.chartView;this.element&&this.element.remove(),t.getController("tooltip").clear(),t.off("tooltip:change",this.renderInnder)},r.prototype.getElement=function(){return this.element||(this.element=document.createElement("div"),this.element.classList.add("bizcharts-tooltip"),this.element.classList.add("g2-tooltip"),this.element.style.width="auto",this.element.style.height="auto"),this.element},r.prototype.overwriteCfg=function(){var t=this,i=this.props,n=i.chartView;i.children;var a=i.domStyles,o=a===void 0?{}:a,l=Rxt(i,["chartView","children","domStyles"]);n.tooltip(yf(yf({inPlot:!1,domStyles:o},l),{customContent:function(){return t.getElement()}})),n.on("tooltip:change",this.renderInnder);var s=kt(ut.getTheme(),["components","tooltip","domStyles",kR],{});$xt(this.element,yf(yf({},s),o[kR]))},r.prototype.render=function(){return this.overwriteCfg(),null},r}(Pt.Component),Nxt=bet(Bxt),Gxt=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}(),Um={},zxt=function(){function e(r){this.cfg={shared:!0},this.chartMap={},this.state={},this.id=Oa("bx-action"),this.type=r||"tooltip"}return e.prototype.connect=function(r,t,i){return this.chartMap[r]={chart:t,pointFinder:i},t.interaction("connect-"+this.type+"-"+this.id),this.type==="tooltip"&&this.cfg.shared&&I(t,["options","tooltip","shared"])===void 0&&jt(t,["options","tooltip","shared"],!0),this},e.prototype.unConnect=function(r){this.chartMap[r].chart.removeInteraction("connect-"+this.type+"-"+this.id),delete this.chartMap[r]},e.prototype.destroy=function(){m3("connect-"+this.type+"-"+this.id)},e}(),Vxt=function(){var e=new zxt("tooltip");return ut.registerAction("connect-tooltip-"+e.id,function(r){Gxt(t,r);function t(){var i=r!==null&&r.apply(this,arguments)||this;return i.CM=e,i}return t.prototype.showTooltip=function(i,n){var a=i.getTooltipItems(n)||n;P(this.CM.chartMap,function(o){var l=o.chart,s=o.pointFinder;if(!(l.destroyed||!l.visible))if(s){var u=s(a,l);u&&l.showTooltip(u)}else l.showTooltip(n)})},t.prototype.hideTooltip=function(){P(this.CM.chartMap,function(i){var n=i.chart;return n.hideTooltip()})},t}(yH)),ut.registerInteraction("connect-tooltip-"+e.id,{start:[{trigger:"plot:mousemove",action:"connect-tooltip-"+e.id+":show"}],end:[{trigger:"plot:mouseleave",action:"connect-tooltip-"+e.id+":hide"}]}),e},RR=function(e,r,t,i,n){var a=Um[e];if(t===null&&a){a.unConnect(r);return}a?a.connect(r,t,n):(Um[e]=Vxt(),Um[e].cfg.shared=!!i,Um[e].connect(r,t,n))};ut.registerAction("tooltip",yH);ut.registerAction("sibling-tooltip",mgt);ut.registerAction("active-region",vgt);ut.registerAction("ellipsis-text",wgt);ut.registerInteraction("tooltip",{start:[{trigger:"plot:mousemove",action:"tooltip:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"plot:touchmove",action:"tooltip:show",throttle:{wait:50,leading:!0,trailing:!1}}],end:[{trigger:"plot:mouseleave",action:"tooltip:hide"},{trigger:"plot:leave",action:"tooltip:hide"},{trigger:"plot:touchend",action:"tooltip:hide"}]});ut.registerInteraction("ellipsis-text",{start:[{trigger:"legend-item-name:mousemove",action:"ellipsis-text:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"legend-item-name:touchstart",action:"ellipsis-text:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"axis-label:mousemove",action:"ellipsis-text:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"axis-label:touchstart",action:"ellipsis-text:show",throttle:{wait:50,leading:!0,trailing:!1}}],end:[{trigger:"legend-item-name:mouseleave",action:"ellipsis-text:hide"},{trigger:"legend-item-name:touchend",action:"ellipsis-text:hide"},{trigger:"axis-label:mouseleave",action:"ellipsis-text:hide"},{trigger:"axis-label:touchend",action:"ellipsis-text:hide"}]});ut.registerInteraction("tooltip-click",{start:[{trigger:"plot:click",action:"tooltip:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"plot:touchstart",action:"tooltip:show",throttle:{wait:50,leading:!0,trailing:!1}}],end:[{trigger:"plot:leave",action:"tooltip:hide"}]});var BR=function(e){var r=e.view.isTooltipLocked();r?e.view.unlockTooltip():e.view.lockTooltip()};ut.registerInteraction("tooltip-lock",{start:[{trigger:"plot:click",action:BR},{trigger:"plot:touchstart",action:BR},{trigger:"plot:touchmove",action:"tooltip:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"plot:mousemove",action:"tooltip:show"}],end:[{trigger:"plot:click",action:"tooltip:hide"},{trigger:"plot:leave",action:"tooltip:hide"},{trigger:"plot:touchend",action:"tooltip:hide"}]});ut.registerInteraction("sibling-tooltip",{start:[{trigger:"plot:mousemove",action:"sibling-tooltip:show"}],end:[{trigger:"plot:mouseleave",action:"sibling-tooltip:hide"}]});var tp=globalThis&&globalThis.__assign||function(){return tp=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},tp.apply(this,arguments)},MY=globalThis&&globalThis.__rest||function(e,r){var t={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&r.indexOf(i)<0&&(t[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,i=Object.getOwnPropertySymbols(e);n<i.length;n++)r.indexOf(i[n])<0&&Object.prototype.propertyIsEnumerable.call(e,i[n])&&(t[i[n]]=e[i[n]]);return t};ut.registerComponentController("tooltip",xlt);var jxt=function(e){var r=e.visible,t=r===void 0?!0:r,i=e.children;return t&&Sa(i)},Hxt=function(e){var r=e.visible,t=r===void 0?!0:r;e.children;var i=MY(e,["visible","children"]),n=fO();return n.getController("tooltip").clear(),t===!0?n.tooltip(tp({customContent:null,showMarkers:!1},i)):n.tooltip(!1),null};function Yxt(e){var r=e.children,t=e.triggerOn,i=e.onShow,n=e.onChange,a=e.onHide,o=e.lock,l=e.linkage,s=MY(e,["children","triggerOn","onShow","onChange","onHide","lock","linkage"]),u=fO();u.removeInteraction("tooltip"),u.removeInteraction("tooltip-click"),u.removeInteraction("tooltip-lock"),t==="click"?u.interaction("tooltip-click"):o?u.interaction("tooltip-lock"):u.interaction("tooltip");var c=Ur.exports.useRef(Kd("tooltip"));Ur.exports.useEffect(function(){sr(l)?RR(l[0],c.current,u,s.shared,l[1]):$h(l)&&RR(l,c.current,u,s.shared)},[l,u]);var f=Ur.exports.useCallback(function(d){Sa(i)&&i(d,u)},[]),h=Ur.exports.useCallback(function(d){Sa(n)&&n(d,u)},[]),v=Ur.exports.useCallback(function(d){Sa(a)&&a(d,u)},[]);return u.off("tooltip:show",f),u.on("tooltip:show",f),u.off("tooltip:change",h),u.on("tooltip:change",h),u.off("tooltip:hide",v),u.on("tooltip:hide",v),jxt(e)?Ci(Nxt,{...tp({},s),children:r}):Ci(Hxt,{...tp({},e)})}Yxt.defaultProps={showMarkers:!1,triggerOn:"hover"};ut.registerAction("list-active",_yt);ut.registerAction("list-selected",Eyt);ut.registerAction("list-highlight",BH);ut.registerAction("list-unchecked",Pyt);ut.registerAction("data-filter",rmt);ut.registerAction("legend-item-highlight",BH,{componentNames:["legend"]});ut.registerInteraction("legend-active",{start:[{trigger:"legend-item:mouseenter",action:["list-active:active","element-active:active"]}],end:[{trigger:"legend-item:mouseleave",action:["list-active:reset","element-active:reset"]}]});ut.registerInteraction("legend-highlight",{start:[{trigger:"legend-item:mouseenter",action:["legend-item-highlight:highlight","element-highlight:highlight"]}],end:[{trigger:"legend-item:mouseleave",action:["legend-item-highlight:reset","element-highlight:reset"]}]});ut.registerInteraction("legend-filter",{showEnable:[{trigger:"legend-item:mouseenter",action:"cursor:pointer"},{trigger:"legend-item:mouseleave",action:"cursor:default"}],start:[{trigger:"legend-item:click",action:"list-unchecked:toggle"},{trigger:"legend-item:click",action:"data-filter:filter"}]});globalThis&&globalThis.__rest;ut.registerComponentController("legend",qpt);var EY={};Object.defineProperty(EY,"__esModule",{value:!0});var Wxt=function(e){return e==null},fi=EY.default=Wxt,NR=globalThis&&globalThis.__assign||function(){return NR=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},NR.apply(this,arguments)};globalThis&&globalThis.__rest;var FY={};Object.defineProperty(FY,"__esModule",{value:!0});var Xxt=Dh,mT=function(e){if(typeof e!="object"||e===null)return e;var r;if(Xxt.default(e)){r=[];for(var t=0,i=e.length;t<i;t++)typeof e[t]=="object"&&e[t]!=null?r[t]=mT(e[t]):r[t]=e[t]}else{r={};for(var n in e)typeof e[n]=="object"&&e[n]!=null?r[n]=mT(e[n]):r[n]=e[n]}return r},Uxt=FY.default=mT,qxt=function(e,r){var t=Uxt(e);return r.forEach(function(i){t[i]===!0?t[i]={}:t[i]===!1&&(t[i]=null)}),t},Zxt=globalThis&&globalThis.__rest||function(e,r){var t={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&r.indexOf(i)<0&&(t[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,i=Object.getOwnPropertySymbols(e);n<i.length;n++)r.indexOf(i[n])<0&&Object.prototype.propertyIsEnumerable.call(e,i[n])&&(t[i[n]]=e[i[n]]);return t};ut.registerComponentController("axis",Npt);var GR=function(e){return e===void 0},Qxt=function(e){return qxt(e,["title","line","tickLine","subTickLine","label","grid"])};function GVt(e){var r=e.name,t=e.visible,i=t===void 0?!0:t,n=Zxt(e,["name","visible"]),a=fO(),o=Qxt(n);return i?GR(r)?a.axis(!0):a.axis(r,o):GR(r)?a.axis(!1):a.axis(r,!1),null}var zR=globalThis&&globalThis.__assign||function(){return zR=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},zR.apply(this,arguments)};globalThis&&globalThis.__rest;ut.registerFacet("rect",Mpt);ut.registerFacet("mirror",Spt);ut.registerFacet("list",mpt);ut.registerFacet("matrix",bpt);ut.registerFacet("circle",vpt);ut.registerFacet("tree",Ppt);ut.registerComponentController("slider",egt);var dS=function(e,r,t,i){if(e===null){xs(t,function(o){var l=r[o];l!==void 0&&(sr(l)||(l=[l]),i(l,o))});return}var n,a;xs(t,function(o){n=e[o],a=r[o],ug(a,n)||(sr(a)||(a=[a]),i(a,o))})};globalThis&&globalThis.__rest;ut.registerGeometryLabel("base",D3);ut.registerGeometryLabel("interval",Jj);ut.registerGeometryLabel("pie",tH);ut.registerGeometryLabel("polar",odt);ut.registerGeometryLabelLayout("overlap",nH);ut.registerGeometryLabelLayout("distribute",eH);ut.registerGeometryLabelLayout("fixed-overlap",lH);ut.registerGeometryLabelLayout("limit-in-shape",iH);ut.registerGeometryLabelLayout("limit-in-canvas",rH);ut.registerAction("cursor",Kyt);ut.registerAction("element-active",Pgt);ut.registerAction("element-single-active",Hgt);ut.registerAction("element-range-active",Ngt);ut.registerAction("element-highlight",Ugt);ut.registerAction("element-highlight-by-x",Jgt);ut.registerAction("element-highlight-by-color",Qgt);ut.registerAction("element-single-highlight",ayt);ut.registerAction("element-range-highlight",OH);ut.registerAction("element-sibling-highlight",OH,{effectSiblings:!0,effectByRecord:!0});ut.registerAction("element-selected",fyt);ut.registerAction("element-single-selected",dyt);ut.registerAction("element-range-selected",syt);ut.registerAction("element-link-by-color",Dgt);ut.registerInteraction("element-active",{start:[{trigger:"element:mouseenter",action:"element-active:active"}],end:[{trigger:"element:mouseleave",action:"element-active:reset"}]});ut.registerInteraction("element-selected",{start:[{trigger:"element:click",action:"element-selected:toggle"}]});ut.registerInteraction("element-highlight",{start:[{trigger:"element:mouseenter",action:"element-highlight:highlight"}],end:[{trigger:"element:mouseleave",action:"element-highlight:reset"}]});ut.registerInteraction("element-highlight-by-x",{start:[{trigger:"element:mouseenter",action:"element-highlight-by-x:highlight"}],end:[{trigger:"element:mouseleave",action:"element-highlight-by-x:reset"}]});ut.registerInteraction("element-highlight-by-color",{start:[{trigger:"element:mouseenter",action:"element-highlight-by-color:highlight"}],end:[{trigger:"element:mouseleave",action:"element-highlight-by-color:reset"}]});var Kxt=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}();ut.registerGeometryLabel("base",D3);var Jxt=["line","area"],t1t=function(){function e(){this.config={}}return e.prototype.setView=function(r){this.view=r,this.rootChart=r.rootChart||r},e.prototype.createGeomInstance=function(r,t){this.geom=this.view[r](t);var i=t.sortable;this.geom.__beforeMapping=this.geom.beforeMapping,this.geom.beforeMapping=function(n){var a=this.getXScale();return i!==!1&&n&&n[0]&&Jxt.includes(r)&&["time","timeCat"].includes(a.type)&&this.sort(n),this.__beforeMapping(n)},this.GemoBaseClassName=r},e.prototype.update=function(r,t){var i=this;this.geom||(this.setView(t.context),this.createGeomInstance(t.GemoBaseClassName,r),this.interactionTypes=t.interactionTypes),dS(this.config,r,["position","shape","color","label","style","tooltip","size","animate","state","customInfo"],function(n,a){var o;Df(!(a==="label"&&n[0]===!0)),(o=i.geom)[a].apply(o,n)}),dS(this.config,r,["adjust"],function(n,a){$h(n[0])?i.geom[a](n[0]):i.geom[a](n)}),this.geom.state(r.state||{}),this.rootChart.on("processElemens",function(){Sa(r.setElements)&&r.setElements(i.geom.elements)}),dS(this.config,r,this.interactionTypes,function(n,a){n[0]?i.rootChart.interaction(a):i.rootChart.removeInteraction(a)}),this.config=Qf(r)},e.prototype.destroy=function(){this.geom&&(this.geom.destroy(),this.geom=null),this.config={}},e}(),Co=function(e){Kxt(r,e);function r(t){var i=e.call(this,t)||this;return i.interactionTypes=[],i.geomHelper=new t1t,i}return r.prototype.componentWillUnmount=function(){this.geomHelper.destroy()},r.prototype.render=function(){var t=this;return this.geomHelper.update(this.props,this),Pt.createElement(Pt.Fragment,null,Pt.Children.map(this.props.children,function(i){return Pt.isValidElement(i)?Pt.cloneElement(i,{parentInstance:t.geomHelper.geom}):Pt.createElement(Pt.Fragment,null)}))},r}(Pt.Component);Co.contextType=Ps;var e1t=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}();ut.registerGeometry("Area",Pft);var zVt=function(e){e1t(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.GemoBaseClassName="area",t}return r}(Co),r1t=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}();ut.registerGeometry("Edge",Bft);(function(e){r1t(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.GemoBaseClassName="edge",t}return r})(Co);var i1t=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}();ut.registerGeometry("Heatmap",Vft);(function(e){i1t(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.GemoBaseClassName="heatmap",t}return r})(Co);var n1t=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}();ut.registerGeometry("Interval",aht);ut.registerGeometryLabel("interval",Jj);ut.registerGeometryLabel("pie",tH);ut.registerInteraction("active-region",{start:[{trigger:"plot:mousemove",action:"active-region:show"}],end:[{trigger:"plot:mouseleave",action:"active-region:hide"}]});(function(e){n1t(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.interactionTypes=["active-region","element-highlight"],t.GemoBaseClassName="interval",t}return r})(Co);var a1t=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}();ut.registerGeometry("Line",sht);var VVt=function(e){a1t(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.GemoBaseClassName="line",t}return r}(Co),o1t=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}();ut.registerGeometry("Point",yht);(function(e){o1t(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.GemoBaseClassName="point",t}return r})(Co);var l1t=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}();ut.registerGeometry("Polygon",Cht);(function(e){l1t(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.GemoBaseClassName="polygon",t}return r})(Co);var s1t=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}();ut.registerGeometry("Schema",Oht);(function(e){s1t(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.GemoBaseClassName="schema",t}return r})(Co);var u1t=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}();ut.registerAnimation("path-in",XE);ut.registerGeometry("Path",mft);(function(e){u1t(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.GemoBaseClassName="path",t}return r})(Co);var OY={},hO={};Object.defineProperty(hO,"__esModule",{value:!0});var c1t=Ls,f1t=function(e){return c1t.default(e,"Number")};hO.default=f1t;Object.defineProperty(OY,"__esModule",{value:!0});var h1t=g_,v1t=sg,d1t=hO,ve=OY.default=function(e,r,t){var i=e,n=v1t.default(r)?r.split("."):r;return n.forEach(function(a,o){o<n.length-1?(h1t.default(i[a])||(i[a]=d1t.default(n[o+1])?[]:{}),i=i[a]):i[a]=t}),e},VR=globalThis&&globalThis.__assign||function(){return VR=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},VR.apply(this,arguments)};globalThis&&globalThis.__rest;ut.registerShape("area","gradient",{draw:function(e,r){var t=oF(e,!1,!1,this),i=t.fill,n=Xu(i);n&&(t.fill="l (90) 0:"+Uu(n.r,n.g,n.b,1).formatRgb()+" 1:"+Uu(n.r,n.g,n.b,.1).formatRgb());var a=r.addShape({type:"path",attrs:t,name:"area"});return a}});ut.registerShape("area","gradient-smooth",{draw:function(e,r){var t=this.coordinate,i=oF(e,!1,!0,this,Mj(t)),n=i.fill,a=Xu(n);a&&(i.fill="l (90) 0:"+Uu(a.r,a.g,a.b,1).formatRgb()+" 1:"+Uu(a.r,a.g,a.b,.1).formatRgb());var o=r.addShape({type:"path",attrs:i,name:"area"});return o}});var jR=globalThis&&globalThis.__assign||function(){return jR=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},jR.apply(this,arguments)};globalThis&&globalThis.__rest;var HR=globalThis&&globalThis.__assign||function(){return HR=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},HR.apply(this,arguments)};function pS(e,r){return r===void 0&&(r={}),{width:Mt(r.width)?r.width:e.clientWidth,height:Mt(r.height)?r.height:e.clientHeight}}var jo=globalThis&&globalThis.__assign||function(){return jo=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},jo.apply(this,arguments)},$a=function(e,r){e.forEach(function(t){var i=t.sourceKey,n=t.targetKey;t.notice;var a=I(r,i);a&&jt(r,n,a)})},YR=function(e,r){var t=I(e,r);if(t===!1||t===null){e[r]=null;return}if(t!==void 0){if(t===!0){e[r]={};return}if(!!Zt(t)){Fr(t,"line",null),Fr(t,"grid",null),Fr(t,"label",null),Fr(t,"tickLine",null),Fr(t,"title",null);var i=I(t,"label");if(i&&Zt(i)){var n=i.suffix;n&&jt(i,"formatter",function(s){return""+s+n});var a=i.offsetX,o=i.offsetY,l=i.offset;K(l)&&(!K(a)||!K(o))&&(r==="xAxis"&&jt(i,"offset",K(a)?o:a),r==="yAxis"&&jt(i,"offset",K(o)?a:o))}e[r]=jo(jo({},t),{label:i})}}},Fr=function(e,r,t){t===void 0&&(t=!1);var i=I(e,r+".visible");return(i===!1||i===null)&&jt(e,r,t),i},He=function(e){var r=jo({},e);Fr(r,"tooltip");var t=Fr(r,"legend");if(t){Fr(r,"legend.title");var i=I(r,"legend.position");i&&jt(r,"legend.position",{"top-center":"top","right-center":"right","left-center":"left","bottom-center":"bottom"}[i]||i)}var n=I(r,"legend.formatter");if(n){var a=I(r,"legend.itemName",{});jt(r,"legend.itemName",jo(jo({},a),{formatter:n}))}var o=I(r,"legend.text");o&&jt(r,"legend.itemName",o),Fr(r,"label"),YR(r,"xAxis"),YR(r,"yAxis");var l=I(r,"guideLine",[]),s=I(r,"data",[]),u=I(r,"yField","y");l.forEach(function(h){if(s.length>0){var v="median";switch(h.type){case"max":v=Qx(s,function(p){return p[u]})[u];break;case"mean":v=hY(s.map(function(p){return p[u]}))/s.length;break;default:v=cM(s,function(p){return p[u]})[u];break}var d=jo(jo({start:["min",v],end:["max",v],style:h.lineStyle,text:{content:v}},h),{type:"line"});I(r,"annotations")||jt(r,"annotations",[]),r.annotations.push(d),jt(r,"point",!1)}});var c=I(r,"interactions",[]),f=c.find(function(h){return h.type==="slider"});return f&&K(r.slider)&&(r.slider=f.cfg),r},WR=function(e,r,t){var i=yx(I(r,"events",[])),n=yx(I(t,"events",[]));i.forEach(function(a){e.off(a[1],r.events[a[0]])}),n.forEach(function(a){e.on(a[1],t.events[a[0]])})},p1t=function(e){var r=I(e,"events",{}),t={};return["onTitleClick","onTitleDblClick","onTitleMouseleave","onTitleMousemove","onTitleMousedown","onTitleMouseup","onTitleMouseenter"].forEach(function(i){r[i]&&(t[i.replace("Title","")]=r[i])}),t},g1t=function(e){var r=I(e,"events",{}),t={};return["onDescriptionClick","onDescriptionDblClick","onDescriptionMouseleave","onDescriptionMousemove","onDescriptionMousedown","onDescriptionMouseup","onDescriptionMouseenter"].forEach(function(i){r[i]&&(t[i.replace("Description","")]=r[i])}),t},xT=function(e,r){if(Zt(e)&&Zt(r)){var t=Object.keys(e),i=Object.keys(r);if(t.length!==i.length)return!1;for(var n=!0,a=0;a<t.length&&(n=xT(e[t[a]],r[t[a]]),!!n);a++);return n}if(it(e)&&it(r)){if(e.length!==r.length)return!1;for(var n=!0,a=0;a<e.length&&(n=xT(e[a],r[a]),!!n);a++);return n}return e===r?!0:(!e||!r,!1)},_s={},mt={},x_={};Object.defineProperty(x_,"__esModule",{value:!0});x_.flow=void 0;function y1t(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];return function(t){return e.reduce(function(i,n){return n(i)},t)}}x_.flow=y1t;var cg={};Object.defineProperty(cg,"__esModule",{value:!0});cg.pick=void 0;function m1t(e,r){var t={};return e!==null&&typeof e=="object"&&r.forEach(function(i){var n=e[i];n!==void 0&&(t[i]=n)}),t}cg.pick=m1t;var __={};Object.defineProperty(__,"__esModule",{value:!0});__.template=void 0;var x1t=Y;function _1t(e,r){return r?x1t.reduce(r,function(t,i,n){return t.replace(new RegExp("{\\s*"+n+"\\s*}","g"),i)},e):e}__.template=_1t;var vO={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.log=e.invariant=e.LEVEL=void 0;var r=V;(function(o){o.ERROR="error",o.WARN="warn",o.INFO="log"})(e.LEVEL||(e.LEVEL={}));var t="AntV/G2Plot";function i(o){for(var l=[],s=1;s<arguments.length;s++)l[s-1]=arguments[s];var u=0;return t+": "+o.replace(/%s/g,function(){return""+l[u++]})}function n(o,l){for(var s=[],u=2;u<arguments.length;u++)s[u-2]=arguments[u];if(!o){var c=new Error(i.apply(void 0,r.__spreadArrays([l],s)));throw c.name=t,c}}e.invariant=n;function a(o,l,s){for(var u=[],c=3;c<arguments.length;c++)u[c-3]=arguments[c];l||console[o](i.apply(void 0,r.__spreadArrays([s],u)))}e.log=a})(vO);var b_={};Object.defineProperty(b_,"__esModule",{value:!0});b_.getContainerSize=void 0;function b1t(e){if(!e)return{width:0,height:0};var r=getComputedStyle(e);return{width:(e.clientWidth||parseInt(r.width,10))-parseInt(r.paddingLeft,10)-parseInt(r.paddingRight,10),height:(e.clientHeight||parseInt(r.height,10))-parseInt(r.paddingTop,10)-parseInt(r.paddingBottom,10)}}b_.getContainerSize=b1t;var ao={};Object.defineProperty(ao,"__esModule",{value:!0});ao.getAllGeometriesRecursively=ao.getAllElementsRecursively=ao.getAllElements=ao.findGeometry=void 0;var ep=Y;function w1t(e,r){return e.geometries.find(function(t){return t.type===r})}ao.findGeometry=w1t;function _T(e){return ep.reduce(e.geometries,function(r,t){return r.concat(t.elements)},[])}ao.getAllElements=_T;function PY(e){return ep.get(e,["views","length"],0)<=0?_T(e):ep.reduce(e.views,function(r,t){return r.concat(PY(t))},_T(e))}ao.getAllElementsRecursively=PY;function C1t(e){return ep.get(e,["views","length"],0)<=0?e.geometries:ep.reduce(e.views,function(r,t){return r.concat(t.geometries)},e.geometries)}ao.getAllGeometriesRecursively=C1t;var Ko={};Object.defineProperty(Ko,"__esModule",{value:!0});Ko.getSiblingViews=Ko.getViews=Ko.findViewById=void 0;function S1t(e,r){return e.views.find(function(t){return t.id===r})}Ko.findViewById=S1t;function IY(e){var r=e.parent;return r?r.views:[]}Ko.getViews=IY;function A1t(e){return IY(e).filter(function(r){return r!==e})}Ko.getSiblingViews=A1t;var w_={};Object.defineProperty(w_,"__esModule",{value:!0});w_.transformLabel=void 0;var T1t=V,M1t=Y;function E1t(e){if(!M1t.isType(e,"Object"))return e;var r=T1t.__assign({},e);return r.formatter&&!r.content&&(r.content=r.formatter),r}w_.transformLabel=E1t;var LY={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.getSplinePath=e.catmullRom2bezier=e.smoothBezier=e.points2Path=void 0;var r=ta;function t(a,o){var l=[];if(a.length){l.push(["M",a[0].x,a[0].y]);for(var s=1,u=a.length;s<u;s+=1){var c=a[s];l.push(["L",c.x,c.y])}o&&l.push(["Z"])}return l}e.points2Path=t,e.smoothBezier=function(a,o,l,s){var u=[],c,f,h=!!s,v,d;if(h){v=[1/0,1/0],d=[-1/0,-1/0];for(var p=0,x=a.length;p<x;p++){var m=a[p];v=r.vec2.min([0,0],v,m),d=r.vec2.max([0,0],d,m)}v=r.vec2.min([0,0],v,s[0]),d=r.vec2.max([0,0],d,s[1])}for(var p=0,_=a.length;p<_;p++){var m=a[p];if(l)c=a[p?p-1:_-1],f=a[(p+1)%_];else if(p===0||p===_-1){u.push(m);continue}else c=a[p-1],f=a[p+1];var b=[0,0];b=r.vec2.sub(b,f,c),b=r.vec2.scale(b,b,o);var w=r.vec2.distance(m,c),S=r.vec2.distance(m,f),M=w+S;M!==0&&(w/=M,S/=M);var F=r.vec2.scale([0,0],b,-w),O=r.vec2.scale([0,0],b,S),L=r.vec2.add([0,0],m,F),D=r.vec2.add([0,0],m,O);h&&(L=r.vec2.max([0,0],L,v),L=r.vec2.min([0,0],L,d),D=r.vec2.max([0,0],D,v),D=r.vec2.min([0,0],D,d)),u.push(L),u.push(D)}return l&&u.push(u.shift()),u};function i(a,o,l){for(var s=!!o,u=[],c=0,f=a.length;c<f;c+=2)u.push([a[c],a[c+1]]);for(var h=e.smoothBezier(u,.4,s,l),v=u.length,d=[],p,x,m,c=0;c<v-1;c++)p=h[c*2],x=h[c*2+1],m=u[c+1],d.push(["C",p[0],p[1],x[0],x[1],m[0],m[1]]);return s&&(p=h[v],x=h[v+1],m=u[0],d.push(["C",p[0],p[1],x[0],x[1],m[0],m[1]])),d}e.catmullRom2bezier=i;function n(a,o,l){var s=[],u=a[0],c=null;if(a.length<=2)return t(a,o);for(var f=0,h=a.length;f<h;f++){var v=a[f];(!c||!(c.x===v.x&&c.y===v.y))&&(s.push(v.x),s.push(v.y),c=v)}var d=l||[[0,0],[1,1]],p=i(s,o,d);return p.unshift(["M",u.x,u.y]),p}e.getSplinePath=n})(LY);var fg={};Object.defineProperty(fg,"__esModule",{value:!0});fg.deepAssign=void 0;var F1t=5,O1t={}.toString,DY=function(e,r){return O1t.call(e)==="[object "+r+"]"},P1t=function(e){return DY(e,"Array")},I1t=function(e){return typeof e=="object"&&e!==null},XR=function(e){if(!I1t(e)||!DY(e,"Object"))return!1;for(var r=e;Object.getPrototypeOf(r)!==null;)r=Object.getPrototypeOf(r);return Object.getPrototypeOf(e)===r},$Y=function(e,r,t,i){t=t||0,i=i||F1t;for(var n in r)if(Object.prototype.hasOwnProperty.call(r,n)){var a=r[n];a?XR(a)?(XR(e[n])||(e[n]={}),t<i?$Y(e[n],a,t+1,i):e[n]=r[n]):P1t(a)?(e[n]=[],e[n]=e[n].concat(a)):e[n]=a:e[n]=a}};fg.deepAssign=function(e){for(var r=[],t=1;t<arguments.length;t++)r[t-1]=arguments[t];for(var i=0;i<r.length;i+=1)$Y(e,r[i]);return e};var C_={};Object.defineProperty(C_,"__esModule",{value:!0});C_.kebabCase=void 0;function L1t(e){if(!e)return e;var r=e.match(/(([A-Z]{0,1}[a-z]*[^A-Z])|([A-Z]{1}))/g);return r.map(function(t){return t.toLowerCase()}).join("-")}C_.kebabCase=L1t;var ba={};Object.defineProperty(ba,"__esModule",{value:!0});ba.renderGaugeStatistic=ba.renderStatistic=ba.setStatisticContainerStyle=ba.adapteStyle=void 0;var mx=V,co=Y,mf=mt;function dO(e){var r={overflow:"hidden","white-space":"nowrap","text-overflow":"ellipsis",display:"flex",justifyContent:"center",alignItems:"center"},t=["stroke","lineWidth","shadowColor","strokeOpacity","shadowBlur","shadowOffsetX","shadowOffsetY","fill"];co.get(e,"fill")&&(r.color=e.fill);var i=mf.pick(e,t),n=i.shadowColor,a=i.shadowBlur,o=a===void 0?0:a,l=i.shadowOffsetX,s=l===void 0?0:l,u=i.shadowOffsetY,c=u===void 0?0:u;r["text-shadow"]=""+[n,s+"px",c+"px",o+"px"].join(" ");var f=mf.pick(e,t),h=f.stroke,v=f.lineWidth,d=v===void 0?0:v;return r["-webkit-text-stroke"]=""+[d+"px",h].join(" "),co.each(e,function(p,x){["fontSize"].includes(x)&&co.isNumber(p)?r[mf.kebabCase(x)]=p+"px":x&&!t.includes(x)&&(r[mf.kebabCase(x)]=""+p)}),r}ba.adapteStyle=dO;function pO(e,r){e.style["pointer-events"]="none",co.each(r,function(t,i){i&&t&&(e.style[i]=t)})}ba.setStatisticContainerStyle=pO;ba.renderStatistic=function(e,r,t){var i=r.statistic,n=r.plotType,a=i.title,o=i.content;[a,o].forEach(function(l,s){if(!!l){var u="";s===0?u=o?"translate(-50%, -100%)":"translate(-50%, -50%)":u=a?"translate(-50%, 0)":"translate(-50%, -50%)";var c=co.isFunction(l.style)?l.style(t):l.style;e.annotation().html(mx.__assign({position:["50%","50%"],html:function(f,h){var v=h.getCoordinate(),d=0;if(n==="pie"||n==="ring-progress")d=v.getRadius()*v.innerRadius*2;else if(n==="liquid"){var p=co.get(h.geometries,[0,"elements",0,"shape"]);if(p){var x=p.find(function(w){return w.get("name")==="wrap"}),m=x.getCanvasBBox().width;d=m}}else d||(d=v.getWidth());pO(f,mx.__assign({width:d+"px",transform:u},dO(c)));var _=h.getData();if(l.customHtml)return l.customHtml(f,h,t,_);var b=l.content;return l.formatter&&(b=l.formatter(t,_)),b?co.isString(b)?b:""+b:"<div></div>"},key:(s===0?"top":"bottom")+"-statistic"},mf.pick(l,["offsetX","offsetY","rotate","style","formatter"])))}})};ba.renderGaugeStatistic=function(e,r,t){var i=r.statistic,n=i.title,a=i.content;[n,a].forEach(function(o){if(!!o){var l=co.isFunction(o.style)?o.style(t):o.style;e.annotation().html(mx.__assign({position:["50%","100%"],html:function(s,u){var c=u.getCoordinate(),f=u.views[0].getCoordinate(),h=f.getCenter(),v=f.getRadius(),d=Math.max(Math.sin(f.startAngle),Math.sin(f.endAngle))*v,p=h.y+d-c.y.start-parseFloat(co.get(l,"fontSize",0)),x=c.getRadius()*c.innerRadius*2;pO(s,mx.__assign({width:x+"px",transform:"translate(-50%, "+p+"px)"},dO(l)));var m=u.getData();if(o.customHtml)return o.customHtml(s,u,t,m);var _=o.content;return o.formatter&&(_=o.formatter(t,m)),_?co.isString(_)?_:""+_:"<div></div>"}},mf.pick(o,["offsetX","offsetY","rotate","style","formatter"])))}})};var S_={},A_={};Object.defineProperty(A_,"__esModule",{value:!0});A_.getCanvasContext=void 0;var gS;function D1t(){return gS||(gS=document.createElement("canvas").getContext("2d")),gS}A_.getCanvasContext=D1t;Object.defineProperty(S_,"__esModule",{value:!0});S_.measureTextWidth=void 0;var $1t=V,yS=Y,k1t=A_;S_.measureTextWidth=yS.memoize(function(e,r){r===void 0&&(r={});var t=r.fontSize,i=r.fontFamily,n=i===void 0?"sans-serif":i,a=r.fontWeight,o=r.fontStyle,l=r.fontVariant,s=k1t.getCanvasContext();s.font=[o,a,l,t+"px",n].join(" ");var u=s.measureText(yS.isString(e)?e:"");return u.width},function(e,r){return r===void 0&&(r={}),$1t.__spreadArrays([e],yS.values(r)).join("")});var bs={};Object.defineProperty(bs,"__esModule",{value:!0});bs.isBetween=bs.isRealNumber=void 0;function R1t(e){return typeof e=="number"&&!isNaN(e)}bs.isRealNumber=R1t;function B1t(e,r,t){var i=Math.min(r,t),n=Math.max(r,t);return e>=i&&e<=n}bs.isBetween=B1t;var fo={};Object.defineProperty(fo,"__esModule",{value:!0});fo.processIllegalData=fo.transformDataToNodeLinkData=fo.adjustYMetaByZero=void 0;var mS=V,Zv=Y,UR=vO,N1t=cg;function G1t(e,r){var t=e.filter(function(a){var o=Zv.get(a,[r]);return Zv.isNumber(o)&&!isNaN(o)}),i=t.every(function(a){return Zv.get(a,[r])>=0}),n=t.every(function(a){return Zv.get(a,[r])<=0});return i?{min:0}:n?{max:0}:{}}fo.adjustYMetaByZero=G1t;function z1t(e,r,t,i,n){if(n===void 0&&(n=[]),!Array.isArray(e))return{nodes:[],links:[]};var a=[],o={},l=-1;return e.forEach(function(s){var u=s[r],c=s[t],f=s[i],h=N1t.pick(s,n);o[u]||(o[u]=mS.__assign({id:++l,name:u},h)),o[c]||(o[c]=mS.__assign({id:++l,name:c},h)),a.push(mS.__assign({source:o[u].id,target:o[c].id,value:f},h))}),{nodes:Object.values(o).sort(function(s,u){return s.id-u.id}),links:a}}fo.transformDataToNodeLinkData=z1t;function V1t(e,r){var t=Zv.filter(e,function(i){var n=i[r];return n===null||typeof n=="number"&&!isNaN(n)});return UR.log(UR.LEVEL.WARN,t.length===e.length,"illegal data existed in chart data."),t}fo.processIllegalData=V1t;var ho={};Object.defineProperty(ho,"__esModule",{value:!0});ho.resolveAllPadding=ho.getAdjustAppendPadding=ho.normalPadding=void 0;var qR=Y;function gO(e){if(qR.isNumber(e))return[e,e,e,e];if(qR.isArray(e)){var r=e.length;if(r===1)return[e[0],e[0],e[0],e[0]];if(r===2)return[e[0],e[1],e[0],e[1]];if(r===3)return[e[0],e[1],e[2],e[1]];if(r===4)return e}return[0,0,0,0]}ho.normalPadding=gO;function j1t(e,r,t){r===void 0&&(r="bottom"),t===void 0&&(t=25);var i=gO(e),n=[r.startsWith("top")?t:0,r.startsWith("right")?t:0,r.startsWith("bottom")?t:0,r.startsWith("left")?t:0];return[i[0]+n[0],i[1]+n[1],i[2]+n[2],i[3]+n[3]]}ho.getAdjustAppendPadding=j1t;function H1t(e){var r=e.map(function(i){return gO(i)}),t=[0,0,0,0];return r.length>0&&(t=t.map(function(i,n){return r.forEach(function(a,o){i+=r[o][n]}),i})),t}ho.resolveAllPadding=H1t;(function(e){Object.defineProperty(e,"__esModule",{value:!0});var r=V,t=x_;Object.defineProperty(e,"flow",{enumerable:!0,get:function(){return t.flow}});var i=cg;Object.defineProperty(e,"pick",{enumerable:!0,get:function(){return i.pick}});var n=__;Object.defineProperty(e,"template",{enumerable:!0,get:function(){return n.template}});var a=vO;Object.defineProperty(e,"log",{enumerable:!0,get:function(){return a.log}}),Object.defineProperty(e,"invariant",{enumerable:!0,get:function(){return a.invariant}}),Object.defineProperty(e,"LEVEL",{enumerable:!0,get:function(){return a.LEVEL}});var o=b_;Object.defineProperty(e,"getContainerSize",{enumerable:!0,get:function(){return o.getContainerSize}}),r.__exportStar(ao,e);var l=Ko;Object.defineProperty(e,"findViewById",{enumerable:!0,get:function(){return l.findViewById}}),Object.defineProperty(e,"getViews",{enumerable:!0,get:function(){return l.getViews}}),Object.defineProperty(e,"getSiblingViews",{enumerable:!0,get:function(){return l.getSiblingViews}});var s=w_;Object.defineProperty(e,"transformLabel",{enumerable:!0,get:function(){return s.transformLabel}});var u=LY;Object.defineProperty(e,"getSplinePath",{enumerable:!0,get:function(){return u.getSplinePath}});var c=fg;Object.defineProperty(e,"deepAssign",{enumerable:!0,get:function(){return c.deepAssign}});var f=C_;Object.defineProperty(e,"kebabCase",{enumerable:!0,get:function(){return f.kebabCase}});var h=ba;Object.defineProperty(e,"renderStatistic",{enumerable:!0,get:function(){return h.renderStatistic}}),Object.defineProperty(e,"renderGaugeStatistic",{enumerable:!0,get:function(){return h.renderGaugeStatistic}});var v=S_;Object.defineProperty(e,"measureTextWidth",{enumerable:!0,get:function(){return v.measureTextWidth}});var d=bs;Object.defineProperty(e,"isBetween",{enumerable:!0,get:function(){return d.isBetween}}),Object.defineProperty(e,"isRealNumber",{enumerable:!0,get:function(){return d.isRealNumber}}),r.__exportStar(fo,e),r.__exportStar(ho,e)})(mt);Object.defineProperty(_s,"__esModule",{value:!0});_s.getLocale=yO=_s.registerLocale=void 0;var xS=Y,Y1t=mt,W1t=R3,M0={};function X1t(e,r){M0[e]=r}var yO=_s.registerLocale=X1t;function U1t(e){return{get:function(r,t){return Y1t.template(xS.get(M0[e],r)||xS.get(M0[W1t.GLOBAL.locale],r)||xS.get(M0["en-US"],r)||r,t)}}}_s.getLocale=U1t;var mO={};Object.defineProperty(mO,"__esModule",{value:!0});var kY=mO.EN_US_LOCALE=void 0;kY=mO.EN_US_LOCALE={locale:"en-US",general:{increase:"Increase",decrease:"Decrease",root:"Root"},statistic:{total:"Total"},conversionTag:{label:"Rate"},legend:{},tooltip:{},slider:{},scrollbar:{},waterfall:{total:"Total"}};var xO={};Object.defineProperty(xO,"__esModule",{value:!0});var RY=xO.ZH_CN_LOCALE=void 0;RY=xO.ZH_CN_LOCALE={locale:"zh-CN",general:{increase:"\u589E\u52A0",decrease:"\u51CF\u5C11",root:"\u521D\u59CB"},statistic:{total:"\u603B\u8BA1"},conversionTag:{label:"\u8F6C\u5316\u7387"},legend:{},tooltip:{},slider:{},scrollbar:{},waterfall:{total:"\u603B\u8BA1"}};var q1t=globalThis&&globalThis.__extends||function(){var e=function(r,t){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,n){i.__proto__=n}||function(i,n){for(var a in n)n.hasOwnProperty(a)&&(i[a]=n[a])},e(r,t)};return function(r,t){e(r,t);function i(){this.constructor=r}r.prototype=t===null?Object.create(t):(i.prototype=t.prototype,new i)}}(),Xr=globalThis&&globalThis.__assign||function(){return Xr=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Xr.apply(this,arguments)},BY=globalThis&&globalThis.__rest||function(e,r){var t={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&r.indexOf(i)<0&&(t[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,i=Object.getOwnPropertySymbols(e);n<i.length;n++)r.indexOf(i[n])<0&&Object.prototype.propertyIsEnumerable.call(e,i[n])&&(t[i[n]]=e[i[n]]);return t},_S=globalThis&&globalThis.__spreadArrays||function(){for(var e=0,r=0,t=arguments.length;r<t;r++)e+=arguments[r].length;for(var i=Array(e),n=0,r=0;r<t;r++)for(var a=arguments[r],o=0,l=a.length;o<l;o++,n++)i[n]=a[o];return i};yO("en-US",kY);yO("zh-CN",RY);var Z1t=Ci("div",{style:{position:"absolute",top:"48%",left:"50%",color:"#aaa",textAlign:"center"},children:"\u6682\u65E0\u6570\u636E"}),Q1t={padding:"8px 24px 10px 10px",fontFamily:"PingFang SC",fontSize:12,color:"grey",textAlign:"left",lineHeight:"16px"},K1t={padding:"10px 0 0 10px",fontFamily:"PingFang SC",fontSize:18,color:"black",textAlign:"left",lineHeight:"20px"},J1t=function(e){q1t(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t._context={chart:null},t}return r.prototype.componentDidMount=function(){this.props.children&&this.g2Instance.chart&&this.g2Instance.chart.render(),WR(this.g2Instance,{},this.props),this.g2Instance.data=this.props.data,this.preConfig=Qf(ts(this.props,_S(Mf,["container","PlotClass","onGetG2Instance","data"])))},r.prototype.componentDidUpdate=function(t){this.props.children&&this.g2Instance.chart&&this.g2Instance.chart.render(),WR(this.g2Instance,t,this.props)},r.prototype.componentWillUnmount=function(){var t=this;this.g2Instance&&setTimeout(function(){t.g2Instance.destroy(),t.g2Instance=null,t._context.chart=null},0)},r.prototype.getG2Instance=function(){return this.g2Instance},r.prototype.getChartView=function(){return this.g2Instance.chart},r.prototype.checkInstanceReady=function(){var t=ts(this.props,_S(Mf,["container","PlotClass","onGetG2Instance","data"]));this.g2Instance?this.shouldReCreate()?(this.g2Instance.destroy(),this.initInstance(),this.g2Instance.render()):this.diffConfig()?this.g2Instance.update(Xr(Xr({},t),{data:this.props.data})):this.diffData()&&this.g2Instance.changeData(this.props.data):(this.initInstance(),this.g2Instance.render()),this.preConfig=Qf(t),this.g2Instance.data=this.props.data},r.prototype.initInstance=function(){var t=this.props,i=t.container,n=t.PlotClass,a=t.onGetG2Instance;t.children;var o=BY(t,["container","PlotClass","onGetG2Instance","children"]);this.g2Instance=new n(i,o),this._context.chart=this.g2Instance,Sa(a)&&a(this.g2Instance)},r.prototype.diffConfig=function(){var t=this.preConfig||{},i=ts(this.props,_S(Mf,["container","PlotClass","onGetG2Instance","data"]));return!xT(t,i)},r.prototype.diffData=function(){var t=this.g2Instance.data,i=this.props.data;if(!it(t)||!it(i))return!t===i;if(t.length!==i.length)return!0;var n=!0;return t.forEach(function(a,o){ug(a,i[o])||(n=!1)}),!n},r.prototype.shouldReCreate=function(){var t=this.props.forceUpdate;return!!t},r.prototype.render=function(){this.checkInstanceReady();var t=this.getChartView();return Ci(y_.Provider,{value:this._context,children:Ci(Ps.Provider,{value:t,children:Ci("div",{children:this.props.children},Kd("plot-chart"))})})},r}(Pt.Component),t_t=aO(J1t);function Qt(e,r,t){t===void 0&&(t=function(n){return n});var i=Pt.forwardRef(function(n,a){var o=n.title,l=n.description,s=n.autoFit,u=s===void 0?!0:s,c=n.forceFit,f=n.errorContent,h=f===void 0?pj:f,v=n.containerStyle,d=n.containerProps,p=n.placeholder,x=n.ErrorBoundaryProps,m=n.isMaterial,_=BY(n,["title","description","autoFit","forceFit","errorContent","containerStyle","containerProps","placeholder","ErrorBoundaryProps","isMaterial"]),b=t(_),w=Ur.exports.useRef(),S=Ur.exports.useRef(),M=Ur.exports.useRef(),F=Ur.exports.useState(0),O=F[0],L=F[1],D=Ur.exports.useRef(),k=Ur.exports.useCallback(function(){if(!!w.current){var q=pS(w.current,n),tt=S.current?pS(S.current):{width:0,height:0},ot=M.current?pS(M.current):{width:0,height:0},st=q.height-tt.height-ot.height;st===0&&(st=350),st<20&&(st=20),Math.abs(O-st)>1&&L(st)}},[w.current,S.current,O,M.current]),H=Ur.exports.useCallback(e1(k,500),[k]),B=Pt.isValidElement(h)?function(){return h}:h;if(p&&!b.data){var j=p===!0?Z1t:p;return Ci(Xd,{...Xr({FallbackComponent:B},x),children:Ci("div",{style:{width:n.width||"100%",height:n.height||400,textAlign:"center",position:"relative"},children:j})})}var U=dT(o,!1),R=dT(l,!1),G=Xr(Xr({},K1t),U.style),N=Xr(Xr(Xr({},Q1t),R.style),{top:G.height}),W=c!==void 0?c:u;return Ur.exports.useEffect(function(){return W?w.current?(k(),D.current=new bY(H),D.current.observe(w.current)):L(0):w.current&&(k(),D.current&&D.current.unobserve(w.current)),function(){D.current&&w.current&&D.current.unobserve(w.current)}},[w.current,W]),Ci(Xd,{...Xr({FallbackComponent:B},x),children:g8("div",{...Xr({ref:function(q){w.current=q,m&&(pt(a)?a(q):a&&(a.current=q))},className:"bizcharts-plot"},d,{style:{position:"relative",height:n.height||"100%",width:n.width||"100%"}}),children:[U.visible&&Ci("div",{...Xr({ref:S},p1t(b),{className:"bizcharts-plot-title",style:G}),children:U.text}),R.visible&&Ci("div",{...Xr({ref:M},g1t(b),{className:"bizcharts-plot-description",style:N}),children:R.text}),!!O&&Ci(t_t,{...Xr({appendPadding:[10,5,10,10],autoFit:W,ref:m?void 0:a},b,{PlotClass:e,containerStyle:Xr(Xr({},v),{height:O})})})]})})});return i.displayName=r||e.name,i}var _O={},ae={},Ye;(function(e){e.FORE="fore",e.MID="mid",e.BG="bg"})(Ye||(Ye={}));var ct;(function(e){e.TOP="top",e.TOP_LEFT="top-left",e.TOP_RIGHT="top-right",e.RIGHT="right",e.RIGHT_TOP="right-top",e.RIGHT_BOTTOM="right-bottom",e.LEFT="left",e.LEFT_TOP="left-top",e.LEFT_BOTTOM="left-bottom",e.BOTTOM="bottom",e.BOTTOM_LEFT="bottom-left",e.BOTTOM_RIGHT="bottom-right",e.RADIUS="radius",e.CIRCLE="circle",e.NONE="none"})(ct||(ct={}));var Mr;(function(e){e.AXIS="axis",e.GRID="grid",e.LEGEND="legend",e.TOOLTIP="tooltip",e.ANNOTATION="annotation",e.SLIDER="slider",e.SCROLLBAR="scrollbar",e.OTHER="other"})(Mr||(Mr={}));var Ff={FORE:3,MID:2,BG:1},Gt;(function(e){e.BEFORE_RENDER="beforerender",e.AFTER_RENDER="afterrender",e.BEFORE_PAINT="beforepaint",e.AFTER_PAINT="afterpaint",e.BEFORE_CHANGE_DATA="beforechangedata",e.AFTER_CHANGE_DATA="afterchangedata",e.BEFORE_CLEAR="beforeclear",e.AFTER_CLEAR="afterclear",e.BEFORE_DESTROY="beforedestroy",e.BEFORE_CHANGE_SIZE="beforechangesize",e.AFTER_CHANGE_SIZE="afterchangesize"})(Gt||(Gt={}));var Of;(function(e){e.BEFORE_DRAW_ANIMATE="beforeanimate",e.AFTER_DRAW_ANIMATE="afteranimate"})(Of||(Of={}));var Ri;(function(e){e.MOUSE_ENTER="plot:mouseenter",e.MOUSE_DOWN="plot:mousedown",e.MOUSE_MOVE="plot:mousemove",e.MOUSE_UP="plot:mouseup",e.MOUSE_LEAVE="plot:mouseleave",e.TOUCH_START="plot:touchstart",e.TOUCH_MOVE="plot:touchmove",e.TOUCH_END="plot:touchend",e.TOUCH_CANCEL="plot:touchcancel",e.CLICK="plot:click",e.DBLCLICK="plot:dblclick",e.CONTEXTMENU="plot:contextmenu",e.LEAVE="plot:leave",e.ENTER="plot:enter"})(Ri||(Ri={}));var xx;(function(e){e.ACTIVE="active",e.INACTIVE="inactive",e.SELECTED="selected",e.DEFAULT="default"})(xx||(xx={}));var Qv=["color","shape","size"],de="_origin",ZR=1,QR=1,KR=.25,NY={};function GY(e){var r=NY[e];if(!r)throw new Error("G engine '"+e+"' is not exist, please register it at first.");return r}function bO(e,r){NY[e]=r}function e_t(e){var r=getComputedStyle(e);return{width:(e.clientWidth||parseInt(r.width,10))-parseInt(r.paddingLeft,10)-parseInt(r.paddingRight,10),height:(e.clientHeight||parseInt(r.height,10))-parseInt(r.paddingTop,10)-parseInt(r.paddingBottom,10)}}function JR(e){return typeof e=="number"&&!isNaN(e)}function tB(e,r,t,i){var n=t,a=i;if(r){var o=e_t(e);n=o.width?o.width:n,a=o.height?o.height:a}return{width:Math.max(JR(n)?n:ZR,ZR),height:Math.max(JR(a)?a:QR,QR)}}function r_t(e){var r=e.parentNode;r&&r.removeChild(e)}var wO=function(e){X(r,e);function r(t){var i=e.call(this)||this;i.destroyed=!1;var n=t.visible,a=n===void 0?!0:n;return i.visible=a,i}return r.prototype.show=function(){var t=this.visible;t||this.changeVisible(!0)},r.prototype.hide=function(){var t=this.visible;t&&this.changeVisible(!1)},r.prototype.destroy=function(){this.off(),this.destroyed=!0},r.prototype.changeVisible=function(t){this.visible!==t&&(this.visible=t)},r}(yp),i_t=$5,n_t=k5,a_t=N5,o_t=B5,eB=G5,l_t=z5,zY=H5;function s_t(e){if(gi(e))return null;var r=e[0].x,t=e[0].x,i=e[0].y,n=e[0].y;return P(e,function(a){r=r>a.x?a.x:r,t=t<a.x?a.x:t,i=i>a.y?a.y:i,n=n<a.y?a.y:n}),{minX:r,maxX:t,minY:i,maxY:n,centerX:(r+t)/2,centerY:(i+n)/2}}function rB(e){return Array.from(new Set(e)).length===1}function iB(e){return(Or(e)+gr(e))/2}function ir(e,r,t,i){return{x:e+t*Math.cos(i),y:r+t*Math.sin(i)}}function es(e,r,t,i,n,a){a===void 0&&(a=0);var o=ir(e,r,t,i),l=ir(e,r,t,n),s=ir(e,r,a,i),u=ir(e,r,a,n);if(n-i===Math.PI*2){var c=ir(e,r,t,i+Math.PI),f=ir(e,r,a,i+Math.PI),h=[["M",o.x,o.y],["A",t,t,0,1,1,c.x,c.y],["A",t,t,0,1,1,l.x,l.y],["M",s.x,s.y]];return a&&(h.push(["A",a,a,0,1,0,f.x,f.y]),h.push(["A",a,a,0,1,0,u.x,u.y])),h.push(["M",o.x,o.y]),h.push(["Z"]),h}var v=n-i<=Math.PI?0:1,d=[["M",o.x,o.y],["A",t,t,0,v,1,l.x,l.y],["L",u.x,u.y]];return a&&d.push(["A",a,a,0,v,0,s.x,s.y]),d.push(["L",o.x,o.y]),d.push(["Z"]),d}function VY(e,r,t,i,n){var a=ir(e,r,t,i),o=ir(e,r,t,n);if(zr(n-i,Math.PI*2)){var l=ir(e,r,t,i+Math.PI);return[["M",a.x,a.y],["A",t,t,0,1,1,l.x,l.y],["A",t,t,0,1,1,a.x,a.y],["A",t,t,0,1,0,l.x,l.y],["A",t,t,0,1,0,a.x,a.y],["Z"]]}var s=n-i<=Math.PI?0:1;return[["M",a.x,a.y],["A",t,t,0,s,1,o.x,o.y]]}function rp(e,r){var t=e.points,i=s_t(t),n,a,o=r.startAngle,l=r.endAngle,s=l-o;return r.isTransposed?(n=i.maxY*s,a=i.minY*s):(n=i.maxX*s,a=i.minX*s),n+=o,a+=o,{startAngle:a,endAngle:n}}function u_t(e,r){if(Mt(e)&&Mt(r))return[e,r];if(e=e,r=r,rB(e)||rB(r))return[iB(e),iB(r)];for(var t=-1,i=0,n=0,a,o=e.length-1,l,s=0;++t<e.length;)a=o,o=t,s+=l=e[a]*r[o]-e[o]*r[a],i+=(e[a]+e[o])*l,n+=(r[a]+r[o])*l;return s*=3,[i/s,n/s]}function jY(e,r){var t=e.attr(),i=r.attr();return P(t,function(n,a){i[a]===void 0&&(i[a]=void 0)}),i}function xf(e,r,t){var i=Math.min(r,t),n=Math.max(r,t);return e>=i&&e<=n}function c_t(e,r,t){if(Ct(e))return e.padEnd(r,t);if(it(e)){var i=e.length;if(i<r)for(var n=r-i,a=0;a<n;a++)e.push(t)}return e}function Gi(e,r){return typeof e=="object"&&r.forEach(function(t){delete e[t]}),e}function Hl(e,r,t){r===void 0&&(r=[]),t===void 0&&(t=new Map);for(var i=0,n=e;i<n.length;i++){var a=n[i];t.has(a)||(r.push(a),t.set(a,!0))}return r}var Ei=function(){function e(r,t,i,n){r===void 0&&(r=0),t===void 0&&(t=0),i===void 0&&(i=0),n===void 0&&(n=0),this.x=r,this.y=t,this.height=n,this.width=i}return e.fromRange=function(r,t,i,n){return new e(r,t,i-r,n-t)},e.fromObject=function(r){return new e(r.minX,r.minY,r.width,r.height)},Object.defineProperty(e.prototype,"minX",{get:function(){return this.x},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"maxX",{get:function(){return this.x+this.width},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"minY",{get:function(){return this.y},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"maxY",{get:function(){return this.y+this.height},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tl",{get:function(){return{x:this.x,y:this.y}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"tr",{get:function(){return{x:this.maxX,y:this.y}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"bl",{get:function(){return{x:this.x,y:this.maxY}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"br",{get:function(){return{x:this.maxX,y:this.maxY}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"top",{get:function(){return{x:this.x+this.width/2,y:this.minY}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"right",{get:function(){return{x:this.maxX,y:this.y+this.height/2}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"bottom",{get:function(){return{x:this.x+this.width/2,y:this.maxY}},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"left",{get:function(){return{x:this.minX,y:this.y+this.height/2}},enumerable:!1,configurable:!0}),e.prototype.isEqual=function(r){return this.x===r.x&&this.y===r.y&&this.width===r.width&&this.height===r.height},e.prototype.contains=function(r){return r.minX>=this.minX&&r.maxX<=this.maxX&&r.minY>=this.minY&&r.maxY<=this.maxY},e.prototype.clone=function(){return new e(this.x,this.y,this.width,this.height)},e.prototype.add=function(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];var i=this.clone();return P(r,function(n){i.x=Math.min(n.x,i.x),i.y=Math.min(n.y,i.y),i.width=Math.max(n.maxX,i.maxX)-i.x,i.height=Math.max(n.maxY,i.maxY)-i.y}),i},e.prototype.merge=function(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];var i=this.clone();return P(r,function(n){i.x=Math.max(n.x,i.x),i.y=Math.max(n.y,i.y),i.width=Math.min(n.maxX,i.maxX)-i.x,i.height=Math.min(n.maxY,i.maxY)-i.y}),i},e.prototype.cut=function(r,t){var i=r.width,n=r.height;switch(t){case ct.TOP:case ct.TOP_LEFT:case ct.TOP_RIGHT:return e.fromRange(this.minX,this.minY+n,this.maxX,this.maxY);case ct.RIGHT:case ct.RIGHT_TOP:case ct.RIGHT_BOTTOM:return e.fromRange(this.minX,this.minY,this.maxX-i,this.maxY);case ct.BOTTOM:case ct.BOTTOM_LEFT:case ct.BOTTOM_RIGHT:return e.fromRange(this.minX,this.minY,this.maxX,this.maxY-n);case ct.LEFT:case ct.LEFT_TOP:case ct.LEFT_BOTTOM:return e.fromRange(this.minX+i,this.minY,this.maxX,this.maxY);default:return this}},e.prototype.shrink=function(r){var t=r[0],i=r[1],n=r[2],a=r[3];return new e(this.x+a,this.y+t,this.width-a-i,this.height-t-n)},e.prototype.expand=function(r){var t=r[0],i=r[1],n=r[2],a=r[3];return new e(this.x-a,this.y-t,this.width+a+i,this.height+t+n)},e.prototype.exceed=function(r){return[Math.max(-this.minY+r.minY,0),Math.max(this.maxX-r.maxX,0),Math.max(this.maxY-r.maxY,0),Math.max(-this.minX+r.minX,0)]},e.prototype.collide=function(r){return this.minX<r.maxX&&this.maxX>r.minX&&this.minY<r.maxY&&this.maxY>r.minY},e.prototype.size=function(){return this.width*this.height},e.prototype.isPointIn=function(r){return r.x>=this.minX&&r.x<=this.maxX&&r.y>=this.minY&&r.y<=this.maxY},e}();function f_t(e){return[[e.minX,e.minY],[e.maxX,e.minY],[e.maxX,e.maxY],[e.minX,e.maxY]]}function hg(e){if(e.isPolar&&!e.isTransposed)return(e.endAngle-e.startAngle)*e.getRadius();var r=e.convert({x:0,y:0}),t=e.convert({x:1,y:0});return Math.sqrt(Math.pow(t.x-r.x,2)+Math.pow(t.y-r.y,2))}function h_t(e){if(e.isPolar){var r=e.startAngle,t=e.endAngle;return t-r===Math.PI*2}return!1}function T_(e,r){var t=e.getCenter();return Math.sqrt(Math.pow(r.x-t.x,2)+Math.pow(r.y-t.y,2))}function bT(e,r){var t=!1;if(e)if(e.type==="theta"){var i=e.start,n=e.end;t=xf(r.x,i.x,n.x)&&xf(r.y,i.y,n.y)}else{var a=e.invert(r);t=xf(a.x,0,1)&&xf(a.y,0,1)}return t}function Kf(e,r){var t=e.getCenter();return Math.atan2(r.y-t.y,r.x-t.x)}function HY(e,r){r===void 0&&(r=0);var t=e.start,i=e.end,n=e.getWidth(),a=e.getHeight();if(e.isPolar){var o=e.startAngle,l=e.endAngle,s=e.getCenter(),u=e.getRadius();return{type:"path",startState:{path:es(s.x,s.y,u+r,o,o)},endState:function(f){var h=(l-o)*f+o,v=es(s.x,s.y,u+r,o,h);return{path:v}},attrs:{path:es(s.x,s.y,u+r,o,l)}}}var c;return e.isTransposed?c={height:a+r*2}:c={width:n+r*2},{type:"rect",startState:{x:t.x-r,y:i.y-r,width:e.isTransposed?n+r*2:0,height:e.isTransposed?0:a+r*2},endState:c,attrs:{x:t.x-r,y:i.y-r,width:n+r*2,height:a+r*2}}}function v_t(e,r){r===void 0&&(r=0);var t=e.start,i=e.end,n=e.getWidth(),a=e.getHeight(),o=Math.min(t.x,i.x),l=Math.min(t.y,i.y);return Ei.fromRange(o-r,l-r,o+n+r,l+a+r)}var d_t=/^(?:(?!0000)[0-9]{4}([-/.]+)(?:(?:0?[1-9]|1[0-2])\1(?:0?[1-9]|1[0-9]|2[0-8])|(?:0?[13-9]|1[0-2])\1(?:29|30)|(?:0?[13578]|1[02])\1(?:31))|(?:[0-9]{2}(?:0[48]|[2468][048]|[13579][26])|(?:0[48]|[2468][048]|[13579][26])00)([-/.]+)0?2\2(?:29))(\s+([01]|([01][0-9]|2[0-3])):([0-9]|[0-5][0-9]):([0-9]|[0-5][0-9]))?$/;function p_t(e){var r="linear";return d_t.test(e)?r="timeCat":Ct(e)&&(r="cat"),r}function g_t(e,r,t){var i=r||[];if(Mt(e)||K(YG(i,e))&&gi(t)){var n=zd("identity");return new n({field:e.toString(),values:[e]})}var a=Xn(i,e),o=I(t,"type",p_t(a[0])),l=zd(o);return new l(A({field:e,values:a},t))}function y_t(e,r){if(e.type!=="identity"&&r.type!=="identity"){var t={};for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(t[i]=r[i]);e.change(t)}}function ip(e){return e.alias||e.field}function YY(e,r,t){var i=e.values,n=i.length,a;if(n===1)a=[.5,1];else{var o=1,l=0;h_t(r)?r.isTransposed?(o=I(t,"widthRatio.multiplePie",1/1.3),l=1/n*o,a=[l/2,1-l/2]):a=[0,1-1/n]:(l=1/n/2,a=[l,1-l])}return a}function m_t(e){var r=e.values.filter(function(t){return!K(t)&&!isNaN(t)});return Math.max.apply(Math,Qr(Qr([],r,!1),[K(e.max)?-1/0:e.max],!1))}function x_t(e){var r,t;switch(e){case ct.TOP:r={x:0,y:1},t={x:1,y:1};break;case ct.RIGHT:r={x:1,y:0},t={x:1,y:1};break;case ct.BOTTOM:r={x:0,y:0},t={x:1,y:0};break;case ct.LEFT:r={x:0,y:0},t={x:0,y:1};break;default:r=t={x:0,y:0}}return{start:r,end:t}}function __t(e){var r,t;return e.isTransposed?(r={x:0,y:0},t={x:1,y:0}):(r={x:0,y:0},t={x:0,y:1}),{start:r,end:t}}function qm(e,r){var t={start:{x:0,y:0},end:{x:0,y:0}};e.isRect?t=x_t(r):e.isPolar&&(t=__t(e));var i=t.start,n=t.end;return{start:e.convert(i),end:e.convert(n)}}function WY(e){var r=e.start,t=e.end;return r.x===t.x}function nB(e,r){var t=e.start,i=e.end,n=WY(e);return n?(t.y-i.y)*(r.x-t.x)>0?1:-1:(i.x-t.x)*(t.y-r.y)>0?-1:1}function Zm(e,r){var t=I(e,["components","axis"],{});return ft({},I(t,["common"],{}),ft({},I(t,[r],{})))}function aB(e,r,t){var i=I(e,["components","axis"],{});return ft({},I(i,["common","title"],{}),ft({},I(i,[r,"title"],{})),t)}function bS(e){var r=e.x,t=e.y,i=e.circleCenter,n=t.start>t.end,a=e.isTransposed?e.convert({x:n?0:1,y:0}):e.convert({x:0,y:n?0:1}),o=[a.x-i.x,a.y-i.y],l=[1,0],s=a.y>i.y?V0(o,l):V0(o,l)*-1,u=s+(r.end-r.start),c=Math.sqrt(Math.pow(a.x-i.x,2)+Math.pow(a.y-i.y,2));return{center:i,radius:c,startAngle:s,endAngle:u}}function _x(e,r){return Yu(e)?e===!1?!1:{}:I(e,[r])}function oB(e,r){return I(e,"position",r)}function lB(e,r){return I(r,["title","text"],ip(e))}var vc=function(){function e(r,t){this.destroyed=!1,this.facets=[],this.view=r,this.cfg=ft({},this.getDefaultCfg(),t)}return e.prototype.init=function(){this.container||(this.container=this.createContainer());var r=this.view.getData();this.facets=this.generateFacets(r)},e.prototype.render=function(){this.renderViews()},e.prototype.update=function(){},e.prototype.clear=function(){this.clearFacetViews()},e.prototype.destroy=function(){this.clear(),this.container&&(this.container.remove(!0),this.container=void 0),this.destroyed=!0,this.view=void 0,this.facets=[]},e.prototype.facetToView=function(r){var t=r.region,i=r.data,n=r.padding,a=n===void 0?this.cfg.padding:n,o=this.view.createView({region:t,padding:a});o.data(i||[]),r.view=o,this.beforeEachView(o,r);var l=this.cfg.eachView;return l&&l(o,r),this.afterEachView(o,r),o},e.prototype.createContainer=function(){var r=this.view.getLayer(Ye.FORE);return r.addGroup()},e.prototype.renderViews=function(){this.createFacetViews()},e.prototype.createFacetViews=function(){var r=this;return this.facets.map(function(t){return r.facetToView(t)})},e.prototype.clearFacetViews=function(){var r=this;P(this.facets,function(t){t.view&&(r.view.removeView(t.view),t.view=void 0)})},e.prototype.parseSpacing=function(){var r=this.view.viewBBox,t=r.width,i=r.height,n=this.cfg.spacing;return n.map(function(a,o){return Mt(a)?a/(o===0?t:i):parseFloat(a)/100})},e.prototype.getFieldValues=function(r,t){var i=[],n={};return P(r,function(a){var o=a[t];!K(o)&&!n[o]&&(i.push(o),n[o]=!0)}),i},e.prototype.getRegion=function(r,t,i,n){var a=this.parseSpacing(),o=a[0],l=a[1],s=(1+o)/(t===0?1:t)-o,u=(1+l)/(r===0?1:r)-l,c={x:(s+o)*i,y:(u+l)*n},f={x:c.x+s,y:c.y+u};return{start:c,end:f}},e.prototype.getDefaultCfg=function(){return{eachView:void 0,showTitle:!0,spacing:[0,0],padding:10,fields:[]}},e.prototype.getDefaultTitleCfg=function(){var r=this.view.getTheme().fontFamily;return{style:{fontSize:14,fill:"#666",fontFamily:r}}},e.prototype.processAxis=function(r,t){var i=r.getOptions(),n=i.coordinate,a=r.geometries,o=I(n,"type","rect");if(o==="rect"&&a.length){K(i.axes)&&(i.axes={});var l=i.axes,s=a[0].getXYFields(),u=s[0],c=s[1],f=_x(l,u),h=_x(l,c);f!==!1&&(i.axes[u]=this.getXAxisOption(u,l,f,t)),h!==!1&&(i.axes[c]=this.getYAxisOption(c,l,h,t))}},e.prototype.getFacetDataFilter=function(r){return function(t){return Zx(r,function(i){var n=i.field,a=i.value;return!K(a)&&n?t[n]===a:!0})}},e}(),XY={},UY=function(e){return XY[sc(e)]},dc=function(e,r){XY[sc(e)]=r},Ie=function(){function e(r,t){this.context=r,this.cfg=t,r.addAction(this)}return e.prototype.applyCfg=function(r){Kt(this,r)},e.prototype.init=function(){this.applyCfg(this.cfg)},e.prototype.destroy=function(){this.context.removeAction(this),this.context=null},e}(),b_t=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.execute=function(){this.callback&&this.callback(this.context)},r.prototype.destroy=function(){e.prototype.destroy.call(this),this.callback=null},r}(Ie),CO={};function w_t(e,r){var t=CO[e],i=null;if(t){var n=t.ActionClass,a=t.cfg;i=new n(r,a),i.name=e,i.init()}return i}function vg(e){var r=CO[e];return I(r,"ActionClass")}function Et(e,r,t){CO[e]={ActionClass:r,cfg:t}}function C_t(e,r){var t=new b_t(r);return t.callback=e,t.name="callback",t}function S_t(e,r){var t=[];if(e.length){t.push(["M",e[0].x,e[0].y]);for(var i=1,n=e.length;i<n;i+=1){var a=e[i];t.push(["L",a.x,a.y])}r&&t.push(["Z"])}return t}function wT(e,r){for(var t=[e[0]],i=1,n=e.length;i<n;i=i+2){var a=r.convert({x:e[i],y:e[i+1]});t.push(a.x,a.y)}return t}function qY(e,r){var t=r.isTransposed,i=e[1],n=e[6],a=e[7],o=r.convert({x:n,y:a}),l=t?0:1;return["A",i,i,0,0,l,o.x,o.y]}function A_t(e,r,t){var i=t.isTransposed,n=t.startAngle,a=t.endAngle,o=e[0].toLowerCase()==="a"?{x:e[6],y:e[7]}:{x:e[1],y:e[2]},l={x:r[1],y:r[2]},s=[],u=i?"y":"x",c=Math.abs(l[u]-o[u])*(a-n),f=l[u]>=o[u]?1:0,h=c>Math.PI?1:0,v=t.convert(l),d=T_(t,v);if(d>=.5)if(c===Math.PI*2){var p={x:(l.x+o.x)/2,y:(l.y+o.y)/2},x=t.convert(p);s.push(["A",d,d,0,h,f,x.x,x.y]),s.push(["A",d,d,0,h,f,v.x,v.y])}else s.push(["A",d,d,0,h,f,v.x,v.y]);return s}function T_t(e){P(e,function(r,t){var i=r;if(i[0].toLowerCase()==="a"){var n=e[t-1],a=e[t+1];a&&a[0].toLowerCase()==="a"?n&&n[0].toLowerCase()==="l"&&(n[0]="M"):n&&n[0].toLowerCase()==="a"&&a&&a[0].toLowerCase()==="l"&&(a[0]="M")}})}var M_t=function(e,r,t,i){var n=[],a=!!i,o,l,s,u,c,f,h;if(a){s=i[0],u=i[1];for(var v=0,d=e.length;v<d;v++){var p=e[v];s=Cr([0,0],s,p),u=Sr([0,0],u,p)}}for(var v=0,x=e.length;v<x;v++){var p=e[v];if(v===0&&!t)h=p;else if(v===x-1&&!t)f=p,n.push(h),n.push(f);else{o=e[t?v?v-1:x-1:v-1],l=e[t?(v+1)%x:v+1];var m=[0,0];m=Kl(m,l,o),m=pi(m,m,r);var _=cs(p,o),b=cs(p,l),w=_+b;w!==0&&(_/=w,b/=w);var S=pi([0,0],m,-_),M=pi([0,0],m,b);f=ma([0,0],p,S),c=ma([0,0],p,M),c=Cr([0,0],c,Sr([0,0],l,p)),c=Sr([0,0],c,Cr([0,0],l,p)),S=Kl([0,0],c,p),S=pi([0,0],S,-_/b),f=ma([0,0],p,S),f=Cr([0,0],f,Sr([0,0],o,p)),f=Sr([0,0],f,Cr([0,0],o,p)),M=Kl([0,0],p,f),M=pi([0,0],M,b/_),c=ma([0,0],p,M),a&&(f=Sr([0,0],f,s),f=Cr([0,0],f,u),c=Sr([0,0],c,s),c=Cr([0,0],c,u)),n.push(h),n.push(f),h=c}}return t&&n.push(n.shift()),n};function ZY(e,r,t){for(var i=!!r,n=[],a=0,o=e.length;a<o;a+=2)n.push([e[a],e[a+1]]);for(var l=M_t(n,.4,i,t),s=n.length,u=[],c,f,h,a=0;a<s-1;a++)c=l[a*2],f=l[a*2+1],h=n[a+1],u.push(["C",c[0],c[1],f[0],f[1],h[0],h[1]]);return i&&(c=l[s],f=l[s+1],h=n[0],u.push(["C",c[0],c[1],f[0],f[1],h[0],h[1]])),u}function dg(e,r){return S_t(e,r)}function bx(e,r,t){var i=[],n=e[0],a=null;if(e.length<=2)return dg(e,r);for(var o=0,l=e.length;o<l;o++){var s=e[o];(!a||!(a.x===s.x&&a.y===s.y))&&(i.push(s.x),i.push(s.y),a=s)}var u=t||[[0,0],[1,1]],c=ZY(i,r,u);return c.unshift(["M",n.x,n.y]),c}function E_t(e,r){var t=[];return P(r,function(i){var n=i[0];switch(n.toLowerCase()){case"m":case"l":case"c":t.push(wT(i,e));break;case"a":t.push(qY(i,e));break;case"z":default:t.push(i);break}}),t}function F_t(e,r){var t=[],i,n,a,o;return P(r,function(l,s){var u=l[0];switch(u.toLowerCase()){case"m":case"c":case"q":t.push(wT(l,e));break;case"l":i=r[s-1],n=l,a=e.isTransposed,o=a?i[i.length-2]===n[1]:i[i.length-1]===n[2],o?t=t.concat(A_t(i,n,e)):t.push(wT(l,e));break;case"a":t.push(qY(l,e));break;case"z":default:t.push(l);break}}),T_t(t),t}function QY(e,r){var t=e.event,i=t.target,n=i.getCanvasBBox();return n.width>=r||n.height>=r?n:null}function O_t(e,r){var t=e.event,i=t.target,n=i.getCanvasBBox();return n.width>=r||n.height>=r?i.attr("path"):null}function ws(e){var r=e.event,t,i=r.target;return i&&(t=i.get("element")),t}function Jf(e){var r=e.event,t=r.target,i;return t&&(i=t.get("delegateObject")),i}function KY(e){var r=e.event.gEvent;return!(r&&r.fromShape&&r.toShape&&r.fromShape.get("element")===r.toShape.get("element"))}function np(e){return e&&e.component&&e.component.isList()}function JY(e){return e&&e.component&&e.component.isSlider()}function ap(e){var r=e.event,t=r.target;return t&&t.get("name")==="mask"}function SO(e,r){var t=e.event.target;if(t.get("type")==="path"){var i=O_t(e,r);return i?L_t(e.view,i):void 0}var n=QY(e,r);return n?AO(e.view,n):null}function tW(e,r,t){var i=QY(e,t);if(!i)return null;var n=e.view,a=CT(n,r,{x:i.x,y:i.y}),o=CT(n,r,{x:i.maxX,y:i.maxY}),l={minX:a.x,minY:a.y,maxX:o.x,maxY:o.y};return AO(r,l)}function Vr(e){var r=e.geometries,t=[];return P(r,function(i){var n=i.elements;t=t.concat(n)}),e.views&&e.views.length&&P(e.views,function(i){t=t.concat(Vr(i))}),t}function P_t(e,r,t){var i=Vr(e);return i.filter(function(n){return Ea(n,r)===t})}function eW(e,r){var t=e.geometries,i=[];return P(t,function(n){var a=n.getElementsBy(function(o){return o.hasState(r)});i=i.concat(a)}),i}function Ea(e,r){var t=e.getModel(),i=t.data,n;return it(i)?n=i[0][r]:n=i[r],n}function I_t(e,r){return!(r.minX>e.maxX||r.maxX<e.minX||r.minY>e.maxY||r.maxY<e.minY)}function AO(e,r){var t=Vr(e),i=[];return P(t,function(n){var a=n.shape,o=a.getCanvasBBox();I_t(r,o)&&i.push(n)}),i}function sB(e){var r=[];return P(e,function(t){var i=t[0];if(i!=="A")for(var n=1;n<t.length;n=n+2)r.push([t[n],t[n+1]]);else{var a=t.length;r.push([t[a-2],t[a-1]])}}),r}function L_t(e,r){var t=Vr(e),i=sB(r),n=t.filter(function(a){var o=a.shape,l;if(o.get("type")==="path")l=sB(o.attr("path"));else{var s=o.getCanvasBBox();l=f_t(s)}return DV(i,l)});return n}function rW(e){return e.getComponents().map(function(r){return r.component})}function TO(e,r){var t=r.x-e.x,i=r.y-e.y;return Math.sqrt(t*t+i*i)}function D_t(e,r){if(e.length<=2)return dg(e,!1);var t=e[0],i=[];P(e,function(a){i.push(a.x),i.push(a.y)});var n=ZY(i,r,null);return n.unshift(["M",t.x,t.y]),n}function uB(e,r){return e.x<=r.x&&e.maxX>=r.x&&e.y<=r.y&&e.maxY>r.y}function vo(e){var r=e.parent,t=null;return r&&(t=r.views.filter(function(i){return i!==e})),t}function $_t(e,r){var t=e.getCoordinate();return t.invert(r)}function CT(e,r,t){var i=$_t(e,t);return r.getCoordinate().convert(i)}function iW(e,r,t,i){var n=!1;return P(e,function(a){if(a[t]===r[t]&&a[i]===r[i])return n=!0,!1}),n}function th(e,r){var t=e.getScaleByField(r);return!t&&e.views&&P(e.views,function(i){if(t=th(i,r),t)return!1}),t}var k_t=function(){function e(r){this.actions=[],this.event=null,this.cacheMap={},this.view=r}return e.prototype.cache=function(){for(var r=[],t=0;t<arguments.length;t++)r[t]=arguments[t];if(r.length===1)return this.cacheMap[r[0]];r.length===2&&(this.cacheMap[r[0]]=r[1])},e.prototype.getAction=function(r){return this.actions.find(function(t){return t.name===r})},e.prototype.addAction=function(r){this.actions.push(r)},e.prototype.removeAction=function(r){var t=this.actions,i=this.actions.indexOf(r);i>=0&&t.splice(i,1)},e.prototype.getCurrentPoint=function(){var r=this.event;if(r)if(r.target instanceof HTMLElement){var t=this.view.getCanvas(),i=t.getPointByClient(r.clientX,r.clientY);return i}else return{x:r.x,y:r.y};return null},e.prototype.getCurrentShape=function(){return I(this.event,["gEvent","shape"])},e.prototype.isInPlot=function(){var r=this.getCurrentPoint();return r?this.view.isPointInPlot(r):!1},e.prototype.isInShape=function(r){var t=this.getCurrentShape();return t?t.get("name")===r:!1},e.prototype.isInComponent=function(r){var t=rW(this.view),i=this.getCurrentPoint();return i?!!t.find(function(n){var a=n.getBBox();return r?n.get("name")===r&&uB(a,i):uB(a,i)}):!1},e.prototype.destroy=function(){P(this.actions.slice(),function(r){r.destroy()}),this.view=null,this.event=null,this.actions=null,this.cacheMap=null},e}(),nW=function(){function e(r,t){this.view=r,this.cfg=t}return e.prototype.init=function(){this.initEvents()},e.prototype.initEvents=function(){},e.prototype.clearEvents=function(){},e.prototype.destroy=function(){this.clearEvents()},e}();function cB(e,r,t){var i=e.split(":"),n=i[0],a=r.getAction(n)||w_t(n,r);if(!a)throw new Error("There is no action named "+n);var o=i[1];return{action:a,methodName:o,arg:t}}function fB(e){var r=e.action,t=e.methodName,i=e.arg;if(r[t])r[t](i);else throw new Error("Action("+r.name+") doesn't have a method called "+t)}var sn={START:"start",SHOW_ENABLE:"showEnable",END:"end",ROLLBACK:"rollback",PROCESSING:"processing"},R_t=function(e){X(r,e);function r(t,i){var n=e.call(this,t,i)||this;return n.callbackCaches={},n.emitCaches={},n.steps=i,n}return r.prototype.init=function(){this.initContext(),e.prototype.init.call(this)},r.prototype.destroy=function(){e.prototype.destroy.call(this),this.steps=null,this.context&&(this.context.destroy(),this.context=null),this.callbackCaches=null,this.view=null},r.prototype.initEvents=function(){var t=this;P(this.steps,function(i,n){P(i,function(a){var o=t.getActionCallback(n,a);o&&t.bindEvent(a.trigger,o)})})},r.prototype.clearEvents=function(){var t=this;P(this.steps,function(i,n){P(i,function(a){var o=t.getActionCallback(n,a);o&&t.offEvent(a.trigger,o)})})},r.prototype.initContext=function(){var t=this.view,i=new k_t(t);this.context=i;var n=this.steps;P(n,function(a){P(a,function(o){if(pt(o.action))o.actionObject={action:C_t(o.action,i),methodName:"execute"};else if(Ct(o.action))o.actionObject=cB(o.action,i,o.arg);else if(it(o.action)){var l=o.action,s=it(o.arg)?o.arg:[o.arg];o.actionObject=[],P(l,function(u,c){o.actionObject.push(cB(u,i,s[c]))})}})})},r.prototype.isAllowStep=function(t){var i=this.currentStepName,n=this.steps;if(i===t||t===sn.SHOW_ENABLE)return!0;if(t===sn.PROCESSING)return i===sn.START;if(t===sn.START)return i!==sn.PROCESSING;if(t===sn.END)return i===sn.PROCESSING||i===sn.START;if(t===sn.ROLLBACK){if(n[sn.END])return i===sn.END;if(i===sn.START)return!0}return!1},r.prototype.isAllowExecute=function(t,i){if(this.isAllowStep(t)){var n=this.getKey(t,i);return i.once&&this.emitCaches[n]?!1:i.isEnable?i.isEnable(this.context):!0}return!1},r.prototype.enterStep=function(t){this.currentStepName=t,this.emitCaches={}},r.prototype.afterExecute=function(t,i){t!==sn.SHOW_ENABLE&&this.currentStepName!==t&&this.enterStep(t);var n=this.getKey(t,i);this.emitCaches[n]=!0},r.prototype.getKey=function(t,i){return t+i.trigger+i.action},r.prototype.getActionCallback=function(t,i){var n=this,a=this.context,o=this.callbackCaches,l=i.actionObject;if(i.action&&l){var s=this.getKey(t,i);if(!o[s]){var u=function(c){a.event=c,n.isAllowExecute(t,i)?(it(l)?P(l,function(f){a.event=c,fB(f)}):(a.event=c,fB(l)),n.afterExecute(t,i),i.callback&&(a.event=c,i.callback(a))):a.event=null};i.debounce?o[s]=e1(u,i.debounce.wait,i.debounce.immediate):i.throttle?o[s]=n1(u,i.throttle.wait,{leading:i.throttle.leading,trailing:i.throttle.trailing}):o[s]=u}return o[s]}return null},r.prototype.bindEvent=function(t,i){var n=t.split(":");n[0]==="window"?window.addEventListener(n[1],i):n[0]==="document"?document.addEventListener(n[1],i):this.view.on(t,i)},r.prototype.offEvent=function(t,i){var n=t.split(":");n[0]==="window"?window.removeEventListener(n[1],i):n[0]==="document"?document.removeEventListener(n[1],i):this.view.off(t,i)},r}(nW),aW={};function oW(e){return aW[sc(e)]}function Lt(e,r){aW[sc(e)]=r}function B_t(e,r,t){var i=oW(e);if(!i)return null;if(wa(i)){var n=Kt(di(i),t);return new R_t(r,n)}else{var a=i;return new a(r,t)}}function N_t(e){return{title:{autoRotate:!0,position:"center",spacing:e.axisTitleSpacing,style:{fill:e.axisTitleTextFillColor,fontSize:e.axisTitleTextFontSize,lineHeight:e.axisTitleTextLineHeight,textBaseline:"middle",fontFamily:e.fontFamily}},label:{autoRotate:!1,autoEllipsis:!1,autoHide:{type:"equidistance",cfg:{minGap:6}},offset:e.axisLabelOffset,style:{fill:e.axisLabelFillColor,fontSize:e.axisLabelFontSize,lineHeight:e.axisLabelLineHeight,fontFamily:e.fontFamily}},line:{style:{lineWidth:e.axisLineBorder,stroke:e.axisLineBorderColor}},grid:{line:{type:"line",style:{stroke:e.axisGridBorderColor,lineWidth:e.axisGridBorder,lineDash:e.axisGridLineDash}},alignTick:!0,animate:!0},tickLine:{style:{lineWidth:e.axisTickLineBorder,stroke:e.axisTickLineBorderColor},alignTick:!0,length:e.axisTickLineLength},subTickLine:null,animate:!0}}function G_t(e){return{title:null,marker:{symbol:"circle",spacing:e.legendMarkerSpacing,style:{r:e.legendCircleMarkerSize,fill:e.legendMarkerColor}},itemName:{spacing:5,style:{fill:e.legendItemNameFillColor,fontFamily:e.fontFamily,fontSize:e.legendItemNameFontSize,lineHeight:e.legendItemNameLineHeight,fontWeight:e.legendItemNameFontWeight,textAlign:"start",textBaseline:"middle"}},itemStates:{active:{nameStyle:{opacity:.8}},unchecked:{nameStyle:{fill:"#D8D8D8"},markerStyle:{fill:"#D8D8D8",stroke:"#D8D8D8"}},inactive:{nameStyle:{fill:"#D8D8D8"},markerStyle:{opacity:.2}}},flipPage:!0,pageNavigator:{marker:{style:{size:e.legendPageNavigatorMarkerSize,inactiveFill:e.legendPageNavigatorMarkerInactiveFillColor,inactiveOpacity:e.legendPageNavigatorMarkerInactiveFillOpacity,fill:e.legendPageNavigatorMarkerFillColor,opacity:e.legendPageNavigatorMarkerFillOpacity}},text:{style:{fill:e.legendPageNavigatorTextFillColor,fontSize:e.legendPageNavigatorTextFontSize}}},animate:!1,maxItemWidth:200,itemSpacing:e.legendItemSpacing,itemMarginBottom:e.legendItemMarginBottom,padding:e.legendPadding}}function lW(e){var r,t={point:{default:{fill:e.pointFillColor,r:e.pointSize,stroke:e.pointBorderColor,lineWidth:e.pointBorder,fillOpacity:e.pointFillOpacity},active:{stroke:e.pointActiveBorderColor,lineWidth:e.pointActiveBorder},selected:{stroke:e.pointSelectedBorderColor,lineWidth:e.pointSelectedBorder},inactive:{fillOpacity:e.pointInactiveFillOpacity,strokeOpacity:e.pointInactiveBorderOpacity}},hollowPoint:{default:{fill:e.hollowPointFillColor,lineWidth:e.hollowPointBorder,stroke:e.hollowPointBorderColor,strokeOpacity:e.hollowPointBorderOpacity,r:e.hollowPointSize},active:{stroke:e.hollowPointActiveBorderColor,strokeOpacity:e.hollowPointActiveBorderOpacity},selected:{lineWidth:e.hollowPointSelectedBorder,stroke:e.hollowPointSelectedBorderColor,strokeOpacity:e.hollowPointSelectedBorderOpacity},inactive:{strokeOpacity:e.hollowPointInactiveBorderOpacity}},area:{default:{fill:e.areaFillColor,fillOpacity:e.areaFillOpacity,stroke:null},active:{fillOpacity:e.areaActiveFillOpacity},selected:{fillOpacity:e.areaSelectedFillOpacity},inactive:{fillOpacity:e.areaInactiveFillOpacity}},hollowArea:{default:{fill:null,stroke:e.hollowAreaBorderColor,lineWidth:e.hollowAreaBorder,strokeOpacity:e.hollowAreaBorderOpacity},active:{fill:null,lineWidth:e.hollowAreaActiveBorder},selected:{fill:null,lineWidth:e.hollowAreaSelectedBorder},inactive:{strokeOpacity:e.hollowAreaInactiveBorderOpacity}},interval:{default:{fill:e.intervalFillColor,fillOpacity:e.intervalFillOpacity},active:{stroke:e.intervalActiveBorderColor,lineWidth:e.intervalActiveBorder},selected:{stroke:e.intervalSelectedBorderColor,lineWidth:e.intervalSelectedBorder},inactive:{fillOpacity:e.intervalInactiveFillOpacity,strokeOpacity:e.intervalInactiveBorderOpacity}},hollowInterval:{default:{fill:e.hollowIntervalFillColor,stroke:e.hollowIntervalBorderColor,lineWidth:e.hollowIntervalBorder,strokeOpacity:e.hollowIntervalBorderOpacity},active:{stroke:e.hollowIntervalActiveBorderColor,lineWidth:e.hollowIntervalActiveBorder,strokeOpacity:e.hollowIntervalActiveBorderOpacity},selected:{stroke:e.hollowIntervalSelectedBorderColor,lineWidth:e.hollowIntervalSelectedBorder,strokeOpacity:e.hollowIntervalSelectedBorderOpacity},inactive:{stroke:e.hollowIntervalInactiveBorderColor,lineWidth:e.hollowIntervalInactiveBorder,strokeOpacity:e.hollowIntervalInactiveBorderOpacity}},line:{default:{stroke:e.lineBorderColor,lineWidth:e.lineBorder,strokeOpacity:e.lineBorderOpacity,fill:null,lineAppendWidth:10,lineCap:"round",lineJoin:"round"},active:{lineWidth:e.lineActiveBorder},selected:{lineWidth:e.lineSelectedBorder},inactive:{strokeOpacity:e.lineInactiveBorderOpacity}}},i=N_t(e),n=G_t(e);return{background:e.backgroundColor,defaultColor:e.brandColor,subColor:e.subColor,semanticRed:e.paletteSemanticRed,semanticGreen:e.paletteSemanticGreen,padding:"auto",fontFamily:e.fontFamily,columnWidthRatio:1/2,maxColumnWidth:null,minColumnWidth:null,roseWidthRatio:.9999999,multiplePieWidthRatio:1/1.3,colors10:e.paletteQualitative10,colors20:e.paletteQualitative20,sequenceColors:e.paletteSequence,shapes:{point:["hollow-circle","hollow-square","hollow-bowtie","hollow-diamond","hollow-hexagon","hollow-triangle","hollow-triangle-down","circle","square","bowtie","diamond","hexagon","triangle","triangle-down","cross","tick","plus","hyphen","line"],line:["line","dash","dot","smooth"],area:["area","smooth","line","smooth-line"],interval:["rect","hollow-rect","line","tick"]},sizes:[1,10],geometries:{interval:{rect:{default:{style:t.interval.default},active:{style:t.interval.active},inactive:{style:t.interval.inactive},selected:{style:function(a){var o=a.geometry.coordinate;if(o.isPolar&&o.isTransposed){var l=rp(a.getModel(),o),s=l.startAngle,u=l.endAngle,c=(s+u)/2,f=7.5,h=f*Math.cos(c),v=f*Math.sin(c);return{matrix:rr(null,[["t",h,v]])}}return t.interval.selected}}},"hollow-rect":{default:{style:t.hollowInterval.default},active:{style:t.hollowInterval.active},inactive:{style:t.hollowInterval.inactive},selected:{style:t.hollowInterval.selected}},line:{default:{style:t.hollowInterval.default},active:{style:t.hollowInterval.active},inactive:{style:t.hollowInterval.inactive},selected:{style:t.hollowInterval.selected}},tick:{default:{style:t.hollowInterval.default},active:{style:t.hollowInterval.active},inactive:{style:t.hollowInterval.inactive},selected:{style:t.hollowInterval.selected}},funnel:{default:{style:t.interval.default},active:{style:t.interval.active},inactive:{style:t.interval.inactive},selected:{style:t.interval.selected}},pyramid:{default:{style:t.interval.default},active:{style:t.interval.active},inactive:{style:t.interval.inactive},selected:{style:t.interval.selected}}},line:{line:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},dot:{default:{style:A(A({},t.line.default),{lineCap:null,lineDash:[1,1]})},active:{style:A(A({},t.line.active),{lineCap:null,lineDash:[1,1]})},inactive:{style:A(A({},t.line.inactive),{lineCap:null,lineDash:[1,1]})},selected:{style:A(A({},t.line.selected),{lineCap:null,lineDash:[1,1]})}},dash:{default:{style:A(A({},t.line.default),{lineCap:null,lineDash:[5.5,1]})},active:{style:A(A({},t.line.active),{lineCap:null,lineDash:[5.5,1]})},inactive:{style:A(A({},t.line.inactive),{lineCap:null,lineDash:[5.5,1]})},selected:{style:A(A({},t.line.selected),{lineCap:null,lineDash:[5.5,1]})}},smooth:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},hv:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},vh:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},hvh:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},vhv:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}}},polygon:{polygon:{default:{style:t.interval.default},active:{style:t.interval.active},inactive:{style:t.interval.inactive},selected:{style:t.interval.selected}}},point:{circle:{default:{style:t.point.default},active:{style:t.point.active},inactive:{style:t.point.inactive},selected:{style:t.point.selected}},square:{default:{style:t.point.default},active:{style:t.point.active},inactive:{style:t.point.inactive},selected:{style:t.point.selected}},bowtie:{default:{style:t.point.default},active:{style:t.point.active},inactive:{style:t.point.inactive},selected:{style:t.point.selected}},diamond:{default:{style:t.point.default},active:{style:t.point.active},inactive:{style:t.point.inactive},selected:{style:t.point.selected}},hexagon:{default:{style:t.point.default},active:{style:t.point.active},inactive:{style:t.point.inactive},selected:{style:t.point.selected}},triangle:{default:{style:t.point.default},active:{style:t.point.active},inactive:{style:t.point.inactive},selected:{style:t.point.selected}},"triangle-down":{default:{style:t.point.default},active:{style:t.point.active},inactive:{style:t.point.inactive},selected:{style:t.point.selected}},"hollow-circle":{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},"hollow-square":{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},"hollow-bowtie":{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},"hollow-diamond":{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},"hollow-hexagon":{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},"hollow-triangle":{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},"hollow-triangle-down":{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},cross:{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},tick:{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},plus:{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},hyphen:{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}},line:{default:{style:t.hollowPoint.default},active:{style:t.hollowPoint.active},inactive:{style:t.hollowPoint.inactive},selected:{style:t.hollowPoint.selected}}},area:{area:{default:{style:t.area.default},active:{style:t.area.active},inactive:{style:t.area.inactive},selected:{style:t.area.selected}},smooth:{default:{style:t.area.default},active:{style:t.area.active},inactive:{style:t.area.inactive},selected:{style:t.area.selected}},line:{default:{style:t.hollowArea.default},active:{style:t.hollowArea.active},inactive:{style:t.hollowArea.inactive},selected:{style:t.hollowArea.selected}},"smooth-line":{default:{style:t.hollowArea.default},active:{style:t.hollowArea.active},inactive:{style:t.hollowArea.inactive},selected:{style:t.hollowArea.selected}}},schema:{candle:{default:{style:t.hollowInterval.default},active:{style:t.hollowInterval.active},inactive:{style:t.hollowInterval.inactive},selected:{style:t.hollowInterval.selected}},box:{default:{style:t.hollowInterval.default},active:{style:t.hollowInterval.active},inactive:{style:t.hollowInterval.inactive},selected:{style:t.hollowInterval.selected}}},edge:{line:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},vhv:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},smooth:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},arc:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}}},violin:{violin:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},smooth:{default:{style:t.line.default},active:{style:t.line.active},inactive:{style:t.line.inactive},selected:{style:t.line.selected}},hollow:{default:{style:t.hollowArea.default},active:{style:t.hollowArea.active},inactive:{style:t.hollowArea.inactive},selected:{style:t.hollowArea.selected}},"hollow-smooth":{default:{style:t.hollowArea.default},active:{style:t.hollowArea.active},inactive:{style:t.hollowArea.inactive},selected:{style:t.hollowArea.selected}}}},components:{axis:{common:i,top:{position:"top",grid:null,title:null,verticalLimitLength:1/2},bottom:{position:"bottom",grid:null,title:null,verticalLimitLength:1/2},left:{position:"left",title:null,line:null,tickLine:null,verticalLimitLength:1/3},right:{position:"right",title:null,line:null,tickLine:null,verticalLimitLength:1/3},circle:{title:null,grid:ft({},i.grid,{line:{type:"line"}})},radius:{title:null,grid:ft({},i.grid,{line:{type:"circle"}})}},legend:{common:n,right:{layout:"vertical",padding:e.legendVerticalPadding},left:{layout:"vertical",padding:e.legendVerticalPadding},top:{layout:"horizontal",padding:e.legendHorizontalPadding},bottom:{layout:"horizontal",padding:e.legendHorizontalPadding},continuous:{title:null,background:null,track:{},rail:{type:"color",size:e.sliderRailHeight,defaultLength:e.sliderRailWidth,style:{fill:e.sliderRailFillColor,stroke:e.sliderRailBorderColor,lineWidth:e.sliderRailBorder}},label:{align:"rail",spacing:4,formatter:null,style:{fill:e.sliderLabelTextFillColor,fontSize:e.sliderLabelTextFontSize,lineHeight:e.sliderLabelTextLineHeight,textBaseline:"middle",fontFamily:e.fontFamily}},handler:{size:e.sliderHandlerWidth,style:{fill:e.sliderHandlerFillColor,stroke:e.sliderHandlerBorderColor}},slidable:!0,padding:n.padding}},tooltip:{showContent:!0,follow:!0,showCrosshairs:!1,showMarkers:!0,shared:!1,enterable:!1,position:"auto",marker:{symbol:"circle",stroke:"#fff",shadowBlur:10,shadowOffsetX:0,shadowOffsetY:0,shadowColor:"rgba(0,0,0,0.09)",lineWidth:2,r:4},crosshairs:{line:{style:{stroke:e.tooltipCrosshairsBorderColor,lineWidth:e.tooltipCrosshairsBorder}},text:null,textBackground:{padding:2,style:{fill:"rgba(0, 0, 0, 0.25)",lineWidth:0,stroke:null}},follow:!1},domStyles:(r={},r[""+Nf]={position:"absolute",visibility:"hidden",zIndex:8,transition:"left 0.4s cubic-bezier(0.23, 1, 0.32, 1) 0s, top 0.4s cubic-bezier(0.23, 1, 0.32, 1) 0s",backgroundColor:e.tooltipContainerFillColor,opacity:e.tooltipContainerFillOpacity,boxShadow:e.tooltipContainerShadow,borderRadius:e.tooltipContainerBorderRadius+"px",color:e.tooltipTextFillColor,fontSize:e.tooltipTextFontSize+"px",fontFamily:e.fontFamily,lineHeight:e.tooltipTextLineHeight+"px",padding:"0 12px 0 12px"},r[""+Gf]={marginBottom:"12px",marginTop:"12px"},r[""+Yd]={margin:0,listStyleType:"none",padding:0},r[""+x1]={listStyleType:"none",padding:0,marginBottom:"12px",marginTop:"12px",marginLeft:0,marginRight:0},r[""+_1]={width:"8px",height:"8px",borderRadius:"50%",display:"inline-block",marginRight:"8px"},r[""+b1]={display:"inline-block",float:"right",marginLeft:"30px"},r)},annotation:{arc:{style:{stroke:e.annotationArcBorderColor,lineWidth:e.annotationArcBorder},animate:!0},line:{style:{stroke:e.annotationLineBorderColor,lineDash:e.annotationLineDash,lineWidth:e.annotationLineBorder},text:{position:"start",autoRotate:!0,style:{fill:e.annotationTextFillColor,stroke:e.annotationTextBorderColor,lineWidth:e.annotationTextBorder,fontSize:e.annotationTextFontSize,textAlign:"start",fontFamily:e.fontFamily,textBaseline:"bottom"}},animate:!0},text:{style:{fill:e.annotationTextFillColor,stroke:e.annotationTextBorderColor,lineWidth:e.annotationTextBorder,fontSize:e.annotationTextFontSize,textBaseline:"middle",textAlign:"start",fontFamily:e.fontFamily},animate:!0},region:{top:!1,style:{lineWidth:e.annotationRegionBorder,stroke:e.annotationRegionBorderColor,fill:e.annotationRegionFillColor,fillOpacity:e.annotationRegionFillOpacity},animate:!0},image:{top:!1,animate:!0},dataMarker:{top:!0,point:{style:{r:3,stroke:e.brandColor,lineWidth:2}},line:{style:{stroke:e.annotationLineBorderColor,lineWidth:e.annotationLineBorder},length:e.annotationDataMarkerLineLength},text:{style:{textAlign:"start",fill:e.annotationTextFillColor,stroke:e.annotationTextBorderColor,lineWidth:e.annotationTextBorder,fontSize:e.annotationTextFontSize,fontFamily:e.fontFamily}},direction:"upward",autoAdjust:!0,animate:!0},dataRegion:{style:{region:{fill:e.annotationRegionFillColor,fillOpacity:e.annotationRegionFillOpacity},text:{textAlign:"center",textBaseline:"bottom",fill:e.annotationTextFillColor,stroke:e.annotationTextBorderColor,lineWidth:e.annotationTextBorder,fontSize:e.annotationTextFontSize,fontFamily:e.fontFamily}},animate:!0}},slider:{common:{padding:[8,8,8,8],backgroundStyle:{fill:e.cSliderBackgroundFillColor,opacity:e.cSliderBackgroundFillOpacity},foregroundStyle:{fill:e.cSliderForegroundFillColor,opacity:e.cSliderForegroundFillOpacity},handlerStyle:{width:e.cSliderHandlerWidth,height:e.cSliderHandlerHeight,fill:e.cSliderHandlerFillColor,opacity:e.cSliderHandlerFillOpacity,stroke:e.cSliderHandlerBorderColor,lineWidth:e.cSliderHandlerBorder,radius:e.cSliderHandlerBorderRadius,highLightFill:e.cSliderHandlerHighlightFillColor},textStyle:{fill:e.cSliderTextFillColor,opacity:e.cSliderTextFillOpacity,fontSize:e.cSliderTextFontSize,lineHeight:e.cSliderTextLineHeight,fontWeight:e.cSliderTextFontWeight,stroke:e.cSliderTextBorderColor,lineWidth:e.cSliderTextBorder}}},scrollbar:{common:{padding:[8,8,8,8]},default:{style:{trackColor:e.scrollbarTrackFillColor,thumbColor:e.scrollbarThumbFillColor}},hover:{style:{thumbColor:e.scrollbarThumbHighlightFillColor}}}},labels:{offset:12,style:{fill:e.labelFillColor,fontSize:e.labelFontSize,fontFamily:e.fontFamily,stroke:e.labelBorderColor,lineWidth:e.labelBorder},fillColorDark:e.labelFillColorDark,fillColorLight:e.labelFillColorLight,autoRotate:!0},innerLabels:{style:{fill:e.innerLabelFillColor,fontSize:e.innerLabelFontSize,fontFamily:e.fontFamily,stroke:e.innerLabelBorderColor,lineWidth:e.innerLabelBorder},autoRotate:!0},overflowLabels:{style:{fill:e.overflowLabelFillColor,fontSize:e.overflowLabelFontSize,fontFamily:e.fontFamily,stroke:e.overflowLabelBorderColor,lineWidth:e.overflowLabelBorder}},pieLabels:{labelHeight:14,offset:10,labelLine:{style:{lineWidth:e.labelLineBorder}},autoRotate:!0}}}var le={100:"#000",95:"#0D0D0D",85:"#262626",65:"#595959",45:"#8C8C8C",25:"#BFBFBF",15:"#D9D9D9",6:"#F0F0F0"},Fv={100:"#FFFFFF",95:"#F2F2F2",85:"#D9D9D9",65:"#A6A6A6",45:"#737373",25:"#404040",15:"#262626",6:"#0F0F0F"},z_t=["#5B8FF9","#5AD8A6","#5D7092","#F6BD16","#6F5EF9","#6DC8EC","#945FB9","#FF9845","#1E9493","#FF99C3"],V_t=["#5B8FF9","#CDDDFD","#5AD8A6","#CDF3E4","#5D7092","#CED4DE","#F6BD16","#FCEBB9","#6F5EF9","#D3CEFD","#6DC8EC","#D3EEF9","#945FB9","#DECFEA","#FF9845","#FFE0C7","#1E9493","#BBDEDE","#FF99C3","#FFE0ED"],j_t=["#B8E1FF","#9AC5FF","#7DAAFF","#5B8FF9","#3D76DD","#085EC0","#0047A5","#00318A","#001D70"],sW=function(e){e===void 0&&(e={});var r=e.backgroundColor,t=r===void 0?"transparent":r,i=e.subColor,n=i===void 0?"rgba(0,0,0,0.05)":i,a=e.paletteQualitative10,o=a===void 0?z_t:a,l=e.paletteQualitative20,s=l===void 0?V_t:l,u=e.paletteSemanticRed,c=u===void 0?"#F4664A":u,f=e.paletteSemanticGreen,h=f===void 0?"#30BF78":f,v=e.paletteSemanticYellow,d=v===void 0?"#FAAD14":v,p=e.paletteSequence,x=p===void 0?j_t:p,m=e.fontFamily,_=m===void 0?`"Segoe UI", Roboto, "Helvetica Neue", Arial,
|
|
"Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol",
|
|
"Noto Color Emoji"`:m,b=e.brandColor,w=b===void 0?o[0]:b;return{backgroundColor:t,brandColor:w,subColor:n,paletteQualitative10:o,paletteQualitative20:s,paletteSemanticRed:c,paletteSemanticGreen:h,paletteSemanticYellow:d,paletteSequence:x,fontFamily:_,axisLineBorderColor:le[25],axisLineBorder:1,axisLineDash:null,axisTitleTextFillColor:le[65],axisTitleTextFontSize:12,axisTitleTextLineHeight:12,axisTitleTextFontWeight:"normal",axisTitleSpacing:12,axisTickLineBorderColor:le[25],axisTickLineLength:4,axisTickLineBorder:1,axisSubTickLineBorderColor:le[15],axisSubTickLineLength:2,axisSubTickLineBorder:1,axisLabelFillColor:le[45],axisLabelFontSize:12,axisLabelLineHeight:12,axisLabelFontWeight:"normal",axisLabelOffset:8,axisGridBorderColor:le[15],axisGridBorder:1,axisGridLineDash:null,legendTitleTextFillColor:le[45],legendTitleTextFontSize:12,legendTitleTextLineHeight:21,legendTitleTextFontWeight:"normal",legendMarkerColor:w,legendMarkerSpacing:8,legendMarkerSize:4,legendCircleMarkerSize:4,legendSquareMarkerSize:4,legendLineMarkerSize:5,legendItemNameFillColor:le[65],legendItemNameFontSize:12,legendItemNameLineHeight:12,legendItemNameFontWeight:"normal",legendItemSpacing:24,legendItemMarginBottom:12,legendPadding:[8,8,8,8],legendHorizontalPadding:[8,0,8,0],legendVerticalPadding:[0,8,0,8],legendPageNavigatorMarkerSize:12,legendPageNavigatorMarkerInactiveFillColor:le[100],legendPageNavigatorMarkerInactiveFillOpacity:.45,legendPageNavigatorMarkerFillColor:le[100],legendPageNavigatorMarkerFillOpacity:1,legendPageNavigatorTextFillColor:le[45],legendPageNavigatorTextFontSize:12,sliderRailFillColor:le[15],sliderRailBorder:0,sliderRailBorderColor:null,sliderRailWidth:100,sliderRailHeight:12,sliderLabelTextFillColor:le[45],sliderLabelTextFontSize:12,sliderLabelTextLineHeight:12,sliderLabelTextFontWeight:"normal",sliderHandlerFillColor:le[6],sliderHandlerWidth:10,sliderHandlerHeight:14,sliderHandlerBorder:1,sliderHandlerBorderColor:le[25],annotationArcBorderColor:le[15],annotationArcBorder:1,annotationLineBorderColor:le[25],annotationLineBorder:1,annotationLineDash:null,annotationTextFillColor:le[65],annotationTextFontSize:12,annotationTextLineHeight:12,annotationTextFontWeight:"normal",annotationTextBorderColor:null,annotationTextBorder:0,annotationRegionFillColor:le[100],annotationRegionFillOpacity:.06,annotationRegionBorder:0,annotationRegionBorderColor:null,annotationDataMarkerLineLength:16,tooltipCrosshairsBorderColor:le[25],tooltipCrosshairsBorder:1,tooltipCrosshairsLineDash:null,tooltipContainerFillColor:"rgb(255, 255, 255)",tooltipContainerFillOpacity:.95,tooltipContainerShadow:"0px 0px 10px #aeaeae",tooltipContainerBorderRadius:3,tooltipTextFillColor:le[65],tooltipTextFontSize:12,tooltipTextLineHeight:12,tooltipTextFontWeight:"bold",labelFillColor:le[65],labelFillColorDark:"#2c3542",labelFillColorLight:"#ffffff",labelFontSize:12,labelLineHeight:12,labelFontWeight:"normal",labelBorderColor:null,labelBorder:0,innerLabelFillColor:Fv[100],innerLabelFontSize:12,innerLabelLineHeight:12,innerLabelFontWeight:"normal",innerLabelBorderColor:null,innerLabelBorder:0,overflowLabelFillColor:le[65],overflowLabelFontSize:12,overflowLabelLineHeight:12,overflowLabelFontWeight:"normal",overflowLabelBorderColor:Fv[100],overflowLabelBorder:1,labelLineBorder:1,labelLineBorderColor:le[25],cSliderRailHieght:16,cSliderBackgroundFillColor:"#416180",cSliderBackgroundFillOpacity:.05,cSliderForegroundFillColor:"#5B8FF9",cSliderForegroundFillOpacity:.15,cSliderHandlerHeight:24,cSliderHandlerWidth:10,cSliderHandlerFillColor:"#F7F7F7",cSliderHandlerFillOpacity:1,cSliderHandlerHighlightFillColor:"#FFF",cSliderHandlerBorderColor:"#BFBFBF",cSliderHandlerBorder:1,cSliderHandlerBorderRadius:2,cSliderTextFillColor:"#000",cSliderTextFillOpacity:.45,cSliderTextFontSize:12,cSliderTextLineHeight:12,cSliderTextFontWeight:"normal",cSliderTextBorderColor:null,cSliderTextBorder:0,scrollbarTrackFillColor:"rgba(0,0,0,0)",scrollbarThumbFillColor:"rgba(0,0,0,0.15)",scrollbarThumbHighlightFillColor:"rgba(0,0,0,0.2)",pointFillColor:w,pointFillOpacity:.95,pointSize:4,pointBorder:1,pointBorderColor:Fv[100],pointBorderOpacity:1,pointActiveBorderColor:le[100],pointSelectedBorder:2,pointSelectedBorderColor:le[100],pointInactiveFillOpacity:.3,pointInactiveBorderOpacity:.3,hollowPointSize:4,hollowPointBorder:1,hollowPointBorderColor:w,hollowPointBorderOpacity:.95,hollowPointFillColor:Fv[100],hollowPointActiveBorder:1,hollowPointActiveBorderColor:le[100],hollowPointActiveBorderOpacity:1,hollowPointSelectedBorder:2,hollowPointSelectedBorderColor:le[100],hollowPointSelectedBorderOpacity:1,hollowPointInactiveBorderOpacity:.3,lineBorder:2,lineBorderColor:w,lineBorderOpacity:1,lineActiveBorder:3,lineSelectedBorder:3,lineInactiveBorderOpacity:.3,areaFillColor:w,areaFillOpacity:.25,areaActiveFillColor:w,areaActiveFillOpacity:.5,areaSelectedFillColor:w,areaSelectedFillOpacity:.5,areaInactiveFillOpacity:.3,hollowAreaBorderColor:w,hollowAreaBorder:2,hollowAreaBorderOpacity:1,hollowAreaActiveBorder:3,hollowAreaActiveBorderColor:le[100],hollowAreaSelectedBorder:3,hollowAreaSelectedBorderColor:le[100],hollowAreaInactiveBorderOpacity:.3,intervalFillColor:w,intervalFillOpacity:.95,intervalActiveBorder:1,intervalActiveBorderColor:le[100],intervalActiveBorderOpacity:1,intervalSelectedBorder:2,intervalSelectedBorderColor:le[100],intervalSelectedBorderOpacity:1,intervalInactiveBorderOpacity:.3,intervalInactiveFillOpacity:.3,hollowIntervalBorder:2,hollowIntervalBorderColor:w,hollowIntervalBorderOpacity:1,hollowIntervalFillColor:Fv[100],hollowIntervalActiveBorder:2,hollowIntervalActiveBorderColor:le[100],hollowIntervalSelectedBorder:3,hollowIntervalSelectedBorderColor:le[100],hollowIntervalSelectedBorderOpacity:1,hollowIntervalInactiveBorderOpacity:.3}};sW();function wx(e){var r=e.styleSheet,t=r===void 0?{}:r,i=ue(e,["styleSheet"]),n=sW(t);return ft({},lW(n),i)}var H_t=wx({}),ST={default:H_t};function rs(e){return I(ST,sc(e),ST.default)}function uW(e,r){ST[sc(e)]=wx(r)}function hB(e,r,t){var i=t.translate(e),n=t.translate(r);return zr(i,n)}function Y_t(e,r){var t=r.coordinate,i=r.getXScale(),n=i.range,a=n[n.length-1],o=n[0],l=t.invert(e),s=l.x;return t.isPolar&&s>(1+a)/2&&(s=o),i.translate(i.invert(s))}function vB(e,r,t){var i=t.coordinate,n=t.getYScale(),a=n.field,o=i.invert(r),l=n.invert(o.y),s=Yn(e,function(u){var c=u[de];return c[a][0]<=l&&c[a][1]>=l});return s||e[e.length-1]}var W_t=uc(function(e){if(e.isCategory)return 1;for(var r=e.values,t=r.length,i=e.translate(r[0]),n=i,a=0;a<t;a++){var o=r[a],l=e.translate(o);l<i&&(i=l),l>n&&(n=l)}return(n-i)/(t-1)});function X_t(e,r,t){var i=r.getAttribute("position"),n=i.getFields(),a=r.scales,o=pt(t)||!t?n[0]:t,l=a[o],s=l?l.getText(e[o]):e[o]||o;return pt(t)?t(s,e):s}function U_t(e){var r=_h(e.attributes);return jr(r,function(t){return eo(Qv,t.type)})}function cW(e){for(var r=U_t(e),t,i=0,n=r;i<n.length;i++){var a=n[i],o=a.getScale(a.type);if(o&&o.isLinear){t=o;break}}var l=e.getXScale(),s=e.getYScale();return t||s||l}function q_t(e,r){var t=r.field,i=e[t];if(it(i)){var n=i.map(function(a){return r.getText(a)});return n.join("-")}return r.getText(i)}function Z_t(e,r){var t,i=r.getGroupScales();if(i.length&&(t=i[0]),t){var n=t.field;return t.getText(e[n])}var a=cW(r);return ip(a)}function fW(e,r,t){if(r.length===0)return null;var i=t.type,n=t.getXScale(),a=t.getYScale(),o=n.field,l=a.field,s=null;if(i==="heatmap"||i==="point"){for(var u=t.coordinate,c=u.invert(e),f=n.invert(c.x),h=a.invert(c.y),v=1/0,d=0;d<r.length;d++){var p=r[d],x=p[de],m=Math.pow(x[o]-f,2)+Math.pow(x[l]-h,2);m<v&&(v=m,s=p)}return s}var _=r[0],b=r[r.length-1],w=Y_t(e,t),S=_[de][o],M=_[de][l],F=b[de][o],O=a.isLinear&&it(M);if(it(S)){for(var d=0;d<r.length;d++){var L=r[d],x=L[de];if(n.translate(x[o][0])<=w&&n.translate(x[o][1])>=w)if(O)it(s)||(s=[]),s.push(L);else{s=L;break}}it(s)&&(s=vB(s,e,t))}else{var D=void 0;if(!n.isLinear&&n.type!=="timeCat"){for(var d=0;d<r.length;d++){var L=r[d],x=L[de];if(hB(x[o],w,n))if(O)it(s)||(s=[]),s.push(L);else{s=L;break}else n.translate(x[o])<=w&&(b=L,D=r[d+1])}it(s)&&(s=vB(s,e,t))}else{if((w>n.translate(F)||w<n.translate(S))&&(w>n.max||w<n.min))return null;for(var k=0,H=r.length-1,B=void 0;k<=H;){B=Math.floor((k+H)/2);var j=r[B][de][o];if(hB(j,w,n))return r[B];n.translate(j)<=n.translate(w)?(k=B+1,b=r[B],D=r[B+1]):(H===0&&(b=r[0]),H=B-1)}}b&&D&&Math.abs(n.translate(b[de][o])-w)>Math.abs(n.translate(D[de][o])-w)&&(b=D)}var U=W_t(t.getXScale());return!s&&Math.abs(n.translate(b[de][o])-w)<=U/2&&(s=b),s}function MO(e,r,t,i){t===void 0&&(t=""),i===void 0&&(i=!1);var n=e[de],a=X_t(n,r,t),o=r.tooltipOption,l=r.theme.defaultColor,s=[],u,c;function f(F,O){if(i||!K(O)&&O!==""){var L={title:a,data:n,mappingData:e,name:F,value:O,color:e.color||l,marker:!0};s.push(L)}}if(Zt(o)){var h=o.fields,v=o.callback;if(v){var d=h.map(function(F){return e[de][F]}),p=v.apply(void 0,d),x=A({data:e[de],mappingData:e,title:a,color:e.color||l,marker:!0},p);s.push(x)}else for(var m=r.scales,_=0,b=h;_<b.length;_++){var w=b[_];if(!K(n[w])){var S=m[w];u=ip(S),c=S.getText(n[w]),f(u,c)}}}else{var M=cW(r);c=q_t(n,M),u=Z_t(n,r),f(u,c)}return s}function dB(e,r,t,i){var n=i.showNil,a=[],o=e.dataArray;if(!gi(o)){e.sort(o);for(var l=0,s=o;l<s.length;l++){var u=s[l],c=fW(r,u,e);if(c){var f=e.getElementId(c),h=e.elementsMap[f];if(e.type==="heatmap"||h.visible){var v=MO(c,e,t,n);v.length&&a.push(v)}}}}return a}function pB(e,r,t,i){var n=i.showNil,a=[],o=e.container,l=o.getShape(r.x,r.y);if(l&&l.get("visible")&&l.get("origin")){var s=l.get("origin").mappingData,u=MO(s,e,t,n);u.length&&a.push(u)}return a}function AT(e,r,t){for(var i=[],n=e.geometries,a=t.shared,o=t.title,l=t.reversed,s=0,u=n;s<u.length;s++){var c=u[s];if(c.visible&&c.tooltipOption!==!1){var f=c.type,h=void 0;["point","edge","polygon"].includes(f)?h=pB(c,r,o,t):["area","line","path","heatmap"].includes(f)||a!==!1?h=dB(c,r,o,t):h=pB(c,r,o,t),h.length&&(l&&h.reverse(),i.push(h))}}return i}function Q_t(e,r,t){for(var i=AT(e,r,t),n=0,a=e.views;n<a.length;n++){var o=a[n];i=i.concat(AT(o,r,t))}return i}function K_t(e){return!Mt(e)&&!it(e)}function EO(e){e===void 0&&(e=0);var r=it(e)?e:[e];switch(r.length){case 0:r=[0,0,0,0];break;case 1:r=new Array(4).fill(r[0]);break;case 2:r=Qr(Qr([],r,!0),r,!0);break;case 3:r=Qr(Qr([],r,!0),[r[1]],!1);break;default:r=r.slice(0,4);break}return r}var FO={};function Ds(e,r){FO[e]=r}function J_t(){return Object.keys(FO)}function tbt(e){return FO[e]}var ebt=function(){function e(r){this.option=this.wrapperOption(r)}return e.prototype.update=function(r){return this.option=this.wrapperOption(r),this},e.prototype.hasAction=function(r){var t=this.option.actions;return gp(t,function(i){return i[0]===r})},e.prototype.create=function(r,t){var i=this.option,n=i.type,a=i.cfg,o=n==="theta",l=A({start:r,end:t},a),s=w5(o?"polar":n);return this.coordinate=new s(l),this.coordinate.type=n,o&&(this.hasAction("transpose")||this.transpose()),this.execActions(),this.coordinate},e.prototype.adjust=function(r,t){return this.coordinate.update({start:r,end:t}),this.coordinate.resetMatrix(),this.execActions(["scale","rotate","translate"]),this.coordinate},e.prototype.rotate=function(r){return this.option.actions.push(["rotate",r]),this},e.prototype.reflect=function(r){return this.option.actions.push(["reflect",r]),this},e.prototype.scale=function(r,t){return this.option.actions.push(["scale",r,t]),this},e.prototype.transpose=function(){return this.option.actions.push(["transpose"]),this},e.prototype.getOption=function(){return this.option},e.prototype.getCoordinate=function(){return this.coordinate},e.prototype.wrapperOption=function(r){return A({type:"rect",actions:[],cfg:{}},r)},e.prototype.execActions=function(r){var t=this,i=this.option.actions;P(i,function(n){var a,o=n[0],l=n.slice(1),s=K(r)?!0:r.includes(o);s&&(a=t.coordinate)[o].apply(a,l)})},e}(),$e=function(){function e(r,t,i){this.view=r,this.gEvent=t,this.data=i,this.type=t.type}return e.fromData=function(r,t,i){return new e(r,new bh(t,{}),i)},Object.defineProperty(e.prototype,"target",{get:function(){return this.gEvent.target},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"event",{get:function(){return this.gEvent.originalEvent},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"x",{get:function(){return this.gEvent.x},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"y",{get:function(){return this.gEvent.y},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"clientX",{get:function(){return this.gEvent.clientX},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"clientY",{get:function(){return this.gEvent.clientY},enumerable:!1,configurable:!0}),e.prototype.toString=function(){return"[Event (type="+this.type+")]"},e.prototype.clone=function(){return new e(this.view,this.gEvent,this.data)},e}();function rbt(e){var r=e.getController("axis"),t=e.getController("legend"),i=e.getController("annotation"),n=e.getController("slider"),a=e.getController("scrollbar");[r,n,a,t,i].forEach(function(o){o&&o.layout()})}var ibt=function(){function e(){this.scales=new Map,this.syncScales=new Map}return e.prototype.createScale=function(r,t,i,n){var a=i,o=this.getScaleMeta(n);if(t.length===0&&o){var l=o.scale,s={type:l.type};l.isCategory&&(s.values=l.values),a=ft(s,o.scaleDef,i)}var u=g_t(r,t,a);return this.cacheScale(u,i,n),u},e.prototype.sync=function(r,t){var i=this;this.syncScales.forEach(function(n,a){var o=Number.MAX_SAFE_INTEGER,l=Number.MIN_SAFE_INTEGER,s=[];P(n,function(u){var c=i.getScale(u);l=Mt(c.max)?Math.max(l,c.max):l,o=Mt(c.min)?Math.min(o,c.min):o,P(c.values,function(f){s.includes(f)||s.push(f)})}),P(n,function(u){var c=i.getScale(u);if(c.isContinuous)c.change({min:o,max:l,values:s});else if(c.isCategory){var f=c.range,h=i.getScaleMeta(u);s&&!I(h,["scaleDef","range"])&&(f=YY(ft({},c,{values:s}),r,t)),c.change({values:s,range:f})}})})},e.prototype.cacheScale=function(r,t,i){var n=this.getScaleMeta(i);n&&n.scale.type===r.type?(y_t(n.scale,r),n.scaleDef=t):(n={key:i,scale:r,scaleDef:t},this.scales.set(i,n));var a=this.getSyncKey(n);if(n.syncKey=a,this.removeFromSyncScales(i),a){var o=this.syncScales.get(a);o||(o=[],this.syncScales.set(a,o)),o.push(i)}},e.prototype.getScale=function(r){var t=this.getScaleMeta(r);if(!t){var i=nr(r.split("-")),n=this.syncScales.get(i);n&&n.length&&(t=this.getScaleMeta(n[0]))}return t&&t.scale},e.prototype.deleteScale=function(r){var t=this.getScaleMeta(r);if(t){var i=t.syncKey,n=this.syncScales.get(i);if(n&&n.length){var a=n.indexOf(r);a!==-1&&n.splice(a,1)}}this.scales.delete(r)},e.prototype.clear=function(){this.scales.clear(),this.syncScales.clear()},e.prototype.removeFromSyncScales=function(r){var t=this;this.syncScales.forEach(function(i,n){var a=i.indexOf(r);if(a!==-1)return i.splice(a,1),i.length===0&&t.syncScales.delete(n),!1})},e.prototype.getSyncKey=function(r){var t=r.scale,i=r.scaleDef,n=t.field,a=I(i,["sync"]);return a===!0?n:a===!1?void 0:a},e.prototype.getScaleMeta=function(r){return this.scales.get(r)},e}(),E0=function(){function e(r,t,i,n){r===void 0&&(r=0),t===void 0&&(t=0),i===void 0&&(i=0),n===void 0&&(n=0),this.top=r,this.right=t,this.bottom=i,this.left=n}return e.instance=function(r,t,i,n){return r===void 0&&(r=0),t===void 0&&(t=0),i===void 0&&(i=0),n===void 0&&(n=0),new e(r,t,i,n)},e.prototype.max=function(r){var t=r[0],i=r[1],n=r[2],a=r[3];return this.top=Math.max(this.top,t),this.right=Math.max(this.right,i),this.bottom=Math.max(this.bottom,n),this.left=Math.max(this.left,a),this},e.prototype.shrink=function(r){var t=r[0],i=r[1],n=r[2],a=r[3];return this.top+=t,this.right+=i,this.bottom+=n,this.left+=a,this},e.prototype.inc=function(r,t){var i=r.width,n=r.height;switch(t){case ct.TOP:case ct.TOP_LEFT:case ct.TOP_RIGHT:this.top+=n;break;case ct.RIGHT:case ct.RIGHT_TOP:case ct.RIGHT_BOTTOM:this.right+=i;break;case ct.BOTTOM:case ct.BOTTOM_LEFT:case ct.BOTTOM_RIGHT:this.bottom+=n;break;case ct.LEFT:case ct.LEFT_TOP:case ct.LEFT_BOTTOM:this.left+=i;break}return this},e.prototype.getPadding=function(){return[this.top,this.right,this.bottom,this.left]},e.prototype.clone=function(){return new(e.bind.apply(e,Qr([void 0],this.getPadding(),!1)))},e}();function nbt(e){var r=e.padding;if(!K_t(r))return new(E0.bind.apply(E0,Qr([void 0],EO(r),!1)));var t=e.viewBBox,i=new E0,n=[],a=[],o=[];return P(e.getComponents(),function(l){var s=l.type;s===Mr.AXIS?n.push(l):[Mr.LEGEND,Mr.SLIDER,Mr.SCROLLBAR].includes(s)?a.push(l):s!==Mr.GRID&&s!==Mr.TOOLTIP&&o.push(l)}),P(n,function(l){var s=l.component,u=s.getLayoutBBox(),c=new Ei(u.x,u.y,u.width,u.height),f=c.exceed(t);i.max(f)}),P(a,function(l){var s=l.component,u=l.direction,c=s.getLayoutBBox(),f=s.get("padding"),h=new Ei(c.x,c.y,c.width,c.height).expand(f);i.inc(h,u)}),P(o,function(l){var s=l.component,u=l.direction,c=s.getLayoutBBox(),f=new Ei(c.x,c.y,c.width,c.height);i.inc(f,u)}),i}function abt(e,r,t){var i=t.instance();r.forEach(function(n){n.autoPadding=i.max(n.autoPadding.getPadding())})}var OO=function(e){X(r,e);function r(t){var i=e.call(this,{visible:t.visible})||this;i.views=[],i.geometries=[],i.controllers=[],i.interactions={},i.limitInPlot=!1,i.options={data:[],animate:!0},i.usedControllers=J_t(),i.scalePool=new ibt,i.layoutFunc=rbt,i.isPreMouseInPlot=!1,i.isDataChanged=!1,i.isCoordinateChanged=!1,i.createdScaleKeys=new Map,i.onCanvasEvent=function(b){var w=b.name;if(!w.includes(":")){var S=i.createViewEvent(b);i.doPlotEvent(S),i.emit(w,S)}},i.onDelegateEvents=function(b){var w=b.name;if(!!w.includes(":")){var S=i.createViewEvent(b);i.emit(w,S)}};var n=t.id,a=n===void 0?Oa("view"):n,o=t.parent,l=t.canvas,s=t.backgroundGroup,u=t.middleGroup,c=t.foregroundGroup,f=t.region,h=f===void 0?{start:{x:0,y:0},end:{x:1,y:1}}:f,v=t.padding,d=t.appendPadding,p=t.theme,x=t.options,m=t.limitInPlot,_=t.syncViewPadding;return i.parent=o,i.canvas=l,i.backgroundGroup=s,i.middleGroup=u,i.foregroundGroup=c,i.region=h,i.padding=v,i.appendPadding=d,i.options=A(A({},i.options),x),i.limitInPlot=m,i.id=a,i.syncViewPadding=_,i.themeObject=Zt(p)?ft({},rs("default"),wx(p)):rs(p),i.init(),i}return r.prototype.setLayout=function(t){this.layoutFunc=t},r.prototype.init=function(){this.calculateViewBBox(),this.initEvents(),this.initComponentController(),this.initOptions()},r.prototype.render=function(t,i){t===void 0&&(t=!1),this.emit(Gt.BEFORE_RENDER,$e.fromData(this,Gt.BEFORE_RENDER,i)),this.paint(t),this.emit(Gt.AFTER_RENDER,$e.fromData(this,Gt.AFTER_RENDER,i)),this.visible===!1&&this.changeVisible(!1)},r.prototype.clear=function(){var t=this;this.emit(Gt.BEFORE_CLEAR),this.filteredData=[],this.coordinateInstance=void 0,this.isDataChanged=!1,this.isCoordinateChanged=!1;for(var i=this.geometries,n=0;n<i.length;n++)i[n].clear(),i[n].container.remove(!0),i[n].labelsContainer.remove(!0);this.geometries=[];for(var a=this.controllers,n=0;n<a.length;n++)a[n].name==="annotation"?a[n].clear(!0):a[n].clear();this.createdScaleKeys.forEach(function(l,s){t.getRootView().scalePool.deleteScale(s)}),this.createdScaleKeys.clear();for(var o=this.views,n=0;n<o.length;n++)o[n].clear();this.emit(Gt.AFTER_CLEAR)},r.prototype.destroy=function(){this.emit(Gt.BEFORE_DESTROY);var t=this.interactions;P(t,function(l){l&&l.destroy()}),this.clear();for(var i=this.controllers,n=0,a=i.length;n<a;n++){var o=i[n];o.destroy()}this.backgroundGroup.remove(!0),this.middleGroup.remove(!0),this.foregroundGroup.remove(!0),e.prototype.destroy.call(this)},r.prototype.changeVisible=function(t){e.prototype.changeVisible.call(this,t);for(var i=this.geometries,n=0,a=i.length;n<a;n++){var o=i[n];o.changeVisible(t)}for(var l=this.controllers,n=0,a=l.length;n<a;n++){var s=l[n];s.changeVisible(t)}return this.foregroundGroup.set("visible",t),this.middleGroup.set("visible",t),this.backgroundGroup.set("visible",t),this.getCanvas().draw(),this},r.prototype.data=function(t){return jt(this.options,"data",t),this.isDataChanged=!0,this},r.prototype.source=function(t){return console.warn("This method will be removed at G2 V4.1. Please use chart.data() instead."),this.data(t)},r.prototype.filter=function(t,i){return pt(i)?(jt(this.options,["filters",t],i),this):(!i&&I(this.options,["filters",t])&&delete this.options.filters[t],this)},r.prototype.axis=function(t,i){return Yu(t)?jt(this.options,["axes"],t):jt(this.options,["axes",t],i),this},r.prototype.legend=function(t,i){return Yu(t)?jt(this.options,["legends"],t):Ct(t)?(jt(this.options,["legends",t],i),wa(i)&&(i==null?void 0:i.selected)&&jt(this.options,["filters",t],function(n){var a;return(a=i==null?void 0:i.selected[n])!==null&&a!==void 0?a:!0})):jt(this.options,["legends"],t),this},r.prototype.scale=function(t,i){var n=this;return Ct(t)?jt(this.options,["scales",t],i):Zt(t)&&P(t,function(a,o){jt(n.options,["scales",o],a)}),this},r.prototype.tooltip=function(t){return jt(this.options,"tooltip",t),this},r.prototype.annotation=function(){return this.getController("annotation")},r.prototype.guide=function(){return console.warn("This method will be removed at G2 V4.1. Please use chart.annotation() instead."),this.annotation()},r.prototype.coordinate=function(t,i){return Ct(t)?jt(this.options,"coordinate",{type:t,cfg:i}):jt(this.options,"coordinate",t),this.coordinateController.update(this.options.coordinate),this.coordinateController},r.prototype.coord=function(t,i){return console.warn("This method will be removed at G2 V4.1. Please use chart.coordinate() instead."),this.coordinate(t,i)},r.prototype.facet=function(t,i){this.facetInstance&&this.facetInstance.destroy();var n=UY(t);if(!n)throw new Error("facet '"+t+"' is not exist!");return this.facetInstance=new n(this,A(A({},i),{type:t})),this},r.prototype.animate=function(t){return jt(this.options,"animate",t),this},r.prototype.updateOptions=function(t){return this.clear(),Kt(this.options,t),this.views.forEach(function(i){return i.destroy()}),this.views=[],this.initOptions(),this.coordinateBBox=this.viewBBox,this},r.prototype.option=function(t,i){if(r.prototype[t])throw new Error(`Can't use built in variable name "`+t+'", please change another one.');return jt(this.options,t,i),this},r.prototype.theme=function(t){return this.themeObject=Zt(t)?ft({},this.themeObject,wx(t)):rs(t),this},r.prototype.interaction=function(t,i){var n=this.interactions[t];n&&n.destroy();var a=B_t(t,this,i);return a&&(a.init(),this.interactions[t]=a),this},r.prototype.removeInteraction=function(t){var i=this.interactions[t];i&&(i.destroy(),this.interactions[t]=void 0)},r.prototype.changeData=function(t){this.isDataChanged=!0,this.emit(Gt.BEFORE_CHANGE_DATA,$e.fromData(this,Gt.BEFORE_CHANGE_DATA,null)),this.data(t),this.paint(!0);for(var i=this.views,n=0,a=i.length;n<a;n++){var o=i[n];o.changeData(t)}this.emit(Gt.AFTER_CHANGE_DATA,$e.fromData(this,Gt.AFTER_CHANGE_DATA,null))},r.prototype.createView=function(t){this.parent&&this.parent.parent&&console.warn("The view nesting recursive feature will be removed at G2 V4.1. Please avoid to use it.");var i={data:this.options.data,scales:di(this.options.scales),axes:di(this.options.axes),coordinate:di(this.coordinateController.getOption()),tooltip:di(this.options.tooltip),legends:di(this.options.legends),animate:this.options.animate,visible:this.visible},n=new r(A(A({parent:this,canvas:this.canvas,backgroundGroup:this.backgroundGroup.addGroup({zIndex:Ff.BG}),middleGroup:this.middleGroup.addGroup({zIndex:Ff.MID}),foregroundGroup:this.foregroundGroup.addGroup({zIndex:Ff.FORE}),theme:this.themeObject,padding:this.padding},t),{options:A(A({},i),I(t,"options",{}))}));return this.views.push(n),n},r.prototype.view=function(t){return console.warn("This method will be removed at G2 V4.1. Please use chart.createView() instead."),this.createView(t)},r.prototype.removeView=function(t){var i=qG(this.views,function(n){return n===t})[0];return i&&i.destroy(),i},r.prototype.getCoordinate=function(){return this.coordinateInstance},r.prototype.getTheme=function(){return this.themeObject},r.prototype.getXScale=function(){var t=this.geometries[0];return t?t.getXScale():null},r.prototype.getYScales=function(){var t={},i=[];return this.geometries.forEach(function(n){var a=n.getYScale(),o=a.field;t[o]||(t[o]=!0,i.push(a))}),i},r.prototype.getScalesByDim=function(t){for(var i=this.geometries,n={},a=0,o=i.length;a<o;a++){var l=i[a],s=t==="x"?l.getXScale():l.getYScale();s&&!n[s.field]&&(n[s.field]=s)}return n},r.prototype.getScale=function(t,i){var n=i||this.getScaleKey(t);return this.getRootView().scalePool.getScale(n)},r.prototype.getScaleByField=function(t,i){return this.getScale(t,i)},r.prototype.getOptions=function(){return this.options},r.prototype.getData=function(){return this.filteredData},r.prototype.getOriginalData=function(){return this.options.data},r.prototype.getPadding=function(){return this.autoPadding.getPadding()},r.prototype.getGeometries=function(){return this.geometries},r.prototype.getElements=function(){return Kr(this.geometries,function(t,i){return t.concat(i.getElements())},[])},r.prototype.getElementsBy=function(t){return this.getElements().filter(function(i){return t(i)})},r.prototype.getLayer=function(t){return t===Ye.BG?this.backgroundGroup:t===Ye.MID?this.middleGroup:t===Ye.FORE?this.foregroundGroup:this.foregroundGroup},r.prototype.isPointInPlot=function(t){return bT(this.getCoordinate(),t)},r.prototype.getLegendAttributes=function(){return qi(this.geometries.map(function(t){return t.getGroupAttributes()}))},r.prototype.getGroupScales=function(){var t=this.geometries.map(function(i){return i.getGroupScales()});return Hl(qi(t))},r.prototype.getCanvas=function(){return this.getRootView().canvas},r.prototype.getRootView=function(){for(var t=this;;){if(t.parent){t=t.parent;continue}break}return t},r.prototype.getXY=function(t){var i=this.getCoordinate(),n=this.getScalesByDim("x"),a=this.getScalesByDim("y"),o,l;if(P(t,function(s,u){n[u]&&(o=n[u].scale(s)),a[u]&&(l=a[u].scale(s))}),!K(o)&&!K(l))return i.convert({x:o,y:l})},r.prototype.getController=function(t){return Yn(this.controllers,function(i){return i.name===t})},r.prototype.showTooltip=function(t){var i=this.getController("tooltip");return i&&i.showTooltip(t),this},r.prototype.hideTooltip=function(){var t=this.getController("tooltip");return t&&t.hideTooltip(),this},r.prototype.lockTooltip=function(){var t=this.getController("tooltip");return t&&t.lockTooltip(),this},r.prototype.unlockTooltip=function(){var t=this.getController("tooltip");return t&&t.unlockTooltip(),this},r.prototype.isTooltipLocked=function(){var t=this.getController("tooltip");return t&&t.isTooltipLocked()},r.prototype.getTooltipItems=function(t){var i=this.getController("tooltip");return i?i.getTooltipItems(t):[]},r.prototype.getSnapRecords=function(t){for(var i=this.geometries,n=[],a=0,o=i.length;a<o;a++){var l=i[a],s=l.dataArray;l.sort(s);for(var u=void 0,c=0,f=s.length;c<f;c++){var h=s[c];u=fW(t,h,l),u&&n.push(u)}}for(var v=this.views,a=0,o=v.length;a<o;a++){var d=v[a],p=d.getSnapRecords(t);n=n.concat(p)}return n},r.prototype.getComponents=function(){for(var t=[],i=this.controllers,n=0,a=i.length;n<a;n++){var o=i[n];t=t.concat(o.getComponents())}return t},r.prototype.filterData=function(t){var i=this.options.filters;return yr(i)===0?t:jr(t,function(n,a){var o=Object.keys(i);return o.every(function(l){var s=i[l];return s(n[l],n,a)})})},r.prototype.filterFieldData=function(t,i){var n=this.options.filters,a=I(n,t);return Yl(a)?i:i.filter(function(o,l){return a(o[t],o,l)})},r.prototype.adjustCoordinate=function(){var t=this.getCoordinate(),i=t.start,n=t.end,a=this.coordinateBBox.bl,o=this.coordinateBBox.tr;if(Ge(i,a)&&Ge(n,o)){this.isCoordinateChanged=!1;return}this.isCoordinateChanged=!0,this.coordinateInstance=this.coordinateController.adjust(a,o)},r.prototype.paint=function(t){this.renderDataRecursive(t),this.syncScale(),this.emit(Gt.BEFORE_PAINT),this.renderPaddingRecursive(t),this.renderLayoutRecursive(t),this.renderBackgroundStyleShape(),this.renderPaintRecursive(t),this.emit(Gt.AFTER_PAINT),this.isDataChanged=!1},r.prototype.renderBackgroundStyleShape=function(){if(!this.parent){var t=I(this.themeObject,"background");if(t){this.backgroundStyleRectShape||(this.backgroundStyleRectShape=this.backgroundGroup.addShape("rect",{attrs:{},zIndex:-1,capture:!1}),this.backgroundStyleRectShape.toBack());var i=this.viewBBox,n=i.x,a=i.y,o=i.width,l=i.height;this.backgroundStyleRectShape.attr({fill:t,x:n,y:a,width:o,height:l})}else this.backgroundStyleRectShape&&(this.backgroundStyleRectShape.remove(!0),this.backgroundStyleRectShape=void 0)}},r.prototype.renderPaddingRecursive=function(t){this.calculateViewBBox(),this.adjustCoordinate(),this.initComponents(t),this.autoPadding=nbt(this).shrink(EO(this.appendPadding)),this.coordinateBBox=this.viewBBox.shrink(this.autoPadding.getPadding()),this.adjustCoordinate();for(var i=this.views,n=0,a=i.length;n<a;n++){var o=i[n];o.renderPaddingRecursive(t)}},r.prototype.renderLayoutRecursive=function(t){var i=this.syncViewPadding===!0?abt:pt(this.syncViewPadding)?this.syncViewPadding:void 0;i&&(i(this,this.views,E0),this.views.forEach(function(s){s.coordinateBBox=s.viewBBox.shrink(s.autoPadding.getPadding()),s.adjustCoordinate()})),this.doLayout();for(var n=this.views,a=0,o=n.length;a<o;a++){var l=n[a];l.renderLayoutRecursive(t)}},r.prototype.renderPaintRecursive=function(t){var i=this.middleGroup;if(this.limitInPlot){var n=HY(this.coordinateInstance),a=n.type,o=n.attrs;i.setClip({type:a,attrs:o})}else i.setClip(void 0);this.paintGeometries(t),this.renderComponents(t);for(var l=this.views,s=0,u=l.length;s<u;s++){var c=l[s];c.renderPaintRecursive(t)}},r.prototype.createScale=function(t,i,n,a){var o=I(this.options.scales,[t]),l=A(A({},o),n);return this.parent?this.parent.createScale(t,i,l,a):this.scalePool.createScale(t,i,l,a)},r.prototype.renderDataRecursive=function(t){this.doFilterData(),this.createCoordinate(),this.initGeometries(t),this.renderFacet(t);for(var i=this.views,n=0,a=i.length;n<a;n++){var o=i[n];o.renderDataRecursive(t)}},r.prototype.calculateViewBBox=function(){var t,i,n,a;if(this.parent){var o=this.parent.coordinateBBox;t=o.x,i=o.y,n=o.width,a=o.height}else t=0,i=0,n=this.canvas.get("width"),a=this.canvas.get("height");var l=this.region,s=l.start,u=l.end,c=new Ei(t+n*s.x,i+a*s.y,n*(u.x-s.x),a*(u.y-s.y));(!this.viewBBox||!this.viewBBox.isEqual(c))&&(this.viewBBox=new Ei(t+n*s.x,i+a*s.y,n*(u.x-s.x),a*(u.y-s.y))),this.coordinateBBox=this.viewBBox},r.prototype.initEvents=function(){this.foregroundGroup.on("*",this.onDelegateEvents),this.middleGroup.on("*",this.onDelegateEvents),this.backgroundGroup.on("*",this.onDelegateEvents),this.canvas.on("*",this.onCanvasEvent)},r.prototype.initComponentController=function(){for(var t=this.usedControllers,i=0,n=t.length;i<n;i++){var a=t[i],o=tbt(a);o&&this.controllers.push(new o(this))}},r.prototype.createViewEvent=function(t){var i=t.shape,n=t.name,a=i?i.get("origin"):null,o=new $e(this,t,a);return o.type=n,o},r.prototype.doPlotEvent=function(t){var i=t.type,n=t.x,a=t.y,o={x:n,y:a},l=["mousedown","mouseup","mousemove","mouseleave","mousewheel","touchstart","touchmove","touchend","touchcancel","click","dblclick","contextmenu"];if(l.includes(i)){var s=this.isPointInPlot(o),u=t.clone();if(s){var c="plot:"+i;u.type=c,this.emit(c,u),(i==="mouseleave"||i==="touchend")&&(this.isPreMouseInPlot=!1)}i==="mousemove"||i==="touchmove"?(this.isPreMouseInPlot&&!s?(i==="mousemove"&&(u.type=Ri.MOUSE_LEAVE,this.emit(Ri.MOUSE_LEAVE,u)),u.type=Ri.LEAVE,this.emit(Ri.LEAVE,u)):!this.isPreMouseInPlot&&s&&(i==="mousemove"&&(u.type=Ri.MOUSE_ENTER,this.emit(Ri.MOUSE_ENTER,u)),u.type=Ri.ENTER,this.emit(Ri.ENTER,u)),this.isPreMouseInPlot=s):(i==="mouseleave"||i==="touchend")&&this.isPreMouseInPlot&&(i==="mouseleave"&&(u.type=Ri.MOUSE_LEAVE,this.emit(Ri.MOUSE_LEAVE,u)),u.type=Ri.LEAVE,this.emit(Ri.LEAVE,u),this.isPreMouseInPlot=!1)}},r.prototype.doFilterData=function(){var t=this.options.data;this.filteredData=this.filterData(t)},r.prototype.initGeometries=function(t){this.createOrUpdateScales();for(var i=this.getCoordinate(),n=I(this.options,"scales",{}),a=this.geometries,o=0,l=a.length;o<l;o++){var s=a[o];s.scales=this.getGeometryScales();var u={coordinate:i,scaleDefs:n,data:this.filteredData,theme:this.themeObject,isDataChanged:this.isDataChanged,isCoordinateChanged:this.isCoordinateChanged};t?s.update(u):s.init(u)}this.adjustScales()},r.prototype.createOrUpdateScales=function(){for(var t=this.getScaleFields(),i=this.getGroupedFields(),n=this.getOptions(),a=n.data,o=n.scales,l=o===void 0?{}:o,s=this.filteredData,u=0,c=t.length;u<c;u++){var f=t[u],h=l[f],v=this.getScaleKey(f);this.createScale(f,i.includes(f)?a:s,h,v),this.createdScaleKeys.set(v,!0)}},r.prototype.syncScale=function(){this.getRootView().scalePool.sync(this.getCoordinate(),this.theme)},r.prototype.getGeometryScales=function(){for(var t=this.getScaleFields(),i={},n=0;n<t.length;n++){var a=t[n];i[a]=this.getScaleByField(a)}return i},r.prototype.getScaleFields=function(){for(var t=[],i=new Map,n=this.geometries,a=0;a<n.length;a++){var o=n[a],l=o.getScaleFields();Hl(l,t,i)}return t},r.prototype.getGroupedFields=function(){for(var t=[],i=new Map,n=this.geometries,a=0;a<n.length;a++){var o=n[a],l=o.getGroupFields();Hl(l,t,i)}return t},r.prototype.adjustScales=function(){this.adjustCategoryScaleRange()},r.prototype.adjustCategoryScaleRange=function(){var t=this,i=Qr([this.getXScale()],this.getYScales(),!0).filter(function(o){return!!o}),n=this.getCoordinate(),a=this.options.scales;P(i,function(o){var l=o.field,s=o.values,u=o.isCategory,c=o.isIdentity;(u||c)&&s&&!I(a,[l,"range"])&&(o.range=YY(o,n,t.theme))})},r.prototype.initComponents=function(t){for(var i=this.controllers,n=0;n<i.length;n++){var a=i[n];t?a.update():(a.clear(),a.render())}},r.prototype.doLayout=function(){this.layoutFunc(this)},r.prototype.createCoordinate=function(){var t=this.coordinateBBox.bl,i=this.coordinateBBox.tr;this.coordinateInstance=this.coordinateController.create(t,i)},r.prototype.paintGeometries=function(t){for(var i=this.options.animate,n=this.getCoordinate(),a={x:this.viewBBox.x,y:this.viewBBox.y,minX:this.viewBBox.minX,minY:this.viewBBox.minY,maxX:this.viewBBox.maxX,maxY:this.viewBBox.maxY,width:this.viewBBox.width,height:this.viewBBox.height},o=this.geometries,l=0;l<o.length;l++){var s=o[l];s.coordinate=n,s.canvasRegion=a,i||s.animate(!1),s.paint(t)}},r.prototype.renderComponents=function(t){for(var i=0;i<this.getComponents().length;i++){var n=this.getComponents()[i];n.component.render()}},r.prototype.renderFacet=function(t){this.facetInstance&&(t?this.facetInstance.update():(this.facetInstance.clear(),this.facetInstance.init(),this.facetInstance.render()))},r.prototype.initOptions=function(){var t=this,i=this.options,n=i.geometries,a=n===void 0?[]:n,o=i.interactions,l=o===void 0?[]:o,s=i.views,u=s===void 0?[]:s,c=i.annotations,f=c===void 0?[]:c,h=i.coordinate,v=i.events,d=i.facets;this.coordinateController?h&&this.coordinateController.update(h):this.coordinateController=new ebt(h);for(var p=0;p<a.length;p++){var x=a[p];this.createGeometry(x)}for(var m=0;m<l.length;m++){var _=l[m],b=_.type,w=_.cfg;this.interaction(b,w)}for(var S=0;S<u.length;S++){var M=u[S];this.createView(M)}for(var F=this.getController("annotation"),O=0;O<f.length;O++){var L=f[O];F.annotation(L)}v&&P(v,function(D,k){t.on(k,D)}),d&&P(d,function(D){var k=D.type,H=ue(D,["type"]);t.facet(k,H)})},r.prototype.createGeometry=function(t){var i=t.type,n=t.cfg,a=n===void 0?{}:n;if(this[i]){var o=this[i](a);P(t,function(l,s){pt(o[s])&&o[s](l)})}},r.prototype.getScaleKey=function(t){return this.id+"-"+t},r}(wO);function ka(e,r){OO.prototype[e.toLowerCase()]=function(t){t===void 0&&(t={});var i=A({container:this.middleGroup.addGroup(),labelsContainer:this.foregroundGroup.addGroup()},t),n=new r(i);return this.geometries.push(n),n}}var hW=function(e){X(r,e);function r(t){var i=this,n=t.container,a=t.width,o=t.height,l=t.autoFit,s=l===void 0?!1:l,u=t.padding,c=t.appendPadding,f=t.renderer,h=f===void 0?"canvas":f,v=t.pixelRatio,d=t.localRefresh,p=d===void 0?!0:d,x=t.visible,m=x===void 0?!0:x,_=t.supportCSSTransform,b=_===void 0?!1:_,w=t.defaultInteractions,S=w===void 0?["tooltip","legend-filter","legend-active","continuous-filter","ellipsis-text"]:w,M=t.options,F=t.limitInPlot,O=t.theme,L=t.syncViewPadding,D=Ct(n)?document.getElementById(n):n,k=Zo('<div style="position:relative;"></div>');D.appendChild(k);var H=tB(D,s,a,o),B=GY(h),j=new B.Canvas(A({container:k,pixelRatio:v,localRefresh:p,supportCSSTransform:b},H));return i=e.call(this,{parent:null,canvas:j,backgroundGroup:j.addGroup({zIndex:Ff.BG}),middleGroup:j.addGroup({zIndex:Ff.MID}),foregroundGroup:j.addGroup({zIndex:Ff.FORE}),padding:u,appendPadding:c,visible:m,options:M,limitInPlot:F,theme:O,syncViewPadding:L})||this,i.onResize=e1(function(){i.forceFit()},300),i.ele=D,i.canvas=j,i.width=H.width,i.height=H.height,i.autoFit=s,i.localRefresh=p,i.renderer=h,i.wrapperElement=k,i.updateCanvasStyle(),i.bindAutoFit(),i.initDefaultInteractions(S),i}return r.prototype.initDefaultInteractions=function(t){var i=this;P(t,function(n){i.interaction(n)})},r.prototype.aria=function(t){var i="aria-label";t===!1?this.ele.removeAttribute(i):this.ele.setAttribute(i,t.label)},r.prototype.changeSize=function(t,i){return this.width===t&&this.height===i?this:(this.emit(Gt.BEFORE_CHANGE_SIZE),this.width=t,this.height=i,this.canvas.changeSize(t,i),this.render(!0),this.emit(Gt.AFTER_CHANGE_SIZE),this)},r.prototype.clear=function(){e.prototype.clear.call(this),this.aria(!1)},r.prototype.destroy=function(){e.prototype.destroy.call(this),this.unbindAutoFit(),this.canvas.destroy(),r_t(this.wrapperElement),this.wrapperElement=null},r.prototype.changeVisible=function(t){return e.prototype.changeVisible.call(this,t),this.wrapperElement.style.display=t?"":"none",this},r.prototype.forceFit=function(){if(!this.destroyed){var t=tB(this.ele,!0,this.width,this.height),i=t.width,n=t.height;this.changeSize(i,n)}},r.prototype.updateCanvasStyle=function(){qr(this.canvas.get("el"),{display:"inline-block",verticalAlign:"middle"})},r.prototype.bindAutoFit=function(){this.autoFit&&window.addEventListener("resize",this.onResize)},r.prototype.unbindAutoFit=function(){this.autoFit&&window.removeEventListener("resize",this.onResize)},r}(OO),pc=function(){function e(r){this.visible=!0,this.components=[],this.view=r}return e.prototype.clear=function(r){P(this.components,function(t){t.component.destroy()}),this.components=[]},e.prototype.destroy=function(){this.clear()},e.prototype.getComponents=function(){return this.components},e.prototype.changeVisible=function(r){this.visible!==r&&(this.components.forEach(function(t){r?t.component.show():t.component.hide()}),this.visible=r)},e}();function obt(e){for(var r=[],t=function(n){var a=e[n],o=Yn(r,function(l){return l.color===a.color&&l.name===a.name&&l.value===a.value&&l.title===a.title});o||r.push(a)},i=0;i<e.length;i++)t(i);return r}var PO=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.isLocked=!1,t}return Object.defineProperty(r.prototype,"name",{get:function(){return"tooltip"},enumerable:!1,configurable:!0}),r.prototype.init=function(){},r.prototype.isVisible=function(){var t=this.view.getOptions().tooltip;return t!==!1},r.prototype.render=function(){},r.prototype.showTooltip=function(t){if(this.point=t,!!this.isVisible()){var i=this.view,n=this.getTooltipItems(t);if(!n.length){this.hideTooltip();return}var a=this.getTitle(n),o={x:n[0].x,y:n[0].y};i.emit("tooltip:show",$e.fromData(i,"tooltip:show",A({items:n,title:a},t)));var l=this.getTooltipCfg(),s=l.follow,u=l.showMarkers,c=l.showCrosshairs,f=l.showContent,h=l.marker,v=this.items,d=this.title;if(!Ge(d,a)||!Ge(v,n)?(i.emit("tooltip:change",$e.fromData(i,"tooltip:change",A({items:n,title:a},t))),(pt(f)?f(n):f)&&(this.tooltip||this.renderTooltip(),this.tooltip.update(Kt({},l,{items:this.getItemsAfterProcess(n),title:a},s?t:{})),this.tooltip.show()),u&&this.renderTooltipMarkers(n,h)):(this.tooltip&&s&&(this.tooltip.update(t),this.tooltip.show()),this.tooltipMarkersGroup&&this.tooltipMarkersGroup.show()),this.items=n,this.title=a,c){var p=I(l,["crosshairs","follow"],!1);this.renderCrosshairs(p?t:o,l)}}},r.prototype.hideTooltip=function(){var t=this.getTooltipCfg().follow;if(!t){this.point=null;return}var i=this.tooltipMarkersGroup;i&&i.hide();var n=this.xCrosshair,a=this.yCrosshair;n&&n.hide(),a&&a.hide();var o=this.tooltip;o&&o.hide(),this.view.emit("tooltip:hide",$e.fromData(this.view,"tooltip:hide",{})),this.point=null},r.prototype.lockTooltip=function(){this.isLocked=!0,this.tooltip&&this.tooltip.setCapture(!0)},r.prototype.unlockTooltip=function(){this.isLocked=!1;var t=this.getTooltipCfg();this.tooltip&&this.tooltip.setCapture(t.capture)},r.prototype.isTooltipLocked=function(){return this.isLocked},r.prototype.clear=function(){var t=this,i=t.tooltip,n=t.xCrosshair,a=t.yCrosshair,o=t.tooltipMarkersGroup;i&&(i.hide(),i.clear()),n&&n.clear(),a&&a.clear(),o&&o.clear(),i!=null&&i.get("customContent")&&(this.tooltip.destroy(),this.tooltip=null),this.title=null,this.items=null},r.prototype.destroy=function(){this.tooltip&&this.tooltip.destroy(),this.xCrosshair&&this.xCrosshair.destroy(),this.yCrosshair&&this.yCrosshair.destroy(),this.guideGroup&&this.guideGroup.remove(!0),this.reset()},r.prototype.reset=function(){this.items=null,this.title=null,this.tooltipMarkersGroup=null,this.tooltipCrosshairsGroup=null,this.xCrosshair=null,this.yCrosshair=null,this.tooltip=null,this.guideGroup=null,this.isLocked=!1,this.point=null},r.prototype.changeVisible=function(t){if(this.visible!==t){var i=this,n=i.tooltip,a=i.tooltipMarkersGroup,o=i.xCrosshair,l=i.yCrosshair;t?(n&&n.show(),a&&a.show(),o&&o.show(),l&&l.show()):(n&&n.hide(),a&&a.hide(),o&&o.hide(),l&&l.hide()),this.visible=t}},r.prototype.getTooltipItems=function(t){var i=this.findItemsFromView(this.view,t);if(i.length){i=qi(i);for(var n=0,a=i;n<a.length;n++)for(var o=a[n],l=0,s=o;l<s.length;l++){var u=s[l],c=u.mappingData,f=c.x,h=c.y;u.x=it(f)?f[f.length-1]:f,u.y=it(h)?h[h.length-1]:h}var v=this.getTooltipCfg().shared;if(v===!1&&i.length>1){for(var d=i[0],p=Math.abs(t.y-d[0].y),x=0,m=i;x<m.length;x++){var _=m[x],b=Math.abs(t.y-_[0].y);b<=p&&(d=_,p=b)}i=[d]}return obt(qi(i))}return[]},r.prototype.layout=function(){},r.prototype.update=function(){if(this.point&&this.showTooltip(this.point),this.tooltip){var t=this.view.getCanvas();this.tooltip.set("region",{start:{x:0,y:0},end:{x:t.get("width"),y:t.get("height")}})}},r.prototype.isCursorEntered=function(t){if(this.tooltip){var i=this.tooltip.getContainer(),n=this.tooltip.get("capture");if(i&&n){var a=i.getBoundingClientRect(),o=a.x,l=a.y,s=a.width,u=a.height;return new Ei(o,l,s,u).isPointIn(t)}}return!1},r.prototype.getTooltipCfg=function(){var t=this.view,i=t.getOptions().tooltip,n=this.processCustomContent(i),a=t.getTheme(),o=I(a,["components","tooltip"],{}),l=I(n,"enterable",o.enterable);return ft({},o,n,{capture:!!(l||this.isLocked)})},r.prototype.processCustomContent=function(t){if(Yu(t)||!I(t,"customContent"))return t;var i=t.customContent,n=function(a,o){var l=i(a,o)||"";return Ct(l)?'<div class="g2-tooltip">'+l+"</div>":l};return A(A({},t),{customContent:n})},r.prototype.getTitle=function(t){var i=t[0].title||t[0].name;return this.title=i,i},r.prototype.renderTooltip=function(){var t=this.view.getCanvas(),i={start:{x:0,y:0},end:{x:t.get("width"),y:t.get("height")}},n=this.getTooltipCfg(),a=new zY(A(A({parent:t.get("el").parentNode,region:i},n),{visible:!1,crosshairs:null}));a.init(),this.tooltip=a},r.prototype.renderTooltipMarkers=function(t,i){for(var n=this.getTooltipMarkersGroup(),a=0,o=t;a<o.length;a++){var l=o[a],s=l.x,u=l.y,c=A(A({fill:l.color,symbol:"circle",shadowColor:l.color},i),{x:s,y:u});n.addShape("marker",{attrs:c})}},r.prototype.renderCrosshairs=function(t,i){var n=I(i,["crosshairs","type"],"x");n==="x"?(this.yCrosshair&&this.yCrosshair.hide(),this.renderXCrosshairs(t,i)):n==="y"?(this.xCrosshair&&this.xCrosshair.hide(),this.renderYCrosshairs(t,i)):n==="xy"&&(this.renderXCrosshairs(t,i),this.renderYCrosshairs(t,i))},r.prototype.renderXCrosshairs=function(t,i){var n=this.getViewWithGeometry(this.view).getCoordinate();if(!!bT(n,t)){var a,o;if(n.isRect)n.isTransposed?(a={x:n.start.x,y:t.y},o={x:n.end.x,y:t.y}):(a={x:t.x,y:n.end.y},o={x:t.x,y:n.start.y});else{var l=Kf(n,t),s=n.getCenter(),u=n.getRadius();o=ir(s.x,s.y,u,l),a=s}var c=ft({start:a,end:o,container:this.getTooltipCrosshairsGroup()},I(i,"crosshairs",{}),this.getCrosshairsText("x",t,i));delete c.type;var f=this.xCrosshair;f?f.update(c):(f=new R5(c),f.init()),f.render(),f.show(),this.xCrosshair=f}},r.prototype.renderYCrosshairs=function(t,i){var n=this.getViewWithGeometry(this.view).getCoordinate();if(!!bT(n,t)){var a,o;if(n.isRect){var l=void 0,s=void 0;n.isTransposed?(l={x:t.x,y:n.end.y},s={x:t.x,y:n.start.y}):(l={x:n.start.x,y:t.y},s={x:n.end.x,y:t.y}),a={start:l,end:s},o="Line"}else a={center:n.getCenter(),radius:T_(n,t),startAngle:n.startAngle,endAngle:n.endAngle},o="Circle";a=ft({container:this.getTooltipCrosshairsGroup()},a,I(i,"crosshairs",{}),this.getCrosshairsText("y",t,i)),delete a.type;var u=this.yCrosshair;u?n.isRect&&u.get("type")==="circle"||!n.isRect&&u.get("type")==="line"?(u=new BA[o](a),u.init()):u.update(a):(u=new BA[o](a),u.init()),u.render(),u.show(),this.yCrosshair=u}},r.prototype.getCrosshairsText=function(t,i,n){var a=I(n,["crosshairs","text"]),o=I(n,["crosshairs","follow"]),l=this.items;if(a){var s=this.getViewWithGeometry(this.view),u=l[0],c=s.getXScale(),f=s.getYScales()[0],h=void 0,v=void 0;if(o){var d=this.view.getCoordinate().invert(i);h=c.invert(d.x),v=f.invert(d.y)}else h=u.data[c.field],v=u.data[f.field];var p=t==="x"?h:v;return pt(a)?a=a(t,p,l,i):a.content=p,{text:a}}},r.prototype.getGuideGroup=function(){if(!this.guideGroup){var t=this.view.foregroundGroup;this.guideGroup=t.addGroup({name:"tooltipGuide",capture:!1})}return this.guideGroup},r.prototype.getTooltipMarkersGroup=function(){var t=this.tooltipMarkersGroup;return t&&!t.destroyed?(t.clear(),t.show()):(t=this.getGuideGroup().addGroup({name:"tooltipMarkersGroup"}),t.toFront(),this.tooltipMarkersGroup=t),t},r.prototype.getTooltipCrosshairsGroup=function(){var t=this.tooltipCrosshairsGroup;return t||(t=this.getGuideGroup().addGroup({name:"tooltipCrosshairsGroup",capture:!1}),t.toBack(),this.tooltipCrosshairsGroup=t),t},r.prototype.findItemsFromView=function(t,i){if(t.getOptions().tooltip===!1)return[];for(var n=this.getTooltipCfg(),a=AT(t,i,n),o=0,l=t.views;o<l.length;o++){var s=l[o];a=a.concat(this.findItemsFromView(s,i))}return a},r.prototype.getViewWithGeometry=function(t){var i=this;return t.geometries.length?t:Yn(t.views,function(n){return i.getViewWithGeometry(n)})},r.prototype.getItemsAfterProcess=function(t){var i=this.getTooltipCfg().customItems,n=i||function(a){return a};return n(t)},r}(pc),vW={};function IO(e){return vW[e.toLowerCase()]}function Qi(e,r){vW[e.toLowerCase()]=r}var eh={appear:{duration:450,easing:"easeQuadOut"},update:{duration:400,easing:"easeQuadInOut"},enter:{duration:400,easing:"easeQuadInOut"},leave:{duration:350,easing:"easeQuadIn"}},lbt={interval:function(e){return{enter:{animation:e.isRect?e.isTransposed?"scale-in-x":"scale-in-y":"fade-in"},update:{animation:e.isPolar&&e.isTransposed?"sector-path-update":null},leave:{animation:"fade-out"}}},line:{enter:{animation:"fade-in"},leave:{animation:"fade-out"}},path:{enter:{animation:"fade-in"},leave:{animation:"fade-out"}},point:{appear:{animation:"zoom-in"},enter:{animation:"zoom-in"},leave:{animation:"zoom-out"}},area:{enter:{animation:"fade-in"},leave:{animation:"fade-out"}},polygon:{enter:{animation:"fade-in"},leave:{animation:"fade-out"}},schema:{enter:{animation:"fade-in"},leave:{animation:"fade-out"}},edge:{enter:{animation:"fade-in"},leave:{animation:"fade-out"}},label:{appear:{animation:"fade-in",delay:450},enter:{animation:"fade-in"},update:{animation:"position-update"},leave:{animation:"fade-out"}}},gB={line:function(){return{animation:"wave-in"}},area:function(){return{animation:"wave-in"}},path:function(){return{animation:"fade-in"}},interval:function(e){var r;return e.isRect?r=e.isTransposed?"grow-in-x":"grow-in-y":(r="grow-in-xy",e.isPolar&&e.isTransposed&&(r="wave-in")),{animation:r}},schema:function(e){var r;return e.isRect?r=e.isTransposed?"grow-in-x":"grow-in-y":r="grow-in-xy",{animation:r}},polygon:function(){return{animation:"fade-in",duration:500}},edge:function(){return{animation:"fade-in"}}};function sbt(e,r){return{delay:pt(e.delay)?e.delay(r):e.delay,easing:pt(e.easing)?e.easing(r):e.easing,duration:pt(e.duration)?e.duration(r):e.duration,callback:e.callback,repeat:e.repeat}}function dW(e,r,t){var i=lbt[e];return i&&(pt(i)&&(i=i(r)),i=ft({},eh,i),t)?i[t]:i}function Pf(e,r,t){var i=I(e.get("origin"),"data",de),n=r.animation,a=sbt(r,i);if(n){var o=IO(n);o&&o(e,a,t)}else e.animate(t.toAttrs,a)}function ubt(e,r,t,i,n){if(gB[t]){var a=gB[t](i),o=IO(I(a,"animation",""));if(o){var l=A(A(A({},eh.appear),a),r);e.stopAnimate(),o(e,l,{coordinate:i,minYPoint:n,toAttrs:null})}}}var LO="element-background",DO=function(e){X(r,e);function r(t){var i=e.call(this,t)||this;i.states=[];var n=t.shapeFactory,a=t.container,o=t.offscreenGroup,l=t.elementIndex,s=t.visible,u=s===void 0?!0:s;return i.shapeFactory=n,i.container=a,i.offscreenGroup=o,i.visible=u,i.elementIndex=l,i}return r.prototype.draw=function(t,i){i===void 0&&(i=!1),this.model=t,this.data=t.data,this.shapeType=this.getShapeType(t),this.drawShape(t,i),this.visible===!1&&this.changeVisible(!1)},r.prototype.update=function(t){var i=this,n=i.shapeFactory,a=i.shape;if(!!a){this.model=t,this.data=t.data,this.shapeType=this.getShapeType(t),this.setShapeInfo(a,t);var o=this.getOffscreenGroup(),l=n.drawShape(this.shapeType,t,o);l.cfg.data=this.data,l.cfg.origin=t,l.cfg.element=this,this.syncShapeStyle(a,l,this.getStates(),this.getAnimateCfg("update"))}},r.prototype.destroy=function(){var t=this,i=t.shapeFactory,n=t.shape;if(n){var a=this.getAnimateCfg("leave");a?Pf(n,a,{coordinate:i.coordinate,toAttrs:A({},n.attr())}):n.remove(!0)}this.states=[],this.shapeFactory=void 0,this.container=void 0,this.shape=void 0,this.animate=void 0,this.geometry=void 0,this.labelShape=void 0,this.model=void 0,this.data=void 0,this.offscreenGroup=void 0,this.statesStyle=void 0,e.prototype.destroy.call(this)},r.prototype.changeVisible=function(t){e.prototype.changeVisible.call(this,t),t?(this.shape&&this.shape.show(),this.labelShape&&this.labelShape.forEach(function(i){i.show()})):(this.shape&&this.shape.hide(),this.labelShape&&this.labelShape.forEach(function(i){i.hide()}))},r.prototype.setState=function(t,i){var n=this,a=n.states,o=n.shapeFactory,l=n.model,s=n.shape,u=n.shapeType,c=a.indexOf(t);if(i){if(c>-1)return;a.push(t),(t==="active"||t==="selected")&&(s==null||s.toFront())}else{if(c===-1)return;a.splice(c,1),(t==="active"||t==="selected")&&(this.geometry.zIndexReversed?s.setZIndex(this.geometry.elements.length-this.elementIndex):s.setZIndex(this.elementIndex))}var f=o.drawShape(u,l,this.getOffscreenGroup());a.length?this.syncShapeStyle(s,f,a,null):this.syncShapeStyle(s,f,["reset"],null),f.remove(!0);var h={state:t,stateStatus:i,element:this,target:this.container};this.container.emit("statechange",h),NM(this.shape,"statechange",h)},r.prototype.clearStates=function(){var t=this,i=this.states;P(i,function(n){t.setState(n,!1)}),this.states=[]},r.prototype.hasState=function(t){return this.states.includes(t)},r.prototype.getStates=function(){return this.states},r.prototype.getData=function(){return this.data},r.prototype.getModel=function(){return this.model},r.prototype.getBBox=function(){var t=this,i=t.shape,n=t.labelShape,a={x:0,y:0,minX:0,minY:0,maxX:0,maxY:0,width:0,height:0};return i&&(a=i.getCanvasBBox()),n&&n.forEach(function(o){var l=o.getCanvasBBox();a.x=Math.min(l.x,a.x),a.y=Math.min(l.y,a.y),a.minX=Math.min(l.minX,a.minX),a.minY=Math.min(l.minY,a.minY),a.maxX=Math.max(l.maxX,a.maxX),a.maxY=Math.max(l.maxY,a.maxY)}),a.width=a.maxX-a.minX,a.height=a.maxY-a.minY,a},r.prototype.getStatesStyle=function(){if(!this.statesStyle){var t=this,i=t.shapeType,n=t.geometry,a=t.shapeFactory,o=n.stateOption,l=a.defaultShapeType,s=a.theme[i]||a.theme[l];this.statesStyle=ft({},s,o)}return this.statesStyle},r.prototype.getStateStyle=function(t,i){var n=this.getStatesStyle(),a=I(n,[t,"style"],{}),o=a[i]||a;return pt(o)?o(this):o},r.prototype.getAnimateCfg=function(t){var i=this,n=this.animate;if(n){var a=n[t];return a&&A(A({},a),{callback:function(){var o;pt(a.callback)&&a.callback(),(o=i.geometry)===null||o===void 0||o.emit(Of.AFTER_DRAW_ANIMATE)}})}return null},r.prototype.drawShape=function(t,i){var n;i===void 0&&(i=!1);var a=this,o=a.shapeFactory,l=a.container,s=a.shapeType;if(this.shape=o.drawShape(s,t,l),this.shape){this.setShapeInfo(this.shape,t);var u=this.shape.cfg.name;u?Ct(u)&&(this.shape.cfg.name=["element",u]):this.shape.cfg.name=["element",this.shapeFactory.geometryType];var c=i?"enter":"appear",f=this.getAnimateCfg(c);f&&((n=this.geometry)===null||n===void 0||n.emit(Of.BEFORE_DRAW_ANIMATE),Pf(this.shape,f,{coordinate:o.coordinate,toAttrs:A({},this.shape.attr())}))}},r.prototype.getOffscreenGroup=function(){if(!this.offscreenGroup){var t=this.container.getGroupBase();this.offscreenGroup=new t({})}return this.offscreenGroup},r.prototype.setShapeInfo=function(t,i){var n=this;if(t.cfg.origin=i,t.cfg.element=this,t.isGroup()){var a=t.get("children");a.forEach(function(o){n.setShapeInfo(o,i)})}},r.prototype.syncShapeStyle=function(t,i,n,a,o){var l=this,s;if(n===void 0&&(n=[]),o===void 0&&(o=0),!(!t||!i)){var u=t.get("clipShape"),c=i.get("clipShape");if(this.syncShapeStyle(u,c,n,a),t.isGroup())for(var f=t.get("children"),h=i.get("children"),v=0;v<f.length;v++)this.syncShapeStyle(f[v],h[v],n,a,o+v);else{if(!gi(n)&&!Ge(n,["reset"])){var d=t.get("name");it(d)&&(d=d[1]),P(n,function(x){if(i.get("name")!==LO){var m=l.getStateStyle(x,d||o);i.attr(m)}})}var p=jY(t,i);this.animate?a?((s=this.geometry)===null||s===void 0||s.emit(Of.BEFORE_DRAW_ANIMATE),Pf(t,a,{coordinate:this.shapeFactory.coordinate,toAttrs:p,shapeModel:this.model})):gi(n)?t.attr(p):(t.stopAnimate(),t.animate(p,{duration:300})):t.attr(p)}}},r.prototype.getShapeType=function(t){var i=I(t,"shape");return it(i)?i[0]:i},r}(wO),pW={},gW={};function yW(e){return pW[e.toLowerCase()]}function kh(e,r){pW[e.toLowerCase()]=r}function mW(e){return gW[e.toLowerCase()]}function Ii(e,r){gW[e.toLowerCase()]=r}var cbt={coordinate:null,defaultShapeType:null,theme:null,getShapePoints:function(e,r){var t=this.getShape(e);return t.getPoints?t.getPoints(r):this.getDefaultPoints(r)},getShape:function(e){var r=this[e]||this[this.defaultShapeType];return r.coordinate=this.coordinate,r},getDefaultPoints:function(){return[]},getDefaultStyle:function(e){return I(e,[this.defaultShapeType,"default","style"],{})},getMarker:function(e,r){var t=this.getShape(e);if(!t.getMarker){var i=this.defaultShapeType;t=this.getShape(i)}var n=this.theme,a=I(n,[e,"default"],{}),o=t.getMarker(r);return ft({},a,o)},drawShape:function(e,r,t){var i=this.getShape(e);return i.draw(r,t)}},fbt={coordinate:null,parsePath:function(e){var r=this.coordinate,t=c1(e);return r.isPolar?t=F_t(r,t):t=E_t(r,t),t},parsePoint:function(e){var r=this.coordinate;return r.convert(e)},parsePoints:function(e){var r=this.coordinate;return e.map(function(t){return r.convert(t)})},draw:function(e,r){}},$O={};function fl(e,r){var t=Os(e),i=A(A(A({},cbt),r),{geometryType:e});return $O[t]=i,i}function te(e,r,t){var i=Os(e),n=$O[i],a=A(A({},fbt),t);return n[r]=a,a}function TT(e){var r=Os(e);return $O[r]}function hbt(e,r,t){if(t===void 0&&(t={}),!r)return[e];var i=uM(e,r),n=[];if(r.length===1&&t[r[0]])for(var a=t[r[0]],o=0,l=a;o<l.length;o++){var s=l[o],u=i["_"+s];u&&n.push(u)}else for(var c in i)if(i.hasOwnProperty(c)){var f=i[c];n.push(f)}return n}function xW(e,r){return gp(["color","shape","size","x","y","isInCircle","data","style","defaultStyle","points","mappingData"],function(t){return!Ge(e[t],r[t])})}function Ov(e){return it(e)?e:e.split("*")}function _W(e,r){for(var t=[],i=[],n=[],a=new Map,o=0;o<r.length;o++){var l=r[o];e[l]?i.push(l):t.push(l),a.set(l,!0)}return Object.keys(e).forEach(function(s){a.has(s)||n.push(s)}),{added:t,updated:i,removed:n}}function vbt(e,r){var t=[];return P(r,function(i,n){var a=n.split(" ")[0];a===e&&t.push(i)}),t}var hl=function(e){X(r,e);function r(t){var i=e.call(this,t)||this;i.type="base",i.attributes={},i.elements=[],i.elementsMap={},i.animateOption=!0,i.attributeOption={},i.lastElementsMap={},i.generatePoints=!1,i.beforeMappingData=null,i.adjusts={},i.idFields=[],i.hasSorted=!1,i.isCoordinateChanged=!1;var n=t.container,a=t.labelsContainer,o=t.coordinate,l=t.data,s=t.sortable,u=s===void 0?!1:s,c=t.visible,f=c===void 0?!0:c,h=t.theme,v=t.scales,d=v===void 0?{}:v,p=t.scaleDefs,x=p===void 0?{}:p,m=t.intervalPadding,_=t.dodgePadding,b=t.maxColumnWidth,w=t.minColumnWidth,S=t.columnWidthRatio,M=t.roseWidthRatio,F=t.multiplePieWidthRatio,O=t.zIndexReversed;return i.container=n,i.labelsContainer=a,i.coordinate=o,i.data=l,i.sortable=u,i.visible=f,i.userTheme=h,i.scales=d,i.scaleDefs=x,i.intervalPadding=m,i.dodgePadding=_,i.maxColumnWidth=b,i.minColumnWidth=w,i.columnWidthRatio=S,i.roseWidthRatio=M,i.multiplePieWidthRatio=F,i.zIndexReversed=O,i}return r.prototype.position=function(t){var i=t;wa(t)||(i={fields:Ov(t)});var n=I(i,"fields");return n.length===1&&(n.unshift("1"),jt(i,"fields",n)),jt(this.attributeOption,"position",i),this},r.prototype.color=function(t,i){return this.createAttrOption("color",t,i),this},r.prototype.shape=function(t,i){return this.createAttrOption("shape",t,i),this},r.prototype.size=function(t,i){return this.createAttrOption("size",t,i),this},r.prototype.adjust=function(t){var i=t;return(Ct(t)||wa(t))&&(i=[t]),P(i,function(n,a){Zt(n)||(i[a]={type:n})}),this.adjustOption=i,this},r.prototype.style=function(t,i){if(Ct(t)){var n=Ov(t);this.styleOption={fields:n,callback:i}}else{var a=t,n=a.fields,o=a.callback,l=a.cfg;n||o||l?this.styleOption=t:this.styleOption={cfg:t}}return this},r.prototype.tooltip=function(t,i){if(Ct(t)){var n=Ov(t);this.tooltipOption={fields:n,callback:i}}else this.tooltipOption=t;return this},r.prototype.animate=function(t){return this.animateOption=t,this},r.prototype.label=function(t,i,n){if(Ct(t)){var a={},o=Ov(t);a.fields=o,pt(i)?a.callback=i:wa(i)&&(a.cfg=i),n&&(a.cfg=n),this.labelOption=a}else this.labelOption=t;return this},r.prototype.state=function(t){return this.stateOption=t,this},r.prototype.customInfo=function(t){return this.customOption=t,this},r.prototype.init=function(t){t===void 0&&(t={}),this.setCfg(t),this.initAttributes(),this.processData(this.data),this.adjustScale()},r.prototype.update=function(t){t===void 0&&(t={});var i=t.data,n=t.isDataChanged,a=t.isCoordinateChanged,o=this,l=o.attributeOption,s=o.lastAttributeOption;Ge(l,s)?i&&(n||!Ge(i,this.data))?(this.setCfg(t),this.initAttributes(),this.processData(i)):this.setCfg(t):this.init(t),this.adjustScale(),this.isCoordinateChanged=a},r.prototype.paint=function(t){t===void 0&&(t=!1),this.animateOption&&(this.animateOption=ft({},dW(this.type,this.coordinate),this.animateOption)),this.defaultSize=void 0,this.elementsMap={},this.elements=[];var i=this.getOffscreenGroup();i.clear();var n=this.beforeMappingData,a=this.beforeMapping(n);this.dataArray=new Array(a.length);for(var o=0;o<a.length;o++){var l=a[o];this.dataArray[o]=this.mapping(l)}if(this.updateElements(this.dataArray,t),this.lastElementsMap=this.elementsMap,this.canDoGroupAnimation(t)){var s=this.container,u=this.type,c=this.coordinate,f=I(this.animateOption,"appear"),h=this.getYScale(),v=c.convert({x:0,y:h.scale(this.getYMinValue())});ubt(s,f,u,c,v)}this.labelOption&&this.renderLabels(qi(this.dataArray),t),this.lastAttributeOption=A({},this.attributeOption),this.visible===!1&&this.changeVisible(!1)},r.prototype.clear=function(){var t=this,i=t.container,n=t.geometryLabel,a=t.offscreenGroup;i&&i.clear(),n&&n.clear(),a&&a.clear(),this.scaleDefs=void 0,this.attributes={},this.scales={},this.elementsMap={},this.lastElementsMap={},this.elements=[],this.adjusts={},this.dataArray=null,this.beforeMappingData=null,this.lastAttributeOption=void 0,this.defaultSize=void 0,this.idFields=[],this.groupScales=void 0,this.hasSorted=!1,this.isCoordinateChanged=!1},r.prototype.destroy=function(){this.clear();var t=this.container;t.remove(!0),this.offscreenGroup&&(this.offscreenGroup.remove(!0),this.offscreenGroup=null),this.geometryLabel&&(this.geometryLabel.destroy(),this.geometryLabel=null),this.theme=void 0,this.shapeFactory=void 0,e.prototype.destroy.call(this)},r.prototype.getGroupScales=function(){return this.groupScales},r.prototype.getAttribute=function(t){return this.attributes[t]},r.prototype.getXScale=function(){return this.getAttribute("position").scales[0]},r.prototype.getYScale=function(){return this.getAttribute("position").scales[1]},r.prototype.getGroupAttributes=function(){var t=[];return P(this.attributes,function(i){Qv.includes(i.type)&&t.push(i)}),t},r.prototype.getDefaultValue=function(t){var i,n=this.getAttribute(t);return n&&gi(n.scales)&&(i=n.values[0]),i},r.prototype.getAttributeValues=function(t,i){for(var n=[],a=t.scales,o=0,l=a.length;o<l;o++){var s=a[o],u=s.field;s.isIdentity?n.push(s.values):n.push(i[u])}return t.mapping.apply(t,n)},r.prototype.getAdjust=function(t){return this.adjusts[t]},r.prototype.getCoordinate=function(){return this.coordinate},r.prototype.getData=function(){return this.data},r.prototype.getShapeMarker=function(t,i){var n=this.getShapeFactory();return n.getMarker(t,i)},r.prototype.getElementsBy=function(t){return this.elements.filter(function(i){return t(i)})},r.prototype.getElements=function(){return this.elements},r.prototype.getElementId=function(t){t=it(t)?t[0]:t;var i=t[de];if(this.idFields.length){for(var n=i[this.idFields[0]],a=1;a<this.idFields.length;a++)n+="-"+i[this.idFields[a]];return n}var o=this.type,l=this.getXScale(),s=this.getYScale(),u=l.field||"x",c=s.field||"y",f=i[c],h;l.type==="identity"?h=l.values[0]:h=i[u];var v;o==="interval"||o==="schema"?v=""+h:o==="line"||o==="area"||o==="path"?v=o:v=h+"-"+f;var d=this.groupScales;gi(d)&&(d=I(this.getAttribute("color"),"scales",[]));for(var a=0,p=d.length;a<p;a++){var x=d[a],m=x.field;v=v+"-"+i[m]}var _=this.getAdjust("dodge");if(_){var b=_.dodgeBy;b&&(v=v+"-"+i[b])}return this.getAdjust("jitter")&&(v=v+"-"+t.x+"-"+t.y),v},r.prototype.getScaleFields=function(){var t=[],i=new Map,n=this,a=n.attributeOption,o=n.labelOption,l=n.tooltipOption;for(var s in a)if(a.hasOwnProperty(s)){var u=a[s];u.fields?Hl(u.fields,t,i):u.values&&Hl(u.values,t,i)}return o&&o.fields&&Hl(o.fields,t,i),Zt(l)&&l.fields&&Hl(l.fields,t,i),t},r.prototype.changeVisible=function(t){e.prototype.changeVisible.call(this,t);for(var i=this.elements,n=0,a=i.length;n<a;n++){var o=i[n];o.changeVisible(t)}t?(this.container&&this.container.show(),this.labelsContainer&&this.labelsContainer.show()):(this.container&&this.container.hide(),this.labelsContainer&&this.labelsContainer.hide())},r.prototype.getFields=function(){var t=new Map,i=[];return Object.values(this.attributeOption).forEach(function(n){var a=(n==null?void 0:n.fields)||[];a.forEach(function(o){t.has(o)||i.push(o),t.set(o,!0)})},[]),i},r.prototype.getGroupFields=function(){for(var t=[],i=new Map,n=0,a=Qv.length;n<a;n++){var o=Qv[n],l=this.attributeOption[o];l&&l.fields&&Hl(l.fields,t,i)}return t},r.prototype.getXYFields=function(){var t=this.attributeOption.position.fields,i=t[0],n=t[1];return[i,n]},r.prototype.getXField=function(){return I(this.getXYFields(),[0])},r.prototype.getYField=function(){return I(this.getXYFields(),[1])},r.prototype.getShapes=function(){return this.elements.map(function(t){return t.shape})},r.prototype.getOffscreenGroup=function(){if(!this.offscreenGroup){var t=this.container.getGroupBase();this.offscreenGroup=new t({})}return this.offscreenGroup},r.prototype.sort=function(t){if(!this.hasSorted)for(var i=this.getXScale(),n=i.field,a=0;a<t.length;a++){var o=t[a];o.sort(function(l,s){return i.translate(l[de][n])-i.translate(s[de][n])})}this.hasSorted=!0},r.prototype.adjustScale=function(){var t=this.getYScale();t&&this.getAdjust("stack")&&this.updateStackRange(t,this.beforeMappingData)},r.prototype.getShapeFactory=function(){var t=this.shapeType;if(!!TT(t))return this.shapeFactory||(this.shapeFactory=di(TT(t))),this.shapeFactory.coordinate=this.coordinate,this.shapeFactory.theme=this.theme.geometries[t]||{},this.shapeFactory},r.prototype.createShapePointsCfg=function(t){var i=this.getXScale(),n=this.getYScale(),a=this.normalizeValues(t[i.field],i),o;return n?o=this.normalizeValues(t[n.field],n):o=t.y?t.y:.1,{x:a,y:o,y0:n?n.scale(this.getYMinValue()):void 0}},r.prototype.createElement=function(t,i,n){n===void 0&&(n=!1);var a=this.container,o=this.getDrawCfg(t),l=this.getShapeFactory(),s=new DO({shapeFactory:l,container:a,offscreenGroup:this.getOffscreenGroup(),elementIndex:i});return s.animate=this.animateOption,s.geometry=this,s.draw(o,n),s},r.prototype.getDrawCfg=function(t){var i=t[de],n={mappingData:t,data:i,x:t.x,y:t.y,color:t.color,size:t.size,isInCircle:this.coordinate.isPolar,customInfo:this.customOption},a=t.shape;!a&&this.getShapeFactory()&&(a=this.getShapeFactory().defaultShapeType),n.shape=a;var o=this.theme.geometries[this.shapeType];n.defaultStyle=I(o,[a,"default"],{}).style,!n.defaultStyle&&this.getShapeFactory()&&(n.defaultStyle=this.getShapeFactory().getDefaultStyle(o));var l=this.styleOption;return l&&(n.style=this.getStyleCfg(l,i)),this.generatePoints&&(n.points=t.points,n.nextPoints=t.nextPoints),n},r.prototype.updateElements=function(t,i){i===void 0&&(i=!1);for(var n=new Map,a=[],o=new Map,l=0,s=0;s<t.length;s++)for(var u=t[s],c=0;c<u.length;c++){var f=u[c],h=this.getElementId(f),v=n.has(h)?h+"-"+s+"-"+c:h;a.push(v),n.set(v,f),o.set(v,l),l++}this.elements=new Array(l);for(var d=_W(this.lastElementsMap,a),p=d.added,x=d.updated,m=d.removed,_=0,b=p;_<b.length;_++){var h=b[_],f=n.get(h),s=o.get(h),w=this.createElement(f,s,i);this.elements[s]=w,this.elementsMap[h]=w,w.shape&&w.shape.setZIndex(this.zIndexReversed?this.elements.length-s:s)}for(var S=0,M=x;S<M.length;S++){var h=M[S],w=this.lastElementsMap[h],f=n.get(h),F=this.getDrawCfg(f),O=w.getModel(),s=o.get(h);(this.isCoordinateChanged||xW(F,O))&&(w.animate=this.animateOption,w.update(F)),this.elements[s]=w,this.elementsMap[h]=w,w.shape&&w.shape.setZIndex(this.zIndexReversed?this.elements.length-s:s)}for(var L=0,D=m;L<D.length;L++){var h=D[L],w=this.lastElementsMap[h];w.animate=this.animateOption,w.destroy()}},r.prototype.getLabelType=function(){var t=this,i=t.labelOption,n=t.coordinate,a=t.type,o=n.type,l=n.isTransposed,s=I(i,["cfg","type"]);return s||(o==="polar"?s=l?"pie":"polar":o==="theta"?s="pie":a==="interval"||a==="polygon"?s="interval":s="base"),s},r.prototype.getYMinValue=function(){var t=this.getYScale(),i=t.min,n=t.max,a;return i>=0?a=i:n<=0?a=n:a=0,a},r.prototype.createAttrOption=function(t,i,n){if(K(i)||Zt(i))Zt(i)&&Ge(Object.keys(i),["values"])?jt(this.attributeOption,t,{fields:i.values}):jt(this.attributeOption,t,i);else{var a={};Mt(i)?a.values=[i]:a.fields=Ov(i),n&&(pt(n)?a.callback=n:a.values=n),jt(this.attributeOption,t,a)}},r.prototype.initAttributes=function(){var t=this,i=this,n=i.attributes,a=i.attributeOption,o=i.theme,l=i.shapeType;this.groupScales=[];var s={},u=function(h){if(a.hasOwnProperty(h)){var v=a[h];if(!v)return{value:void 0};var d=A({},v),p=d.callback,x=d.values,m=d.fields,_=m===void 0?[]:m,b=_.map(function(S){var M=t.scales[S];return M.isCategory&&!s[S]&&Qv.includes(h)&&(t.groupScales.push(M),s[S]=!0),M});d.scales=b,h!=="position"&&b.length===1&&b[0].type==="identity"?d.values=b[0].values:!p&&!x&&(h==="size"?d.values=o.sizes:h==="shape"?d.values=o.shapes[l]||[]:h==="color"&&(b.length?d.values=b[0].values.length<=10?o.colors10:o.colors20:d.values=o.colors10));var w=BM(h);n[h]=new w(d)}};for(var c in a){var f=u(c);if(typeof f=="object")return f.value}},r.prototype.processData=function(t){this.hasSorted=!1;for(var i=this.getAttribute("position").scales,n=i.filter(function(S){return S.isCategory}),a=this.groupData(t),o=[],l=0,s=a.length;l<s;l++){for(var u=a[l],c=[],f=0,h=u.length;f<h;f++){var v=u[f],d={};for(var p in v)d[p]=v[p];d[de]=v;for(var x=0,m=n;x<m.length;x++){var _=m[x],b=_.field;d[b]=_.translate(d[b])}c.push(d)}o.push(c)}var w=this.adjustData(o);return this.beforeMappingData=w,w},r.prototype.adjustData=function(t){var i=this.adjustOption,n=this,a=n.intervalPadding,o=n.dodgePadding,l=n.theme,s=this.maxColumnWidth||l.maxColumnWidth,u=this.minColumnWidth||l.minColumnWidth,c=this.columnWidthRatio||l.columnWidthRatio,f=t;if(i){var h=this.getXScale(),v=this.getYScale(),d=h.field,p=v?v.field:null,x=hg(this.coordinate),m=h.values.length,_=this.getAttribute("size"),b=void 0;_&&(b=_.values[0]);for(var w=0,S=i.length;w<S;w++){var M=i[w],F=A({xField:d,yField:p,intervalPadding:a,dodgePadding:o,xDimensionLength:x,groupNum:m,defaultSize:b,maxColumnWidth:s,minColumnWidth:u,columnWidthRatio:c},M),O=M.type;if(O==="dodge"){var L=[];if(h.isCategory||h.type==="identity")L.push("x");else if(!v)L.push("y");else throw new Error("dodge is not support linear attribute, please use category attribute!");F.adjustNames=L,F.dodgeRatio=c}else if(O==="stack"){var D=this.coordinate;if(!v){F.height=D.getHeight();var k=this.getDefaultValue("size")||3;F.size=k}!D.isTransposed&&K(F.reverseOrder)&&(F.reverseOrder=!0)}var H=LM(O),B=new H(F);f=B.process(f),this.adjusts[O]=B}}return f},r.prototype.groupData=function(t){for(var i=this.getGroupScales(),n=this.scaleDefs,a={},o=[],l=0;l<i.length;l++){var s=i[l],u=s.field;o.push(u),I(n,[u,"values"])&&(a[u]=n[u].values)}return hbt(t,o,a)},r.prototype.updateStackRange=function(t,i){for(var n=qi(i),a=t.field,o=t.min,l=t.max,s=0;s<n.length;s++){var u=n[s],c=Math.min.apply(null,u[a]),f=Math.max.apply(null,u[a]);c<o&&(o=c),f>l&&(l=f)}var h=this.scaleDefs,v={};o<t.min&&!I(h,[a,"min"])&&(v.min=o),l>t.max&&!I(h,[a,"max"])&&(v.max=l),t.change(v)},r.prototype.beforeMapping=function(t){var i=t;if(this.sortable&&this.sort(i),this.generatePoints)for(var n=0,a=i.length;n<a;n++){var o=i[n];this.generateShapePoints(o);var l=i[n+1];l&&(this.generateShapePoints(l),o[0].nextPoints=l[0].points)}return i},r.prototype.generateShapePoints=function(t){for(var i=this.getShapeFactory(),n=this.getAttribute("shape"),a=0;a<t.length;a++){var o=t[a],l=this.createShapePointsCfg(o),s=n?this.getAttributeValues(n,o):null,u=i.getShapePoints(s,l);o.points=u}},r.prototype.normalizeValues=function(t,i){var n=[];if(it(t))for(var a=0;a<t.length;a++){var o=t[a];n.push(i.scale(o))}else n=i.scale(t);return n},r.prototype.mapping=function(t){for(var i=this.attributes,n=[],a=0;a<t.length;a++){var o=t[a],l={_origin:o[de],points:o.points,nextPoints:o.nextPoints};for(var s in i)if(i.hasOwnProperty(s)){var u=i[s],c=u.names,f=this.getAttributeValues(u,o);if(c.length>1)for(var h=0;h<f.length;h+=1){var v=f[h],d=c[h];l[d]=it(v)&&v.length===1?v[0]:v}else l[c[0]]=f.length===1?f[0]:f}this.convertPoint(l),n.push(l)}return n},r.prototype.convertPoint=function(t){var i=t.x,n=t.y,a,o,l,s=this.coordinate;if(it(i)&&it(n)){a=[],o=[];for(var u=0,c=0,f=i.length,h=n.length;u<f&&c<h;u+=1,c+=1)l=s.convert({x:i[u],y:n[c]}),a.push(l.x),o.push(l.y)}else if(it(n)){o=[];for(var v=0;v<n.length;v++){var d=n[v];l=s.convert({x:i,y:d}),a&&a!==l.x?(it(a)||(a=[a]),a.push(l.x)):a=l.x,o.push(l.y)}}else if(it(i)){a=[];for(var v=0;v<i.length;v++){var p=i[v];l=s.convert({x:p,y:n}),o&&o!==l.y?(it(o)||(o=[o]),o.push(l.y)):o=l.y,a.push(l.x)}}else{var x=s.convert({x:i,y:n});a=x.x,o=x.y}t.x=a,t.y=o},r.prototype.getStyleCfg=function(t,i){var n=t.fields,a=n===void 0?[]:n,o=t.callback,l=t.cfg;if(l)return l;var s=a.map(function(u){return i[u]});return o.apply(void 0,s)},r.prototype.setCfg=function(t){var i=this,n=t.coordinate,a=t.data,o=t.theme,l=t.scaleDefs;n&&(this.coordinate=n),a&&(this.data=a),l&&(this.scaleDefs=l,this.idFields=[],P(l,function(s,u){s&&s.key&&i.idFields.push(u)})),o&&(this.theme=this.userTheme?ft({},o,this.userTheme):o)},r.prototype.renderLabels=function(t,i){i===void 0&&(i=!1);var n=this.geometryLabel;if(!n){var a=this.getLabelType(),o=yW(a);n=new o(this),this.geometryLabel=n}n.render(t,i);var l=n.labelsRenderer.shapesMap;P(this.elementsMap,function(s,u){var c=vbt(u,l);if(c.length){s.labelShape=c;for(var f=0;f<c.length;f++)for(var h=c[f],v=h.getChildren(),d=0;d<v.length;d++){var p=v[d];p.cfg.name=["element","label"],p.cfg.element=s}}})},r.prototype.canDoGroupAnimation=function(t){return!t&&this.animateOption&&(I(this.animateOption,"appear")===void 0||I(this.animateOption,"appear")&&I(this.animateOption,["appear","animation"])===void 0)},r}(wO),M_=rr;function pg(e,r,t){var i=M_(e.getMatrix(),[["t",r,t]]);e.setMatrix(i)}function dbt(e,r){var t=e.attr(),i=t.x,n=t.y,a=M_(e.getMatrix(),[["t",-i,-n],["r",r],["t",i,n]]);return a}function kO(e,r){var t=dbt(e,r);e.setMatrix(t)}function pbt(e,r){var t=e.getBBox(),i=(t.minX+t.maxX)/2,n=(t.minY+t.maxY)/2;e.applyToMatrix([i,n,1]);var a=M_(e.getMatrix(),[["t",-i,-n],["s",r,r],["t",i,n]]);e.setMatrix(a)}function Cs(e){return e.find(function(r){return r.get("type")==="text"})}function MT(e,r,t){t===void 0&&(t=[0,0,0,0]);var i=e.getChildren()[0];if(i){var n=i.clone();r!=null&&r.rotate&&kO(n,-r.rotate);var a=n.getCanvasBBox(),o=a.x,l=a.y,s=a.width,u=a.height;n.destroy();var c=t;return K(c)?c=[2,2,2,2]:Mt(c)&&(c=new Array(4).fill(c)),{x:o-c[3],y:l-c[0],width:s+c[1]+c[3],height:u+c[0]+c[2],rotation:(r==null?void 0:r.rotate)||0}}}function gbt(e,r,t){t===void 0&&(t=0);var i=Math.max(0,Math.min(e.x+e.width+t,r.x+r.width+t)-Math.max(e.x-t,r.x-t)),n=Math.max(0,Math.min(e.y+e.height+t,r.y+r.height+t)-Math.max(e.y-t,r.y-t));return i*n}function ybt(e,r){var t=e.getBBox();return gp(r,function(i){var n=i.getBBox();return gbt(t,n,2)>0})}function bW(e,r,t){var i=t.data,n=t.origin,a=t.animateCfg,o=t.coordinate,l=I(a,"update");e.set("data",i),e.set("origin",n),e.set("animateCfg",a),e.set("coordinate",o),e.set("visible",r.get("visible")),e.getChildren().forEach(function(s,u){var c=r.getChildByIndex(u);if(!c)e.removeChild(s),s.remove(!0);else{s.set("data",i),s.set("origin",n),s.set("animateCfg",a),s.set("coordinate",o);var f=jY(s,c);l?Pf(s,l,{toAttrs:f,coordinate:o}):s.attr(f),c.isGroup()&&bW(s,c,t)}}),P(r.getChildren(),function(s,u){u>=e.getCount()&&(s.destroyed||e.add(s))})}var mbt=function(){function e(r){this.shapesMap={},this.lastShapesMap={};var t=r.layout,i=r.container;this.layout=t,this.container=i}return e.prototype.render=function(r,t,i){var n=this;i===void 0&&(i=!1),this.shapesMap={};var a=this.container,o=this.createOffscreenGroup();if(r.length){for(var l=0,s=r;l<s.length;l++){var u=s[l];u&&this.renderLabel(u,o)}this.doLayout(r,t),this.renderLabelLine(r),this.renderLabelBackground(r),this.adjustLabel(r)}var c=this.lastShapesMap,f=this.shapesMap;P(f,function(h,v){if(h.destroyed)delete f[v];else{if(c[v]){var d=h.get("data"),p=h.get("origin"),x=h.get("coordinate"),m=h.get("animateCfg"),_=c[v];bW(_,f[v],{data:d,origin:p,animateCfg:m,coordinate:x}),n.shapesMap[v]=_}else{a.add(h);var b=I(h.get("animateCfg"),i?"enter":"appear");b&&Pf(h,b,{toAttrs:A({},h.attr()),coordinate:h.get("coordinate")})}delete c[v]}}),P(c,function(h){var v=I(h.get("animateCfg"),"leave");v?Pf(h,v,{toAttrs:null,coordinate:h.get("coordinate")}):h.remove(!0)}),this.lastShapesMap=f,o.destroy()},e.prototype.clear=function(){this.container.clear(),this.shapesMap={},this.lastShapesMap={}},e.prototype.destroy=function(){this.container.destroy(),this.shapesMap=null,this.lastShapesMap=null},e.prototype.renderLabel=function(r,t){var i=r.id,n=r.elementId,a=r.data,o=r.mappingData,l=r.coordinate,s=r.animate,u=r.content,c={id:i,elementId:n,data:a,origin:A(A({},o),{data:o[de]}),coordinate:l},f=t.addGroup(A({name:"label",animateCfg:this.animate===!1||s===null||s===!1?!1:ft({},this.animate,s)},c)),h;if(u.isGroup&&u.isGroup()||u.isShape&&u.isShape()){var v=u.getCanvasBBox(),d=v.width,p=v.height,x=I(r,"textAlign","left"),m=r.x,_=r.y-p/2;x==="center"?m=m-d/2:(x==="right"||x==="end")&&(m=m-d),pg(u,m,_),h=u,f.add(u)}else{var b=I(r,["style","fill"]);h=f.addShape("text",A({attrs:A(A({x:r.x,y:r.y,textAlign:r.textAlign,textBaseline:I(r,"textBaseline","middle"),text:r.content},r.style),{fill:JG(b)?r.color:b})},c))}r.rotate&&kO(h,r.rotate),this.shapesMap[i]=f},e.prototype.doLayout=function(r,t){var i=this;if(this.layout){var n=it(this.layout)?this.layout:[this.layout];P(n,function(a){var o=mW(I(a,"type",""));if(o){var l=[],s=[];P(i.shapesMap,function(u,c){l.push(u),s.push(t[u.get("elementId")])}),o(r,l,s,i.region,a.cfg)}})}},e.prototype.renderLabelLine=function(r){var t=this;P(r,function(i){var n=I(i,"coordinate");if(!(!i||!n)){var a=n.getCenter(),o=n.getRadius();if(!!i.labelLine){var l=I(i,"labelLine",{}),s=i.id,u=l.path;if(!u){var c=ir(a.x,a.y,o,i.angle);u=[["M",c.x,c.y],["L",i.x,i.y]]}var f=t.shapesMap[s];f.destroyed||f.addShape("path",{capture:!1,attrs:A({path:u,stroke:i.color?i.color:I(i,["style","fill"],"#000"),fill:null},l.style),id:s,origin:i.mappingData,data:i.data,coordinate:i.coordinate})}}})},e.prototype.renderLabelBackground=function(r){var t=this;P(r,function(i){var n=I(i,"coordinate"),a=I(i,"background");if(!(!a||!n)){var o=i.id,l=t.shapesMap[o];if(!l.destroyed){var s=l.getChildren()[0];if(s){var u=MT(l,i,a.padding),c=u.rotation,f=ue(u,["rotation"]),h=l.addShape("rect",{attrs:A(A({},f),a.style||{}),id:o,origin:i.mappingData,data:i.data,coordinate:i.coordinate});if(h.setZIndex(-1),c){var v=s.getMatrix();h.setMatrix(v)}}}}})},e.prototype.createOffscreenGroup=function(){var r=this.container,t=r.getGroupBase(),i=new t({});return i},e.prototype.adjustLabel=function(r){var t=this;P(r,function(i){if(i){var n=i.id,a=t.shapesMap[n];if(!a.destroyed){var o=a.findAll(function(l){return l.get("type")!=="path"});P(o,function(l){l&&(i.offsetX&&l.attr("x",l.attr("x")+i.offsetX),i.offsetY&&l.attr("y",l.attr("y")+i.offsetY))})}}})},e}();function yB(e){var r=0;return P(e,function(t){r+=t}),r/e.length}var gg=function(){function e(r){this.geometry=r}return e.prototype.getLabelItems=function(r){var t=this,i=[],n=this.getLabelCfgs(r);return P(r,function(a,o){var l=n[o];if(!l||K(a.x)||K(a.y)){i.push(null);return}var s=it(l.content)?l.content:[l.content];l.content=s;var u=s.length;P(s,function(c,f){if(K(c)||c===""){i.push(null);return}var h=A(A({},l),t.getLabelPoint(l,a,f));h.textAlign||(h.textAlign=t.getLabelAlign(h,f,u)),h.offset<=0&&(h.labelLine=null),i.push(h)})}),i},e.prototype.render=function(r,t){t===void 0&&(t=!1);var i=this.getLabelItems(r),n=this.getLabelsRenderer(),a=this.getGeometryShapes();n.render(i,a,t)},e.prototype.clear=function(){var r=this.labelsRenderer;r&&r.clear()},e.prototype.destroy=function(){var r=this.labelsRenderer;r&&r.destroy(),this.labelsRenderer=null},e.prototype.getCoordinate=function(){return this.geometry.coordinate},e.prototype.getDefaultLabelCfg=function(r,t){var i=this.geometry,n=i.type,a=i.theme;return n==="polygon"||n==="interval"&&t==="middle"||r<0&&!["line","point","path"].includes(n)?I(a,"innerLabels",{}):I(a,"labels",{})},e.prototype.getThemedLabelCfg=function(r){var t=this.geometry,i=this.getDefaultLabelCfg(),n=t.type,a=t.theme,o;return n==="polygon"||r.offset<0&&!["line","point","path"].includes(n)?o=ft({},i,a.innerLabels,r):o=ft({},i,a.labels,r),o},e.prototype.setLabelPosition=function(r,t,i,n){},e.prototype.getLabelOffset=function(r){var t=this.getCoordinate(),i=this.getOffsetVector(r);return t.isTransposed?i[0]:i[1]},e.prototype.getLabelOffsetPoint=function(r,t,i){var n=r.offset,a=this.getCoordinate(),o=a.isTransposed,l=o?"x":"y",s=o?1:-1,u={x:0,y:0};return t>0||i===1?u[l]=n*s:u[l]=n*s*-1,u},e.prototype.getLabelPoint=function(r,t,i){var n=this.getCoordinate(),a=r.content.length;function o(x,m,_){_===void 0&&(_=!1);var b=x;return it(b)&&(r.content.length===1?_?b=yB(b):b.length<=2?b=b[x.length-1]:b=yB(b):b=b[m]),b}var l={content:r.content[i],x:0,y:0,start:{x:0,y:0},color:"#fff"},s=it(t.shape)?t.shape[0]:t.shape,u=s==="funnel"||s==="pyramid";if(this.geometry.type==="polygon"){var c=u_t(t.x,t.y);l.x=c[0],l.y=c[1]}else this.geometry.type==="interval"&&!u?(l.x=o(t.x,i,!0),l.y=o(t.y,i)):(l.x=o(t.x,i),l.y=o(t.y,i));if(u){var f=I(t,"nextPoints"),h=I(t,"points");if(f){var v=n.convert(h[1]),d=n.convert(f[1]);l.x=(v.x+d.x)/2,l.y=(v.y+d.y)/2}else if(s==="pyramid"){var v=n.convert(h[1]),d=n.convert(h[2]);l.x=(v.x+d.x)/2,l.y=(v.y+d.y)/2}}r.position&&this.setLabelPosition(l,t,i,r.position);var p=this.getLabelOffsetPoint(r,i,a);return l.start={x:l.x,y:l.y},l.x+=p.x,l.y+=p.y,l.color=t.color,l},e.prototype.getLabelAlign=function(r,t,i){var n="center",a=this.getCoordinate();if(a.isTransposed){var o=r.offset;o<0?n="right":o===0?n="center":n="left",i>1&&t===0&&(n==="right"?n="left":n==="left"&&(n="right"))}return n},e.prototype.getLabelId=function(r){var t=this.geometry,i=t.type,n=t.getXScale(),a=t.getYScale(),o=r[de],l=t.getElementId(r);return i==="line"||i==="area"?l+=" "+o[n.field]:i==="path"&&(l+=" "+o[n.field]+"-"+o[a.field]),l},e.prototype.getLabelsRenderer=function(){var r=this.geometry,t=r.labelsContainer,i=r.labelOption,n=r.canvasRegion,a=r.animateOption,o=this.geometry.coordinate,l=this.labelsRenderer;return l||(l=new mbt({container:t,layout:I(i,["cfg","layout"],{type:this.defaultLayout})}),this.labelsRenderer=l),l.region=n,l.animate=a?dW("label",o):!1,l},e.prototype.getLabelCfgs=function(r){var t=this,i=this.geometry,n=i.labelOption,a=i.scales,o=i.coordinate,l=n,s=l.fields,u=l.callback,c=l.cfg,f=s.map(function(v){return a[v]}),h=[];return P(r,function(v,d){var p=v[de],x=t.getLabelText(p,f),m;if(u){var _=s.map(function(F){return p[F]});if(m=u.apply(void 0,_),K(m)){h.push(null);return}}var b=A(A({id:t.getLabelId(v),elementId:t.geometry.getElementId(v),data:p,mappingData:v,coordinate:o},c),m);pt(b.position)&&(b.position=b.position(p,v,d));var w=t.getLabelOffset(b.offset||0),S=t.getDefaultLabelCfg(w,b.position);b=ft({},S,b),b.offset=t.getLabelOffset(b.offset||0);var M=b.content;pt(M)?b.content=M(p,v,d):Yl(M)&&(b.content=x[0]),h.push(b)}),h},e.prototype.getLabelText=function(r,t){var i=[];return P(t,function(n){var a=r[n.field];it(a)?a=a.map(function(o){return n.getText(o)}):a=n.getText(a),K(a)||a===""?i.push(null):i.push(a)}),i},e.prototype.getOffsetVector=function(r){r===void 0&&(r=0);var t=this.getCoordinate(),i=0;return Mt(r)&&(i=r),t.isTransposed?t.applyMatrix(i,0):t.applyMatrix(0,i)},e.prototype.getGeometryShapes=function(){var r=this.geometry,t={};return P(r.elementsMap,function(i,n){t[n]=i.shape}),P(r.getOffscreenGroup().getChildren(),function(i){var n=r.getElementId(i.get("origin").mappingData);t[n]=i}),t},e}();function ET(e,r,t){if(!e)return t;var i;if(e.callback&&e.callback.length>1){var n=Array(e.callback.length-1).fill("");i=e.mapping.apply(e,Qr([r],n,!1)).join("")}else i=e.mapping(r).join("");return i||t}var tc={hexagon:function(e,r,t){var i=t/2*Math.sqrt(3);return[["M",e,r-t],["L",e+i,r-t/2],["L",e+i,r+t/2],["L",e,r+t],["L",e-i,r+t/2],["L",e-i,r-t/2],["Z"]]},bowtie:function(e,r,t){var i=t-1.5;return[["M",e-t,r-i],["L",e+t,r+i],["L",e+t,r-i],["L",e-t,r+i],["Z"]]},cross:function(e,r,t){return[["M",e-t,r-t],["L",e+t,r+t],["M",e+t,r-t],["L",e-t,r+t]]},tick:function(e,r,t){return[["M",e-t/2,r-t],["L",e+t/2,r-t],["M",e,r-t],["L",e,r+t],["M",e-t/2,r+t],["L",e+t/2,r+t]]},plus:function(e,r,t){return[["M",e-t,r],["L",e+t,r],["M",e,r-t],["L",e,r+t]]},hyphen:function(e,r,t){return[["M",e-t,r],["L",e+t,r]]},line:function(e,r,t){return[["M",e,r-t],["L",e,r+t]]}},xbt=["line","cross","tick","plus","hyphen"];function _bt(e,r){return pt(r)?r(e):ft({},e,r)}function bbt(e,r){var t=e.symbol;if(Ct(t)&&xbt.indexOf(t)!==-1){var i=I(e,"style",{}),n=I(i,"lineWidth",1),a=i.stroke||i.fill||r;e.style=ft({},e.style,{lineWidth:n,stroke:a,fill:null})}}function wW(e){var r=e.symbol;Ct(r)&&tc[r]&&(e.symbol=tc[r])}function wS(e){return e.startsWith(ct.LEFT)||e.startsWith(ct.RIGHT)?"vertical":"horizontal"}function CW(e,r,t,i,n){var a=t.getScale(t.type);if(a.isCategory){var o=a.field,l=r.getAttribute("color"),s=r.getAttribute("shape"),u=e.getTheme().defaultColor,c=r.coordinate.isPolar;return a.getTicks().map(function(f,h){var v,d=f.text,p=f.value,x=d,m=a.invert(p),_=e.filterFieldData(o,[(v={},v[o]=m,v)]).length===0;P(e.views,function(F){var O;F.filterFieldData(o,[(O={},O[o]=m,O)]).length||(_=!0)});var b=ET(l,m,u),w=ET(s,m,"point"),S=r.getShapeMarker(w,{color:b,isInPolar:c}),M=n;return pt(M)&&(M=M(x,h,A({name:x,value:m},ft({},i,S)))),S=ft({},i,S,Gi(A({},M),["style"])),bbt(S,b),M&&M.style&&(S.style=_bt(S.style,M.style)),wW(S),{id:m,name:x,value:m,marker:S,unchecked:_}})}return[]}function wbt(e,r,t){return t.map(function(i,n){var a=r;pt(a)&&(a=a(i.name,n,ft({},e,i)));var o=pt(i.marker)?i.marker(i.name,n,ft({},e,i)):i.marker,l=ft({},e,a,o);return wW(l),i.marker=l,i})}function mB(e,r){var t=I(e,["components","legend"],{});return ft({},I(t,["common"],{}),ft({},I(t,[r],{})))}var Cbt="4.1.32",Fi={getLegendItems:CW,translate:pg,rotate:kO,zoom:pbt,transform:M_,getAngle:rp,getSectorPath:es,polarToCartesian:ir,getDelegationObject:Jf,getTooltipItems:MO,getMappingValue:ET},lu={100:"#000",95:"#0D0D0D",85:"#262626",65:"#595959",45:"#8C8C8C",25:"#BFBFBF",15:"#D9D9D9",6:"#F0F0F0"},he={100:"#FFFFFF",95:"#F2F2F2",85:"#D9D9D9",65:"#A6A6A6",45:"#737373",25:"#404040",15:"#262626",6:"#0F0F0F"},fa=["#5B8FF9","#5AD8A6","#5D7092","#F6BD16","#E86452","#6DC8EC","#945FB9","#FF9845","#1E9493","#FF99C3"],Sbt=["#5B8FF9","#CDDDFD","#5AD8A6","#CDF3E4","#5D7092","#CED4DE","#F6BD16","#FCEBB9","#E86452","#F8D0CB","#6DC8EC","#D3EEF9","#945FB9","#DECFEA","#FF9845","#FFE0C7","#1E9493","#BBDEDE","#FF99C3","#FFE0ED"],Abt=["#B8E1FF","#9AC5FF","#7DAAFF","#5B8FF9","#3D76DD","#085EC0","#0047A5","#00318A","#001D70"],Tbt=function(e){e===void 0&&(e={});var r=e.backgroundColor,t=r===void 0?"#141414":r,i=e.subColor,n=i===void 0?"rgba(255,255,255,0.05)":i,a=e.paletteQualitative10,o=a===void 0?fa:a,l=e.paletteQualitative20,s=l===void 0?Sbt:l,u=e.paletteSemanticRed,c=u===void 0?"#F4664A":u,f=e.paletteSemanticGreen,h=f===void 0?"#30BF78":f,v=e.paletteSemanticYellow,d=v===void 0?"#FAAD14":v,p=e.paletteSequence,x=p===void 0?Abt:p,m=e.fontFamily,_=m===void 0?`"Segoe UI", Roboto, "Helvetica Neue", Arial,
|
|
"Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol",
|
|
"Noto Color Emoji"`:m,b=e.brandColor,w=b===void 0?o[0]:b;return{backgroundColor:t,brandColor:w,subColor:n,paletteQualitative10:o,paletteQualitative20:s,paletteSemanticRed:c,paletteSemanticGreen:h,paletteSemanticYellow:d,paletteSequence:x,fontFamily:_,axisLineBorderColor:he[25],axisLineBorder:1,axisLineDash:null,axisTitleTextFillColor:he[65],axisTitleTextFontSize:12,axisTitleTextLineHeight:12,axisTitleTextFontWeight:"normal",axisTitleSpacing:12,axisTickLineBorderColor:he[25],axisTickLineLength:4,axisTickLineBorder:1,axisSubTickLineBorderColor:he[15],axisSubTickLineLength:2,axisSubTickLineBorder:1,axisLabelFillColor:he[45],axisLabelFontSize:12,axisLabelLineHeight:12,axisLabelFontWeight:"normal",axisLabelOffset:8,axisGridBorderColor:he[15],axisGridBorder:1,axisGridLineDash:null,legendTitleTextFillColor:he[45],legendTitleTextFontSize:12,legendTitleTextLineHeight:21,legendTitleTextFontWeight:"normal",legendMarkerColor:fa[0],legendMarkerSpacing:8,legendMarkerSize:4,legendCircleMarkerSize:4,legendSquareMarkerSize:4,legendLineMarkerSize:5,legendItemNameFillColor:he[65],legendItemNameFontSize:12,legendItemNameLineHeight:12,legendItemNameFontWeight:"normal",legendItemSpacing:24,legendItemMarginBottom:12,legendSpacing:16,legendPadding:[8,8,8,8],legendHorizontalPadding:[8,0,8,0],legendVerticalPadding:[0,8,0,8],legendPageNavigatorMarkerSize:12,legendPageNavigatorMarkerInactiveFillColor:he[45],legendPageNavigatorMarkerInactiveFillOpacity:.45,legendPageNavigatorMarkerFillColor:he[45],legendPageNavigatorMarkerFillOpacity:1,legendPageNavigatorTextFillColor:he[65],legendPageNavigatorTextFontSize:12,sliderRailFillColor:he[15],sliderRailBorder:0,sliderRailBorderColor:null,sliderRailWidth:100,sliderRailHeight:12,sliderLabelTextFillColor:he[45],sliderLabelTextFontSize:12,sliderLabelTextLineHeight:12,sliderLabelTextFontWeight:"normal",sliderHandlerFillColor:lu[6],sliderHandlerWidth:10,sliderHandlerHeight:14,sliderHandlerBorder:1,sliderHandlerBorderColor:lu[25],annotationArcBorderColor:he[15],annotationArcBorder:1,annotationLineBorderColor:he[25],annotationLineBorder:1,annotationLineDash:null,annotationTextFillColor:he[65],annotationTextFontSize:12,annotationTextLineHeight:12,annotationTextFontWeight:"normal",annotationTextBorderColor:null,annotationTextBorder:0,annotationRegionFillColor:he[100],annotationRegionFillOpacity:.06,annotationRegionBorder:0,annotationRegionBorderColor:null,annotationDataMarkerLineLength:16,tooltipCrosshairsBorderColor:he[25],tooltipCrosshairsBorder:1,tooltipCrosshairsLineDash:null,tooltipContainerFillColor:"#1f1f1f",tooltipContainerFillOpacity:.95,tooltipContainerShadow:"0px 2px 4px rgba(0,0,0,.5)",tooltipContainerBorderRadius:3,tooltipTextFillColor:he[65],tooltipTextFontSize:12,tooltipTextLineHeight:12,tooltipTextFontWeight:"bold",labelFillColor:he[65],labelFillColorDark:"#2c3542",labelFillColorLight:"#ffffff",labelFontSize:12,labelLineHeight:12,labelFontWeight:"normal",labelBorderColor:null,labelBorder:0,innerLabelFillColor:lu[100],innerLabelFontSize:12,innerLabelLineHeight:12,innerLabelFontWeight:"normal",innerLabelBorderColor:null,innerLabelBorder:0,overflowLabelFillColor:he[65],overflowLabelFillColorDark:"#2c3542",overflowLabelFillColorLight:"#ffffff",overflowLabelFontSize:12,overflowLabelLineHeight:12,overflowLabelFontWeight:"normal",overflowLabelBorderColor:lu[100],overflowLabelBorder:1,labelLineBorder:1,labelLineBorderColor:he[25],cSliderRailHieght:16,cSliderBackgroundFillColor:"#416180",cSliderBackgroundFillOpacity:.05,cSliderForegroundFillColor:"#5B8FF9",cSliderForegroundFillOpacity:.15,cSliderHandlerHeight:24,cSliderHandlerWidth:10,cSliderHandlerFillColor:"#F7F7F7",cSliderHandlerFillOpacity:1,cSliderHandlerHighlightFillColor:"#FFF",cSliderHandlerBorderColor:"#BFBFBF",cSliderHandlerBorder:1,cSliderHandlerBorderRadius:2,cSliderTextFillColor:"#fff",cSliderTextFillOpacity:.45,cSliderTextFontSize:12,cSliderTextLineHeight:12,cSliderTextFontWeight:"normal",cSliderTextBorderColor:null,cSliderTextBorder:0,scrollbarTrackFillColor:"rgba(255,255,255,0.65)",scrollbarThumbFillColor:"rgba(0,0,0,0.35)",scrollbarThumbHighlightFillColor:"rgba(0,0,0,0.45)",pointFillColor:fa[0],pointFillOpacity:.95,pointSize:4,pointBorder:1,pointBorderColor:lu[100],pointBorderOpacity:1,pointActiveBorderColor:he[100],pointSelectedBorder:2,pointSelectedBorderColor:he[100],pointInactiveFillOpacity:.3,pointInactiveBorderOpacity:.3,hollowPointSize:4,hollowPointBorder:1,hollowPointBorderColor:fa[0],hollowPointBorderOpacity:.95,hollowPointFillColor:lu[100],hollowPointActiveBorder:1,hollowPointActiveBorderColor:he[100],hollowPointActiveBorderOpacity:1,hollowPointSelectedBorder:2,hollowPointSelectedBorderColor:he[100],hollowPointSelectedBorderOpacity:1,hollowPointInactiveBorderOpacity:.3,lineBorder:2,lineBorderColor:fa[0],lineBorderOpacity:1,lineActiveBorder:3,lineSelectedBorder:3,lineInactiveBorderOpacity:.3,areaFillColor:fa[0],areaFillOpacity:.25,areaActiveFillColor:fa[0],areaActiveFillOpacity:.5,areaSelectedFillColor:fa[0],areaSelectedFillOpacity:.5,areaInactiveFillOpacity:.3,hollowAreaBorderColor:fa[0],hollowAreaBorder:2,hollowAreaBorderOpacity:1,hollowAreaActiveBorder:3,hollowAreaActiveBorderColor:he[100],hollowAreaSelectedBorder:3,hollowAreaSelectedBorderColor:he[100],hollowAreaInactiveBorderOpacity:.3,intervalFillColor:fa[0],intervalFillOpacity:.95,intervalActiveBorder:1,intervalActiveBorderColor:he[100],intervalActiveBorderOpacity:1,intervalSelectedBorder:2,intervalSelectedBorderColor:he[100],intervalSelectedBorderOpacity:1,intervalInactiveBorderOpacity:.3,intervalInactiveFillOpacity:.3,hollowIntervalBorder:2,hollowIntervalBorderColor:fa[0],hollowIntervalBorderOpacity:1,hollowIntervalFillColor:lu[100],hollowIntervalActiveBorder:2,hollowIntervalActiveBorderColor:he[100],hollowIntervalSelectedBorder:3,hollowIntervalSelectedBorderColor:he[100],hollowIntervalSelectedBorderOpacity:1,hollowIntervalInactiveBorderOpacity:.3}},Mbt=Tbt();function CS(e){return e?!1:e==null||isNaN(e)}function xB(e){if(it(e))return CS(e[1].y);var r=e.y;return it(r)?CS(r[0]):CS(r)}function RO(e,r,t){if(r===void 0&&(r=!1),t===void 0&&(t=!0),!e.length||e.length===1&&!t)return[];if(r){for(var i=[],n=0,a=e.length;n<a;n++){var o=e[n];xB(o)||i.push(o)}return[i]}for(var l=[],s=[],n=0,a=e.length;n<a;n++){var o=e[n];xB(o)?s.length&&(s.length===1&&!t||l.push(s),s=[]):s.push(o)}return s.length&&l.push(s),l}function SW(e){for(var r=[],t=0;t<e.length;t++){var i=e[t];if(i){var n=t===0?"M":"L";r.push([n,i.x,i.y])}}var a=e[0];return a&&(r.push(["L",a.x,a.y]),r.push(["z"])),r}function AW(e){for(var r=e.length/2,t=[],i=[],n=0;n<e.length;n++)n<r?t.push(e[n]):i.push(e[n]);var a=bx(t,!1),o=bx(i,!1);i.length&&a.push(["L",i[0].x,i[0].y]),o.shift();var l=a.concat(o);return t.length&&l.push(["L",t[0].x,t[0].y]),l.push(["z"]),l}function Ze(e,r,t,i){i===void 0&&(i="");var n=e.style,a=n===void 0?{}:n,o=e.defaultStyle,l=e.color,s=e.size,u=A(A({},o),a);return l&&(r&&(a.stroke||(u.stroke=l)),t&&(a.fill||(u.fill=l))),i&&K(a[i])&&!K(s)&&(u[i]=s),u}function TW(e){return ft({},{fill:"#CCD6EC",fillOpacity:.3},I(e,["background","style"]))}function BO(e){var r=e.x,t=it(e.y)?e.y:[e.y];return t.map(function(i,n){return{x:it(r)?r[n]:r,y:i}})}var Ebt={line:function(e,r,t){return[["M",e-t,r],["L",e+t,r]]},dot:function(e,r,t){return[["M",e-t,r],["L",e+t,r]]},dash:function(e,r,t){return[["M",e-t,r],["L",e+t,r]]},smooth:function(e,r,t){return[["M",e-t,r],["A",t/2,t/2,0,1,1,e,r],["A",t/2,t/2,0,1,0,e+t,r]]},hv:function(e,r,t){return[["M",e-t-1,r-2.5],["L",e,r-2.5],["L",e,r+2.5],["L",e+t+1,r+2.5]]},vh:function(e,r,t){return[["M",e-t-1,r+2.5],["L",e,r+2.5],["L",e,r-2.5],["L",e+t+1,r-2.5]]},hvh:function(e,r,t){return[["M",e-(t+1),r+2.5],["L",e-t/2,r+2.5],["L",e-t/2,r-2.5],["L",e+t/2,r-2.5],["L",e+t/2,r+2.5],["L",e+t+1,r+2.5]]},vhv:function(e,r){return[["M",e-5,r+2.5],["L",e-5,r],["L",e,r],["L",e,r-3],["L",e,r+3],["L",e+6.5,r+3]]}};function MW(e,r){var t=e.color;return{symbol:Ebt[r],style:{lineWidth:2,r:6,stroke:t}}}function Fbt(e,r,t){for(var i=e.isStack,n=e.connectNulls,a=e.isInCircle,o=e.showSinglePoint,l=Ze(e,!0,!1,"lineWidth"),s=RO(e.points,n,o),u=[],c=0,f=s.length;c<f;c++){var h=s[c];u=u.concat(Pbt(h,a,i,r,t,l))}return l.path=u,l}function FT(e,r,t,i,n){if(e.length===1)return[["M",e[0].x,e[0].y-n.lineWidth/2],["L",e[0].x,e[0].y],["L",e[0].x,e[0].y+n.lineWidth/2]];var a;return t?(r&&e.length&&e.push({x:e[0].x,y:e[0].y}),a=bx(e,!1,i)):(a=dg(e,!1),r&&a.push(["Z"])),a}function Obt(e,r,t,i,n,a){var o=[],l=[];P(e,function(c){var f=BO(c);o.push(f[1]),l.push(f[0])});var s=FT(o,r,i,n,a),u=FT(l,r,i,n,a);return t?s:s.concat(u)}function Pbt(e,r,t,i,n,a){if(e.length){var o=e[0];return it(o.y)?Obt(e,r,t,i,n,a):FT(e,r,i,n,a)}return[]}fl("line",{defaultShapeType:"line"});P(["line","dot","dash","smooth"],function(e){te("line",e,{draw:function(r,t){var i=e==="smooth",n;if(i){var a=this.coordinate,o=a.start,l=a.end;n=[[o.x,l.y],[l.x,o.y]]}var s=Fbt(r,i,n),u=t.addShape({type:"path",attrs:s,name:"line",capture:!i});return u},getMarker:function(r){return MW(r,e)}})});var NO=function(e){X(r,e);function r(t){var i=e.call(this,t)||this;i.type="path",i.shapeType="line";var n=t.connectNulls,a=n===void 0?!1:n,o=t.showSinglePoint,l=o===void 0?!0:o;return i.connectNulls=a,i.showSinglePoint=l,i}return r.prototype.updateElements=function(t,i){i===void 0&&(i=!1);for(var n=new Map,a=new Map,o=[],l=0,s=0;s<t.length;s++){var u=t[s],c=this.getElementId(u);o.push(c),n.set(c,u),a.set(c,l),l++}this.elements=new Array(l);for(var f=_W(this.lastElementsMap,o),h=f.added,v=f.updated,d=f.removed,p=0,x=h;p<x.length;p++){var c=x[p],u=n.get(c),m=this.getShapeFactory(),_=this.getShapeInfo(u),s=a.get(c),b=new DO({shapeFactory:m,container:this.container,offscreenGroup:this.getOffscreenGroup(),elementIndex:s});b.geometry=this,b.animate=this.animateOption,b.draw(_,i),this.elementsMap[c]=b,this.elements[s]=b}for(var w=0,S=v;w<S.length;w++){var c=S[w],u=n.get(c),b=this.lastElementsMap[c],s=a.get(c),_=this.getShapeInfo(u),M=b.getModel();(this.isCoordinateChanged||xW(M,_))&&(b.animate=this.animateOption,b.update(_)),this.elementsMap[c]=b,this.elements[s]=b}for(var F=0,O=d;F<O.length;F++){var c=O[F],b=this.lastElementsMap[c];b.animate=this.animateOption,b.destroy()}},r.prototype.getPointsAndData=function(t){for(var i=[],n=[],a=0,o=t.length;a<o;a++){var l=t[a];i.push({x:l.x,y:l.y}),n.push(l[de])}return{points:i,data:n}},r.prototype.getShapeInfo=function(t){var i=this.getDrawCfg(t[0]),n=this.getPointsAndData(t),a=n.points,o=n.data;return i.mappingData=t,i.data=o,i.isStack=!!this.getAdjust("stack"),i.points=a,i.connectNulls=this.connectNulls,i.showSinglePoint=this.showSinglePoint,i},r}(hl);function Ibt(e,r,t,i,n){var a=[];if(e.length){for(var o=[],l=[],s=0,u=e.length;s<u;s++){var c=e[s];o.push(c[1]),l.push(c[0])}l=l.reverse(),P([o,l],function(f,h){var v=[],d=i.parsePoints(f),p=d[0];o.length===1&&l.length===1?v=h===0?[["M",p.x-.5,p.y],["L",p.x+.5,p.y]]:[["L",p.x+.5,p.y],["L",p.x-.5,p.y]]:(r&&d.push({x:p.x,y:p.y}),t?v=bx(d,!1,n):v=dg(d,!1),h>0&&(v[0][0]="L")),a=a.concat(v)}),a.push(["Z"])}return a}function E_(e,r,t,i,n){for(var a=Ze(e,r,!r,"lineWidth"),o=e.connectNulls,l=e.isInCircle,s=e.points,u=e.showSinglePoint,c=RO(s,o,u),f=[],h=0,v=c.length;h<v;h++){var d=c[h];f=f.concat(Ibt(d,l,t,i,n))}return a.path=f,a}function EW(e){var r=e.start,t=e.end;return[[r.x,t.y],[t.x,r.y]]}fl("area",{defaultShapeType:"area",getDefaultPoints:function(e){var r=e.x,t=e.y0,i=it(e.y)?e.y:[t,e.y];return i.map(function(n){return{x:r,y:n}})}});te("area","area",{draw:function(e,r){var t=E_(e,!1,!1,this),i=r.addShape({type:"path",attrs:t,name:"area"});return i},getMarker:function(e){var r=e.color;return{symbol:function(t,i,n){return n===void 0&&(n=5.5),[["M",t-n,i-4],["L",t+n,i-4],["L",t+n,i+4],["L",t-n,i+4],["Z"]]},style:{r:5,fill:r}}}});var Lbt=function(e){X(r,e);function r(t){var i=e.call(this,t)||this;i.type="area",i.shapeType="area",i.generatePoints=!0,i.startOnZero=!0;var n=t.startOnZero,a=n===void 0?!0:n,o=t.sortable,l=o===void 0?!1:o,s=t.showSinglePoint,u=s===void 0?!1:s;return i.startOnZero=a,i.sortable=l,i.showSinglePoint=u,i}return r.prototype.getPointsAndData=function(t){for(var i=[],n=[],a=0,o=t.length;a<o;a++){var l=t[a];i.push(l.points),n.push(l[de])}return{points:i,data:n}},r.prototype.getYMinValue=function(){if(this.startOnZero)return e.prototype.getYMinValue.call(this);var t=this.getYScale();return t.min},r}(NO);fl("edge",{defaultShapeType:"line",getDefaultPoints:function(e){return BO(e)}});te("edge","line",{draw:function(e,r){var t=Ze(e,!0,!1,"lineWidth"),i=dg(this.parsePoints(e.points),this.coordinate.isPolar);return r.addShape("path",{attrs:A(A({},t),{path:i})})},getMarker:function(e){return{symbol:"circle",style:{r:4.5,fill:e.color}}}});var Dbt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="edge",t.shapeType="edge",t.generatePoints=!0,t}return r}(hl),$bt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="heatmap",t.paletteCache={},t}return r.prototype.updateElements=function(t,i){for(var n=0;n<t.length;n++){var a=t[n],o=this.prepareRange(a),l=this.prepareSize(),s=I(this.styleOption,["cfg","shadowBlur"]);Mt(s)||(s=l/2),this.prepareGreyScaleBlurredCircle(l,s),this.drawWithRange(a,o,l,s)}},r.prototype.color=function(t,i){return this.createAttrOption("color",t,typeof i!="function"?i:""),this},r.prototype.clear=function(){e.prototype.clear.call(this),this.clearShadowCanvasCtx(),this.paletteCache={}},r.prototype.prepareRange=function(t){var i=this.getAttribute("color"),n=i.getFields()[0],a=1/0,o=-1/0;return t.forEach(function(l){var s=l[de][n];s>o&&(o=s),s<a&&(a=s)}),a===o&&(a=o-1),[a,o]},r.prototype.prepareSize=function(){var t=this.getDefaultValue("size");return Mt(t)||(t=this.getDefaultSize()),t},r.prototype.prepareGreyScaleBlurredCircle=function(t,i){var n=this.getGrayScaleBlurredCanvas(),a=t+i,o=n.getContext("2d");n.width=n.height=a*2,o.clearRect(0,0,n.width,n.height),o.shadowOffsetX=o.shadowOffsetY=a*2,o.shadowBlur=i,o.shadowColor="black",o.beginPath(),o.arc(-a,-a,t,0,Math.PI*2,!0),o.closePath(),o.fill()},r.prototype.drawWithRange=function(t,i,n,a){var o=this.coordinate,l=o.start,s=o.end,u=this.coordinate.getWidth(),c=this.coordinate.getHeight(),f=this.getAttribute("color"),h=f.getFields()[0];this.clearShadowCanvasCtx();var v=this.getShadowCanvasCtx();i&&(t=t.filter(function(O){return O[de][h]<=i[1]&&O[de][h]>=i[0]}));for(var d=this.scales[h],p=0,x=t;p<x.length;p++){var m=x[p],_=this.getDrawCfg(m),b=_.x,w=_.y,S=d.scale(m[de][h]);this.drawGrayScaleBlurredCircle(b-l.x,w-s.y,n+a,S,v)}var M=v.getImageData(0,0,u,c);this.clearShadowCanvasCtx(),this.colorize(M),v.putImageData(M,0,0);var F=this.getImageShape();F.attr("x",l.x),F.attr("y",s.y),F.attr("width",u),F.attr("height",c),F.attr("img",v.canvas),F.set("origin",this.getShapeInfo(t))},r.prototype.getDefaultSize=function(){var t=this.getAttribute("position"),i=this.coordinate;return Math.min(i.getWidth()/(t.scales[0].ticks.length*4),i.getHeight()/(t.scales[1].ticks.length*4))},r.prototype.clearShadowCanvasCtx=function(){var t=this.getShadowCanvasCtx();t.clearRect(0,0,t.canvas.width,t.canvas.height)},r.prototype.getShadowCanvasCtx=function(){var t=this.shadowCanvas;return t||(t=document.createElement("canvas"),this.shadowCanvas=t),t.width=this.coordinate.getWidth(),t.height=this.coordinate.getHeight(),t.getContext("2d")},r.prototype.getGrayScaleBlurredCanvas=function(){return this.grayScaleBlurredCanvas||(this.grayScaleBlurredCanvas=document.createElement("canvas")),this.grayScaleBlurredCanvas},r.prototype.drawGrayScaleBlurredCircle=function(t,i,n,a,o){var l=this.getGrayScaleBlurredCanvas();o.globalAlpha=a,o.drawImage(l,t-n,i-n)},r.prototype.colorize=function(t){for(var i=this.getAttribute("color"),n=t.data,a=this.paletteCache,o=3;o<n.length;o+=4){var l=n[o];if(Mt(l)){var s=a[l]?a[l]:Qo.rgb2arr(i.gradient(l/256));n[o-3]=s[0],n[o-2]=s[1],n[o-1]=s[2],n[o]=l}}},r.prototype.getImageShape=function(){var t=this.imageShape;if(t)return t;var i=this.container;return t=i.addShape({type:"image",attrs:{}}),this.imageShape=t,t},r.prototype.getShapeInfo=function(t){var i=this.getDrawCfg(t[0]),n=t.map(function(a){return a[de]});return A(A({},i),{mappingData:t,data:n})},r}(hl);function GO(e){var r=e.x,t=e.y,i=e.y0,n=e.size,a,o;it(t)?(a=t[0],o=t[1]):(a=i,o=t);var l,s;it(r)?(l=r[0],s=r[1]):(l=r-n/2,s=r+n/2);var u=[{x:l,y:a},{x:l,y:o}];return u.push({x:s,y:o},{x:s,y:a}),u}function zO(e,r){r===void 0&&(r=!0);var t=[],i=e[0];t.push(["M",i.x,i.y]);for(var n=1,a=e.length;n<a;n++)t.push(["L",e[n].x,e[n].y]);return r&&(t.push(["L",i.x,i.y]),t.push(["z"])),t}function Kv(e,r){var t=0,i=0,n=0,a=0;return it(e)?e.length===1?t=i=n=a=e[0]:e.length===2?(t=n=e[0],i=a=e[1]):e.length===3?(t=e[0],i=a=e[1],n=e[2]):(t=e[0],i=e[1],n=e[2],a=e[3]):t=i=n=a=e,t+i>r&&(t=t?r/(1+i/t):0,i=r-t),n+a>r&&(n=n?r/(1+a/n):0,a=r-n),[t||0,i||0,n||0,a||0]}function FW(e,r,t){var i=[];if(t.isRect){var n=t.isTransposed?{x:t.start.x,y:r[0].y}:{x:r[0].x,y:t.start.y},a=t.isTransposed?{x:t.end.x,y:r[2].y}:{x:r[3].x,y:t.end.y},o=I(e,["background","style","radius"]);if(o){var l=t.isTransposed?Math.abs(r[0].y-r[2].y):r[2].x-r[1].x,s=t.isTransposed?t.getWidth():t.getHeight(),u=Kv(o,Math.min(l,s)),c=u[0],f=u[1],h=u[2],v=u[3];i.push(["M",n.x,a.y+c]),c!==0&&i.push(["A",c,c,0,0,1,n.x+c,a.y]),i.push(["L",a.x-f,a.y]),f!==0&&i.push(["A",f,f,0,0,1,a.x,a.y+f]),i.push(["L",a.x,n.y-h]),h!==0&&i.push(["A",h,h,0,0,1,a.x-h,n.y]),i.push(["L",n.x+v,n.y]),v!==0&&i.push(["A",v,v,0,0,1,n.x,n.y-v])}else i.push(["M",n.x,n.y]),i.push(["L",a.x,n.y]),i.push(["L",a.x,a.y]),i.push(["L",n.x,a.y]),i.push(["L",n.x,n.y]);i.push(["z"])}if(t.isPolar){var d=t.getCenter(),p=rp(e,t),x=p.startAngle,m=p.endAngle;if(t.type!=="theta"&&!t.isTransposed)i=es(d.x,d.y,t.getRadius(),x,m);else{var _=function(S){return Math.pow(S,2)},c=Math.sqrt(_(d.x-r[0].x)+_(d.y-r[0].y)),f=Math.sqrt(_(d.x-r[2].x)+_(d.y-r[2].y));i=es(d.x,d.y,c,t.startAngle,t.endAngle,f)}}return i}function kbt(e,r,t){var i=t.getWidth(),n=t.getHeight(),a=t.type==="rect",o=[],l=(e[2].x-e[1].x)/2,s=t.isTransposed?l*n/i:l*i/n;return r==="round"?(a?(o.push(["M",e[0].x,e[0].y+s]),o.push(["L",e[1].x,e[1].y-s]),o.push(["A",l,l,0,0,1,e[2].x,e[2].y-s]),o.push(["L",e[3].x,e[3].y+s]),o.push(["A",l,l,0,0,1,e[0].x,e[0].y+s])):(o.push(["M",e[0].x,e[0].y]),o.push(["L",e[1].x,e[1].y]),o.push(["A",l,l,0,0,1,e[2].x,e[2].y]),o.push(["L",e[3].x,e[3].y]),o.push(["A",l,l,0,0,1,e[0].x,e[0].y])),o.push(["z"])):o=zO(e),o}function OW(e,r,t){var i=[];return K(r)?t?i.push(["M",e[0].x,e[0].y],["L",e[1].x,e[1].y],["L",(e[2].x+e[3].x)/2,(e[2].y+e[3].y)/2],["Z"]):i.push(["M",e[0].x,e[0].y],["L",e[1].x,e[1].y],["L",e[2].x,e[2].y],["L",e[3].x,e[3].y],["Z"]):i.push(["M",e[0].x,e[0].y],["L",e[1].x,e[1].y],["L",r[1].x,r[1].y],["L",r[0].x,r[0].y],["Z"]),i}function Rbt(e,r,t){var i,n,a,o,l=e[0],s=e[1],u=e[2],c=e[3],f=[0,0,0,0],h=f[0],v=f[1],d=f[2],p=f[3];l.y<s.y?(s=e[0],l=e[1],c=e[2],u=e[3],i=Kv(t,Math.min(c.x-l.x,l.y-s.y)),p=i[0],d=i[1],v=i[2],h=i[3]):(n=Kv(t,Math.min(c.x-l.x,l.y-s.y)),h=n[0],v=n[1],d=n[2],p=n[3]),r.isTransposed&&(l=e[0],c=e[1],u=e[2],s=e[3],e[0].x>e[1].x?(c=e[0],l=e[1],s=e[2],u=e[3],a=Kv(t,Math.min(c.x-l.x,l.y-s.y)),h=a[0],p=a[1],d=a[2],v=a[3]):(o=Kv(t,Math.min(c.x-l.x,l.y-s.y)),v=o[0],d=o[1],p=o[2],h=o[3]));var x=[];return x.push(["M",s.x,s.y+h]),h!==0&&x.push(["A",h,h,0,0,1,s.x+h,s.y]),x.push(["L",u.x-v,u.y]),v!==0&&x.push(["A",v,v,0,0,1,u.x,u.y+v]),x.push(["L",c.x,c.y-d]),d!==0&&x.push(["A",d,d,0,0,1,c.x-d,c.y]),x.push(["L",l.x+p,l.y]),p!==0&&x.push(["A",p,p,0,0,1,l.x,l.y-p]),x.push(["L",s.x,s.y+h]),x.push(["z"]),x}fl("interval",{defaultShapeType:"rect",getDefaultPoints:function(e){return GO(e)}});te("interval","rect",{draw:function(e,r){var t=Ze(e,!1,!0),i=r,n=e==null?void 0:e.background;if(n){i=r.addGroup();var a=TW(e),o=FW(e,this.parsePoints(e.points),this.coordinate);i.addShape("path",{attrs:A(A({},a),{path:o}),zIndex:-1,name:LO})}var l;t.radius&&this.coordinate.isRect?l=Rbt(this.parsePoints(e.points),this.coordinate,t.radius):l=this.parsePath(kbt(e.points,t.lineCap,this.coordinate));var s=i.addShape("path",{attrs:A(A({},t),{path:l}),name:"interval"});return n?i:s},getMarker:function(e){var r=e.color,t=e.isInPolar;return t?{symbol:"circle",style:{r:4.5,fill:r}}:{symbol:"square",style:{r:4,fill:r}}}});function Bbt(e,r){var t=e.length,i=e;Ct(i[0])&&(i=e.map(function(l){return r.translate(l)}));for(var n=i[1]-i[0],a=2;a<t;a++){var o=i[a]-i[a-1];n>o&&(n=o)}return n}function Nbt(e,r){if(r){var t=qi(e),i=Xn(t,r);return i.length}return e.length}function VO(e){var r=e.theme,t=e.coordinate,i=e.getXScale(),n=i.values,a=e.beforeMappingData,o=n.length,l=hg(e.coordinate),s=e.intervalPadding,u=e.dodgePadding,c=e.maxColumnWidth||r.maxColumnWidth,f=e.minColumnWidth||r.minColumnWidth,h=e.columnWidthRatio||r.columnWidthRatio,v=e.multiplePieWidthRatio||r.multiplePieWidthRatio,d=e.roseWidthRatio||r.roseWidthRatio;if(i.isLinear&&n.length>1){n.sort();var p=Bbt(n,i);o=(i.max-i.min)/p,n.length>o&&(o=n.length)}var x=i.range,m=1/o,_=1;if(t.isPolar?t.isTransposed&&o>1?_=v:_=d:(i.isLinear&&(m*=x[1]-x[0]),_=h),!K(s)&&s>=0){var b=s/l;m=(1-(o-1)*b)/o}else m*=_;if(e.getAdjust("dodge")){var w=e.getAdjust("dodge"),S=w.dodgeBy,M=Nbt(a,S);if(!K(u)&&u>=0){var F=u/l;m=(m-F*(M-1))/M}else!K(s)&&s>=0&&(m*=_),m=m/M;m=m>=0?m:0}if(!K(c)&&c>=0){var O=c/l;m>O&&(m=O)}if(!K(f)&&f>=0){var L=f/l;m<L&&(m=L)}return m}var Gbt=function(e){X(r,e);function r(t){var i=e.call(this,t)||this;i.type="interval",i.shapeType="interval",i.generatePoints=!0;var n=t.background;return i.background=n,i}return r.prototype.createShapePointsCfg=function(t){var i=e.prototype.createShapePointsCfg.call(this,t),n,a=this.getAttribute("size");if(a){n=this.getAttributeValues(a,t)[0];var o=this.coordinate,l=hg(o);n=n/l}else this.defaultSize||(this.defaultSize=VO(this)),n=this.defaultSize;return i.size=n,i},r.prototype.adjustScale=function(){e.prototype.adjustScale.call(this);var t=this.getYScale();if(this.coordinate.type==="theta")t.change({nice:!1,min:0,max:m_t(t)});else{var i=this.scaleDefs,n=t.field,a=t.min,o=t.max,l=t.type;l!=="time"&&(a>0&&!I(i,[n,"min"])&&t.change({min:0}),o<=0&&!I(i,[n,"max"])&&t.change({max:0}))}},r.prototype.getDrawCfg=function(t){var i=e.prototype.getDrawCfg.call(this,t);return i.background=this.background,i},r}(hl),zbt=function(e){X(r,e);function r(t){var i=e.call(this,t)||this;i.type="line";var n=t.sortable,a=n===void 0?!1:n;return i.sortable=a,i}return r}(NO),PW=["circle","square","bowtie","diamond","hexagon","triangle","triangle-down"],Vbt=["cross","tick","plus","hyphen","line"];function jO(e,r,t,i,n){var a=Ze(r,n,!n,"r"),o=e.parsePoints(r.points),l=o[0];if(r.isStack)l=o[1];else if(o.length>1){for(var s=t.addGroup(),u=0,c=o;u<c.length;u++){var f=c[u];s.addShape({type:"marker",attrs:A(A(A({},a),{symbol:tc[i]||i}),f)})}return s}return t.addShape({type:"marker",attrs:A(A(A({},a),{symbol:tc[i]||i}),l)})}fl("point",{defaultShapeType:"hollow-circle",getDefaultPoints:function(e){return BO(e)}});P(PW,function(e){te("point","hollow-"+e,{draw:function(r,t){return jO(this,r,t,e,!0)},getMarker:function(r){var t=r.color;return{symbol:tc[e]||e,style:{r:4.5,stroke:t,fill:null}}}})});var jbt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="point",t.shapeType="point",t.generatePoints=!0,t}return r.prototype.getDrawCfg=function(t){var i=e.prototype.getDrawCfg.call(this,t);return A(A({},i),{isStack:!!this.getAdjust("stack")})},r}(hl);function Hbt(e){for(var r=e[0],t=1,i=[["M",r.x,r.y]];t<e.length;){var n=e[t];(n.x!==e[t-1].x||n.y!==e[t-1].y)&&(i.push(["L",n.x,n.y]),n.x===r.x&&n.y===r.y&&t<e.length-1&&(r=e[t+1],i.push(["Z"]),i.push(["M",r.x,r.y]),t++)),t++}return Ge(nr(i),r)||i.push(["L",r.x,r.y]),i.push(["Z"]),i}fl("polygon",{defaultShapeType:"polygon",getDefaultPoints:function(e){var r=[];return P(e.x,function(t,i){var n=e.y[i];r.push({x:t,y:n})}),r}});te("polygon","polygon",{draw:function(e,r){if(!gi(e.points)){var t=Ze(e,!0,!0),i=this.parsePath(Hbt(e.points));return r.addShape("path",{attrs:A(A({},t),{path:i}),name:"polygon"})}},getMarker:function(e){var r=e.color;return{symbol:"square",style:{r:4,fill:r}}}});var Ybt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="polygon",t.shapeType="polygon",t.generatePoints=!0,t}return r.prototype.createShapePointsCfg=function(t){var i=e.prototype.createShapePointsCfg.call(this,t),n=i.x,a=i.y,o;if(!(it(n)&&it(a))){var l=this.getXScale(),s=this.getYScale(),u=l.values.length,c=s.values.length,f=.5*1/u,h=.5*1/c;l.isCategory&&s.isCategory?(n=[n-f,n-f,n+f,n+f],a=[a-h,a+h,a+h,a-h]):it(n)?(o=n,n=[o[0],o[0],o[1],o[1]],a=[a-h/2,a+h/2,a+h/2,a-h/2]):it(a)&&(o=a,a=[o[0],o[1],o[1],o[0]],n=[n-f/2,n-f/2,n+f/2,n+f/2]),i.x=n,i.y=a}return i},r}(hl);fl("schema",{defaultShapeType:""});var Wbt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="schema",t.shapeType="schema",t.generatePoints=!0,t}return r.prototype.createShapePointsCfg=function(t){var i=e.prototype.createShapePointsCfg.call(this,t),n,a=this.getAttribute("size");if(a){n=this.getAttributeValues(a,t)[0];var o=this.coordinate,l=hg(o);n=n/l}else this.defaultSize||(this.defaultSize=VO(this)),n=this.defaultSize;return i.size=n,i},r}(hl);function Xbt(e){if(!it(e))return[];var r=gr(e);return je(e,function(t){return t/r})}fl("violin",{defaultShapeType:"violin",getDefaultPoints:function(e){var r=e.size/2,t=[],i=Xbt(e._size);return P(e.y,function(n,a){var o=i[a]*r,l=a===0,s=a===e.y.length-1;t.push({isMin:l,isMax:s,x:e.x-o,y:n}),t.unshift({isMin:l,isMax:s,x:e.x+o,y:n})}),t}});te("violin","violin",{draw:function(e,r){var t=Ze(e,!0,!0),i=this.parsePath(SW(e.points));return r.addShape("path",{attrs:A(A({},t),{path:i}),name:"violin"})},getMarker:function(e){var r=e.color;return{symbol:"circle",style:{r:4,fill:r}}}});var Ubt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="violin",t.shapeType="violin",t.generatePoints=!0,t}return r.prototype.createShapePointsCfg=function(t){var i=e.prototype.createShapePointsCfg.call(this,t),n,a=this.getAttribute("size");if(a){n=this.getAttributeValues(a,t)[0];var o=this.coordinate,l=hg(o);n=n/l}else this.defaultSize||(this.defaultSize=VO(this)),n=this.defaultSize;return i.size=n,i._size=I(t[de],[this._sizeField]),i},r.prototype.initAttributes=function(){var t=this.attributeOption,i=t.size?t.size.fields[0]:this._sizeField?this._sizeField:"size";this._sizeField=i,delete t.size,e.prototype.initAttributes.call(this)},r}(hl);te("area","line",{draw:function(e,r){var t=E_(e,!0,!1,this),i=r.addShape({type:"path",attrs:t,name:"area"});return i},getMarker:function(e){var r=e.color;return{symbol:function(t,i,n){return n===void 0&&(n=5.5),[["M",t-n,i-4],["L",t+n,i-4],["L",t+n,i+4],["L",t-n,i+4],["Z"]]},style:{r:5,stroke:r,fill:null}}}});te("area","smooth",{draw:function(e,r){var t=this.coordinate,i=E_(e,!1,!0,this,EW(t)),n=r.addShape({type:"path",attrs:i,name:"area"});return n},getMarker:function(e){var r=e.color;return{symbol:function(t,i,n){return n===void 0&&(n=5.5),[["M",t-n,i-4],["L",t+n,i-4],["L",t+n,i+4],["L",t-n,i+4],["Z"]]},style:{r:5,fill:r}}}});te("area","smooth-line",{draw:function(e,r){var t=this.coordinate,i=E_(e,!0,!0,this,EW(t)),n=r.addShape({type:"path",attrs:i,name:"area"});return n},getMarker:function(e){var r=e.color;return{symbol:function(t,i,n){return n===void 0&&(n=5.5),[["M",t-n,i-4],["L",t+n,i-4],["L",t+n,i+4],["L",t-n,i+4],["Z"]]},style:{r:5,stroke:r,fill:null}}}});function OT(e,r){return["C",e.x*1/2+r.x*1/2,e.y,e.x*1/2+r.x*1/2,r.y,r.x,r.y]}function PT(e,r){var t=[];t.push({x:r.x,y:r.y}),t.push(e);var i=["Q"];return P(t,function(n){i.push(n.x,n.y)}),i}function qbt(e,r,t){var i=PT(r,t),n=[["M",e.x,e.y]];return n.push(i),n}function Zbt(e,r){var t=PT(e[1],r),i=PT(e[3],r),n=[["M",e[0].x,e[0].y]];return n.push(i),n.push(["L",e[3].x,e[3].y]),n.push(["L",e[2].x,e[2].y]),n.push(t),n.push(["L",e[1].x,e[1].y]),n.push(["L",e[0].x,e[0].y]),n.push(["Z"]),n}te("edge","arc",{draw:function(e,r){var t=Ze(e,!0,!1,"lineWidth"),i=e.points,n=i.length>2?"weight":"normal",a;if(e.isInCircle){var o={x:0,y:1};return n==="normal"?a=qbt(i[0],i[1],o):(t.fill=t.stroke,a=Zbt(i,o)),a=this.parsePath(a),r.addShape("path",{attrs:A(A({},t),{path:a})})}else{if(n==="normal")return i=this.parsePoints(i),a=VY((i[1].x+i[0].x)/2,i[0].y,Math.abs(i[1].x-i[0].x)/2,Math.PI,Math.PI*2),r.addShape("path",{attrs:A(A({},t),{path:a})});var l=OT(i[1],i[3]),s=OT(i[2],i[0]);return a=[["M",i[0].x,i[0].y],["L",i[1].x,i[1].y],l,["L",i[3].x,i[3].y],["L",i[2].x,i[2].y],s,["Z"]],a=this.parsePath(a),t.fill=t.stroke,r.addShape("path",{attrs:A(A({},t),{path:a})})}},getMarker:function(e){return{symbol:"circle",style:{r:4.5,fill:e.color}}}});function Qbt(e,r){var t=OT(e,r),i=[["M",e.x,e.y]];return i.push(t),i}te("edge","smooth",{draw:function(e,r){var t=Ze(e,!0,!1,"lineWidth"),i=e.points,n=this.parsePath(Qbt(i[0],i[1]));return r.addShape("path",{attrs:A(A({},t),{path:n})})},getMarker:function(e){return{symbol:"circle",style:{r:4.5,fill:e.color}}}});var Qm=1/3;function Kbt(e,r){var t=[];t.push({x:e.x,y:e.y*(1-Qm)+r.y*Qm}),t.push({x:r.x,y:e.y*(1-Qm)+r.y*Qm}),t.push(r);var i=[["M",e.x,e.y]];return P(t,function(n){i.push(["L",n.x,n.y])}),i}te("edge","vhv",{draw:function(e,r){var t=Ze(e,!0,!1,"lineWidth"),i=e.points,n=this.parsePath(Kbt(i[0],i[1]));return r.addShape("path",{attrs:A(A({},t),{path:n})})},getMarker:function(e){return{symbol:"circle",style:{r:4.5,fill:e.color}}}});te("interval","funnel",{getPoints:function(e){return e.size=e.size*2,GO(e)},draw:function(e,r){var t=Ze(e,!1,!0),i=this.parsePath(OW(e.points,e.nextPoints,!1)),n=r.addShape("path",{attrs:A(A({},t),{path:i}),name:"interval"});return n},getMarker:function(e){var r=e.color;return{symbol:"square",style:{r:4,fill:r}}}});te("interval","hollow-rect",{draw:function(e,r){var t=Ze(e,!0,!1),i=r,n=e==null?void 0:e.background;if(n){i=r.addGroup();var a=TW(e),o=FW(e,this.parsePoints(e.points),this.coordinate);i.addShape("path",{attrs:A(A({},a),{path:o}),zIndex:-1,name:LO})}var l=this.parsePath(zO(e.points)),s=i.addShape("path",{attrs:A(A({},t),{path:l}),name:"interval"});return n?i:s},getMarker:function(e){var r=e.color,t=e.isInPolar;return t?{symbol:"circle",style:{r:4.5,stroke:r,fill:null}}:{symbol:"square",style:{r:4,stroke:r,fill:null}}}});function Jbt(e){var r=e.x,t=e.y,i=e.y0;return it(t)?t.map(function(n,a){return{x:it(r)?r[a]:r,y:n}}):[{x:r,y:i},{x:r,y:t}]}te("interval","line",{getPoints:function(e){return Jbt(e)},draw:function(e,r){var t=Ze(e,!0,!1,"lineWidth"),i=Gi(A({},t),["fill"]),n=this.parsePath(zO(e.points,!1)),a=r.addShape("path",{attrs:A(A({},i),{path:n}),name:"interval"});return a},getMarker:function(e){var r=e.color;return{symbol:function(t,i,n){return[["M",t,i-n],["L",t,i+n]]},style:{r:5,stroke:r}}}});te("interval","pyramid",{getPoints:function(e){return e.size=e.size*2,GO(e)},draw:function(e,r){var t=Ze(e,!1,!0),i=this.parsePath(OW(e.points,e.nextPoints,!0)),n=r.addShape("path",{attrs:A(A({},t),{path:i}),name:"interval"});return n},getMarker:function(e){var r=e.color;return{symbol:"square",style:{r:4,fill:r}}}});function twt(e){var r=e.x,t=e.y,i=e.y0,n=e.size,a,o;it(t)?(a=t[0],o=t[1]):(a=i,o=t);var l=r+n/2,s=r-n/2;return[{x:r,y:a},{x:r,y:o},{x:s,y:a},{x:l,y:a},{x:s,y:o},{x:l,y:o}]}function ewt(e){return[["M",e[0].x,e[0].y],["L",e[1].x,e[1].y],["M",e[2].x,e[2].y],["L",e[3].x,e[3].y],["M",e[4].x,e[4].y],["L",e[5].x,e[5].y]]}te("interval","tick",{getPoints:function(e){return twt(e)},draw:function(e,r){var t=Ze(e,!0,!1),i=this.parsePath(ewt(e.points)),n=r.addShape("path",{attrs:A(A({},t),{path:i}),name:"interval"});return n},getMarker:function(e){var r=e.color;return{symbol:function(t,i,n){return[["M",t-n/2,i-n],["L",t+n/2,i-n],["M",t,i-n],["L",t,i+n],["M",t-n/2,i+n],["L",t+n/2,i+n]]},style:{r:5,stroke:r}}}});var rwt=function(e,r,t){var i=e.x,n=e.y,a=r.x,o=r.y,l;switch(t){case"hv":l=[{x:a,y:n}];break;case"vh":l=[{x:i,y:o}];break;case"hvh":var s=(a+i)/2;l=[{x:s,y:n},{x:s,y:o}];break;case"vhv":var u=(n+o)/2;l=[{x:i,y:u},{x:a,y:u}];break}return l};function iwt(e,r){var t=[];return P(e,function(i,n){var a=e[n+1];if(t.push(i),a){var o=rwt(i,a,r);t=t.concat(o)}}),t}function nwt(e){return e.map(function(r,t){return t===0?["M",r.x,r.y]:["L",r.x,r.y]})}function awt(e,r){var t=RO(e.points,e.connectNulls,e.showSinglePoint),i=[];return P(t,function(n){var a=iwt(n,r);i=i.concat(nwt(a))}),A(A({},Ze(e,!0,!1,"lineWidth")),{path:i})}P(["hv","vh","hvh","vhv"],function(e){te("line",e,{draw:function(r,t){var i=awt(r,e),n=t.addShape({type:"path",attrs:i,name:"line"});return n},getMarker:function(r){return MW(r,e)}})});P(Vbt,function(e){te("point",e,{draw:function(r,t){return jO(this,r,t,e,!0)},getMarker:function(r){var t=r.color;return{symbol:tc[e],style:{r:4.5,stroke:t,fill:null}}}})});te("point","image",{draw:function(e,r){var t=Ze(e,!1,!1,"r").r,i=this.parsePoints(e.points),n=i[0];if(e.isStack)n=i[1];else if(i.length>1){for(var a=r.addGroup(),o=0,l=i;o<l.length;o++){var s=l[o];a.addShape("image",{attrs:{x:s.x-t/2,y:s.y-t,width:t,height:t,img:e.shape[1]}})}return a}return r.addShape("image",{attrs:{x:n.x-t/2,y:n.y-t,width:t,height:t,img:e.shape[1]}})},getMarker:function(e){var r=e.color;return{symbol:"circle",style:{r:4.5,fill:r}}}});P(PW,function(e){te("point",e,{draw:function(r,t){return jO(this,r,t,e,!1)},getMarker:function(r){var t=r.color;return{symbol:tc[e]||e,style:{r:4.5,fill:t}}}})});function _B(e){var r=it(e)?e:[e],t=r[0],i=r[r.length-1],n=r.length>1?r[1]:t,a=r.length>3?r[3]:i,o=r.length>2?r[2]:n;return{min:t,max:i,min1:n,max1:a,median:o}}function bB(e,r,t){var i=t/2,n;if(it(r)){var a=_B(r),o=a.min,l=a.max,s=a.median,u=a.min1,c=a.max1,f=e-i,h=e+i;n=[[f,l],[h,l],[e,l],[e,c],[f,u],[f,c],[h,c],[h,u],[e,u],[e,o],[f,o],[h,o],[f,s],[h,s]]}else{r=K(r)?.5:r;var v=_B(e),o=v.min,l=v.max,s=v.median,u=v.min1,c=v.max1,d=r-i,p=r+i;n=[[o,d],[o,p],[o,r],[u,r],[u,d],[u,p],[c,p],[c,d],[c,r],[l,r],[l,d],[l,p],[s,d],[s,p]]}return n.map(function(x){return{x:x[0],y:x[1]}})}function owt(e){return[["M",e[0].x,e[0].y],["L",e[1].x,e[1].y],["M",e[2].x,e[2].y],["L",e[3].x,e[3].y],["M",e[4].x,e[4].y],["L",e[5].x,e[5].y],["L",e[6].x,e[6].y],["L",e[7].x,e[7].y],["L",e[4].x,e[4].y],["Z"],["M",e[8].x,e[8].y],["L",e[9].x,e[9].y],["M",e[10].x,e[10].y],["L",e[11].x,e[11].y],["M",e[12].x,e[12].y],["L",e[13].x,e[13].y]]}te("schema","box",{getPoints:function(e){var r=e.x,t=e.y,i=e.size;return bB(r,t,i)},draw:function(e,r){var t=Ze(e,!0,!1),i=this.parsePath(owt(e.points)),n=r.addShape("path",{attrs:A(A({},t),{path:i,name:"schema"})});return n},getMarker:function(e){var r=e.color;return{symbol:function(t,i,n){var a=[i-6,i-3,i,i+3,i+6],o=bB(t,a,n);return[["M",o[0].x+1,o[0].y],["L",o[1].x-1,o[1].y],["M",o[2].x,o[2].y],["L",o[3].x,o[3].y],["M",o[4].x,o[4].y],["L",o[5].x,o[5].y],["L",o[6].x,o[6].y],["L",o[7].x,o[7].y],["L",o[4].x,o[4].y],["Z"],["M",o[8].x,o[8].y],["L",o[9].x,o[9].y],["M",o[10].x+1,o[10].y],["L",o[11].x-1,o[11].y],["M",o[12].x,o[12].y],["L",o[13].x,o[13].y]]},style:{r:6,lineWidth:1,stroke:r}}}});function lwt(e){var r=it(e)?e:[e],t=r.sort(function(i,n){return n-i});return c_t(t,4,t[t.length-1])}function wB(e,r,t){var i=lwt(r);return[{x:e,y:i[0]},{x:e,y:i[1]},{x:e-t/2,y:i[2]},{x:e-t/2,y:i[1]},{x:e+t/2,y:i[1]},{x:e+t/2,y:i[2]},{x:e,y:i[2]},{x:e,y:i[3]}]}function swt(e){return[["M",e[0].x,e[0].y],["L",e[1].x,e[1].y],["M",e[2].x,e[2].y],["L",e[3].x,e[3].y],["L",e[4].x,e[4].y],["L",e[5].x,e[5].y],["Z"],["M",e[6].x,e[6].y],["L",e[7].x,e[7].y]]}te("schema","candle",{getPoints:function(e){var r=e.x,t=e.y,i=e.size;return wB(r,t,i)},draw:function(e,r){var t=Ze(e,!0,!0),i=this.parsePath(swt(e.points)),n=r.addShape("path",{attrs:A(A({},t),{path:i,name:"schema"})});return n},getMarker:function(e){var r=e.color;return{symbol:function(t,i,n){var a=[i+7.5,i+3,i-3,i-7.5],o=wB(t,a,n);return[["M",o[0].x,o[0].y],["L",o[1].x,o[1].y],["M",o[2].x,o[2].y],["L",o[3].x,o[3].y],["L",o[4].x,o[4].y],["L",o[5].x,o[5].y],["Z"],["M",o[6].x,o[6].y],["L",o[7].x,o[7].y]]},style:{lineWidth:1,stroke:r,fill:r,r:6}}}});function uwt(e,r){var t=Math.abs(e[0].x-e[2].x),i=Math.abs(e[0].y-e[2].y),n=Math.min(t,i);r&&(n=Ce(r,0,Math.min(t,i))),n=n/2;var a=(e[0].x+e[2].x)/2,o=(e[0].y+e[2].y)/2;return{x:a-n,y:o-n,width:n*2,height:n*2}}te("polygon","square",{draw:function(e,r){if(!gi(e.points)){var t=Ze(e,!0,!0),i=this.parsePoints(e.points);return r.addShape("rect",{attrs:A(A({},t),uwt(i,e.size)),name:"polygon"})}},getMarker:function(e){var r=e.color;return{symbol:"square",style:{r:4,fill:r}}}});te("violin","smooth",{draw:function(e,r){var t=Ze(e,!0,!0),i=this.parsePath(AW(e.points));return r.addShape("path",{attrs:A(A({},t),{path:i})})},getMarker:function(e){var r=e.color;return{symbol:"circle",style:{stroke:null,r:4,fill:r}}}});te("violin","hollow",{draw:function(e,r){var t=Ze(e,!0,!1),i=this.parsePath(SW(e.points));return r.addShape("path",{attrs:A(A({},t),{path:i})})},getMarker:function(e){var r=e.color;return{symbol:"circle",style:{r:4,fill:null,stroke:r}}}});te("violin","hollow-smooth",{draw:function(e,r){var t=Ze(e,!0,!1),i=this.parsePath(AW(e.points));return r.addShape("path",{attrs:A(A({},t),{path:i})})},getMarker:function(e){var r=e.color;return{symbol:"circle",style:{r:4,fill:null,stroke:r}}}});var cwt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getLabelValueDir=function(t){var i="y",n=t.points;return n[0][i]<=n[2][i]?1:-1},r.prototype.getLabelOffsetPoint=function(t,i,n,a){var o,l=e.prototype.getLabelOffsetPoint.call(this,t,i,n),s=this.getCoordinate(),u=s.isTransposed,c=u?"x":"y",f=this.getLabelValueDir(t.mappingData);return l=A(A({},l),(o={},o[c]=l[c]*f,o)),s.isReflect("x")&&(l=A(A({},l),{x:l.x*-1})),s.isReflect("y")&&(l=A(A({},l),{y:l.y*-1})),l},r.prototype.getThemedLabelCfg=function(t){var i=this.geometry,n=this.getDefaultLabelCfg(),a=i.theme;return ft({},n,a.labels,t.position==="middle"?{offset:0}:{},t)},r.prototype.setLabelPosition=function(t,i,n,a){var o=this.getCoordinate(),l=o.isTransposed,s=i.points,u=o.convert(s[0]),c=o.convert(s[2]),f=this.getLabelValueDir(i),h,v,d,p,x=it(i.shape)?i.shape[0]:i.shape;if(x==="funnel"||x==="pyramid"){var m=I(i,"nextPoints"),_=I(i,"points");if(m){var b=o.convert(_[0]),w=o.convert(_[1]),S=o.convert(m[0]),M=o.convert(m[1]);l?(h=Math.min(S.y,b.y),d=Math.max(S.y,b.y),v=(w.x+M.x)/2,p=(b.x+S.x)/2):(h=Math.min((w.y+M.y)/2,(b.y+S.y)/2),d=Math.max((w.y+M.y)/2,(b.y+S.y)/2),v=M.x,p=b.x)}else h=Math.min(c.y,u.y),d=Math.max(c.y,u.y),v=c.x,p=u.x}else h=Math.min(c.y,u.y),d=Math.max(c.y,u.y),v=c.x,p=u.x;switch(a){case"right":t.x=v,t.y=(h+d)/2,t.textAlign=I(t,"textAlign",f>0?"left":"right");break;case"left":t.x=p,t.y=(h+d)/2,t.textAlign=I(t,"textAlign",f>0?"left":"right");break;case"bottom":l&&(t.x=(v+p)/2),t.y=d,t.textAlign=I(t,"textAlign","center"),t.textBaseline=I(t,"textBaseline",f>0?"bottom":"top");break;case"middle":l&&(t.x=(v+p)/2),t.y=(h+d)/2,t.textAlign=I(t,"textAlign","center"),t.textBaseline=I(t,"textBaseline","middle");break;case"top":l&&(t.x=(v+p)/2),t.y=h,t.textAlign=I(t,"textAlign","center"),t.textBaseline=I(t,"textBaseline",f>0?"bottom":"top");break}},r}(gg),Km=Math.PI/2,IW=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getLabelOffset=function(t){var i=this.getCoordinate(),n=0;if(Mt(t))n=t;else if(Ct(t)&&t.indexOf("%")!==-1){var a=i.getRadius();i.innerRadius>0&&(a=a*(1-i.innerRadius)),n=parseFloat(t)*.01*a}return n},r.prototype.getLabelItems=function(t){var i=e.prototype.getLabelItems.call(this,t),n=this.geometry.getYScale();return je(i,function(a){if(a&&n){var o=n.scale(I(a.data,n.field));return A(A({},a),{percent:o})}return a})},r.prototype.getLabelAlign=function(t){var i=this.getCoordinate(),n;if(t.labelEmit)n=t.angle<=Math.PI/2&&t.angle>=-Math.PI/2?"left":"right";else if(!i.isTransposed)n="center";else{var a=i.getCenter(),o=t.offset;Math.abs(t.x-a.x)<1?n="center":t.angle>Math.PI||t.angle<=0?n=o>0?"left":"right":n=o>0?"right":"left"}return n},r.prototype.getLabelPoint=function(t,i,n){var a=1,o,l=t.content[n];this.isToMiddle(i)?o=this.getMiddlePoint(i.points):(t.content.length===1&&n===0?n=1:n===0&&(a=-1),o=this.getArcPoint(i,n));var s=t.offset*a,u=this.getPointAngle(o),c=t.labelEmit,f=this.getCirclePoint(u,s,o,c);return f.r===0?f.content="":(f.content=l,f.angle=u,f.color=i.color),f.rotate=t.autoRotate?this.getLabelRotate(u,s,c):t.rotate,f.start={x:o.x,y:o.y},f},r.prototype.getArcPoint=function(t,i){return i===void 0&&(i=0),!it(t.x)&&!it(t.y)?{x:t.x,y:t.y}:{x:it(t.x)?t.x[i]:t.x,y:it(t.y)?t.y[i]:t.y}},r.prototype.getPointAngle=function(t){return Kf(this.getCoordinate(),t)},r.prototype.getCirclePoint=function(t,i,n,a){var o=this.getCoordinate(),l=o.getCenter(),s=T_(o,n);if(s===0)return A(A({},l),{r:s});var u=t;if(o.isTransposed&&s>i&&!a){var c=Math.asin(i/(2*s));u=t+c*2}else s=s+i;return{x:l.x+s*Math.cos(u),y:l.y+s*Math.sin(u),r:s}},r.prototype.getLabelRotate=function(t,i,n){var a=t+Km;return n&&(a-=Km),a&&(a>Km?a=a-Math.PI:a<-Km&&(a=a+Math.PI)),a},r.prototype.getMiddlePoint=function(t){var i=this.getCoordinate(),n=t.length,a={x:0,y:0};return P(t,function(o){a.x+=o.x,a.y+=o.y}),a.x/=n,a.y/=n,a=i.convert(a),a},r.prototype.isToMiddle=function(t){return t.x.length>2},r}(gg),fwt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.defaultLayout="distribute",t}return r.prototype.getDefaultLabelCfg=function(t,i){var n=e.prototype.getDefaultLabelCfg.call(this,t,i);return ft({},n,I(this.geometry.theme,"pieLabels",{}))},r.prototype.getLabelOffset=function(t){return e.prototype.getLabelOffset.call(this,t)||0},r.prototype.getLabelRotate=function(t,i,n){var a;return i<0&&(a=t,a>Math.PI/2&&(a=a-Math.PI),a<-Math.PI/2&&(a=a+Math.PI)),a},r.prototype.getLabelAlign=function(t){var i=this.getCoordinate(),n=i.getCenter(),a;return t.angle<=Math.PI/2&&t.x>=n.x?a="left":a="right",t.offset<=0&&(a==="right"?a="left":a="right"),a},r.prototype.getArcPoint=function(t){return t},r.prototype.getPointAngle=function(t){var i=this.getCoordinate(),n={x:it(t.x)?t.x[0]:t.x,y:t.y[0]},a={x:it(t.x)?t.x[1]:t.x,y:t.y[1]},o,l=Kf(i,n);if(t.points&&t.points[0].y===t.points[1].y)o=l;else{var s=Kf(i,a);l>=s&&(s=s+Math.PI*2),o=l+(s-l)/2}return o},r.prototype.getCirclePoint=function(t,i){var n=this.getCoordinate(),a=n.getCenter(),o=n.getRadius()+i;return A(A({},ir(a.x,a.y,o,t)),{angle:t,r:o})},r}(IW),CB=4;function hwt(e,r,t,i,n,a){var o=!0,l=i.start,s=i.end,u=Math.min(l.y,s.y),c=Math.abs(l.y-s.y),f,h=0,v=Number.MIN_VALUE,d=r.map(function(S){return S.y>h&&(h=S.y),S.y<v&&(v=S.y),{size:t,targets:[S.y-u]}});for(v-=u,h-u>c&&(c=h-u);o;)for(d.forEach(function(S){var M=(Math.min.apply(v,S.targets)+Math.max.apply(v,S.targets))/2;S.pos=Math.min(Math.max(v,M-S.size/2),c-S.size)}),o=!1,f=d.length;f--;)if(f>0){var p=d[f-1],x=d[f];p.pos+p.size>x.pos&&(p.size+=x.size,p.targets=p.targets.concat(x.targets),p.pos+p.size>c&&(p.pos=c-p.size),d.splice(f,1),o=!0)}f=0,d.forEach(function(S){var M=u+t/2;S.targets.forEach(function(){r[f].y=S.pos+M,M+=t,f++})});for(var m={},_=0,b=e;_<b.length;_++){var w=b[_];m[w.get("id")]=w}r.forEach(function(S){var M=S.r*S.r,F=Math.pow(Math.abs(S.y-n.y),2);if(M<F)S.x=n.x;else{var O=Math.sqrt(M-F);a?S.x=n.x+O:S.x=n.x-O}var L=m[S.id];L.attr("x",S.x),L.attr("y",S.y);var D=Yn(L.getChildren(),function(k){return k.get("type")==="text"});D&&(D.attr("y",S.y),D.attr("x",S.x))})}function vwt(e,r,t,i){if(!(!e.length||!r.length)){var n=e[0]?e[0].offset:0,a=r[0].get("coordinate"),o=a.getRadius(),l=a.getCenter();if(n>0){var s=14,u=o+n,c=u*2+s*2,f={start:a.start,end:a.end},h=[[],[]];e.forEach(function(v){!v||(v.textAlign==="right"?h[0].push(v):h[1].push(v))}),h.forEach(function(v,d){var p=c/s;v.length>p&&(v.sort(function(x,m){return m["..percent"]-x["..percent"]}),v.splice(p,v.length-p)),v.sort(function(x,m){return x.y-m.y}),hwt(r,v,s,f,l,d)})}P(e,function(v){if(v&&v.labelLine){var d=v.offset,p=v.angle,x=ir(l.x,l.y,o,p),m=ir(l.x,l.y,o+d/2,p),_=v.x+I(v,"offsetX",0),b=v.y+I(v,"offsetY",0),w={x:_-Math.cos(p)*CB,y:b-Math.sin(p)*CB};Zt(v.labelLine)||(v.labelLine={}),v.labelLine.path=["M "+x.x,x.y+" Q"+m.x,m.y+" "+w.x,w.y].join(",")}})}}function LW(e,r,t){var i=e.filter(function(d){return!d.invisible});i.sort(function(d,p){return d.y-p.y});var n=!0,a=t.minY,o=t.maxY,l=Math.abs(a-o),s,u=0,c=Number.MIN_VALUE,f=i.map(function(d){return d.y>u&&(u=d.y),d.y<c&&(c=d.y),{content:d.content,size:r,targets:[d.y-a],pos:null}});for(c-=a,u-a>l&&(l=u-a);n;)for(f.forEach(function(d){var p=(Math.min.apply(c,d.targets)+Math.max.apply(c,d.targets))/2;d.pos=Math.min(Math.max(c,p-d.size/2),l-d.size),d.pos=Math.max(0,d.pos)}),n=!1,s=f.length;s--;)if(s>0){var h=f[s-1],v=f[s];h.pos+h.size>v.pos&&(h.size+=v.size,h.targets=h.targets.concat(v.targets),h.pos+h.size>l&&(h.pos=l-h.size),f.splice(s,1),n=!0)}s=0,f.forEach(function(d){var p=a+r/2;d.targets.forEach(function(){i[s].y=d.pos+p,p+=r,s++})})}var SB=4;function dwt(e,r){var t=r.getCenter(),i=r.getRadius();if(e&&e.labelLine){var n=e.angle,a=e.offset,o=ir(t.x,t.y,i,n),l=e.x+I(e,"offsetX",0)*(Math.cos(n)>0?1:-1),s=e.y+I(e,"offsetY",0)*(Math.sin(n)>0?1:-1),u={x:l-Math.cos(n)*SB,y:s-Math.sin(n)*SB},c=e.labelLine.smooth,f=[],h=u.x-t.x,v=u.y-t.y,d=Math.atan(v/h);if(h<0&&(d+=Math.PI),c===!1){Zt(e.labelLine)||(e.labelLine={});var p=0;(n<0&&n>-Math.PI/2||n>Math.PI*1.5)&&u.y>o.y&&(p=1),n>=0&&n<Math.PI/2&&u.y>o.y&&(p=1),n>=Math.PI/2&&n<Math.PI&&o.y>u.y&&(p=1),(n<-Math.PI/2||n>=Math.PI&&n<Math.PI*1.5)&&o.y>u.y&&(p=1);var x=a/2>4?4:Math.max(a/2-1,0),m=ir(t.x,t.y,i+x,n),_=ir(t.x,t.y,i+a/2,d),b=0;f.push("M "+o.x+" "+o.y),f.push("L "+m.x+" "+m.y),f.push("A "+t.x+" "+t.y+" 0 "+b+" "+p+" "+_.x+" "+_.y),f.push("L "+u.x+" "+u.y)}else{var m=ir(t.x,t.y,i+(a/2>4?4:Math.max(a/2-1,0)),n),w=o.x<t.x?1:-1;f.push("M "+u.x+" "+u.y);var S=(o.y-t.y)/(o.x-t.x),M=(u.y-t.y)/(u.x-t.x);Math.abs(S-M)>Math.pow(Math.E,-16)&&f.push.apply(f,["C",u.x+w*4,u.y,2*m.x-o.x,2*m.y-o.y,o.x,o.y]),f.push("L "+o.x+" "+o.y)}e.labelLine.path=f.join(" ")}}function pwt(e,r,t,i){var n=jr(e,function(M){return!K(M)}),a=r[0]&&r[0].get("coordinate");if(!!a){for(var o=a.getCenter(),l=a.getRadius(),s={},u=0,c=r;u<c.length;u++){var f=c[u];s[f.get("id")]=f}var h=I(n[0],"labelHeight",14),v=I(n[0],"offset",0);if(!(v<=0)){var d="left",p="right",x=Xi(n,function(M){return M.x<o.x?d:p}),m=a.start,_=a.end,b=Math.min((l+v+h)*2,a.getHeight()),w=b/2,S={minX:m.x,maxX:_.x,minY:o.y-w,maxY:o.y+w};P(x,function(M,F){var O=Math.floor(b/h);M.length>O&&(M.sort(function(L,D){return D.percent-L.percent}),P(M,function(L,D){D+1>O&&(s[L.id].set("visible",!1),L.invisible=!0)})),LW(M,h,S)}),P(x,function(M,F){P(M,function(O){var L=F===p,D=s[O.id],k=D.getChildByIndex(0);if(k){var H=l+v,B=O.y-o.y,j=Math.pow(H,2),U=Math.pow(B,2),R=j-U>0?j-U:0,G=Math.sqrt(R),N=Math.abs(Math.cos(O.angle)*H);L?O.x=o.x+Math.max(G,N):O.x=o.x-Math.max(G,N)}k&&(k.attr("y",O.y),k.attr("x",O.x)),dwt(O,a)})})}}}var IT=4,gwt=4,AB=4;function ywt(e,r,t){var i=r.getCenter(),n=r.getRadius(),a={x:e.x-(t?AB:-AB),y:e.y},o=ir(i.x,i.y,n+IT,e.angle),l={x:a.x,y:a.y},s={x:o.x,y:o.y},u=ir(i.x,i.y,n,e.angle),c="";if(a.y!==o.y){var f=t?4:-4;l.y=a.y,e.angle<0&&e.angle>=-Math.PI/2&&(l.x=Math.max(o.x,a.x-f),a.y<o.y?s.y=l.y:(s.y=o.y,s.x=Math.max(s.x,l.x-f))),e.angle>0&&e.angle<Math.PI/2&&(l.x=Math.max(o.x,a.x-f),a.y>o.y?s.y=l.y:(s.y=o.y,s.x=Math.max(s.x,l.x-f))),e.angle>Math.PI/2&&(l.x=Math.min(o.x,a.x-f),a.y>o.y?s.y=l.y:(s.y=o.y,s.x=Math.min(s.x,l.x-f))),e.angle<-Math.PI/2&&(l.x=Math.min(o.x,a.x-f),a.y<o.y?s.y=l.y:(s.y=o.y,s.x=Math.min(s.x,l.x-f)))}c=["M "+a.x+","+a.y,"L "+l.x+","+l.y,"L "+s.x+","+s.y,"L "+o.x+","+o.y,"L "+u.x+","+u.y].join(" "),e.labelLine=ft({},e.labelLine,{path:c})}function mwt(e,r,t,i){var n=r[0]&&r[0].get("coordinate");if(!!n){for(var a=n.getCenter(),o=n.getRadius(),l={},s=0,u=r;s<u.length;s++){var c=u[s];l[c.get("id")]=c}var f=I(e[0],"labelHeight",14),h=Math.max(I(e[0],"offset",0),IT);P(e,function(M){var F=I(l,[M.id]);if(!!F){var O=M.x>a.x||M.x===a.x&&M.y>a.y,L=K(M.offsetX)?gwt:M.offsetX,D=ir(a.x,a.y,o+IT,M.angle),k=h+L;M.x=a.x+(O?1:-1)*(o+k),M.y=D.y}});var v=n.start,d=n.end,p="left",x="right",m=Xi(e,function(M){return M.x<a.x?p:x}),_=(o+h)*2+f;P(m,function(M){var F=M.length*f;F>_&&(_=Math.min(F,Math.abs(v.y-d.y)))});var b={minX:v.x,maxX:d.x,minY:a.y-_/2,maxY:a.y+_/2};P(m,function(M,F){var O=_/f;M.length>O&&(M.sort(function(L,D){return D.percent-L.percent}),P(M,function(L,D){D>O&&(l[L.id].set("visible",!1),L.invisible=!0)})),LW(M,f,b)});var w=b.minY,S=b.maxY;P(m,function(M,F){var O=F===x;P(M,function(L){var D=I(l,L&&[L.id]);if(!!D){if(L.y<w||L.y>S){D.set("visible",!1);return}var k=D.getChildByIndex(0),H=k.getCanvasBBox(),B={x:O?H.x:H.maxX,y:H.y+H.height/2};pg(k,L.x-B.x,L.y-B.y),L.labelLine&&ywt(L,n,O)}})})}}function xwt(e,r,t,i){P(r,function(n){var a=i.minX,o=i.minY,l=i.maxX,s=i.maxY,u=n.getCanvasBBox(),c=u.minX,f=u.minY,h=u.maxX,v=u.maxY,d=u.x,p=u.y,x=u.width,m=u.height,_=d,b=p;(c<a||h<a)&&(_=a),(f<o||v<o)&&(b=o),c>l?_=l-x:h>l&&(_=_-(h-l)),f>s?b=s-m:v>s&&(b=b-(v-s)),(_!==d||b!==p)&&pg(n,_-d,b-p)})}function _wt(e,r,t,i){P(r,function(n,a){var o=n.getCanvasBBox(),l=t[a].getBBox();(o.minX<l.minX||o.minY<l.minY||o.maxX>l.maxX||o.maxY>l.maxY)&&n.remove(!0)})}var bwt=100,DW=function(){function e(r){r===void 0&&(r={}),this.bitmap={};var t=r.xGap,i=t===void 0?1:t,n=r.yGap,a=n===void 0?8:n;this.xGap=i,this.yGap=a}return e.prototype.hasGap=function(r){for(var t=!0,i=this.bitmap,n=Math.round(r.minX),a=Math.round(r.maxX),o=Math.round(r.minY),l=Math.round(r.maxY),s=n;s<=a;s+=1){if(!i[s]){i[s]={};continue}if(s===n||s===a){for(var u=o;u<=l;u++)if(i[s][u]){t=!1;break}}else if(i[s][o]||i[s][l]){t=!1;break}}return t},e.prototype.fillGap=function(r){for(var t=this.bitmap,i=Math.round(r.minX),n=Math.round(r.maxX),a=Math.round(r.minY),o=Math.round(r.maxY),l=i;l<=n;l+=1)t[l]||(t[l]={});for(var l=i;l<=n;l+=this.xGap){for(var s=a;s<=o;s+=this.yGap)t[l][s]=!0;t[l][o]=!0}if(this.yGap!==1)for(var l=a;l<=o;l+=1)t[i][l]=!0,t[n][l]=!0;if(this.xGap!==1)for(var l=i;l<=n;l+=1)t[l][a]=!0,t[l][o]=!0},e.prototype.destroy=function(){this.bitmap={}},e}();function wwt(e,r,t){t===void 0&&(t=bwt);var i=-1,n=e.attr(),a=n.x,o=n.y,l=e.getCanvasBBox(),s=Math.sqrt(l.width*l.width+l.height*l.height),u,c=-i,f=0,h=0,v=function(m){var _=m*.1;return[_*Math.cos(_),_*Math.sin(_)]};if(r.hasGap(l))return r.fillGap(l),!0;for(var d=!1,p=0,x={};Math.min(Math.abs(f),Math.abs(h))<s&&p<t;)if(u=v(c+=i),f=~~u[0],h=~~u[1],!(!f&&!h||x[f+"-"+h])&&(e.attr({x:a+f,y:o+h}),f+h<0&&e.attr("textAlign","right"),p++,r.hasGap(e.getCanvasBBox()))){r.fillGap(e.getCanvasBBox()),d=!0,x[f+"-"+h]=!0;break}return d}function Cwt(e,r,t,i){var n=e.getCanvasBBox(),a=n.width,o=n.height,l={x:r,y:t,textAlign:"center"};switch(i){case 0:l.y-=o+1,l.x+=1,l.textAlign="left";break;case 1:l.y-=o+1,l.x-=1,l.textAlign="right";break;case 2:l.y+=o+1,l.x-=1,l.textAlign="right";break;case 3:l.y+=o+1,l.x+=1,l.textAlign="left";break;case 5:l.y-=o*2+2;break;case 6:l.y+=o*2+2;break;case 7:l.x+=a+1,l.textAlign="left";break;case 8:l.x-=a+1,l.textAlign="right";break}return e.attr(l),e.getCanvasBBox()}function Swt(e,r,t,i){var n=new DW;P(r,function(a){var o=a.find(function(l){return l.get("type")==="text"});wwt(o,n)||a.remove(!0)}),n.destroy()}function Awt(e,r,t,i){var n=new DW;P(r,function(a){for(var o=a.find(function(v){return v.get("type")==="text"}),l=o.attr(),s=l.x,u=l.y,c=!1,f=0;f<=8;f++){var h=Cwt(o,s,u,f);if(n.hasGap(h)){n.fillGap(h),c=!0;break}}c||a.remove(!0)}),n.destroy()}var Twt=xM;function TB(e){if(e.length>4)return[];var r=function(n,a){return[a.x-n.x,a.y-n.y]},t=r(e[0],e[1]),i=r(e[1],e[2]);return[t,i]}function Jm(e,r,t){r===void 0&&(r=0),t===void 0&&(t={x:0,y:0});var i=e.x,n=e.y;return{x:(i-t.x)*Math.cos(-r)+(n-t.y)*Math.sin(-r)+t.x,y:(t.x-i)*Math.sin(-r)+(n-t.y)*Math.cos(-r)+t.y}}function MB(e){var r=[{x:e.x,y:e.y},{x:e.x+e.width,y:e.y},{x:e.x+e.width,y:e.y+e.height},{x:e.x,y:e.y+e.height}],t=e.rotation;return t?[Jm(r[0],t,r[0]),Jm(r[1],t,r[0]),Jm(r[2],t,r[0]),Jm(r[3],t,r[0])]:r}function EB(e,r){if(e.length>4)return{min:0,max:0};var t=[];return e.forEach(function(i){t.push(Twt([i.x,i.y],r))}),{min:Math.min.apply(Math,t),max:Math.max.apply(Math,t)}}function Mwt(e,r){return e.max>r.min&&e.min<r.max}function Ewt(e){return Mt(e)&&!Number.isNaN(e)&&e!==1/0&&e!==-1/0}function FB(e){return Object.values(e).every(Ewt)}function Fwt(e,r,t){return t===void 0&&(t=0),!(r.x>e.x+e.width+t||r.x+r.width<e.x-t||r.y>e.y+e.height+t||r.y+r.height<e.y-t)}function Owt(e,r){if(!FB(e)||!FB(r))return!1;if(!e.rotation&&!r.rotation)return Fwt(e,r);for(var t=MB(e),i=MB(r),n=Qr(Qr([],TB(t),!0),TB(i),!0),a=0;a<n.length;a++){var o=n[a],l=EB(t,o),s=EB(i,o);if(!Mwt(l,s))return!1}return!0}function Pwt(e,r,t,i){for(var n=0;n<r.length;n++){var a=r[n];if(r[n].get("visible"))for(var o=n+1;o<r.length;o++){var l=r[o];if(a&&l&&a!==l&&l.get("visible")){var s=MT(a,e[n],I(e[n],"background.padding")),u=MT(l,e[o],I(e[o],"background.padding"));Owt(s,u)&&r[o].set("visible",!1)}}}}var OB={"#5B8FF9":!0},Iwt=function(e){var r=Qo.toRGB(e).toUpperCase();if(OB[r])return OB[r];var t=Qo.rgb2arr(r),i=t[0],n=t[1],a=t[2],o=(i*299+n*587+a*114)/1e3<128;return o};function Lwt(e,r,t){if(t.length!==0){var i=t[0].get("element"),n=i.geometry.theme,a=n.labels||{},o=a.fillColorLight,l=a.fillColorDark;t.forEach(function(s,u){var c=r[u],f=c.find(function(m){return m.get("type")==="text"}),h=Ei.fromObject(s.getBBox()),v=Ei.fromObject(f.getCanvasBBox()),d=!h.contains(v),p=s.attr("fill"),x=Iwt(p);d?f.attr(n.overflowLabels.style):x?o&&f.attr("fill",o):l&&f.attr("fill",l)})}}function Dwt(e,r,t){var i=e.coordinate,n=Cs(r),a=Ei.fromObject(n.getCanvasBBox()),o=Ei.fromObject(t.getBBox());return i.isTransposed?o.height>=a.height:o.width>=a.width}function $wt(e,r,t){var i=!!e.getAdjust("stack");return i||r.every(function(n,a){var o=t[a];return Dwt(e,n,o)})}function kwt(e,r,t){var i=e.coordinate,n=Ei.fromObject(t.getBBox()),a=Cs(r);i.isTransposed?a.attr({x:n.minX+n.width/2,textAlign:"center"}):a.attr({y:n.minY+n.height/2,textBaseline:"middle"})}function Rwt(e,r,t){var i;if(t.length!==0){var n=(i=t[0])===null||i===void 0?void 0:i.get("element"),a=n==null?void 0:n.geometry;if(!(!a||a.type!=="interval")){var o=$wt(a,r,t);o&&t.forEach(function(l,s){var u=r[s];kwt(a,u,l)})}}}function Bwt(e){var r=500,t=[],i=Math.max(Math.floor(e.length/r),1);return P(e,function(n,a){a%i===0?t.push(n):n.set("visible",!1)}),t}function Nwt(e,r,t){var i;if(t.length!==0){var n=(i=t[0])===null||i===void 0?void 0:i.get("element"),a=n==null?void 0:n.geometry;if(!(!a||a.type!=="interval")){var o=Bwt(r),l=a.getXYFields()[0],s=[],u=[],c=Xi(o,function(p){return p.get("data")[l]}),f=us(je(o,function(p){return p.get("data")[l]})),h;o.forEach(function(p){p.set("visible",!0)});var v=function(p){p&&(p.length&&u.push(p.pop()),u.push.apply(u,p))};for(yr(f)>0&&(h=f.shift(),v(c[h])),yr(f)>0&&(h=f.pop(),v(c[h])),P(f.reverse(),function(p){v(c[p])});u.length>0;){var d=u.shift();d.get("visible")&&(ybt(d,s)?d.set("visible",!1):s.push(d))}}}}function Gwt(e,r){var t=e.getXYFields()[1],i=[],n=r.sort(function(a,o){return a.get("data")[t]-a.get("data")[t]});return n.length>0&&i.push(n.shift()),n.length>0&&i.push(n.pop()),i.push.apply(i,n),i}function $W(e,r,t){return e.some(function(i){return t(i,r)})}function zwt(e,r,t){t===void 0&&(t=0);var i=Math.max(0,Math.min(e.x+e.width+t,r.x+r.width+t)-Math.max(e.x-t,r.x-t)),n=Math.max(0,Math.min(e.y+e.height+t,r.y+r.height+t)-Math.max(e.y-t,r.y-t));return i*n}function PB(e,r){return $W(e,r,function(t,i){var n=Cs(t),a=Cs(i);return zwt(n.getCanvasBBox(),a.getCanvasBBox(),2)>0})}function Vwt(e,r,t,i,n){var a,o;if(t.length!==0){var l=(a=t[0])===null||a===void 0?void 0:a.get("element"),s=l==null?void 0:l.geometry;if(!(!s||s.type!=="point")){var u=s.getXYFields(),c=u[0],f=u[1],h=Xi(r,function(p){return p.get("data")[c]}),v=[],d=n&&n.offset||((o=e[0])===null||o===void 0?void 0:o.offset)||12;je(lc(h).reverse(),function(p){for(var x=Gwt(s,h[p]);x.length;){var m=x.shift(),_=Cs(m);if($W(v,m,function(S,M){return S.get("data")[c]===M.get("data")[c]&&S.get("data")[f]===M.get("data")[f]})){_.set("visible",!1);continue}var b=PB(v,m),w=!1;if(b&&(_.attr("y",_.attr("y")+2*d),w=PB(v,m)),w){_.set("visible",!1);continue}v.push(m)}})}}}function jwt(e,r){var t=e.getXYFields()[1],i=[],n=r.sort(function(a,o){return a.get("data")[t]-a.get("data")[t]});return n.length>0&&i.push(n.shift()),n.length>0&&i.push(n.pop()),i.push.apply(i,n),i}function kW(e,r,t){return e.some(function(i){return t(i,r)})}function Hwt(e,r,t){t===void 0&&(t=0);var i=Math.max(0,Math.min(e.x+e.width+t,r.x+r.width+t)-Math.max(e.x-t,r.x-t)),n=Math.max(0,Math.min(e.y+e.height+t,r.y+r.height+t)-Math.max(e.y-t,r.y-t));return i*n}function IB(e,r){return kW(e,r,function(t,i){var n=Cs(t),a=Cs(i);return Hwt(n.getCanvasBBox(),a.getCanvasBBox(),2)>0})}function Ywt(e,r,t,i,n){var a,o;if(t.length!==0){var l=(a=t[0])===null||a===void 0?void 0:a.get("element"),s=l==null?void 0:l.geometry;if(!(!s||["path","line","area"].indexOf(s.type)<0)){var u=s.getXYFields(),c=u[0],f=u[1],h=Xi(r,function(p){return p.get("data")[c]}),v=[],d=n&&n.offset||((o=e[0])===null||o===void 0?void 0:o.offset)||12;je(lc(h).reverse(),function(p){for(var x=jwt(s,h[p]);x.length;){var m=x.shift(),_=Cs(m);if(kW(v,m,function(S,M){return S.get("data")[c]===M.get("data")[c]&&S.get("data")[f]===M.get("data")[f]})){_.set("visible",!1);continue}var b=IB(v,m),w=!1;if(b&&(_.attr("y",_.attr("y")+2*d),w=IB(v,m)),w){_.set("visible",!1);continue}v.push(m)}})}}}var SS;function Wwt(){return SS||(SS=document.createElement("canvas").getContext("2d")),SS}var t0=uc(function(e,r){r===void 0&&(r={});var t=r.fontSize,i=r.fontFamily,n=r.fontWeight,a=r.fontStyle,o=r.fontVariant,l=Wwt();return l.font=[a,o,n,t+"px",i].join(" "),l.measureText(Ct(e)?e:"").width},function(e,r){return r===void 0&&(r={}),Qr([e],_h(r),!0).join("")}),Xwt=function(e,r,t){var i=16,n=t0("...",t),a;Ct(e)?a=e:a=Fs(e);var o=r,l=[],s,u;if(t0(e,t)<=r)return e;for(;s=a.substr(0,i),u=t0(s,t),!(u+n>o&&u>o);)if(l.push(s),o-=u,a=a.substr(i),!a)return l.join("");for(;s=a.substr(0,1),u=t0(s,t),!(u+n>o);)if(l.push(s),o-=u,a=a.substr(1),!a)return l.join("");return l.join("")+"..."};function Uwt(e,r,t,i,n){if(!(r.length<=0)){var a=(n==null?void 0:n.direction)||["top","right","bottom","left"],o=(n==null?void 0:n.action)||"translate",l=(n==null?void 0:n.margin)||0,s=r[0].get("coordinate");if(!!s){var u=v_t(s,l),c=u.minX,f=u.minY,h=u.maxX,v=u.maxY;P(r,function(d){var p=d.getCanvasBBox(),x=p.minX,m=p.minY,_=p.maxX,b=p.maxY,w=p.x,S=p.y,M=p.width,F=p.height,O=w,L=S;if(a.indexOf("left")>=0&&(x<c||_<c)&&(O=c),a.indexOf("top")>=0&&(m<f||b<f)&&(L=f),a.indexOf("right")>=0&&(x>h?O=h-M:_>h&&(O=O-(_-h))),a.indexOf("bottom")>=0&&(m>v?L=v-F:b>v&&(L=L-(b-v))),O!==w||L!==S){var D=O-w;if(o==="translate")pg(d,D,L-S);else if(o==="ellipsis"){var k=d.findAll(function(H){return H.get("type")==="text"});k.forEach(function(H){var B=r1(H.attr(),["fontSize","fontFamily","fontWeight","fontStyle","fontVariant"]),j=H.getCanvasBBox(),U=Xwt(H.attr("text"),j.width-Math.abs(D),B);H.attr("text",U)})}else d.hide()}})}}}function qwt(e,r,t){var i={fillOpacity:K(e.attr("fillOpacity"))?1:e.attr("fillOpacity"),strokeOpacity:K(e.attr("strokeOpacity"))?1:e.attr("strokeOpacity"),opacity:K(e.attr("opacity"))?1:e.attr("opacity")};e.attr({fillOpacity:0,strokeOpacity:0,opacity:0}),e.animate(i,r)}function Zwt(e,r,t){var i={fillOpacity:0,strokeOpacity:0,opacity:0},n=r.easing,a=r.duration,o=r.delay;e.animate(i,a,n,function(){e.remove(!0)},o)}function Qwt(e,r,t){var i,n=r[0],a=r[1];return e.applyToMatrix([n,a,1]),t==="x"?(e.setMatrix(rr(e.getMatrix(),[["t",-n,-a],["s",.01,1],["t",n,a]])),i=rr(e.getMatrix(),[["t",-n,-a],["s",100,1],["t",n,a]])):t==="y"?(e.setMatrix(rr(e.getMatrix(),[["t",-n,-a],["s",1,.01],["t",n,a]])),i=rr(e.getMatrix(),[["t",-n,-a],["s",1,100],["t",n,a]])):t==="xy"&&(e.setMatrix(rr(e.getMatrix(),[["t",-n,-a],["s",.01,.01],["t",n,a]])),i=rr(e.getMatrix(),[["t",-n,-a],["s",100,100],["t",n,a]])),i}function HO(e,r,t,i,n){var a=t.start,o=t.end,l=t.getWidth(),s=t.getHeight(),u,c;n==="y"?(u=a.x+l/2,c=i.y<a.y?i.y:a.y):n==="x"?(u=i.x>a.x?i.x:a.x,c=a.y+s/2):n==="xy"&&(t.isPolar?(u=t.getCenter().x,c=t.getCenter().y):(u=(a.x+o.x)/2,c=(a.y+o.y)/2));var f=Qwt(e,[u,c],n);e.animate({matrix:f},r)}function Kwt(e,r,t){var i=t.coordinate,n=t.minYPoint;HO(e,r,i,n,"x")}function Jwt(e,r,t){var i=t.coordinate,n=t.minYPoint;HO(e,r,i,n,"y")}function tCt(e,r,t){var i=t.coordinate,n=t.minYPoint;HO(e,r,i,n,"xy")}function eCt(e,r,t){var i=e.getTotalLength();e.attr("lineDash",[i]),e.animate(function(n){return{lineDashOffset:(1-n)*i}},r)}function rCt(e,r,t){var i=t.toAttrs,n=i.x,a=i.y;delete i.x,delete i.y,e.attr(i),e.animate({x:n,y:a},r)}function iCt(e,r,t){var i=e.getBBox(),n=e.get("origin").mappingData,a=n.points,o=a[0].y-a[1].y>0?i.maxX:i.minX,l=(i.minY+i.maxY)/2;e.applyToMatrix([o,l,1]);var s=rr(e.getMatrix(),[["t",-o,-l],["s",.01,1],["t",o,l]]);e.setMatrix(s),e.animate({matrix:rr(e.getMatrix(),[["t",-o,-l],["s",100,1],["t",o,l]])},r)}function nCt(e,r,t){var i=e.getBBox(),n=e.get("origin").mappingData,a=(i.minX+i.maxX)/2,o=n.points,l=o[0].y-o[1].y<=0?i.maxY:i.minY;e.applyToMatrix([a,l,1]);var s=rr(e.getMatrix(),[["t",-a,-l],["s",1,.01],["t",a,l]]);e.setMatrix(s),e.animate({matrix:rr(e.getMatrix(),[["t",-a,-l],["s",1,100],["t",a,l]])},r)}function LB(e,r){var t,i=lx(e,r),n=i.startAngle,a=i.endAngle;return!zr(n,-Math.PI*.5)&&n<-Math.PI*.5&&(n+=Math.PI*2),!zr(a,-Math.PI*.5)&&a<-Math.PI*.5&&(a+=Math.PI*2),r[5]===0&&(t=[a,n],n=t[0],a=t[1]),zr(n,Math.PI*1.5)&&(n=Math.PI*-.5),zr(a,Math.PI*-.5)&&(a=Math.PI*1.5),{startAngle:n,endAngle:a}}function DB(e){var r;return e[0]==="M"||e[0]==="L"?r=[e[1],e[2]]:(e[0]==="a"||e[0]==="A"||e[0]==="C")&&(r=[e[e.length-2],e[e.length-1]]),r}function $B(e){var r,t,i,n=e.filter(function(b){return b[0]==="A"||b[0]==="a"});if(n.length===0)return{startAngle:0,endAngle:0,radius:0,innerRadius:0};var a=n[0],o=n.length>1?n[1]:n[0],l=e.indexOf(a),s=e.indexOf(o),u=DB(e[l-1]),c=DB(e[s-1]),f=LB(u,a),h=f.startAngle,v=f.endAngle,d=LB(c,o),p=d.startAngle,x=d.endAngle;zr(h,p)&&zr(v,x)?(t=h,i=v):(t=Math.min(h,p),i=Math.max(v,x));var m=a[1],_=n[n.length-1][1];return m<_?(r=[_,m],m=r[0],_=r[1]):m===_&&(_=0),{startAngle:t,endAngle:i,radius:m,innerRadius:_}}function aCt(e,r,t){var i=t.toAttrs,n=t.coordinate,a=i.path||[],o=a.map(function(_){return _[0]});if(!(a.length<1)){var l=$B(a),s=l.startAngle,u=l.endAngle,c=l.radius,f=l.innerRadius,h=$B(e.attr("path")),v=h.startAngle,d=h.endAngle,p=n.getCenter(),x=s-v,m=u-d;if(x===0&&m===0){e.attr("path",a);return}e.animate(function(_){var b=v+_*x,w=d+_*m;return A(A({},i),{path:Ge(o,["M","A","A","Z"])?VY(p.x,p.y,c,b,w):es(p.x,p.y,c,b,w,f)})},A(A({},r),{callback:function(){e.attr("path",a)}}))}}function oCt(e,r,t){var i=HY(t.coordinate,20),n=i.type,a=i.startState,o=i.endState,l=e.setClip({type:n,attrs:a});l.animate(o,A(A({},r),{callback:function(){e&&!e.get("destroyed")&&e.set("clipShape",null),l.remove(!0)}}))}function YO(e,r,t){if(e.isGroup())P(e.getChildren(),function(l){YO(l,r,t)});else{var i=e.getBBox(),n=(i.minX+i.maxX)/2,a=(i.minY+i.maxY)/2;if(e.applyToMatrix([n,a,1]),t==="zoomIn"){var o=rr(e.getMatrix(),[["t",-n,-a],["s",.01,.01],["t",n,a]]);e.setMatrix(o),e.animate({matrix:rr(e.getMatrix(),[["t",-n,-a],["s",100,100],["t",n,a]])},r)}else e.animate({matrix:rr(e.getMatrix(),[["t",-n,-a],["s",.01,.01],["t",n,a]])},A(A({},r),{callback:function(){e.remove(!0)}}))}}function lCt(e,r,t){YO(e,r,"zoomIn")}function sCt(e,r,t){YO(e,r,"zoomOut")}function sl(e){return[ct.TOP,ct.BOTTOM].includes(e)?{offsetX:0,offsetY:e===ct.TOP?-8:8,style:{textAlign:"center",textBaseline:e===ct.TOP?"bottom":"top"}}:[ct.LEFT,ct.RIGHT].includes(e)?{offsetX:e===ct.LEFT?-8:8,offsetY:0,style:{textAlign:e===ct.LEFT?"right":"left",textBaseline:"middle",rotate:Math.PI/2}}:{}}function AS(e,r,t){return{x:e.x+r*Math.cos(t),y:e.y+r*Math.sin(t)}}var uCt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){return ft({},e.prototype.getDefaultCfg.call(this),{type:"circle",showTitle:!0,title:e.prototype.getDefaultTitleCfg.call(this)})},r.prototype.render=function(){e.prototype.render.call(this),this.cfg.showTitle&&this.renderTitle()},r.prototype.getRegion=function(t,i){var n=.5,a={x:.5,y:.5},o=Math.PI*2/t,l=-1*Math.PI/2+o*i,s=n/(1+1/Math.sin(o/2)),u=AS(a,n-s,l),c=Math.PI*5/4,f=Math.PI*1/4;return{start:AS(u,s,c),end:AS(u,s,f)}},r.prototype.afterEachView=function(t,i){this.processAxis(t,i)},r.prototype.beforeEachView=function(t,i){},r.prototype.generateFacets=function(t){var i=this,n=this.cfg,a=n.fields,o=n.type,l=a[0];if(!l)throw new Error("No `fields` specified!");var s=this.getFieldValues(t,l),u=s.length,c=[];return s.forEach(function(f,h){var v=[{field:l,value:f,values:s}],d=jr(t,i.getFacetDataFilter(v)),p={type:o,data:d,region:i.getRegion(u,h),columnValue:f,columnField:l,columnIndex:h,columnValuesLength:u,rowValue:null,rowField:null,rowIndex:0,rowValuesLength:1};c.push(p)}),c},r.prototype.getXAxisOption=function(t,i,n,a){return n},r.prototype.getYAxisOption=function(t,i,n,a){return n},r.prototype.renderTitle=function(){var t=this;P(this.facets,function(i){var n=i.columnValue,a=i.view,o=I(t.cfg.title,"formatter"),l=ft({position:["50%","0%"],content:o?o(n):n},sl(ct.TOP),t.cfg.title);a.annotation().text(l)})},r}(vc),cCt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){return ft({},e.prototype.getDefaultCfg.call(this),{type:"list",cols:null,showTitle:!0,title:e.prototype.getDefaultTitleCfg.call(this)})},r.prototype.render=function(){e.prototype.render.call(this),this.cfg.showTitle&&this.renderTitle()},r.prototype.afterEachView=function(t,i){this.processAxis(t,i)},r.prototype.beforeEachView=function(t,i){},r.prototype.generateFacets=function(t){var i=this,n=this.cfg.fields,a=this.cfg.cols,o=n[0];if(!o)throw new Error("No `fields` specified!");var l=this.getFieldValues(t,o),s=l.length;a=a||s;var u=this.getPageCount(s,a),c=[];return l.forEach(function(f,h){var v=i.getRowCol(h,a),d=v.row,p=v.col,x=[{field:o,value:f,values:l}],m=jr(t,i.getFacetDataFilter(x)),_={type:i.cfg.type,data:m,region:i.getRegion(u,a,p,d),columnValue:f,rowValue:f,columnField:o,rowField:null,columnIndex:p,rowIndex:d,columnValuesLength:a,rowValuesLength:u,total:s};c.push(_)}),c},r.prototype.getXAxisOption=function(t,i,n,a){return a.rowIndex!==a.rowValuesLength-1&&a.columnValuesLength*a.rowIndex+a.columnIndex+1+a.columnValuesLength<=a.total?A(A({},n),{label:null,title:null}):n},r.prototype.getYAxisOption=function(t,i,n,a){return a.columnIndex!==0?A(A({},n),{title:null,label:null}):n},r.prototype.renderTitle=function(){var t=this;P(this.facets,function(i){var n=i.columnValue,a=i.view,o=I(t.cfg.title,"formatter"),l=ft({position:["50%","0%"],content:o?o(n):n},sl(ct.TOP),t.cfg.title);a.annotation().text(l)})},r.prototype.getPageCount=function(t,i){return Math.floor((t+i-1)/i)},r.prototype.getRowCol=function(t,i){var n=Math.floor(t/i),a=t%i;return{row:n,col:a}},r}(vc),fCt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){return ft({},e.prototype.getDefaultCfg.call(this),{type:"matrix",showTitle:!1,columnTitle:A({},e.prototype.getDefaultTitleCfg.call(this)),rowTitle:A({},e.prototype.getDefaultTitleCfg.call(this))})},r.prototype.render=function(){e.prototype.render.call(this),this.cfg.showTitle&&this.renderTitle()},r.prototype.afterEachView=function(t,i){this.processAxis(t,i)},r.prototype.beforeEachView=function(t,i){},r.prototype.generateFacets=function(t){for(var i=this.cfg,n=i.fields,a=i.type,o=n.length,l=o,s=[],u=0;u<l;u++)for(var c=n[u],f=0;f<o;f++){var h=n[f],v={type:a,data:t,region:this.getRegion(o,l,u,f),columnValue:c,rowValue:h,columnField:c,rowField:h,columnIndex:u,rowIndex:f,columnValuesLength:l,rowValuesLength:o};s.push(v)}return s},r.prototype.getXAxisOption=function(t,i,n,a){return a.rowIndex!==a.rowValuesLength-1?A(A({},n),{label:null,title:null}):n},r.prototype.getYAxisOption=function(t,i,n,a){return a.columnIndex!==0?A(A({},n),{title:null,label:null}):n},r.prototype.renderTitle=function(){var t=this;P(this.facets,function(i,n){var a=i.columnIndex,o=i.rowIndex,l=i.columnValuesLength;i.rowValuesLength;var s=i.columnValue,u=i.rowValue,c=i.view;if(o===0){var f=I(t.cfg.columnTitle,"formatter"),h=ft({position:["50%","0%"],content:f?f(s):s},sl(ct.TOP),t.cfg.columnTitle);c.annotation().text(h)}if(a===l-1){var f=I(t.cfg.rowTitle,"formatter"),h=ft({position:["100%","50%"],content:f?f(u):u},sl(ct.RIGHT),t.cfg.rowTitle);c.annotation().text(h)}})},r}(vc),hCt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getDefaultCfg=function(){return ft({},e.prototype.getDefaultCfg.call(this),{type:"mirror",showTitle:!0,title:e.prototype.getDefaultTitleCfg.call(this),transpose:!1})},r.prototype.render=function(){e.prototype.render.call(this),this.cfg.showTitle&&this.renderTitle()},r.prototype.beforeEachView=function(t,i){this.cfg.transpose?i.columnIndex%2===0?t.coordinate().transpose().reflect("x"):t.coordinate().transpose():i.rowIndex%2!==0&&t.coordinate().reflect("y")},r.prototype.afterEachView=function(t,i){this.processAxis(t,i)},r.prototype.generateFacets=function(t){var i=this,n=this.cfg.fields[0],a=[],o=1,l=1,s=[""],u=[""],c,f;return this.cfg.transpose?(c=n,s=this.getFieldValues(t,c).slice(0,2),o=s.length):(f=n,u=this.getFieldValues(t,f).slice(0,2),l=u.length),s.forEach(function(h,v){u.forEach(function(d,p){var x=[{field:c,value:h,values:s},{field:f,value:d,values:u}],m=jr(t,i.getFacetDataFilter(x)),_={type:i.cfg.type,data:m,region:i.getRegion(l,o,v,p),columnValue:h,rowValue:d,columnField:c,rowField:f,columnIndex:v,rowIndex:p,columnValuesLength:o,rowValuesLength:l};a.push(_)})}),a},r.prototype.getXAxisOption=function(t,i,n,a){return a.columnIndex===1||a.rowIndex===1?A(A({},n),{label:null,title:null}):n},r.prototype.getYAxisOption=function(t,i,n,a){return n},r.prototype.renderTitle=function(){var t=this;P(this.facets,function(i,n){var a=i.columnValue,o=i.rowValue,l=i.view,s=I(t.cfg.title,"formatter");if(t.cfg.transpose){var u=ft({position:["50%","0%"],content:s?s(a):a},sl(ct.TOP),t.cfg.title);l.annotation().text(u)}else{var u=ft({position:["100%","50%"],content:s?s(o):o},sl(ct.RIGHT),t.cfg.title);l.annotation().text(u)}})},r}(vc),vCt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.afterEachView=function(t,i){this.processAxis(t,i)},r.prototype.beforeEachView=function(t,i){},r.prototype.getDefaultCfg=function(){return ft({},e.prototype.getDefaultCfg.call(this),{type:"rect",columnTitle:A({},e.prototype.getDefaultTitleCfg.call(this)),rowTitle:A({},e.prototype.getDefaultTitleCfg.call(this))})},r.prototype.render=function(){e.prototype.render.call(this),this.cfg.showTitle&&this.renderTitle()},r.prototype.generateFacets=function(t){var i=this,n=this.cfg.fields,a=n[0],o=n[1],l=[],s=1,u=1,c=[""],f=[""];return a&&(c=this.getFieldValues(t,a),s=c.length),o&&(f=this.getFieldValues(t,o),u=f.length),c.forEach(function(h,v){f.forEach(function(d,p){var x=[{field:a,value:h,values:c},{field:o,value:d,values:f}],m=jr(t,i.getFacetDataFilter(x)),_={type:i.cfg.type,data:m,region:i.getRegion(u,s,v,p),columnValue:h,rowValue:d,columnField:a,rowField:o,columnIndex:v,rowIndex:p,columnValuesLength:s,rowValuesLength:u};l.push(_)})}),l},r.prototype.renderTitle=function(){var t=this;P(this.facets,function(i,n){var a=i.columnIndex,o=i.rowIndex,l=i.columnValuesLength,s=i.columnValue,u=i.rowValue,c=i.view;if(o===0){var f=I(t.cfg.columnTitle,"formatter"),h=ft({position:["50%","0%"],content:f?f(s):s},sl(ct.TOP),t.cfg.columnTitle);c.annotation().text(h)}if(a===l-1){var f=I(t.cfg.rowTitle,"formatter"),h=ft({position:["100%","50%"],content:f?f(u):u},sl(ct.RIGHT),t.cfg.rowTitle);c.annotation().text(h)}})},r.prototype.getXAxisOption=function(t,i,n,a){return a.rowIndex!==a.rowValuesLength-1?A(A({},n),{title:null,label:null}):a.columnIndex!==Math.floor((a.columnValuesLength-1)/2)?A(A({},n),{title:null}):n},r.prototype.getYAxisOption=function(t,i,n,a){return a.columnIndex!==0?A(A({},n),{title:null,label:null}):a.rowIndex!==Math.floor((a.rowValuesLength-1)/2)?A(A({},n),{title:null}):n},r}(vc),dCt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.afterChartRender=function(){t.facets&&t.cfg.line&&(t.container.clear(),t.drawLines(t.facets))},t}return r.prototype.afterEachView=function(t,i){this.processAxis(t,i)},r.prototype.beforeEachView=function(t,i){},r.prototype.init=function(){e.prototype.init.call(this),this.view.on(Gt.AFTER_RENDER,this.afterChartRender)},r.prototype.getDefaultCfg=function(){return ft({},e.prototype.getDefaultCfg.call(this),{type:"tree",line:{style:{lineWidth:1,stroke:"#ddd"},smooth:!1},showTitle:!0,title:e.prototype.getDefaultTitleCfg.call(this)})},r.prototype.generateFacets=function(t){var i=this.cfg.fields;if(!i.length)throw new Error("Please specify for the fields for rootFacet!");var n=[],a={type:this.cfg.type,data:t,region:null,rowValuesLength:this.getRows(),columnValuesLength:1,rowIndex:0,columnIndex:0,rowField:"",columnField:"",rowValue:"",columnValue:""};return n.push(a),a.children=this.getChildFacets(t,1,n),this.setRegion(n),n},r.prototype.setRegion=function(t){var i=this;this.forceColIndex(t),t.forEach(function(n){n.region=i.getRegion(n.rowValuesLength,n.columnValuesLength,n.columnIndex,n.rowIndex)})},r.prototype.getRegion=function(t,i,n,a){var o=1/i,l=1/t,s={x:o*n,y:l*a},u={x:s.x+o,y:s.y+l*2/3};return{start:s,end:u}},r.prototype.forceColIndex=function(t){var i=this,n=[],a=0;t.forEach(function(h){i.isLeaf(h)&&(n.push(h),h.columnIndex=a,a++)}),n.forEach(function(h){h.columnValuesLength=n.length});for(var o=this.cfg.fields.length,l=o-1;l>=0;l--)for(var s=this.getFacetsByLevel(t,l),u=0,c=s;u<c.length;u++){var f=c[u];this.isLeaf(f)||(f.originColIndex=f.columnIndex,f.columnIndex=this.getRegionIndex(f.children),f.columnValuesLength=n.length)}},r.prototype.getFacetsByLevel=function(t,i){var n=[];return t.forEach(function(a){a.rowIndex===i&&n.push(a)}),n},r.prototype.getRegionIndex=function(t){var i=t[0],n=t[t.length-1];return(n.columnIndex-i.columnIndex)/2+i.columnIndex},r.prototype.isLeaf=function(t){return!t.children||!t.children.length},r.prototype.getRows=function(){return this.cfg.fields.length+1},r.prototype.getChildFacets=function(t,i,n){var a=this,o=this.cfg.fields,l=o.length;if(!(l<i)){var s=[],u=o[i-1],c=this.getFieldValues(t,u);return c.forEach(function(f,h){var v=[{field:u,value:f,values:c}],d=t.filter(a.getFacetDataFilter(v));if(d.length){var p={type:a.cfg.type,data:d,region:null,columnValue:f,rowValue:"",columnField:u,rowField:"",columnIndex:h,rowValuesLength:a.getRows(),columnValuesLength:1,rowIndex:i,children:a.getChildFacets(d,i+1,n)};s.push(p),n.push(p)}}),s}},r.prototype.render=function(){e.prototype.render.call(this),this.cfg.showTitle&&this.renderTitle()},r.prototype.renderTitle=function(){var t=this;P(this.facets,function(i){var n=i.columnValue,a=i.view,o=I(t.cfg.title,"formatter"),l=ft({position:["50%","0%"],content:o?o(n):n},sl(ct.TOP),t.cfg.title);a.annotation().text(l)})},r.prototype.drawLines=function(t){var i=this;t.forEach(function(n){if(!i.isLeaf(n)){var a=n.children;i.addFacetLines(n,a)}})},r.prototype.addFacetLines=function(t,i){var n=this,a=t.view,o=a.coordinateBBox,l={x:o.x+o.width/2,y:o.y+o.height};i.forEach(function(s){var u=s.view.coordinateBBox,c={x:u.bl.x+(u.tr.x-u.bl.x)/2,y:u.tr.y},f={x:l.x,y:l.y+(c.y-l.y)/2},h={x:c.x,y:f.y};n.drawLine([l,f,h,c])})},r.prototype.getPath=function(t){var i=[],n=this.cfg.line.smooth;return n?(i.push(["M",t[0].x,t[0].y]),i.push(["C",t[1].x,t[1].y,t[2].x,t[2].y,t[3].x,t[3].y])):t.forEach(function(a,o){o===0?i.push(["M",a.x,a.y]):i.push(["L",a.x,a.y])}),i},r.prototype.drawLine=function(t){var i=this.getPath(t),n=this.cfg.line.style;this.container.addShape("path",{attrs:Kt({path:i},n)})},r.prototype.getXAxisOption=function(t,i,n,a){return a.rowIndex!==a.rowValuesLength-1?A(A({},n),{title:null,label:null}):n},r.prototype.getYAxisOption=function(t,i,n,a){return a.originColIndex!==0&&a.columnIndex!==0?A(A({},n),{title:null,label:null}):n},r}(vc);function kB(e){var r=Qr([],e,!0);r.sort(function(i,n){return i-n});var t=r.length;return t===0?0:t%2===1?r[(t-1)/2]:(r[t/2]+r[t/2-1])/2}function pCt(e){var r=Kr(e,function(t,i){return t+=isNaN(i)||!Mt(i)?0:i},0);return e.length===0?0:r/e.length}function e0(e,r){if(!r)return null;var t;switch(e){case"start":return 0;case"center":return .5;case"end":return 1;case"median":{t=r.isCategory?kB(r.values.map(function(i,n){return n})):kB(r.values);break}case"mean":{t=r.isCategory?(r.values.length-1)/2:pCt(r.values);break}case"min":t=r.isCategory?0:r[e];break;case"max":t=r.isCategory?r.values.length-1:r[e];break;default:t=e;break}return r.scale(t)}var r0=["regionFilter","shape"],gCt=function(e){X(r,e);function r(t){var i=e.call(this,t)||this;return i.cache=new Map,i.foregroundContainer=i.view.getLayer(Ye.FORE).addGroup(),i.backgroundContainer=i.view.getLayer(Ye.BG).addGroup(),i.option=[],i}return Object.defineProperty(r.prototype,"name",{get:function(){return"annotation"},enumerable:!1,configurable:!0}),r.prototype.init=function(){},r.prototype.layout=function(){this.update()},r.prototype.render=function(){},r.prototype.update=function(){var t=this;this.onAfterRender(function(){var n=new Map;P(t.option,function(a){if(eo(r0,a.type)){var o=t.updateOrCreate(a);o&&n.set(t.getCacheKey(a),o)}}),t.cache=t.syncCache(n)});var i=new Map;P(this.option,function(n){if(!eo(r0,n.type)){var a=t.updateOrCreate(n);a&&i.set(t.getCacheKey(n),a)}}),this.cache=this.syncCache(i)},r.prototype.clear=function(t){t===void 0&&(t=!1),e.prototype.clear.call(this),this.clearComponents(),this.foregroundContainer.clear(),this.backgroundContainer.clear(),t&&(this.option=[])},r.prototype.destroy=function(){this.clear(!0),this.foregroundContainer.remove(!0),this.backgroundContainer.remove(!0)},r.prototype.getComponents=function(){var t=[];return this.cache.forEach(function(i){t.push(i)}),t},r.prototype.clearComponents=function(){this.getComponents().forEach(function(t){t.component.destroy()}),this.cache.clear()},r.prototype.onAfterRender=function(t){this.view.getOptions().animate?this.view.geometries.forEach(function(i){i.animateOption&&i.once(Of.AFTER_DRAW_ANIMATE,function(){t()})}):this.view.getRootView().once(Gt.AFTER_RENDER,function(){t()})},r.prototype.createAnnotation=function(t){var i=t.type,n=M5[Os(i)];if(n){var a=this.getAnnotationTheme(i),o=this.getAnnotationCfg(i,t,a),l=new n(o);return{component:l,layer:this.isTop(o)?Ye.FORE:Ye.BG,direction:ct.NONE,type:Mr.ANNOTATION,extra:t}}},r.prototype.annotation=function(t){this.option.push(t)},r.prototype.arc=function(t){return this.annotation(A({type:"arc"},t)),this},r.prototype.image=function(t){return this.annotation(A({type:"image"},t)),this},r.prototype.line=function(t){return this.annotation(A({type:"line"},t)),this},r.prototype.region=function(t){return this.annotation(A({type:"region"},t)),this},r.prototype.text=function(t){return this.annotation(A({type:"text"},t)),this},r.prototype.dataMarker=function(t){return this.annotation(A({type:"dataMarker"},t)),this},r.prototype.dataRegion=function(t){this.annotation(A({type:"dataRegion"},t))},r.prototype.regionFilter=function(t){this.annotation(A({type:"regionFilter"},t))},r.prototype.shape=function(t){this.annotation(A({type:"shape"},t))},r.prototype.html=function(t){this.annotation(A({type:"html"},t))},r.prototype.parsePosition=function(t){var i=this.view.getXScale(),n=this.view.getScalesByDim("y"),a=pt(t)?t.call(null,i,n):t,o=0,l=0;if(it(a)){var s=a[0],u=a[1];if(Ct(s)&&s.indexOf("%")!==-1&&!isNaN(s.slice(0,-1)))return this.parsePercentPosition(a);o=e0(s,i),l=e0(u,Object.values(n)[0])}else if(!K(a))for(var c=0,f=lc(a);c<f.length;c++){var h=f[c],v=a[h];h===i.field&&(o=e0(v,i)),n[h]&&(l=e0(v,n[h]))}return this.view.getCoordinate().convert({x:o,y:l})},r.prototype.getRegionPoints=function(t,i){var n=this,a=this.view.getXScale(),o=this.view.getScalesByDim("y"),l=Object.values(o)[0],s=a.field,u=this.view.getData(),c=it(t)?t[0]:t[s],f=it(i)?i[0]:i[s],h=[],v;return P(u,function(d,p){if(d[s]===c&&(v=p),p>=v){var x=n.parsePosition([d[s],d[l.field]]);x&&h.push(x)}if(d[s]===f)return!1}),h},r.prototype.parsePercentPosition=function(t){var i=parseFloat(t[0])/100,n=parseFloat(t[1])/100,a=this.view.getCoordinate(),o=a.start,l=a.end,s={x:Math.min(o.x,l.x),y:Math.min(o.y,l.y)},u=a.getWidth()*i+s.x,c=a.getHeight()*n+s.y;return{x:u,y:c}},r.prototype.getCoordinateBBox=function(){var t=this.view.getCoordinate(),i=t.start,n=t.end,a=t.getWidth(),o=t.getHeight(),l={x:Math.min(i.x,n.x),y:Math.min(i.y,n.y)};return{x:l.x,y:l.y,minX:l.x,minY:l.y,maxX:l.x+a,maxY:l.y+o,width:a,height:o}},r.prototype.getAnnotationCfg=function(t,i,n){var a=this,o=this.view.getCoordinate(),l=this.view.getCanvas(),s={};if(K(i))return null;if(t==="arc"){var u=i,c=u.start,f=u.end,h=ue(u,["start","end"]),v=this.parsePosition(c),d=this.parsePosition(f),p=Kf(o,v),x=Kf(o,d);p>x&&(x=Math.PI*2+x),s=A(A({},h),{center:o.getCenter(),radius:T_(o,v),startAngle:p,endAngle:x})}else if(t==="image"){var m=i,c=m.start,f=m.end,h=ue(m,["start","end"]);s=A(A({},h),{start:this.parsePosition(c),end:this.parsePosition(f),src:i.src})}else if(t==="line"){var _=i,c=_.start,f=_.end,h=ue(_,["start","end"]);s=A(A({},h),{start:this.parsePosition(c),end:this.parsePosition(f),text:I(i,"text",null)})}else if(t==="region"){var b=i,c=b.start,f=b.end,h=ue(b,["start","end"]);s=A(A({},h),{start:this.parsePosition(c),end:this.parsePosition(f)})}else if(t==="text"){var w=this.view.getData(),S=i,M=S.position,F=S.content,h=ue(S,["position","content"]),O=F;pt(F)&&(O=F(w)),s=A(A(A({},this.parsePosition(M)),h),{content:O})}else if(t==="dataMarker"){var L=i,M=L.position,D=L.point,k=L.line,H=L.text,B=L.autoAdjust,j=L.direction,h=ue(L,["position","point","line","text","autoAdjust","direction"]);s=A(A(A({},h),this.parsePosition(M)),{coordinateBBox:this.getCoordinateBBox(),point:D,line:k,text:H,autoAdjust:B,direction:j})}else if(t==="dataRegion"){var U=i,c=U.start,f=U.end,R=U.region,H=U.text,G=U.lineLength,h=ue(U,["start","end","region","text","lineLength"]);s=A(A({},h),{points:this.getRegionPoints(c,f),region:R,text:H,lineLength:G})}else if(t==="regionFilter"){var N=i,c=N.start,f=N.end,W=N.apply,q=N.color,h=ue(N,["start","end","apply","color"]),tt=this.view.geometries,ot=[],st=function(Nt){!Nt||(Nt.isGroup()?Nt.getChildren().forEach(function(pe){return st(pe)}):ot.push(Nt))};P(tt,function(Nt){W?eo(W,Nt.type)&&P(Nt.elements,function(pe){st(pe.shape)}):P(Nt.elements,function(pe){st(pe.shape)})}),s=A(A({},h),{color:q,shapes:ot,start:this.parsePosition(c),end:this.parsePosition(f)})}else if(t==="shape"){var Z=i,et=Z.render,lt=ue(Z,["render"]),dt=function(_t){if(pt(i.render))return et(_t,a.view,{parsePosition:a.parsePosition.bind(a)})};s=A(A({},lt),{render:dt})}else if(t==="html"){var ht=i,wt=ht.html,M=ht.position,lt=ue(ht,["html","position"]),gt=function(qt){return pt(wt)?wt(qt,a.view):wt};s=A(A(A({},lt),this.parsePosition(M)),{parent:l.get("el").parentNode,html:gt})}var vt=ft({},n,A(A({},s),{top:i.top,style:i.style,offsetX:i.offsetX,offsetY:i.offsetY}));return t!=="html"&&(vt.container=this.getComponentContainer(vt)),vt.animate=this.view.getOptions().animate&&vt.animate&&I(i,"animate",vt.animate),vt.animateOption=ft({},eh,vt.animateOption,i.animateOption),vt},r.prototype.isTop=function(t){return I(t,"top",!0)},r.prototype.getComponentContainer=function(t){return this.isTop(t)?this.foregroundContainer:this.backgroundContainer},r.prototype.getAnnotationTheme=function(t){return I(this.view.getTheme(),["components","annotation",t],{})},r.prototype.updateOrCreate=function(t){var i=this.cache.get(this.getCacheKey(t));if(i){var n=t.type,a=this.getAnnotationTheme(n),o=this.getAnnotationCfg(n,t,a);Gi(o,["container"]),i.component.update(o),eo(r0,t.type)&&i.component.render()}else i=this.createAnnotation(t),i&&(i.component.init(),eo(r0,t.type)&&i.component.render());return i},r.prototype.syncCache=function(t){var i=this,n=new Map(this.cache);return t.forEach(function(a,o){n.set(o,a)}),n.forEach(function(a,o){Yn(i.option,function(l){return o===i.getCacheKey(l)})||(a.component.destroy(),n.delete(o))}),n},r.prototype.getCacheKey=function(t){return t},r}(pc);function RB(e,r){var t=ft({},I(e,["components","axis","common"]),I(e,["components","axis",r]));return I(t,["grid"],{})}function i0(e,r,t,i){var n=[],a=r.getTicks();return e.isPolar&&a.push({value:1,text:"",tickValue:""}),a.reduce(function(o,l,s){var u=l.value;if(i)n.push({points:[e.convert(t==="y"?{x:0,y:u}:{x:u,y:0}),e.convert(t==="y"?{x:1,y:u}:{x:u,y:1})]});else if(s){var c=o.value,f=(c+u)/2;n.push({points:[e.convert(t==="y"?{x:0,y:f}:{x:f,y:0}),e.convert(t==="y"?{x:1,y:f}:{x:f,y:1})]})}return l},a[0]),n}function TS(e,r,t,i,n){var a=r.values.length,o=[],l=t.getTicks();return l.reduce(function(s,u){var c=s?s.value:u.value,f=u.value,h=(c+f)/2;return n==="x"?o.push({points:[e.convert({x:i?f:h,y:0}),e.convert({x:i?f:h,y:1})]}):o.push({points:je(Array(a+1),function(v,d){return e.convert({x:d/a,y:i?f:h})})}),u},l[0]),o}function BB(e,r){var t=I(r,"grid");if(t===null)return!1;var i=I(e,"grid");return!(t===void 0&&i===null)}var Ll=["container"],NB=A(A({},eh),{appear:null}),yCt=function(e){X(r,e);function r(t){var i=e.call(this,t)||this;return i.cache=new Map,i.gridContainer=i.view.getLayer(Ye.BG).addGroup(),i.gridForeContainer=i.view.getLayer(Ye.FORE).addGroup(),i.axisContainer=i.view.getLayer(Ye.BG).addGroup(),i.axisForeContainer=i.view.getLayer(Ye.FORE).addGroup(),i}return Object.defineProperty(r.prototype,"name",{get:function(){return"axis"},enumerable:!1,configurable:!0}),r.prototype.init=function(){},r.prototype.render=function(){this.update()},r.prototype.layout=function(){var t=this,i=this.view.getCoordinate();P(this.getComponents(),function(n){var a=n.component,o=n.direction,l=n.type,s=n.extra,u=s.dim,c=s.scale,f=s.alignTick,h;if(l===Mr.AXIS)i.isPolar?u==="x"?h=i.isTransposed?qm(i,o):bS(i):u==="y"&&(h=i.isTransposed?bS(i):qm(i,o)):h=qm(i,o);else if(l===Mr.GRID)if(i.isPolar){var v=void 0;i.isTransposed?v=u==="x"?TS(i,t.view.getYScales()[0],c,f,u):i0(i,c,u,f):v=u==="x"?i0(i,c,u,f):TS(i,t.view.getXScale(),c,f,u),h={items:v,center:t.view.getCoordinate().getCenter()}}else h={items:i0(i,c,u,f)};a.update(h)})},r.prototype.update=function(){this.option=this.view.getOptions().axes;var t=new Map;this.updateXAxes(t),this.updateYAxes(t);var i=new Map;this.cache.forEach(function(n,a){t.has(a)?i.set(a,n):n.component.destroy()}),this.cache=i},r.prototype.clear=function(){e.prototype.clear.call(this),this.cache.clear(),this.gridContainer.clear(),this.gridForeContainer.clear(),this.axisContainer.clear(),this.axisForeContainer.clear()},r.prototype.destroy=function(){e.prototype.destroy.call(this),this.gridContainer.remove(!0),this.gridForeContainer.remove(!0),this.axisContainer.remove(!0),this.axisForeContainer.remove(!0)},r.prototype.getComponents=function(){var t=[];return this.cache.forEach(function(i){t.push(i)}),t},r.prototype.updateXAxes=function(t){var i=this.view.getXScale();if(!(!i||i.isIdentity)){var n=_x(this.option,i.field);if(n!==!1){var a=oB(n,ct.BOTTOM),o=Ye.BG,l="x",s=this.view.getCoordinate(),u=this.getId("axis",i.field),c=this.getId("grid",i.field);if(s.isRect){var f=this.cache.get(u);if(f){var h=this.getLineAxisCfg(i,n,a);Gi(h,Ll),f.component.update(h),t.set(u,f)}else f=this.createLineAxis(i,n,o,a,l),this.cache.set(u,f),t.set(u,f);var v=this.cache.get(c);if(v){var h=this.getLineGridCfg(i,n,a,l);Gi(h,Ll),v.component.update(h),t.set(c,v)}else v=this.createLineGrid(i,n,o,a,l),v&&(this.cache.set(c,v),t.set(c,v))}else if(s.isPolar){var f=this.cache.get(u);if(f){var h=s.isTransposed?this.getLineAxisCfg(i,n,ct.RADIUS):this.getCircleAxisCfg(i,n,a);Gi(h,Ll),f.component.update(h),t.set(u,f)}else{if(s.isTransposed){if(Yl(n))return;f=this.createLineAxis(i,n,o,ct.RADIUS,l)}else f=this.createCircleAxis(i,n,o,a,l);this.cache.set(u,f),t.set(u,f)}var v=this.cache.get(c);if(v){var h=s.isTransposed?this.getCircleGridCfg(i,n,ct.RADIUS,l):this.getLineGridCfg(i,n,ct.CIRCLE,l);Gi(h,Ll),v.component.update(h),t.set(c,v)}else{if(s.isTransposed){if(Yl(n))return;v=this.createCircleGrid(i,n,o,ct.RADIUS,l)}else v=this.createLineGrid(i,n,o,ct.CIRCLE,l);v&&(this.cache.set(c,v),t.set(c,v))}}}}},r.prototype.updateYAxes=function(t){var i=this,n=this.view.getYScales();P(n,function(a,o){if(!(!a||a.isIdentity)){var l=a.field,s=_x(i.option,l);if(s!==!1){var u=Ye.BG,c="y",f=i.getId("axis",l),h=i.getId("grid",l),v=i.view.getCoordinate();if(v.isRect){var d=oB(s,o===0?ct.LEFT:ct.RIGHT),p=i.cache.get(f);if(p){var x=i.getLineAxisCfg(a,s,d);Gi(x,Ll),p.component.update(x),t.set(f,p)}else p=i.createLineAxis(a,s,u,d,c),i.cache.set(f,p),t.set(f,p);var m=i.cache.get(h);if(m){var x=i.getLineGridCfg(a,s,d,c);Gi(x,Ll),m.component.update(x),t.set(h,m)}else m=i.createLineGrid(a,s,u,d,c),m&&(i.cache.set(h,m),t.set(h,m))}else if(v.isPolar){var p=i.cache.get(f);if(p){var x=v.isTransposed?i.getCircleAxisCfg(a,s,ct.CIRCLE):i.getLineAxisCfg(a,s,ct.RADIUS);Gi(x,Ll),p.component.update(x),t.set(f,p)}else{if(v.isTransposed){if(Yl(s))return;p=i.createCircleAxis(a,s,u,ct.CIRCLE,c)}else p=i.createLineAxis(a,s,u,ct.RADIUS,c);i.cache.set(f,p),t.set(f,p)}var m=i.cache.get(h);if(m){var x=v.isTransposed?i.getLineGridCfg(a,s,ct.CIRCLE,c):i.getCircleGridCfg(a,s,ct.RADIUS,c);Gi(x,Ll),m.component.update(x),t.set(h,m)}else{if(v.isTransposed){if(Yl(s))return;m=i.createLineGrid(a,s,u,ct.CIRCLE,c)}else m=i.createCircleGrid(a,s,u,ct.RADIUS,c);m&&(i.cache.set(h,m),t.set(h,m))}}}}})},r.prototype.createLineAxis=function(t,i,n,a,o){var l={component:new i_t(this.getLineAxisCfg(t,i,a)),layer:n,direction:a===ct.RADIUS?ct.NONE:a,type:Mr.AXIS,extra:{dim:o,scale:t}};return l.component.set("field",t.field),l.component.init(),l},r.prototype.createLineGrid=function(t,i,n,a,o){var l=this.getLineGridCfg(t,i,a,o);if(l){var s={component:new a_t(l),layer:n,direction:ct.NONE,type:Mr.GRID,extra:{dim:o,scale:t,alignTick:I(l,"alignTick",!0)}};return s.component.init(),s}},r.prototype.createCircleAxis=function(t,i,n,a,o){var l={component:new n_t(this.getCircleAxisCfg(t,i,a)),layer:n,direction:a,type:Mr.AXIS,extra:{dim:o,scale:t}};return l.component.set("field",t.field),l.component.init(),l},r.prototype.createCircleGrid=function(t,i,n,a,o){var l=this.getCircleGridCfg(t,i,a,o);if(l){var s={component:new o_t(l),layer:n,direction:ct.NONE,type:Mr.GRID,extra:{dim:o,scale:t,alignTick:I(l,"alignTick",!0)}};return s.component.init(),s}},r.prototype.getLineAxisCfg=function(t,i,n){var a=I(i,["top"])?this.axisForeContainer:this.axisContainer,o=this.view.getCoordinate(),l=qm(o,n),s=lB(t,i),u=Zm(this.view.getTheme(),n),c=I(i,["title"])?ft({title:{style:{text:s}}},{title:aB(this.view.getTheme(),n,i.title)},i):i,f=ft(A(A({container:a},l),{ticks:t.getTicks().map(function(b){return{id:""+b.tickValue,name:b.text,value:b.value}}),verticalFactor:o.isPolar?nB(l,o.getCenter())*-1:nB(l,o.getCenter()),theme:u}),u,c),h=this.getAnimateCfg(f),v=h.animate,d=h.animateOption;f.animateOption=d,f.animate=v;var p=WY(l),x=I(f,"verticalLimitLength",p?1/3:1/2);if(x<=1){var m=this.view.getCanvas().get("width"),_=this.view.getCanvas().get("height");f.verticalLimitLength=x*(p?m:_)}return f},r.prototype.getLineGridCfg=function(t,i,n,a){if(!!BB(Zm(this.view.getTheme(),n),i)){var o=RB(this.view.getTheme(),n),l=ft({container:I(i,["top"])?this.gridForeContainer:this.gridContainer},o,I(i,"grid"),this.getAnimateCfg(i));return l.items=i0(this.view.getCoordinate(),t,a,I(l,"alignTick",!0)),l}},r.prototype.getCircleAxisCfg=function(t,i,n){var a=I(i,["top"])?this.axisForeContainer:this.axisContainer,o=this.view.getCoordinate(),l=t.getTicks().map(function(p){return{id:""+p.tickValue,name:p.text,value:p.value}});!t.isCategory&&Math.abs(o.endAngle-o.startAngle)===Math.PI*2&&l.pop();var s=lB(t,i),u=Zm(this.view.getTheme(),ct.CIRCLE),c=I(i,["title"])?ft({title:{style:{text:s}}},{title:aB(this.view.getTheme(),n,i.title)},i):i,f=ft(A(A({container:a},bS(this.view.getCoordinate())),{ticks:l,verticalFactor:1,theme:u}),u,c),h=this.getAnimateCfg(f),v=h.animate,d=h.animateOption;return f.animate=v,f.animateOption=d,f},r.prototype.getCircleGridCfg=function(t,i,n,a){if(!!BB(Zm(this.view.getTheme(),n),i)){var o=RB(this.view.getTheme(),ct.RADIUS),l=ft({container:I(i,["top"])?this.gridForeContainer:this.gridContainer,center:this.view.getCoordinate().getCenter()},o,I(i,"grid"),this.getAnimateCfg(i)),s=I(l,"alignTick",!0),u=a==="x"?this.view.getYScales()[0]:this.view.getXScale();return l.items=TS(this.view.getCoordinate(),u,t,s,a),l}},r.prototype.getId=function(t,i){var n=this.view.getCoordinate();return t+"-"+i+"-"+n.type},r.prototype.getAnimateCfg=function(t){return{animate:this.view.getOptions().animate&&I(t,"animate"),animateOption:t&&t.animateOption?ft({},NB,t.animateOption):NB}},r}(pc);function ql(e,r,t){return t===ct.TOP?[e.minX+e.width/2-r.width/2,e.minY]:t===ct.BOTTOM?[e.minX+e.width/2-r.width/2,e.maxY-r.height]:t===ct.LEFT?[e.minX,e.minY+e.height/2-r.height/2]:t===ct.RIGHT?[e.maxX-r.width,e.minY+e.height/2-r.height/2]:t===ct.TOP_LEFT||t===ct.LEFT_TOP?[e.tl.x,e.tl.y]:t===ct.TOP_RIGHT||t===ct.RIGHT_TOP?[e.tr.x-r.width,e.tr.y]:t===ct.BOTTOM_LEFT||t===ct.LEFT_BOTTOM?[e.bl.x,e.bl.y-r.height]:t===ct.BOTTOM_RIGHT||t===ct.RIGHT_BOTTOM?[e.br.x-r.width,e.br.y-r.height]:[0,0]}function GB(e,r){return Yu(e)?e===!1?!1:{}:I(e,[r],e)}function n0(e){return I(e,"position",ct.BOTTOM)}var mCt=function(e){X(r,e);function r(t){var i=e.call(this,t)||this;return i.container=i.view.getLayer(Ye.FORE).addGroup(),i}return Object.defineProperty(r.prototype,"name",{get:function(){return"legend"},enumerable:!1,configurable:!0}),r.prototype.init=function(){},r.prototype.render=function(){this.update()},r.prototype.layout=function(){var t=this;this.layoutBBox=this.view.viewBBox,P(this.components,function(i){var n=i.component,a=i.direction,o=wS(a),l=n.get("maxWidthRatio"),s=n.get("maxHeightRatio"),u=t.getCategoryLegendSizeCfg(o,l,s),c=n.get("maxWidth"),f=n.get("maxHeight");n.update({maxWidth:Math.min(u.maxWidth,c||0),maxHeight:Math.min(u.maxHeight,f||0)});var h=n.get("padding"),v=n.getLayoutBBox(),d=new Ei(v.x,v.y,v.width,v.height).expand(h),p=ql(t.view.viewBBox,d,a),x=p[0],m=p[1],_=ql(t.layoutBBox,d,a),b=_[0],w=_[1],S=0,M=0;a.startsWith("top")||a.startsWith("bottom")?(S=x,M=w):(S=b,M=m),n.setLocation({x:S+h[3],y:M+h[0]}),t.layoutBBox=t.layoutBBox.cut(d,a)})},r.prototype.update=function(){var t=this;this.option=this.view.getOptions().legends;var i={},n=function(h,v,d){var p=t.getId(d.field),x=t.getComponentById(p);if(x){var m=void 0,_=GB(t.option,d.field);_!==!1&&(I(_,"custom")?m=t.getCategoryCfg(h,v,d,_,!0):d.isLinear?m=t.getContinuousCfg(h,v,d,_):d.isCategory&&(m=t.getCategoryCfg(h,v,d,_))),m&&(Gi(m,["container"]),x.direction=n0(_),x.component.update(m),i[p]=!0)}else{var b=t.createFieldLegend(h,v,d);b&&(b.component.init(),t.components.push(b),i[p]=!0)}};if(I(this.option,"custom")){var a="global-custom",o=this.getComponentById(a);if(o){var l=this.getCategoryCfg(void 0,void 0,void 0,this.option,!0);Gi(l,["container"]),o.component.update(l),i[a]=!0}else{var s=this.createCustomLegend(void 0,void 0,void 0,this.option);if(s){s.init();var u=Ye.FORE,c=n0(this.option);this.components.push({id:a,component:s,layer:u,direction:c,type:Mr.LEGEND,extra:void 0}),i[a]=!0}}}else this.loopLegends(n);var f=[];P(this.getComponents(),function(h){i[h.id]?f.push(h):h.component.destroy()}),this.components=f},r.prototype.clear=function(){e.prototype.clear.call(this),this.container.clear()},r.prototype.destroy=function(){e.prototype.destroy.call(this),this.container.remove(!0)},r.prototype.getGeometries=function(t){var i=this,n=t.geometries;return P(t.views,function(a){n=n.concat(i.getGeometries(a))}),n},r.prototype.loopLegends=function(t){var i=this.view.getRootView()===this.view;if(!!i){var n=this.getGeometries(this.view),a={};P(n,function(o){var l=o.getGroupAttributes();P(l,function(s){var u=s.getScale(s.type);!u||u.type==="identity"||a[u.field]||(t(o,s,u),a[u.field]=!0)})})}},r.prototype.createFieldLegend=function(t,i,n){var a,o=GB(this.option,n.field),l=Ye.FORE,s=n0(o);if(o!==!1&&(I(o,"custom")?a=this.createCustomLegend(t,i,n,o):n.isLinear?a=this.createContinuousLegend(t,i,n,o):n.isCategory&&(a=this.createCategoryLegend(t,i,n,o))),a)return a.set("field",n.field),{id:this.getId(n.field),component:a,layer:l,direction:s,type:Mr.LEGEND,extra:{scale:n}}},r.prototype.createCustomLegend=function(t,i,n,a){var o=this.getCategoryCfg(t,i,n,a,!0);return new eB(o)},r.prototype.createContinuousLegend=function(t,i,n,a){var o=this.getContinuousCfg(t,i,n,Gi(a,["value"]));return new l_t(o)},r.prototype.createCategoryLegend=function(t,i,n,a){var o=this.getCategoryCfg(t,i,n,a);return new eB(o)},r.prototype.getContinuousCfg=function(t,i,n,a){var o=n.getTicks(),l=Yn(o,function(p){return p.value===0}),s=Yn(o,function(p){return p.value===1}),u=o.map(function(p){var x=p.value,m=p.tickValue,_=i.mapping(n.invert(x)).join("");return{value:m,attrValue:_,color:_,scaleValue:x}});l||u.push({value:n.min,attrValue:i.mapping(n.invert(0)).join(""),color:i.mapping(n.invert(0)).join(""),scaleValue:0}),s||u.push({value:n.max,attrValue:i.mapping(n.invert(1)).join(""),color:i.mapping(n.invert(1)).join(""),scaleValue:1}),u.sort(function(p,x){return p.value-x.value});var c={min:Wi(u).value,max:nr(u).value,colors:[],rail:{type:i.type},track:{}};i.type==="size"&&(c.track={style:{fill:i.type==="size"?this.view.getTheme().defaultColor:void 0}}),i.type==="color"&&(c.colors=u.map(function(p){return p.attrValue}));var f=this.container,h=n0(a),v=wS(h),d=I(a,"title");return d&&(d=ft({text:ip(n)},d)),c.container=f,c.layout=v,c.title=d,c.animateOption=eh,this.mergeLegendCfg(c,a,"continuous")},r.prototype.getCategoryCfg=function(t,i,n,a,o){var l=this.container,s=I(a,"position",ct.BOTTOM),u=mB(this.view.getTheme(),s),c=I(u,["marker"]),f=I(a,"marker"),h=wS(s),v=I(u,["pageNavigator"]),d=I(a,"pageNavigator"),p=o?wbt(c,f,a.items):CW(this.view,t,i,c,f),x=I(a,"title");x&&(x=ft({text:n?ip(n):""},x));var m=I(a,"maxWidthRatio"),_=I(a,"maxHeightRatio"),b=this.getCategoryLegendSizeCfg(h,m,_);b.container=l,b.layout=h,b.items=p,b.title=x,b.animateOption=eh,b.pageNavigator=ft({},v,d);var w=this.mergeLegendCfg(b,a,s);w.reversed&&w.items.reverse();var S=I(w,"maxItemWidth");return S&&S<=1&&(w.maxItemWidth=this.view.viewBBox.width*S),w},r.prototype.mergeLegendCfg=function(t,i,n){var a=n.split("-")[0],o=mB(this.view.getTheme(),a);return ft({},o,t,i)},r.prototype.getId=function(t){return this.name+"-"+t},r.prototype.getComponentById=function(t){return Yn(this.components,function(i){return i.id===t})},r.prototype.getCategoryLegendSizeCfg=function(t,i,n){i===void 0&&(i=KR),n===void 0&&(n=KR);var a=this.view.viewBBox,o=a.width,l=a.height;return t==="vertical"?{maxWidth:o*i,maxHeight:l}:{maxWidth:o,maxHeight:l*n}},r}(pc),xCt=function(e){X(r,e);function r(t){var i=e.call(this,t)||this;return i.onChangeFn=Wo,i.resetMeasure=function(){i.clear()},i.onValueChange=function(n){var a=n[0],o=n[1];i.start=a,i.end=o,i.changeViewData(a,o)},i.container=i.view.getLayer(Ye.FORE).addGroup(),i.onChangeFn=n1(i.onValueChange,20,{leading:!0}),i.width=0,i.view.on(Gt.BEFORE_CHANGE_DATA,i.resetMeasure),i.view.on(Gt.BEFORE_CHANGE_SIZE,i.resetMeasure),i}return Object.defineProperty(r.prototype,"name",{get:function(){return"slider"},enumerable:!1,configurable:!0}),r.prototype.destroy=function(){e.prototype.destroy.call(this),this.view.off(Gt.BEFORE_CHANGE_DATA,this.resetMeasure),this.view.off(Gt.BEFORE_CHANGE_SIZE,this.resetMeasure)},r.prototype.init=function(){},r.prototype.render=function(){this.option=this.view.getOptions().slider;var t=this.getSliderCfg(),i=t.start,n=t.end;K(this.start)&&(this.start=i,this.end=n);var a=this.view.getOptions().data;this.option&&!gi(a)?this.slider?this.slider=this.updateSlider():(this.slider=this.createSlider(),this.slider.component.on("sliderchange",this.onChangeFn)):this.slider&&(this.slider.component.destroy(),this.slider=void 0)},r.prototype.layout=function(){var t=this;if(this.option&&!this.width&&(this.measureSlider(),setTimeout(function(){t.view.destroyed||t.changeViewData(t.start,t.end)},0)),this.slider){var i=this.view.coordinateBBox.width,n=this.slider.component.get("padding"),a=n[0];n[1],n[2];var o=n[3],l=this.slider.component.getLayoutBBox(),s=new Ei(l.x,l.y,Math.min(l.width,i),l.height).expand(n),u=this.getMinMaxText(this.start,this.end),c=u.minText,f=u.maxText,h=ql(this.view.viewBBox,s,ct.BOTTOM);h[0];var v=h[1],d=ql(this.view.coordinateBBox,s,ct.BOTTOM),p=d[0];d[1],this.slider.component.update(A(A({},this.getSliderCfg()),{x:p+o,y:v+a,width:this.width,start:this.start,end:this.end,minText:c,maxText:f})),this.view.viewBBox=this.view.viewBBox.cut(s,ct.BOTTOM)}},r.prototype.update=function(){this.render()},r.prototype.createSlider=function(){var t=this.getSliderCfg(),i=new X5(A({container:this.container},t));return i.init(),{component:i,layer:Ye.FORE,direction:ct.BOTTOM,type:Mr.SLIDER}},r.prototype.updateSlider=function(){var t=this.getSliderCfg();if(this.width){var i=this.getMinMaxText(this.start,this.end),n=i.minText,a=i.maxText;t=A(A({},t),{width:this.width,start:this.start,end:this.end,minText:n,maxText:a})}return this.slider.component.update(t),this.slider},r.prototype.measureSlider=function(){var t=this.getSliderCfg().width;this.width=t},r.prototype.getSliderCfg=function(){var t={height:16,start:0,end:1,minText:"",maxText:"",x:0,y:0,width:this.view.coordinateBBox.width};if(Zt(this.option)){var i=A({data:this.getData()},I(this.option,"trendCfg",{}));t=ft({},t,this.getThemeOptions(),this.option),t=A(A({},t),{trendCfg:i})}return t.start=Ce(Math.min(K(t.start)?0:t.start,K(t.end)?1:t.end),0,1),t.end=Ce(Math.max(K(t.start)?0:t.start,K(t.end)?1:t.end),0,1),t},r.prototype.getData=function(){var t=this.view.getOptions().data,i=this.view.getYScales()[0],n=this.view.getGroupScales();if(n.length){var a=n[0],o=a.field,l=a.ticks;return t.reduce(function(s,u){return u[o]===l[0]&&s.push(u[i.field]),s},[])}return t.map(function(s){return s[i.field]||0})},r.prototype.getThemeOptions=function(){var t=this.view.getTheme();return I(t,["components","slider","common"],{})},r.prototype.getMinMaxText=function(t,i){var n=this.view.getOptions().data,a=this.view.getXScale(),o=Xn(n,a.field),l=o,s=yr(n);if(!a||!s)return{};var u=yr(l),c=Math.floor(t*(u-1)),f=Math.floor(i*(u-1)),h=I(l,[c]),v=I(l,[f]),d=this.getSliderCfg().formatter;return d&&(h=d(h,n[c],c),v=d(v,n[f],f)),{minText:h,maxText:v}},r.prototype.changeViewData=function(t,i){var n=this.view.getOptions().data,a=this.view.getXScale(),o=yr(n);if(!(!a||!o)){var l=Xn(n,a.field),s=l,u=yr(s),c=Math.floor(t*(u-1)),f=Math.floor(i*(u-1));this.view.filter(a.field,function(h,v){var d=s.indexOf(h);return d>-1?xf(d,c,f):!0}),this.view.render(!0)}},r.prototype.getComponents=function(){return this.slider?[this.slider]:[]},r.prototype.clear=function(){this.slider&&(this.slider.component.destroy(),this.slider=void 0),this.width=0,this.start=void 0,this.end=void 0},r}(pc),a0=0,zB=8,_Ct=32,bCt=20,wCt=function(e){X(r,e);function r(t){var i=e.call(this,t)||this;return i.onChangeFn=Wo,i.resetMeasure=function(){i.clear()},i.onValueChange=function(n){var a=n.ratio,o=i.getValidScrollbarCfg().animate;i.ratio=Ce(a,0,1);var l=i.view.getOptions().animate;o||i.view.animate(!1),i.changeViewData(i.getScrollRange(),!0),i.view.animate(l)},i.container=i.view.getLayer(Ye.FORE).addGroup(),i.onChangeFn=n1(i.onValueChange,20,{leading:!0}),i.trackLen=0,i.thumbLen=0,i.ratio=0,i.view.on(Gt.BEFORE_CHANGE_DATA,i.resetMeasure),i.view.on(Gt.BEFORE_CHANGE_SIZE,i.resetMeasure),i}return Object.defineProperty(r.prototype,"name",{get:function(){return"scrollbar"},enumerable:!1,configurable:!0}),r.prototype.destroy=function(){e.prototype.destroy.call(this),this.view.off(Gt.BEFORE_CHANGE_DATA,this.resetMeasure),this.view.off(Gt.BEFORE_CHANGE_SIZE,this.resetMeasure)},r.prototype.init=function(){},r.prototype.render=function(){this.option=this.view.getOptions().scrollbar,this.option?this.scrollbar?this.scrollbar=this.updateScrollbar():(this.scrollbar=this.createScrollbar(),this.scrollbar.component.on("scrollchange",this.onChangeFn)):this.scrollbar&&(this.scrollbar.component.destroy(),this.scrollbar=void 0)},r.prototype.layout=function(){var t=this;if(this.option&&!this.trackLen&&(this.measureScrollbar(),setTimeout(function(){t.view.destroyed||t.changeViewData(t.getScrollRange(),!0)})),this.scrollbar){var i=this.view.coordinateBBox.width,n=this.scrollbar.component.get("padding"),a=this.scrollbar.component.getLayoutBBox(),o=new Ei(a.x,a.y,Math.min(a.width,i),a.height).expand(n),l=this.getScrollbarComponentCfg(),s=void 0,u=void 0;if(l.isHorizontal){var c=ql(this.view.viewBBox,o,ct.BOTTOM);c[0];var f=c[1],h=ql(this.view.coordinateBBox,o,ct.BOTTOM),v=h[0];h[1],s=v,u=f}else{var d=ql(this.view.viewBBox,o,ct.RIGHT);d[0];var f=d[1],p=ql(this.view.viewBBox,o,ct.RIGHT),v=p[0];p[1],s=v,u=f}s+=n[3],u+=n[0],this.trackLen?this.scrollbar.component.update(A(A({},l),{x:s,y:u,trackLen:this.trackLen,thumbLen:this.thumbLen,thumbOffset:(this.trackLen-this.thumbLen)*this.ratio})):this.scrollbar.component.update(A(A({},l),{x:s,y:u})),this.view.viewBBox=this.view.viewBBox.cut(o,l.isHorizontal?ct.BOTTOM:ct.RIGHT)}},r.prototype.update=function(){this.render()},r.prototype.getComponents=function(){return this.scrollbar?[this.scrollbar]:[]},r.prototype.clear=function(){this.scrollbar&&(this.scrollbar.component.destroy(),this.scrollbar=void 0),this.trackLen=0,this.thumbLen=0,this.ratio=0,this.cnt=0,this.step=0,this.data=void 0,this.xScaleCfg=void 0,this.yScalesCfg=[]},r.prototype.setValue=function(t){this.onValueChange({ratio:t})},r.prototype.getValue=function(){return this.ratio},r.prototype.getThemeOptions=function(){var t=this.view.getTheme();return I(t,["components","scrollbar","common"],{})},r.prototype.getScrollbarTheme=function(t){var i=I(this.view.getTheme(),["components","scrollbar"]),n=t||{},a=n.thumbHighlightColor,o=ue(n,["thumbHighlightColor"]);return{default:ft({},I(i,["default","style"],{}),o),hover:ft({},I(i,["hover","style"],{}),{thumbColor:a})}},r.prototype.measureScrollbar=function(){var t=this.view.getXScale(),i=this.view.getYScales().slice();this.data=this.getScrollbarData(),this.step=this.getStep(),this.cnt=this.getCnt();var n=this.getScrollbarComponentCfg(),a=n.trackLen,o=n.thumbLen;this.trackLen=a,this.thumbLen=o,this.xScaleCfg={field:t.field,values:t.values||[]},this.yScalesCfg=i},r.prototype.getScrollRange=function(){var t=Math.floor((this.cnt-this.step)*Ce(this.ratio,0,1)),i=Math.min(t+this.step-1,this.cnt-1);return[t,i]},r.prototype.changeViewData=function(t,i){var n=this,a=t[0],o=t[1],l=this.getValidScrollbarCfg().type,s=l!=="vertical",u=Xn(this.data,this.xScaleCfg.field),c=s?u:u.reverse();this.yScalesCfg.forEach(function(f){n.view.scale(f.field,{formatter:f.formatter,type:f.type,min:f.min,max:f.max})}),this.view.filter(this.xScaleCfg.field,function(f){var h=c.indexOf(f);return h>-1?xf(h,a,o):!0}),this.view.render(!0)},r.prototype.createScrollbar=function(){var t=this.getValidScrollbarCfg().type,i=t!=="vertical",n=new U5(A(A({container:this.container},this.getScrollbarComponentCfg()),{x:0,y:0}));return n.init(),{component:n,layer:Ye.FORE,direction:i?ct.BOTTOM:ct.RIGHT,type:Mr.SCROLLBAR}},r.prototype.updateScrollbar=function(){var t=this.getScrollbarComponentCfg(),i=this.trackLen?A(A({},t),{trackLen:this.trackLen,thumbLen:this.thumbLen,thumbOffset:(this.trackLen-this.thumbLen)*this.ratio}):A({},t);return this.scrollbar.component.update(i),this.scrollbar},r.prototype.getStep=function(){if(this.step)return this.step;var t=this.view.coordinateBBox,i=this.getValidScrollbarCfg(),n=i.type,a=i.categorySize,o=n!=="vertical";return Math.floor((o?t.width:t.height)/a)},r.prototype.getCnt=function(){if(this.cnt)return this.cnt;var t=this.view.getXScale(),i=this.getScrollbarData(),n=Xn(i,t.field);return yr(n)},r.prototype.getScrollbarComponentCfg=function(){var t=this.view,i=t.coordinateBBox,n=t.viewBBox,a=this.getValidScrollbarCfg(),o=a.type,l=a.padding,s=a.width,u=a.height,c=a.style,f=o!=="vertical",h=l[0],v=l[1],d=l[2],p=l[3],x=f?{x:i.minX+p,y:n.maxY-u-d}:{x:n.maxX-s-v,y:i.minY+h},m=this.getStep(),_=this.getCnt(),b=f?i.width-p-v:i.height-h-d,w=Math.max(b*Ce(m/_,0,1),bCt);return A(A({},this.getThemeOptions()),{x:x.x,y:x.y,size:f?u:s,isHorizontal:f,trackLen:b,thumbLen:w,thumbOffset:0,theme:this.getScrollbarTheme(c)})},r.prototype.getValidScrollbarCfg=function(){var t={type:"horizontal",categorySize:_Ct,width:zB,height:zB,padding:[0,0,0,0],animate:!0,style:{}};return Zt(this.option)&&(t=A(A({},t),this.option)),(!Zt(this.option)||!this.option.padding)&&(t.padding=t.type==="horizontal"?[a0,0,a0,0]:[0,a0,0,a0]),t},r.prototype.getScrollbarData=function(){var t=this.view.getCoordinate(),i=this.getValidScrollbarCfg(),n=this.view.getOptions().data||[];return t.isReflect("y")&&i.type==="vertical"&&(n=Qr([],n,!0).reverse()),n},r}(pc),CCt={fill:"#CCD6EC",opacity:.3};function SCt(e,r,t){var i=Q_t(e,r,t);if(i.length){i=qi(i);for(var n=0,a=i;n<a.length;n++)for(var o=a[n],l=0,s=o;l<s.length;l++){var u=s[l],c=u.mappingData,f=c.x,h=c.y;u.x=it(f)?f[f.length-1]:f,u.y=it(h)?h[h.length-1]:h}var v=t.shared;if(v===!1&&i.length>1){for(var d=i[0],p=Math.abs(r.y-d[0].y),x=0,m=i;x<m.length;x++){var _=m[x],b=Math.abs(r.y-_[0].y);b<=p&&(d=_,p=b)}i=[d]}return us(qi(i))}return[]}var ACt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.show=function(t){var i=this.context.view,n=this.context.event,a=i.getController("tooltip").getTooltipCfg(),o=SCt(i,{x:n.x,y:n.y},a);if(!Ge(o,this.items)&&(this.items=o,o.length)){var l=i.getXScale().field,s=o[0].data[l],u=[],c=i.geometries;if(P(c,function(N){if(N.type==="interval"||N.type==="schema"){var W=N.getElementsBy(function(q){var tt=q.getData();return tt[l]===s});u=u.concat(W)}}),u.length){var f=i.getCoordinate(),h=u[0].shape.getCanvasBBox(),v=u[0].shape.getCanvasBBox(),d=h;P(u,function(N){var W=N.shape.getCanvasBBox();f.isTransposed?(W.minY<h.minY&&(h=W),W.maxY>v.maxY&&(v=W)):(W.minX<h.minX&&(h=W),W.maxX>v.maxX&&(v=W)),d.x=Math.min(W.minX,d.minX),d.y=Math.min(W.minY,d.minY),d.width=Math.max(W.maxX,d.maxX)-d.x,d.height=Math.max(W.maxY,d.maxY)-d.y});var p=i.backgroundGroup,x=i.coordinateBBox,m=void 0;if(f.isRect){var _=i.getXScale(),b=t||{},w=b.appendRatio,S=b.appendWidth;K(S)&&(w=K(w)?_.isLinear?0:.25:w,S=f.isTransposed?w*v.height:w*h.width);var M=void 0,F=void 0,O=void 0,L=void 0;f.isTransposed?(M=x.minX,F=Math.min(v.minY,h.minY)-S,O=x.width,L=d.height+S*2):(M=Math.min(h.minX,v.minX)-S,F=x.minY,O=d.width+S*2,L=x.height),m=[["M",M,F],["L",M+O,F],["L",M+O,F+L],["L",M,F+L],["Z"]]}else{var D=Wi(u),k=nr(u),H=rp(D.getModel(),f).startAngle,B=rp(k.getModel(),f).endAngle,j=f.getCenter(),U=f.getRadius(),R=f.innerRadius*U;m=es(j.x,j.y,U,H,B,R)}if(this.regionPath)this.regionPath.attr("path",m),this.regionPath.show();else{var G=I(t,"style",CCt);this.regionPath=p.addShape({type:"path",name:"active-region",capture:!1,attrs:A(A({},G),{path:m})})}}}},r.prototype.hide=function(){this.regionPath&&this.regionPath.hide(),this.items=null},r.prototype.destroy=function(){this.hide(),this.regionPath&&this.regionPath.remove(!0),e.prototype.destroy.call(this)},r}(Ie),RW=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.timeStamp=0,t}return r.prototype.show=function(){var t=this.context,i=t.event,n=t.view,a=n.isTooltipLocked();if(!a){var o=this.timeStamp,l=+new Date,s=I(t.view.getOptions(),"tooltip.showDelay",16);if(l-o>s){var u=this.location,c={x:i.x,y:i.y};(!u||!Ge(u,c))&&this.showTooltip(n,c),this.timeStamp=l,this.location=c}}},r.prototype.hide=function(){var t=this.context.view,i=t.getController("tooltip"),n=this.context.event,a=n.clientX,o=n.clientY;i.isCursorEntered({x:a,y:o})||t.isTooltipLocked()||(this.hideTooltip(t),this.location=null)},r.prototype.showTooltip=function(t,i){t.showTooltip(i)},r.prototype.hideTooltip=function(t){t.hideTooltip()},r}(Ie),TCt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.showTooltip=function(t,i){var n=vo(t);P(n,function(a){var o=CT(t,a,i);a.showTooltip(o)})},r.prototype.hideTooltip=function(t){var i=vo(t);P(i,function(n){n.hideTooltip()})},r}(RW),MCt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.timeStamp=0,t}return r.prototype.destroy=function(){e.prototype.destroy.call(this),this.tooltip&&this.tooltip.destroy()},r.prototype.show=function(){var t=this.context,i=t.event,n=this.timeStamp,a=+new Date;if(a-n>16){var o=this.location,l={x:i.x,y:i.y};(!o||!Ge(o,l))&&this.showTooltip(l),this.timeStamp=a,this.location=l}},r.prototype.hide=function(){this.hideTooltip(),this.location=null},r.prototype.showTooltip=function(t){var i=this.context,n=i.event,a=n.target;if(a&&a.get("tip")){this.tooltip||this.renderTooltip();var o=a.get("tip");this.tooltip.update(A({title:o},t)),this.tooltip.show()}},r.prototype.hideTooltip=function(){this.tooltip&&this.tooltip.hide()},r.prototype.renderTooltip=function(){var t,i=this.context.view,n=i.canvas,a={start:{x:0,y:0},end:{x:n.get("width"),y:n.get("height")}},o=i.getTheme(),l=I(o,["components","tooltip","domStyles"],{}),s=new zY({parent:n.get("el").parentNode,region:a,visible:!1,crosshairs:null,domStyles:A({},ft({},l,(t={},t[Nf]={"max-width":"50%"},t[Gf]={"word-break":"break-all"},t)))});s.init(),s.setCapture(!1),this.tooltip=s},r}(Ie),WO=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="",t}return r.prototype.hasState=function(t){return t.hasState(this.stateName)},r.prototype.setElementState=function(t,i){t.setState(this.stateName,i)},r.prototype.setState=function(){this.setStateEnable(!0)},r.prototype.clear=function(){var t=this.context.view;this.clearViewState(t)},r.prototype.clearViewState=function(t){var i=this,n=eW(t,this.stateName);P(n,function(a){i.setElementState(a,!1)})},r}(Ie);function VB(e){return I(e.get("delegateObject"),"item")}var XO=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.ignoreListItemStates=["unchecked"],t}return r.prototype.isItemIgnore=function(t,i){var n=this.ignoreListItemStates,a=n.filter(function(o){return i.hasState(t,o)});return!!a.length},r.prototype.setStateByComponent=function(t,i,n){var a=this.context.view,o=t.get("field"),l=Vr(a);this.setElementsStateByItem(l,o,i,n)},r.prototype.setStateByElement=function(t,i){this.setElementState(t,i)},r.prototype.isMathItem=function(t,i,n){var a=this.context.view,o=th(a,i),l=Ea(t,i);return!K(l)&&n.name===o.getText(l)},r.prototype.setElementsStateByItem=function(t,i,n,a){var o=this;P(t,function(l){o.isMathItem(l,i,n)&&l.setState(o.stateName,a)})},r.prototype.setStateEnable=function(t){var i=ws(this.context);if(i)KY(this.context)&&this.setStateByElement(i,t);else{var n=Jf(this.context);if(np(n)){var a=n.item,o=n.component;if(a&&o&&!this.isItemIgnore(a,o)){var l=this.context.event.gEvent;if(l&&l.fromShape&&l.toShape&&VB(l.fromShape)===VB(l.toShape))return;this.setStateByComponent(o,a,t)}}}},r.prototype.toggle=function(){var t=ws(this.context);if(t){var i=t.hasState(this.stateName);this.setElementState(t,!i)}},r.prototype.reset=function(){this.setStateEnable(!1)},r}(WO),ECt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="active",t}return r.prototype.active=function(){this.setState()},r}(XO),FCt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.cache={},t}return r.prototype.getColorScale=function(t,i){var n=i.geometry.getAttribute("color");if(!n)return null;var a=t.getScaleByField(n.getFields()[0]);return a},r.prototype.getLinkPath=function(t,i){var n=this.context.view,a=n.getCoordinate().isTransposed,o=t.shape.getCanvasBBox(),l=i.shape.getCanvasBBox(),s=a?[["M",o.minX,o.minY],["L",l.minX,l.maxY],["L",l.maxX,l.maxY],["L",o.maxX,o.minY],["Z"]]:[["M",o.maxX,o.minY],["L",l.minX,l.minY],["L",l.minX,l.maxY],["L",o.maxX,o.maxY],["Z"]];return s},r.prototype.addLinkShape=function(t,i,n,a){var o={opacity:.4,fill:i.shape.attr("fill")};t.addShape({type:"path",attrs:A(A({},ft({},o,pt(a)?a(o,i):a)),{path:this.getLinkPath(i,n)})})},r.prototype.linkByElement=function(t,i){var n=this,a=this.context.view,o=this.getColorScale(a,t);if(!!o){var l=Ea(t,o.field);if(!this.cache[l]){var s=P_t(a,o.field,l),u=this.linkGroup,c=u.addGroup();this.cache[l]=c;var f=s.length;P(s,function(h,v){if(v<f-1){var d=s[v+1];n.addLinkShape(c,h,d,i)}})}}},r.prototype.removeLink=function(t){var i=this.getColorScale(this.context.view,t);if(!!i){var n=Ea(t,i.field);this.cache[n]&&(this.cache[n].remove(),this.cache[n]=null)}},r.prototype.link=function(t){var i=this.context;this.linkGroup||(this.linkGroup=i.view.foregroundGroup.addGroup({id:"link-by-color-group",capture:!1}));var n=ws(i);n&&this.linkByElement(n,t==null?void 0:t.style)},r.prototype.unlink=function(){var t=ws(this.context);t&&this.removeLink(t)},r.prototype.clear=function(){this.linkGroup&&this.linkGroup.clear(),this.cache={}},r.prototype.destroy=function(){e.prototype.destroy.call(this),this.linkGroup&&this.linkGroup.remove()},r}(Ie),UO=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.startPoint=null,t.endPoint=null,t.isStarted=!1,t.effectSiblings=!1,t.effectByRecord=!1,t}return r.prototype.getCurrentPoint=function(){var t=this.context.event;return{x:t.x,y:t.y}},r.prototype.start=function(){this.clear(),this.startPoint=this.getCurrentPoint(),this.isStarted=!0},r.prototype.getIntersectElements=function(){var t=null;if(ap(this.context))t=SO(this.context,10);else{var i=this.startPoint,n=this.isStarted?this.getCurrentPoint():this.endPoint;if(!i||!n)return;var a={minX:Math.min(i.x,n.x),minY:Math.min(i.y,n.y),maxX:Math.max(i.x,n.x),maxY:Math.max(i.y,n.y)},o=this.context.view;t=AO(o,a)}return t},r.prototype.setStateEnable=function(t){if(this.effectSiblings&&!this.effectByRecord)this.setSiblingsState(t);else{var i=Vr(this.context.view),n=this.getIntersectElements();n&&n.length?this.effectByRecord?this.setSiblingsStateByRecord(n,t):this.setElementsState(n,t,i):this.clear()}},r.prototype.setSiblingsStateByRecord=function(t,i){var n=this,a=this.context.view,o=vo(a),l=t.map(function(c){return c.getModel().data}),s=a.getXScale().field,u=a.getYScales()[0].field;P(o,function(c){var f=Vr(c),h=f.filter(function(v){var d=v.getModel().data;return iW(l,d,s,u)});n.setElementsState(h,i,f)})},r.prototype.setSiblingsState=function(t){var i=this,n=this.context.view,a=vo(n);ap(this.context)&&P(a,function(o){var l=Vr(o),s=tW(i.context,o,10);s&&s.length?i.setElementsState(s,t,l):i.clearViewState(o)})},r.prototype.setElementsState=function(t,i,n){var a=this;P(n,function(o){t.includes(o)?a.setElementState(o,i):a.setElementState(o,!1)})},r.prototype.end=function(){this.isStarted=!1,this.endPoint=this.getCurrentPoint()},r.prototype.clear=function(){var t=this,i=this.context.view;if(this.effectSiblings){var n=vo(i);P(n,function(a){t.clearViewState(a)})}else this.clearViewState(i)},r}(WO),OCt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="active",t}return r.prototype.active=function(){this.setState()},r}(UO),qO=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.setStateEnable=function(t){var i=ws(this.context);if(i){if(!KY(this.context))return;t?(this.clear(),this.setElementState(i,!0)):this.hasState(i)&&this.setElementState(i,!1)}},r.prototype.toggle=function(){var t=ws(this.context);if(t){var i=this.hasState(t);i||this.clear(),this.setElementState(t,!i)}},r.prototype.reset=function(){this.setStateEnable(!1)},r}(WO),PCt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="active",t}return r.prototype.active=function(){this.setState()},r}(qO),Sd="inactive",Ad="active";function ZO(e){var r=Vr(e);P(r,function(t){t.hasState(Ad)&&t.setState(Ad,!1),t.hasState(Sd)&&t.setState(Sd,!1)})}function BW(e,r,t){P(e,function(i){r(i)?(i.hasState(Sd)&&i.setState(Sd,!1),i.setState(Ad,t)):(i.hasState(Ad)&&i.setState(Ad,!1),i.setState(Sd,t))})}var Fu=xx.INACTIVE,zo=xx.ACTIVE,QO=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName=zo,t}return r.prototype.setElementsStateByItem=function(t,i,n,a){var o=this,l=function(s){return o.isMathItem(s,i,n)};this.setHighlightBy(t,l,a)},r.prototype.setElementHighlight=function(t,i){i(t)?(t.hasState(Fu)&&t.setState(Fu,!1),t.setState(zo,!0)):t.hasState(zo)||t.setState(Fu,!0)},r.prototype.setHighlightBy=function(t,i,n){var a=this;if(n)P(t,function(s){a.setElementHighlight(s,i)});else{var o=eW(this.context.view,zo),l=!0;P(o,function(s){if(!i(s))return l=!1,!1}),l?this.clear():P(t,function(s){i(s)&&(s.hasState(zo)&&s.setState(zo,!1),s.setState(Fu,!0))})}},r.prototype.setElementState=function(t,i){var n=this.context.view,a=Vr(n);this.setHighlightBy(a,function(o){return t===o},i)},r.prototype.highlight=function(){this.setState()},r.prototype.clear=function(){var t=this.context.view;ZO(t)},r}(XO),ICt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.setStateByElement=function(t,i){var n=this.context.view,a=t.geometry.getAttribute("color");if(!!a){var o=n.getScaleByField(a.getFields()[0]),l=Ea(t,o.field),s=Vr(n),u=s.filter(function(c){return Ea(c,o.field)===l});this.setHighlightBy(s,function(c){return u.includes(c)},i)}},r}(QO),LCt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.setElementHighlight=function(t,i){i(t)?(t.hasState(Fu)&&t.setState(Fu,!1),t.setState(zo,!0)):(t.setState(Fu,!0),t.hasState(zo)&&t.setState(zo,!1))},r.prototype.setStateByElement=function(t,i){var n=this.context.view,a=n.getXScale(),o=Ea(t,a.field),l=Vr(n),s=l.filter(function(u){return Ea(u,a.field)===o});this.setHighlightBy(l,function(u){return s.includes(u)},i)},r.prototype.toggle=function(){var t=ws(this.context);if(t){var i=t.hasState(this.stateName);this.setStateByElement(t,!i)}},r}(QO),da;(function(e){e.BEFORE_HIGHLIGHT="element-range-highlight:beforehighlight",e.AFTER_HIGHLIGHT="element-range-highlight:afterhighlight",e.BEFORE_CLEAR="element-range-highlight:beforeclear",e.AFTER_CLEAR="element-range-highlight:afterclear"})(da||(da={}));var NW=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="active",t}return r.prototype.clearViewState=function(t){ZO(t)},r.prototype.highlight=function(){var t=this.context,i=t.view,n=t.event,a=this.getIntersectElements(),o={view:i,event:n,highlightElements:a};i.emit(da.BEFORE_HIGHLIGHT,$e.fromData(i,da.BEFORE_HIGHLIGHT,o)),this.setState(),i.emit(da.AFTER_HIGHLIGHT,$e.fromData(i,da.AFTER_HIGHLIGHT,o))},r.prototype.clear=function(){var t=this.context.view;t.emit(da.BEFORE_CLEAR,$e.fromData(t,da.BEFORE_CLEAR,{})),e.prototype.clear.call(this),t.emit(da.AFTER_CLEAR,$e.fromData(t,da.AFTER_CLEAR,{}))},r.prototype.setElementsState=function(t,i,n){BW(n,function(a){return t.indexOf(a)>=0},i)},r}(UO),DCt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="active",t}return r.prototype.highlight=function(){this.setState()},r.prototype.setElementState=function(t,i){var n=this.context.view,a=Vr(n);BW(a,function(o){return t===o},i)},r.prototype.clear=function(){var t=this.context.view;ZO(t)},r}(qO),$Ct=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="selected",t}return r.prototype.selected=function(){this.setState()},r}(UO),kCt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="selected",t}return r.prototype.selected=function(){this.setState()},r}(XO),RCt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="selected",t}return r.prototype.selected=function(){this.setState()},r}(qO),yg=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="",t.ignoreItemStates=[],t}return r.prototype.getTriggerListInfo=function(){var t=Jf(this.context),i=null;return np(t)&&(i={item:t.item,list:t.component}),i},r.prototype.getAllowComponents=function(){var t=this,i=this.context.view,n=rW(i),a=[];return P(n,function(o){o.isList()&&t.allowSetStateByElement(o)&&a.push(o)}),a},r.prototype.hasState=function(t,i){return t.hasState(i,this.stateName)},r.prototype.clearAllComponentsState=function(){var t=this,i=this.getAllowComponents();P(i,function(n){n.clearItemsState(t.stateName)})},r.prototype.allowSetStateByElement=function(t){var i=t.get("field");if(!i)return!1;if(this.cfg&&this.cfg.componentNames){var n=t.get("name");if(this.cfg.componentNames.indexOf(n)===-1)return!1}var a=this.context.view,o=th(a,i);return o&&o.isCategory},r.prototype.allowSetStateByItem=function(t,i){var n=this.ignoreItemStates;if(n.length){var a=n.filter(function(o){return i.hasState(t,o)});return a.length===0}return!0},r.prototype.setStateByElement=function(t,i,n){var a=t.get("field"),o=this.context.view,l=th(o,a),s=Ea(i,a),u=l.getText(s);this.setItemsState(t,u,n)},r.prototype.setStateEnable=function(t){var i=this,n=ws(this.context);if(n){var a=this.getAllowComponents();P(a,function(u){i.setStateByElement(u,n,t)})}else{var o=Jf(this.context);if(np(o)){var l=o.item,s=o.component;this.allowSetStateByElement(s)&&this.allowSetStateByItem(l,s)&&this.setItemState(s,l,t)}}},r.prototype.setItemsState=function(t,i,n){var a=this,o=t.getItems();P(o,function(l){l.name===i&&a.setItemState(t,l,n)})},r.prototype.setItemState=function(t,i,n){t.setItemState(i,this.stateName,n)},r.prototype.setState=function(){this.setStateEnable(!0)},r.prototype.reset=function(){this.setStateEnable(!1)},r.prototype.toggle=function(){var t=this.getTriggerListInfo();if(t&&t.item){var i=t.list,n=t.item,a=this.hasState(i,n);this.setItemState(i,n,!a)}},r.prototype.clear=function(){var t=this.getTriggerListInfo();t?t.list.clearItemsState(this.stateName):this.clearAllComponentsState()},r}(Ie),BCt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="active",t}return r.prototype.active=function(){this.setState()},r}(yg),jB="inactive",HB="active";function NCt(e){var r=e.getItems();P(r,function(t){e.hasState(t,HB)&&e.setItemState(t,HB,!1),e.hasState(t,jB)&&e.setItemState(t,jB,!1)})}var Pv="inactive",su="active",KO=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName=su,t.ignoreItemStates=["unchecked"],t}return r.prototype.setItemsState=function(t,i,n){this.setHighlightBy(t,function(a){return a.name===i},n)},r.prototype.setItemState=function(t,i,n){t.getItems(),this.setHighlightBy(t,function(a){return a===i},n)},r.prototype.setHighlightBy=function(t,i,n){var a=t.getItems();if(n)P(a,function(s){i(s)?(t.hasState(s,Pv)&&t.setItemState(s,Pv,!1),t.setItemState(s,su,!0)):t.hasState(s,su)||t.setItemState(s,Pv,!0)});else{var o=t.getItemsByState(su),l=!0;P(o,function(s){if(!i(s))return l=!1,!1}),l?this.clear():P(a,function(s){i(s)&&(t.hasState(s,su)&&t.setItemState(s,su,!1),t.setItemState(s,Pv,!0))})}},r.prototype.highlight=function(){this.setState()},r.prototype.clear=function(){var t=this.getTriggerListInfo();if(t)NCt(t.list);else{var i=this.getAllowComponents();P(i,function(n){n.clearItemsState(su),n.clearItemsState(Pv)})}},r}(yg),GCt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="selected",t}return r.prototype.selected=function(){this.setState()},r}(yg),zCt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName="unchecked",t}return r.prototype.unchecked=function(){this.setState()},r}(yg),Yc="unchecked",o0="checked",VCt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.stateName=o0,t}return r.prototype.setItemState=function(t,i,n){this.setCheckedBy(t,function(a){return a===i},n)},r.prototype.setCheckedBy=function(t,i,n){var a=t.getItems();n&&P(a,function(o){i(o)?(t.hasState(o,Yc)&&t.setItemState(o,Yc,!1),t.setItemState(o,o0,!0)):t.hasState(o,o0)||t.setItemState(o,Yc,!0)})},r.prototype.toggle=function(){var t=this.getTriggerListInfo();if(t&&t.item){var i=t.list,n=t.item,a=!gp(i.getItems(),function(o){return i.hasState(o,Yc)});a||i.hasState(n,Yc)?this.setItemState(i,n,!0):this.reset()}},r.prototype.checked=function(){this.setState()},r.prototype.reset=function(){var t=this.getAllowComponents();P(t,function(i){i.clearItemsState(o0),i.clearItemsState(Yc)})},r}(yg),JO=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.maskShape=null,t.points=[],t.starting=!1,t.moving=!1,t.preMovePoint=null,t.shapeType="path",t}return r.prototype.getCurrentPoint=function(){var t=this.context.event;return{x:t.x,y:t.y}},r.prototype.emitEvent=function(t){var i="mask:"+t,n=this.context.view,a=this.context.event;n.emit(i,{target:this.maskShape,shape:this.maskShape,points:this.points,x:a.x,y:a.y})},r.prototype.createMask=function(){var t=this.context.view,i=this.getMaskAttrs(),n=t.foregroundGroup.addShape({type:this.shapeType,name:"mask",draggable:!0,attrs:A({fill:"#C5D4EB",opacity:.3},i)});return n},r.prototype.getMaskPath=function(){return[]},r.prototype.show=function(){this.maskShape&&(this.maskShape.show(),this.emitEvent("show"))},r.prototype.start=function(t){this.starting=!0,this.moving=!1,this.points=[this.getCurrentPoint()],this.maskShape||(this.maskShape=this.createMask(),this.maskShape.set("capture",!1)),this.updateMask(t==null?void 0:t.maskStyle),this.emitEvent("start")},r.prototype.moveStart=function(){this.moving=!0,this.preMovePoint=this.getCurrentPoint()},r.prototype.move=function(){if(!(!this.moving||!this.maskShape)){var t=this.getCurrentPoint(),i=this.preMovePoint,n=t.x-i.x,a=t.y-i.y,o=this.points;P(o,function(l){l.x+=n,l.y+=a}),this.updateMask(),this.emitEvent("change"),this.preMovePoint=t}},r.prototype.updateMask=function(t){var i=ft({},this.getMaskAttrs(),t);this.maskShape.attr(i)},r.prototype.moveEnd=function(){this.moving=!1,this.preMovePoint=null},r.prototype.end=function(){this.starting=!1,this.emitEvent("end"),this.maskShape&&this.maskShape.set("capture",!0)},r.prototype.hide=function(){this.maskShape&&(this.maskShape.hide(),this.emitEvent("hide"))},r.prototype.resize=function(){this.starting&&this.maskShape&&(this.points.push(this.getCurrentPoint()),this.updateMask(),this.emitEvent("change"))},r.prototype.destroy=function(){this.points=[],this.maskShape&&this.maskShape.remove(),this.maskShape=null,this.preMovePoint=null,e.prototype.destroy.call(this)},r}(Ie),jCt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.shapeType="circle",t}return r.prototype.getMaskAttrs=function(){var t=this.points,i=nr(this.points),n=0,a=0,o=0;if(t.length){var l=t[0];n=TO(l,i)/2,a=(i.x+l.x)/2,o=(i.y+l.y)/2}return{x:a,y:o,r:n}},r}(JO),GW=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.shapeType="rect",t}return r.prototype.getRegion=function(){var t=this.points;return{start:Wi(t),end:nr(t)}},r.prototype.getMaskAttrs=function(){var t=this.getRegion(),i=t.start,n=t.end,a=Math.min(i.x,n.x),o=Math.min(i.y,n.y),l=Math.abs(n.x-i.x),s=Math.abs(n.y-i.y);return{x:a,y:o,width:l,height:s}},r}(JO);function YB(e){e.x=Ce(e.x,0,1),e.y=Ce(e.y,0,1)}var zW=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.dim="x",t.inPlot=!0,t}return r.prototype.getRegion=function(){var t=null,i=null,n=this.points,a=this.dim,o=this.context.view.getCoordinate(),l=o.invert(Wi(n)),s=o.invert(nr(n));return this.inPlot&&(YB(l),YB(s)),a==="x"?(t=o.convert({x:l.x,y:0}),i=o.convert({x:s.x,y:1})):(t=o.convert({x:0,y:l.y}),i=o.convert({x:1,y:s.y})),{start:t,end:i}},r}(GW),VW=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getMaskPath=function(){var t=this.points,i=[];return t.length&&(P(t,function(n,a){a===0?i.push(["M",n.x,n.y]):i.push(["L",n.x,n.y])}),i.push(["L",t[0].x,t[0].y])),i},r.prototype.getMaskAttrs=function(){return{path:this.getMaskPath()}},r.prototype.addPoint=function(){this.resize()},r}(JO),HCt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getMaskPath=function(){var t=this.points;return D_t(t,!0)},r}(VW),YCt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.setCursor=function(t){var i=this.context.view;i.getCanvas().setCursor(t)},r.prototype.default=function(){this.setCursor("default")},r.prototype.pointer=function(){this.setCursor("pointer")},r.prototype.move=function(){this.setCursor("move")},r.prototype.crosshair=function(){this.setCursor("crosshair")},r.prototype.wait=function(){this.setCursor("wait")},r.prototype.help=function(){this.setCursor("help")},r.prototype.text=function(){this.setCursor("text")},r.prototype.eResize=function(){this.setCursor("e-resize")},r.prototype.wResize=function(){this.setCursor("w-resize")},r.prototype.nResize=function(){this.setCursor("n-resize")},r.prototype.sResize=function(){this.setCursor("s-resize")},r.prototype.neResize=function(){this.setCursor("ne-resize")},r.prototype.nwResize=function(){this.setCursor("nw-resize")},r.prototype.seResize=function(){this.setCursor("se-resize")},r.prototype.swResize=function(){this.setCursor("sw-resize")},r.prototype.nsResize=function(){this.setCursor("ns-resize")},r.prototype.ewResize=function(){this.setCursor("ew-resize")},r}(Ie),WCt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.filterView=function(t,i,n){var a=this;t.getScaleByField(i)&&t.filter(i,n),t.views&&t.views.length&&P(t.views,function(o){a.filterView(o,i,n)})},r.prototype.filter=function(){var t=Jf(this.context);if(t){var i=this.context.view,n=t.component,a=n.get("field");if(np(t)){if(a){var o=n.getItemsByState("unchecked"),l=th(i,a),s=o.map(function(h){return h.name});s.length?this.filterView(i,a,function(h){var v=l.getText(h);return!s.includes(v)}):this.filterView(i,a,null),i.render(!0)}}else if(JY(t)){var u=n.getValue(),c=u[0],f=u[1];this.filterView(i,a,function(h){return h>=c&&h<=f}),i.render(!0)}}},r}(Ie);function WB(e,r,t,i){var n=Math.min(t[r],i[r]),a=Math.max(t[r],i[r]),o=e.range,l=o[0],s=o[1];if(n<l&&(n=l),a>s&&(a=s),n===s&&a===s)return null;var u=e.invert(n),c=e.invert(a);if(e.isCategory){var f=e.values.indexOf(u),h=e.values.indexOf(c),v=e.values.slice(f,h+1);return function(d){return v.includes(d)}}else return function(d){return d>=u&&d<=c}}var bi;(function(e){e.FILTER="brush-filter-processing",e.RESET="brush-filter-reset",e.BEFORE_FILTER="brush-filter:beforefilter",e.AFTER_FILTER="brush-filter:afterfilter",e.BEFORE_RESET="brush-filter:beforereset",e.AFTER_RESET="brush-filter:afterreset"})(bi||(bi={}));var F_=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.dims=["x","y"],t.startPoint=null,t.isStarted=!1,t}return r.prototype.hasDim=function(t){return this.dims.includes(t)},r.prototype.start=function(){var t=this.context;this.isStarted=!0,this.startPoint=t.getCurrentPoint()},r.prototype.filter=function(){var t,i;if(ap(this.context)){var n=this.context.event.target,a=n.getCanvasBBox();t={x:a.x,y:a.y},i={x:a.maxX,y:a.maxY}}else{if(!this.isStarted)return;t=this.startPoint,i=this.context.getCurrentPoint()}if(!(Math.abs(t.x-i.x)<5||Math.abs(t.x-i.y)<5)){var o=this.context,l=o.view,s=o.event,u={view:l,event:s,dims:this.dims};l.emit(bi.BEFORE_FILTER,$e.fromData(l,bi.BEFORE_FILTER,u));var c=l.getCoordinate(),f=c.invert(i),h=c.invert(t);if(this.hasDim("x")){var v=l.getXScale(),d=WB(v,"x",f,h);this.filterView(l,v.field,d)}if(this.hasDim("y")){var p=l.getYScales()[0],d=WB(p,"y",f,h);this.filterView(l,p.field,d)}this.reRender(l,{source:bi.FILTER}),l.emit(bi.AFTER_FILTER,$e.fromData(l,bi.AFTER_FILTER,u))}},r.prototype.end=function(){this.isStarted=!1},r.prototype.reset=function(){var t=this.context.view;if(t.emit(bi.BEFORE_RESET,$e.fromData(t,bi.BEFORE_RESET,{})),this.isStarted=!1,this.hasDim("x")){var i=t.getXScale();this.filterView(t,i.field,null)}if(this.hasDim("y")){var n=t.getYScales()[0];this.filterView(t,n.field,null)}this.reRender(t,{source:bi.RESET}),t.emit(bi.AFTER_RESET,$e.fromData(t,bi.AFTER_RESET,{}))},r.prototype.filterView=function(t,i,n){t.filter(i,n)},r.prototype.reRender=function(t,i){t.render(!0,i)},r}(Ie),tP=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.filterView=function(t,i,n){var a=vo(t);P(a,function(o){o.filter(i,n)})},r.prototype.reRender=function(t){var i=vo(t);P(i,function(n){n.render(!0)})},r}(F_),XCt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.filter=function(){var t=Jf(this.context),i=this.context.view,n=Vr(i);if(ap(this.context)){var a=SO(this.context,10);a&&P(n,function(d){a.includes(d)?d.show():d.hide()})}else if(t){var o=t.component,l=o.get("field");if(np(t)){if(l){var s=o.getItemsByState("unchecked"),u=th(i,l),c=s.map(function(d){return d.name});P(n,function(d){var p=Ea(d,l),x=u.getText(p);c.indexOf(x)>=0?d.hide():d.show()})}}else if(JY(t)){var f=o.getValue(),h=f[0],v=f[1];P(n,function(d){var p=Ea(d,l);p>=h&&p<=v?d.show():d.hide()})}}},r.prototype.clear=function(){var t=Vr(this.context.view);P(t,function(i){i.show()})},r.prototype.reset=function(){this.clear()},r}(Ie),jW=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.byRecord=!1,t}return r.prototype.filter=function(){ap(this.context)&&(this.byRecord?this.filterByRecord():this.filterByBBox())},r.prototype.filterByRecord=function(){var t=this.context.view,i=SO(this.context,10);if(!!i){var n=t.getXScale().field,a=t.getYScales()[0].field,o=i.map(function(s){return s.getModel().data}),l=vo(t);P(l,function(s){var u=Vr(s);P(u,function(c){var f=c.getModel().data;iW(o,f,n,a)?c.show():c.hide()})})}},r.prototype.filterByBBox=function(){var t=this,i=this.context.view,n=vo(i);P(n,function(a){var o=tW(t.context,a,10),l=Vr(a);o&&P(l,function(s){o.includes(s)?s.show():s.hide()})})},r.prototype.reset=function(){var t=vo(this.context.view);P(t,function(i){var n=Vr(i);P(n,function(a){a.show()})})},r}(Ie),UCt=10,qCt=5,ZCt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.buttonGroup=null,t.buttonCfg={name:"button",text:"button",textStyle:{x:0,y:0,fontSize:12,fill:"#333333",cursor:"pointer"},padding:[8,10],style:{fill:"#f7f7f7",stroke:"#cccccc",cursor:"pointer"},activeStyle:{fill:"#e6e6e6"}},t}return r.prototype.getButtonCfg=function(){return ft(this.buttonCfg,this.cfg)},r.prototype.drawButton=function(){var t=this.getButtonCfg(),i=this.context.view.foregroundGroup.addGroup({name:t.name}),n=i.addShape({type:"text",name:"button-text",attrs:A({text:t.text},t.textStyle)}),a=n.getBBox(),o=EO(t.padding),l=i.addShape({type:"rect",name:"button-rect",attrs:A({x:a.x-o[3],y:a.y-o[0],width:a.width+o[1]+o[3],height:a.height+o[0]+o[2]},t.style)});l.toBack(),i.on("mouseenter",function(){l.attr(t.activeStyle)}),i.on("mouseleave",function(){l.attr(t.style)}),this.buttonGroup=i},r.prototype.resetPosition=function(){var t=this.context.view,i=t.getCoordinate(),n=i.convert({x:1,y:1}),a=this.buttonGroup,o=a.getBBox(),l=rr(null,[["t",n.x-o.width-UCt,n.y+o.height+qCt]]);a.setMatrix(l)},r.prototype.show=function(){this.buttonGroup||this.drawButton(),this.resetPosition(),this.buttonGroup.show()},r.prototype.hide=function(){this.buttonGroup&&this.buttonGroup.hide()},r.prototype.destroy=function(){var t=this.buttonGroup;t&&t.remove(),e.prototype.destroy.call(this)},r}(Ie),QCt=4,KCt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.starting=!1,t.dragStart=!1,t}return r.prototype.start=function(){this.starting=!0,this.startPoint=this.context.getCurrentPoint()},r.prototype.drag=function(){if(!!this.startPoint){var t=this.context.getCurrentPoint(),i=this.context.view,n=this.context.event;this.dragStart?i.emit("drag",{target:n.target,x:n.x,y:n.y}):TO(t,this.startPoint)>QCt&&(i.emit("dragstart",{target:n.target,x:n.x,y:n.y}),this.dragStart=!0)}},r.prototype.end=function(){if(this.dragStart){var t=this.context.view,i=this.context.event;t.emit("dragend",{target:i.target,x:i.x,y:i.y})}this.starting=!1,this.dragStart=!1},r}(Ie),JCt=5,tSt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.starting=!1,t.isMoving=!1,t.startPoint=null,t.startMatrix=null,t}return r.prototype.start=function(){this.starting=!0,this.startPoint=this.context.getCurrentPoint(),this.startMatrix=this.context.view.middleGroup.getMatrix()},r.prototype.move=function(){if(!!this.starting){var t=this.startPoint,i=this.context.getCurrentPoint(),n=TO(t,i);if(n>JCt&&!this.isMoving&&(this.isMoving=!0),this.isMoving){var a=this.context.view,o=rr(this.startMatrix,[["t",i.x-t.x,i.y-t.y]]);a.backgroundGroup.setMatrix(o),a.foregroundGroup.setMatrix(o),a.middleGroup.setMatrix(o)}}},r.prototype.end=function(){this.isMoving&&(this.isMoving=!1),this.startMatrix=null,this.starting=!1,this.startPoint=null},r.prototype.reset=function(){this.starting=!1,this.startPoint=null,this.isMoving=!1;var t=this.context.view;t.backgroundGroup.resetMatrix(),t.foregroundGroup.resetMatrix(),t.middleGroup.resetMatrix(),this.isMoving=!1},r}(Ie),XB="x",UB="y",HW=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.dims=[XB,UB],t.cfgFields=["dims"],t.cacheScaleDefs={},t}return r.prototype.hasDim=function(t){return this.dims.includes(t)},r.prototype.getScale=function(t){var i=this.context.view;return t==="x"?i.getXScale():i.getYScales()[0]},r.prototype.resetDim=function(t){var i=this.context.view;if(this.hasDim(t)&&this.cacheScaleDefs[t]){var n=this.getScale(t);i.scale(n.field,this.cacheScaleDefs[t]),this.cacheScaleDefs[t]=null}},r.prototype.reset=function(){this.resetDim(XB),this.resetDim(UB);var t=this.context.view;t.render(!0)},r}(Ie),eSt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.startPoint=null,t.starting=!1,t.startCache={},t}return r.prototype.start=function(){var t=this;this.startPoint=this.context.getCurrentPoint(),this.starting=!0;var i=this.dims;P(i,function(n){var a=t.getScale(n),o=a.min,l=a.max,s=a.values;t.startCache[n]={min:o,max:l,values:s}})},r.prototype.end=function(){this.startPoint=null,this.starting=!1,this.startCache={}},r.prototype.translate=function(){var t=this;if(!!this.starting){var i=this.startPoint,n=this.context.view.getCoordinate(),a=this.context.getCurrentPoint(),o=n.invert(i),l=n.invert(a),s=l.x-o.x,u=l.y-o.y,c=this.context.view,f=this.dims;P(f,function(h){t.translateDim(h,{x:s*-1,y:u*-1})}),c.render(!0)}},r.prototype.translateDim=function(t,i){if(this.hasDim(t)){var n=this.getScale(t);n.isLinear&&this.translateLinear(t,n,i)}},r.prototype.translateLinear=function(t,i,n){var a=this.context.view,o=this.startCache[t],l=o.min,s=o.max,u=s-l,c=n[t]*u;this.cacheScaleDefs[t]||(this.cacheScaleDefs[t]={nice:i.nice,min:l,max:s}),a.scale(i.field,{nice:!1,min:l+c,max:s+c})},r.prototype.reset=function(){e.prototype.reset.call(this),this.startPoint=null,this.starting=!1},r}(HW),rSt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.zoomRatio=.05,t}return r.prototype.zoomIn=function(){this.zoom(this.zoomRatio)},r.prototype.zoom=function(t){var i=this,n=this.dims;P(n,function(a){i.zoomDim(a,t)}),this.context.view.render(!0)},r.prototype.zoomOut=function(){this.zoom(-1*this.zoomRatio)},r.prototype.zoomDim=function(t,i){if(this.hasDim(t)){var n=this.getScale(t);n.isLinear&&this.zoomLinear(t,n,i)}},r.prototype.zoomLinear=function(t,i,n){var a=this.context.view;this.cacheScaleDefs[t]||(this.cacheScaleDefs[t]={nice:i.nice,min:i.min,max:i.max});var o=this.cacheScaleDefs[t],l=o.max-o.min,s=i.min,u=i.max,c=n*l,f=s-c,h=u+c,v=h-f,d=v/l;h>f&&d<100&&d>.01&&a.scale(i.field,{nice:!1,min:s-c,max:u+c})},r}(HW);function iSt(e){var r=e.gEvent.originalEvent;return r.deltaY>0}var nSt=1,aSt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.scroll=function(t){var i=this.context,n=i.view,a=i.event;if(!!n.getOptions().scrollbar){var o=(t==null?void 0:t.wheelDelta)||nSt,l=n.getController("scrollbar"),s=n.getXScale(),u=n.getOptions().data,c=yr(Xn(u,s.field)),f=yr(s.values),h=l.getValue(),v=Math.floor((c-f)*h),d=v+(iSt(a)?o:-o),p=o/(c-f)/1e4,x=Ce(d/(c-f)+p,0,1);l.setValue(x)}},r}(Ie);uW("dark",lW(Mbt));bO("canvas",uj);bO("svg",Cj);ka("Polygon",Ybt);ka("Interval",Gbt);ka("Schema",Wbt);ka("Path",NO);ka("Point",jbt);ka("Line",zbt);ka("Area",Lbt);ka("Edge",Dbt);ka("Heatmap",$bt);ka("Violin",Ubt);kh("base",gg);kh("interval",cwt);kh("pie",fwt);kh("polar",IW);Ii("overlap",Awt);Ii("distribute",vwt);Ii("fixed-overlap",Swt);Ii("hide-overlap",Pwt);Ii("limit-in-shape",_wt);Ii("limit-in-canvas",xwt);Ii("limit-in-plot",Uwt);Ii("pie-outer",pwt);Ii("adjust-color",Lwt);Ii("interval-adjust-position",Rwt);Ii("interval-hide-overlap",Nwt);Ii("point-adjust-position",Vwt);Ii("pie-spider",mwt);Ii("path-adjust-position",Ywt);Qi("fade-in",qwt);Qi("fade-out",Zwt);Qi("grow-in-x",Kwt);Qi("grow-in-xy",tCt);Qi("grow-in-y",Jwt);Qi("scale-in-x",iCt);Qi("scale-in-y",nCt);Qi("wave-in",oCt);Qi("zoom-in",lCt);Qi("zoom-out",sCt);Qi("position-update",rCt);Qi("sector-path-update",aCt);Qi("path-in",eCt);dc("rect",vCt);dc("mirror",hCt);dc("list",cCt);dc("matrix",fCt);dc("circle",uCt);dc("tree",dCt);Ds("axis",yCt);Ds("legend",mCt);Ds("tooltip",PO);Ds("annotation",gCt);Ds("slider",xCt);Ds("scrollbar",wCt);Et("tooltip",RW);Et("sibling-tooltip",TCt);Et("ellipsis-text",MCt);Et("element-active",ECt);Et("element-single-active",PCt);Et("element-range-active",OCt);Et("element-highlight",QO);Et("element-highlight-by-x",LCt);Et("element-highlight-by-color",ICt);Et("element-single-highlight",DCt);Et("element-range-highlight",NW);Et("element-sibling-highlight",NW,{effectSiblings:!0,effectByRecord:!0});Et("element-selected",kCt);Et("element-single-selected",RCt);Et("element-range-selected",$Ct);Et("element-link-by-color",FCt);Et("active-region",ACt);Et("list-active",BCt);Et("list-selected",GCt);Et("list-highlight",KO);Et("list-unchecked",zCt);Et("list-checked",VCt);Et("legend-item-highlight",KO,{componentNames:["legend"]});Et("axis-label-highlight",KO,{componentNames:["axis"]});Et("rect-mask",GW);Et("x-rect-mask",zW,{dim:"x"});Et("y-rect-mask",zW,{dim:"y"});Et("circle-mask",jCt);Et("path-mask",VW);Et("smooth-path-mask",HCt);Et("cursor",YCt);Et("data-filter",WCt);Et("brush",F_);Et("brush-x",F_,{dims:["x"]});Et("brush-y",F_,{dims:["y"]});Et("sibling-filter",tP);Et("sibling-x-filter",tP);Et("sibling-y-filter",tP);Et("element-filter",XCt);Et("element-sibling-filter",jW);Et("element-sibling-filter-record",jW,{byRecord:!0});Et("view-drag",KCt);Et("view-move",tSt);Et("scale-translate",eSt);Et("scale-zoom",rSt);Et("reset-button",ZCt,{name:"reset-button",text:"reset"});Et("mousewheel-scroll",aSt);function is(e){return e.isInPlot()}Lt("tooltip",{start:[{trigger:"plot:mousemove",action:"tooltip:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"plot:touchmove",action:"tooltip:show",throttle:{wait:50,leading:!0,trailing:!1}}],end:[{trigger:"plot:mouseleave",action:"tooltip:hide"},{trigger:"plot:leave",action:"tooltip:hide"},{trigger:"plot:touchend",action:"tooltip:hide"}]});Lt("ellipsis-text",{start:[{trigger:"legend-item-name:mousemove",action:"ellipsis-text:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"legend-item-name:touchstart",action:"ellipsis-text:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"axis-label:mousemove",action:"ellipsis-text:show",throttle:{wait:50,leading:!0,trailing:!1}},{trigger:"axis-label:touchstart",action:"ellipsis-text:show",throttle:{wait:50,leading:!0,trailing:!1}}],end:[{trigger:"legend-item-name:mouseleave",action:"ellipsis-text:hide"},{trigger:"legend-item-name:touchend",action:"ellipsis-text:hide"},{trigger:"axis-label:mouseleave",action:"ellipsis-text:hide"},{trigger:"axis-label:touchend",action:"ellipsis-text:hide"}]});Lt("element-active",{start:[{trigger:"element:mouseenter",action:"element-active:active"}],end:[{trigger:"element:mouseleave",action:"element-active:reset"}]});Lt("element-selected",{start:[{trigger:"element:click",action:"element-selected:toggle"}]});Lt("element-highlight",{start:[{trigger:"element:mouseenter",action:"element-highlight:highlight"}],end:[{trigger:"element:mouseleave",action:"element-highlight:reset"}]});Lt("element-highlight-by-x",{start:[{trigger:"element:mouseenter",action:"element-highlight-by-x:highlight"}],end:[{trigger:"element:mouseleave",action:"element-highlight-by-x:reset"}]});Lt("element-highlight-by-color",{start:[{trigger:"element:mouseenter",action:"element-highlight-by-color:highlight"}],end:[{trigger:"element:mouseleave",action:"element-highlight-by-color:reset"}]});Lt("legend-active",{start:[{trigger:"legend-item:mouseenter",action:["list-active:active","element-active:active"]}],end:[{trigger:"legend-item:mouseleave",action:["list-active:reset","element-active:reset"]}]});Lt("legend-highlight",{start:[{trigger:"legend-item:mouseenter",action:["legend-item-highlight:highlight","element-highlight:highlight"]}],end:[{trigger:"legend-item:mouseleave",action:["legend-item-highlight:reset","element-highlight:reset"]}]});Lt("axis-label-highlight",{start:[{trigger:"axis-label:mouseenter",action:["axis-label-highlight:highlight","element-highlight:highlight"]}],end:[{trigger:"axis-label:mouseleave",action:["axis-label-highlight:reset","element-highlight:reset"]}]});Lt("element-list-highlight",{start:[{trigger:"element:mouseenter",action:["list-highlight:highlight","element-highlight:highlight"]}],end:[{trigger:"element:mouseleave",action:["list-highlight:reset","element-highlight:reset"]}]});Lt("element-range-highlight",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"mask:mouseenter",action:"cursor:move"},{trigger:"plot:mouseleave",action:"cursor:default"},{trigger:"mask:mouseleave",action:"cursor:crosshair"}],start:[{trigger:"plot:mousedown",isEnable:function(e){return!e.isInShape("mask")},action:["rect-mask:start","rect-mask:show"]},{trigger:"mask:dragstart",action:["rect-mask:moveStart"]}],processing:[{trigger:"plot:mousemove",action:["rect-mask:resize"]},{trigger:"mask:drag",action:["rect-mask:move"]},{trigger:"mask:change",action:["element-range-highlight:highlight"]}],end:[{trigger:"plot:mouseup",action:["rect-mask:end"]},{trigger:"mask:dragend",action:["rect-mask:moveEnd"]},{trigger:"document:mouseup",isEnable:function(e){return!e.isInPlot()},action:["element-range-highlight:clear","rect-mask:end","rect-mask:hide"]}],rollback:[{trigger:"dblclick",action:["element-range-highlight:clear","rect-mask:hide"]}]});Lt("brush",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"mousedown",isEnable:is,action:["brush:start","rect-mask:start","rect-mask:show"]}],processing:[{trigger:"mousemove",isEnable:is,action:["rect-mask:resize"]}],end:[{trigger:"mouseup",isEnable:is,action:["brush:filter","brush:end","rect-mask:end","rect-mask:hide","reset-button:show"]}],rollback:[{trigger:"reset-button:click",action:["brush:reset","reset-button:hide","cursor:crosshair"]}]});Lt("brush-visible",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"plot:mousedown",action:["rect-mask:start","rect-mask:show"]}],processing:[{trigger:"plot:mousemove",action:["rect-mask:resize"]},{trigger:"mask:change",action:["element-range-highlight:highlight"]}],end:[{trigger:"plot:mouseup",action:["rect-mask:end","rect-mask:hide","element-filter:filter","element-range-highlight:clear"]}],rollback:[{trigger:"dblclick",action:["element-filter:clear"]}]});Lt("brush-x",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"mousedown",isEnable:is,action:["brush-x:start","x-rect-mask:start","x-rect-mask:show"]}],processing:[{trigger:"mousemove",isEnable:is,action:["x-rect-mask:resize"]}],end:[{trigger:"mouseup",isEnable:is,action:["brush-x:filter","brush-x:end","x-rect-mask:end","x-rect-mask:hide"]}],rollback:[{trigger:"dblclick",action:["brush-x:reset"]}]});Lt("element-path-highlight",{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"mousedown",isEnable:is,action:"path-mask:start"},{trigger:"mousedown",isEnable:is,action:"path-mask:show"}],processing:[{trigger:"mousemove",action:"path-mask:addPoint"}],end:[{trigger:"mouseup",action:"path-mask:end"}],rollback:[{trigger:"dblclick",action:"path-mask:hide"}]});Lt("element-single-selected",{start:[{trigger:"element:click",action:"element-single-selected:toggle"}]});Lt("legend-filter",{showEnable:[{trigger:"legend-item:mouseenter",action:"cursor:pointer"},{trigger:"legend-item:mouseleave",action:"cursor:default"}],start:[{trigger:"legend-item:click",action:["list-unchecked:toggle","data-filter:filter"]}]});Lt("continuous-filter",{start:[{trigger:"legend:valuechanged",action:"data-filter:filter"}]});Lt("continuous-visible-filter",{start:[{trigger:"legend:valuechanged",action:"element-filter:filter"}]});Lt("legend-visible-filter",{showEnable:[{trigger:"legend-item:mouseenter",action:"cursor:pointer"},{trigger:"legend-item:mouseleave",action:"cursor:default"}],start:[{trigger:"legend-item:click",action:["list-unchecked:toggle","element-filter:filter"]}]});Lt("active-region",{start:[{trigger:"plot:mousemove",action:"active-region:show"}],end:[{trigger:"plot:mouseleave",action:"active-region:hide"}]});function qB(e){return e.gEvent.preventDefault(),e.gEvent.originalEvent.deltaY>0}Lt("view-zoom",{start:[{trigger:"plot:mousewheel",isEnable:function(e){return qB(e.event)},action:"scale-zoom:zoomOut",throttle:{wait:100,leading:!0,trailing:!1}},{trigger:"plot:mousewheel",isEnable:function(e){return!qB(e.event)},action:"scale-zoom:zoomIn",throttle:{wait:100,leading:!0,trailing:!1}}]});Lt("sibling-tooltip",{start:[{trigger:"plot:mousemove",action:"sibling-tooltip:show"}],end:[{trigger:"plot:mouseleave",action:"sibling-tooltip:hide"}]});Lt("plot-mousewheel-scroll",{start:[{trigger:"plot:mousewheel",action:"mousewheel-scroll:scroll"}]});var oSt=Object.freeze(Object.defineProperty({__proto__:null,get BRUSH_FILTER_EVENTS(){return bi},get ELEMENT_RANGE_HIGHLIGHT_EVENTS(){return da},get VIEW_LIFE_CIRCLE(){return Gt},Chart:hW,View:OO,Event:$e,ComponentController:pc,TooltipController:PO,Geometry:hl,Element:DO,GeometryLabel:gg,Interaction:nW,Action:Ie,Facet:vc,InteractionAction:Ie,registerComponentController:Ds,registerGeometry:ka,registerShape:te,registerShapeFactory:fl,getShapeFactory:TT,registerGeometryLabel:kh,registerGeometryLabelLayout:Ii,getGeometryLabel:yW,getGeometryLabelLayout:mW,getInteraction:oW,registerInteraction:Lt,registerAction:Et,getActionClass:vg,getFacet:UY,registerFacet:dc,getTheme:rs,registerTheme:uW,registerEngine:bO,getEngine:GY,registerAnimation:Qi,getAnimation:IO,get LAYER(){return Ye},get DIRECTION(){return ct},Coordinate:Ip,Scale:Sh,VERSION:Cbt,Util:Fi},Symbol.toStringTag,{value:"Module"})),me=br(oSt),ns={},rh={},YW={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var r=1,t=function(){return"".concat(r++)};e.default=t})(YW);var O_={},P_={},eP={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var r=function(i){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:60,a=null;return function(){for(var o=this,l=arguments.length,s=new Array(l),u=0;u<l;u++)s[u]=arguments[u];clearTimeout(a),a=setTimeout(function(){i.apply(o,s)},n)}};e.default=r})(eP);var Jo={};Object.defineProperty(Jo,"__esModule",{value:!0});Jo.SensorTabIndex=Jo.SensorClassName=Jo.SizeSensorId=void 0;var lSt="size-sensor-id";Jo.SizeSensorId=lSt;var sSt="size-sensor-object";Jo.SensorClassName=sSt;var uSt="-1";Jo.SensorTabIndex=uSt;Object.defineProperty(P_,"__esModule",{value:!0});P_.createSensor=void 0;var cSt=fSt(eP),ZB=Jo;function fSt(e){return e&&e.__esModule?e:{default:e}}var hSt=function(r){var t=void 0,i=[],n=function(){getComputedStyle(r).position==="static"&&(r.style.position="relative");var c=document.createElement("object");return c.onload=function(){c.contentDocument.defaultView.addEventListener("resize",a),a()},c.style.display="block",c.style.position="absolute",c.style.top="0",c.style.left="0",c.style.height="100%",c.style.width="100%",c.style.overflow="hidden",c.style.pointerEvents="none",c.style.zIndex="-1",c.style.opacity="0",c.setAttribute("class",ZB.SensorClassName),c.setAttribute("tabindex",ZB.SensorTabIndex),c.type="text/html",r.appendChild(c),c.data="about:blank",c},a=(0,cSt.default)(function(){i.forEach(function(u){u(r)})}),o=function(c){t||(t=n()),i.indexOf(c)===-1&&i.push(c)},l=function(){t&&t.parentNode&&(t.contentDocument&&t.contentDocument.defaultView.removeEventListener("resize",a),t.parentNode.removeChild(t),t=void 0,i=[])},s=function(c){var f=i.indexOf(c);f!==-1&&i.splice(f,1),i.length===0&&t&&l()};return{element:r,bind:o,destroy:l,unbind:s}};P_.createSensor=hSt;var I_={};Object.defineProperty(I_,"__esModule",{value:!0});I_.createSensor=void 0;var vSt=dSt(eP);function dSt(e){return e&&e.__esModule?e:{default:e}}var pSt=function(r){var t=void 0,i=[],n=(0,vSt.default)(function(){i.forEach(function(u){u(r)})}),a=function(){var c=new ResizeObserver(n);return c.observe(r),n(),c},o=function(c){t||(t=a()),i.indexOf(c)===-1&&i.push(c)},l=function(){t.disconnect(),i=[],t=void 0},s=function(c){var f=i.indexOf(c);f!==-1&&i.splice(f,1),i.length===0&&t&&l()};return{element:r,bind:o,destroy:l,unbind:s}};I_.createSensor=pSt;Object.defineProperty(O_,"__esModule",{value:!0});O_.createSensor=void 0;var gSt=P_,ySt=I_,mSt=typeof ResizeObserver!="undefined"?ySt.createSensor:gSt.createSensor;O_.createSensor=mSt;Object.defineProperty(rh,"__esModule",{value:!0});rh.removeSensor=rh.getSensor=void 0;var xSt=bSt(YW),_St=O_,Cx=Jo;function bSt(e){return e&&e.__esModule?e:{default:e}}var Td={},wSt=function(r){var t=r.getAttribute(Cx.SizeSensorId);if(t&&Td[t])return Td[t];var i=(0,xSt.default)();r.setAttribute(Cx.SizeSensorId,i);var n=(0,_St.createSensor)(r);return Td[i]=n,n};rh.getSensor=wSt;var CSt=function(r){var t=r.element.getAttribute(Cx.SizeSensorId);r.element.removeAttribute(Cx.SizeSensorId),r.destroy(),t&&Td[t]&&delete Td[t]};rh.removeSensor=CSt;Object.defineProperty(ns,"__esModule",{value:!0});ns.ver=ns.clear=WW=ns.bind=void 0;var LT=rh,SSt=function(r,t){var i=(0,LT.getSensor)(r);return i.bind(t),function(){i.unbind(t)}},WW=ns.bind=SSt,ASt=function(r){var t=(0,LT.getSensor)(r);(0,LT.removeSensor)(t)};ns.clear=ASt;var TSt="1.0.1";ns.ver=TSt;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Plot=e.PLOT_CONTAINER_OPTIONS=void 0;var r=V,t=me,i=Y,n=r.__importDefault(h3),a=ns,o=mt,l="data-chart-source-type";e.PLOT_CONTAINER_OPTIONS=["padding","appendPadding","renderer","pixelRatio","syncViewPadding","supportCSSTransform","limitInPlot"];var s=function(u){r.__extends(c,u);function c(f,h){var v=u.call(this)||this;return v.container=typeof f=="string"?document.getElementById(f):f,v.options=o.deepAssign({},v.getDefaultOptions(),h),v.createG2(),v.bindEvents(),v}return c.getDefaultOptions=function(){return{renderer:"canvas",xAxis:{nice:!0,label:{autoRotate:!1,autoHide:{type:"equidistance",cfg:{minGap:6}}}},yAxis:{nice:!0,label:{autoHide:!0,autoRotate:!1}},animation:!0}},c.prototype.createG2=function(){var f=this.options,h=f.width,v=f.height,d=f.defaultInteractions;this.chart=new t.Chart(r.__assign(r.__assign(r.__assign(r.__assign({container:this.container,autoFit:!1},this.getChartSize(h,v)),{localRefresh:!1}),o.pick(this.options,e.PLOT_CONTAINER_OPTIONS)),{defaultInteractions:d})),this.container.setAttribute(l,"G2Plot")},c.prototype.getChartSize=function(f,h){var v=o.getContainerSize(this.container);return{width:f||v.width||400,height:h||v.height||400}},c.prototype.bindEvents=function(){var f=this;this.chart&&this.chart.on("*",function(h){h!=null&&h.type&&f.emit(h.type,h)})},c.prototype.getDefaultOptions=function(){return c.getDefaultOptions()},c.prototype.render=function(){this.chart.clear(),this.chart.options={data:[],animate:!0},this.chart.views=[],this.execAdaptor(),this.chart.render(),this.bindSizeSensor()},c.prototype.update=function(f){this.updateOption(f),this.render()},c.prototype.updateOption=function(f){this.options=o.deepAssign({},this.options,f)},c.prototype.setState=function(f,h,v){v===void 0&&(v=!0);var d=o.getAllElementsRecursively(this.chart);i.each(d,function(p){h(p.getData())&&p.setState(f,v)})},c.prototype.getStates=function(){var f=o.getAllElementsRecursively(this.chart),h=[];return i.each(f,function(v){var d=v.getData(),p=v.getStates();i.each(p,function(x){h.push({data:d,state:x,geometry:v.geometry,element:v})})}),h},c.prototype.changeData=function(f){this.update({data:f})},c.prototype.changeSize=function(f,h){this.chart.changeSize(f,h)},c.prototype.addAnnotations=function(f){var h=r.__spreadArrays(f),v=this.chart.getController("annotation"),d=v.getComponents().map(function(m){return m.extra});v.clear(!0);for(var p=function(m){var _=d[m],b=h.findIndex(function(w){return w.id&&w.id===_.id});b!==-1&&(_=o.deepAssign({},_,h[b]),h.splice(b,1)),v.annotation(_)},x=0;x<d.length;x++)p(x);h.forEach(function(m){return v.annotation(m)}),this.chart.render(!0)},c.prototype.removeAnnotations=function(f){var h=this.chart.getController("annotation"),v=h.getComponents().map(function(x){return x.extra});h.clear(!0);for(var d=function(x){var m=v[x];f.find(function(_){return _.id&&_.id===m.id})||h.annotation(m)},p=0;p<v.length;p++)d(p);this.chart.render(!0)},c.prototype.destroy=function(){this.unbindSizeSensor(),this.chart.destroy(),this.off(),this.container.removeAttribute(l)},c.prototype.execAdaptor=function(){var f=this.getSchemaAdaptor(),h=this.options,v=h.padding,d=h.appendPadding;this.chart.padding=v,this.chart.appendPadding=d,f({chart:this.chart,options:this.options})},c.prototype.triggerResize=function(){this.chart.forceFit()},c.prototype.bindSizeSensor=function(){var f=this;if(!this.unbind){var h=this.options.autoFit,v=h===void 0?!0:h;v&&(this.unbind=a.bind(this.container,function(){var d=o.getContainerSize(f.container),p=d.width,x=d.height;(p!==f.chart.width||x!==f.chart.height)&&f.triggerResize()}))}},c.prototype.unbindSizeSensor=function(){this.unbind&&(this.unbind(),this.unbind=void 0)},c}(n.default);e.Plot=s})(ae);var ec={},Qe={},mg={};Object.defineProperty(mg,"__esModule",{value:!0});mg.AXIS_META_CONFIG_KEYS=void 0;mg.AXIS_META_CONFIG_KEYS=["type","alias","tickCount","tickInterval","min","max","nice","minLimit","maxLimit","range","tickMethod","base","exponent","mask","sync"];var $s={},L_={},XW={},vi={};Object.defineProperty(vi,"__esModule",{value:!0});vi.transformMatrix=vi.getSymbolsPosition=vi.getUnitPatternSize=vi.drawBackground=vi.initCanvas=vi.getPixelRatio=void 0;function UW(){return typeof window=="object"?window==null?void 0:window.devicePixelRatio:2}vi.getPixelRatio=UW;function MSt(e,r){r===void 0&&(r=e);var t=document.createElement("canvas"),i=UW();t.width=e*i,t.height=r*i,t.style.width=e+"px",t.style.height=r+"px";var n=t.getContext("2d");return n.scale(i,i),t}vi.initCanvas=MSt;function ESt(e,r,t,i){i===void 0&&(i=t);var n=r.backgroundColor,a=r.opacity;e.globalAlpha=a,e.fillStyle=n,e.beginPath(),e.fillRect(0,0,t,i),e.closePath()}vi.drawBackground=ESt;function FSt(e,r,t){var i=e+r;return t?i*2:i}vi.getUnitPatternSize=FSt;function OSt(e,r){var t=r?[[e*.25,e*.25],[e*.75,e*.75]]:[[e*.5,e*.5]];return t}vi.getSymbolsPosition=OSt;function PSt(e,r){var t=r*Math.PI/180,i={a:Math.cos(t)*(1/e),b:Math.sin(t)*(1/e),c:-Math.sin(t)*(1/e),d:Math.cos(t)*(1/e),e:0,f:0};return i}vi.transformMatrix=PSt;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.createDotPattern=e.drawDot=e.defaultDotPatternCfg=void 0;var r=mt,t=vi;e.defaultDotPatternCfg={size:6,padding:2,backgroundColor:"transparent",opacity:1,rotation:0,fill:"#fff",fillOpacity:.5,stroke:"transparent",lineWidth:0,isStagger:!0};function i(a,o,l,s){var u=o.size,c=o.fill,f=o.lineWidth,h=o.stroke,v=o.fillOpacity;a.beginPath(),a.globalAlpha=v,a.fillStyle=c,a.strokeStyle=h,a.lineWidth=f,a.arc(l,s,u/2,0,2*Math.PI,!1),a.fill(),f&&a.stroke(),a.closePath()}e.drawDot=i;function n(a){var o=r.deepAssign({},e.defaultDotPatternCfg,a),l=o.size,s=o.padding,u=o.isStagger,c=o.rotation,f=t.getUnitPatternSize(l,s,u),h=t.getSymbolsPosition(f,u),v=t.initCanvas(f,f),d=v.getContext("2d");t.drawBackground(d,o,f);for(var p=0,x=h;p<x.length;p++){var m=x[p],_=m[0],b=m[1];i(d,o,_,b)}var w=d.createPattern(v,"repeat");if(w){var S=t.getPixelRatio(),M=t.transformMatrix(S,c);w.setTransform(M)}return w}e.createDotPattern=n})(XW);var qW={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.createLinePattern=e.drawLine=e.defaultLinePatternCfg=void 0;var r=mt,t=vi;e.defaultLinePatternCfg={rotation:45,spacing:5,opacity:1,backgroundColor:"transparent",strokeOpacity:.5,stroke:"#fff",lineWidth:2};function i(a,o,l){var s=o.stroke,u=o.lineWidth,c=o.strokeOpacity,f=new Path2D(l);a.globalAlpha=c,a.lineCap="square",a.strokeStyle=u?s:"transparent",a.lineWidth=u,a.stroke(f)}e.drawLine=i;function n(a){var o=r.deepAssign({},e.defaultLinePatternCfg,a),l=o.spacing,s=o.rotation,u=o.lineWidth,c=l+u||1,f=l+u||1,h=`
|
|
M 0 0 L `+c+` 0
|
|
M 0 `+f+" L "+c+" "+f+`
|
|
`,v=t.initCanvas(c,f),d=v.getContext("2d");t.drawBackground(d,o,c,f),i(d,o,h);var p=d.createPattern(v,"repeat");if(p){var x=t.getPixelRatio(),m=t.transformMatrix(x,s);p.setTransform(m)}return p}e.createLinePattern=n})(qW);var ZW={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.createSquarePattern=e.drawSquare=e.defaultSquarePatternCfg=void 0;var r=mt,t=vi;e.defaultSquarePatternCfg={size:6,padding:1,isStagger:!0,backgroundColor:"transparent",opacity:1,rotation:0,fill:"#fff",fillOpacity:.5,stroke:"transparent",lineWidth:0};function i(a,o,l,s){var u=o.stroke,c=o.size,f=o.fill,h=o.lineWidth,v=o.fillOpacity;a.globalAlpha=v,a.strokeStyle=u,a.lineWidth=h,a.fillStyle=f,a.strokeRect(l-c/2,s-c/2,c,c),a.fillRect(l-c/2,s-c/2,c,c)}e.drawSquare=i;function n(a){var o=r.deepAssign({},e.defaultSquarePatternCfg,a),l=o.size,s=o.padding,u=o.isStagger,c=o.rotation,f=t.getUnitPatternSize(l,s,u),h=t.getSymbolsPosition(f,u),v=t.initCanvas(f,f),d=v.getContext("2d");t.drawBackground(d,o,f);for(var p=0,x=h;p<x.length;p++){var m=x[p],_=m[0],b=m[1];i(d,o,_,b)}var w=d.createPattern(v,"repeat");if(w){var S=t.getPixelRatio(),M=t.transformMatrix(S,c);w.setTransform(M)}return w}e.createSquarePattern=n})(ZW);Object.defineProperty(L_,"__esModule",{value:!0});L_.getCanvasPattern=void 0;var ISt=XW,LSt=qW,DSt=ZW;function $St(e){var r=e.type,t=e.cfg,i;switch(r){case"dot":i=ISt.createDotPattern(t);break;case"line":i=LSt.createLinePattern(t);break;case"square":i=DSt.createSquarePattern(t);break}return i}L_.getCanvasPattern=$St;Object.defineProperty($s,"__esModule",{value:!0});$s.pattern=void 0;var MS=V,kSt=me,RSt=Y,BSt=L_,QB=mt;function NSt(e){var r=this;return function(t){var i,n=t.options,a=t.chart,o=n.pattern;if(!o)return t;var l=function(s){for(var u,c,f,h=[],v=1;v<arguments.length;v++)h[v-1]=arguments[v];var d=a.getTheme().defaultColor,p=d,x=(c=(u=a.geometries)===null||u===void 0?void 0:u[0])===null||c===void 0?void 0:c.getAttribute("color");if(x){var m=x.getFields()[0],_=RSt.get(s,m);p=kSt.Util.getMappingValue(x,_,((f=x.values)===null||f===void 0?void 0:f[0])||d)}var b=o;typeof o=="function"&&(b=o.call(r,s,p)),b instanceof CanvasPattern||(b=BSt.getCanvasPattern(QB.deepAssign({},{cfg:{backgroundColor:p}},b)));var w=n[e];return MS.__assign(MS.__assign({},typeof w=="function"?w.call.apply(w,MS.__spreadArrays([r,s],h)):w||{}),{fill:b||p})};return QB.deepAssign({},t,{options:(i={},i[e]=l,i)})}}$s.pattern=NSt;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.limitInPlot=e.annotation=e.scale=e.scrollbar=e.slider=e.state=e.theme=e.animation=e.interaction=e.tooltip=e.legend=void 0;var r=V,t=Y,i=mg,n=mt;function a(m){var _=m.chart,b=m.options,w=b.legend,S=b.colorField,M=b.seriesField;return w===!1?_.legend(!1):(S||M)&&_.legend(S||M,w),m}e.legend=a;function o(m){var _=m.chart,b=m.options,w=b.tooltip;return w!==void 0&&_.tooltip(w),m}e.tooltip=o;function l(m){var _=m.chart,b=m.options,w=b.interactions;return t.each(w,function(S){S.enable===!1?_.removeInteraction(S.type):_.interaction(S.type,S.cfg||{})}),m}e.interaction=l;function s(m){var _=m.chart,b=m.options,w=b.animation;return typeof w=="boolean"?_.animate(w):_.animate(!0),t.each(_.geometries,function(S){S.animate(w)}),m}e.animation=s;function u(m){var _=m.chart,b=m.options,w=b.theme;return w&&_.theme(w),m}e.theme=u;function c(m){var _=m.chart,b=m.options,w=b.state;return w&&t.each(_.geometries,function(S){S.state(w)}),m}e.state=c;function f(m){var _=m.chart,b=m.options,w=b.slider;return _.option("slider",w),m}e.slider=f;function h(m){var _=m.chart,b=m.options,w=b.scrollbar;return _.option("scrollbar",w),m}e.scrollbar=h;function v(m,_){return function(b){var w=b.chart,S=b.options,M={};return t.each(m,function(F,O){M[O]=n.pick(F,i.AXIS_META_CONFIG_KEYS)}),M=n.deepAssign({},_,S.meta,M),w.scale(M),b}}e.scale=v;function d(m){return function(_){var b=_.chart,w=_.options,S=b.getController("annotation");return t.each(r.__spreadArrays(w.annotations||[],m||[]),function(M){S.annotation(M)}),_}}e.annotation=d;function p(m){var _=m.chart,b=m.options,w=b.yAxis,S=b.limitInPlot,M=S;return t.isObject(w)&&t.isNil(S)&&(Object.values(n.pick(w,["min","max","minLimit","maxLimit"])).some(function(F){return!t.isNil(F)})?M=!0:M=!1),_.limitInPlot=M,m}e.limitInPlot=p;var x=$s;Object.defineProperty(e,"pattern",{enumerable:!0,get:function(){return x.pattern}})})(Qe);var Lr={},D_={},Li={};Object.defineProperty(Li,"__esModule",{value:!0});Li.getTooltipMapping=void 0;var KB=Y;function GSt(e,r){if(e===!1)return{fields:!1};var t=KB.get(e,"fields"),i=KB.get(e,"formatter");return i&&!t&&(t=r),{fields:t,formatter:i}}Li.getTooltipMapping=GSt;var _r={};Object.defineProperty(_r,"__esModule",{value:!0});_r.geometry=_r.getMappingFunction=_r.getMappingField=void 0;var Ou=V,qa=Y,zSt=mt;function Jv(e,r){var t=e.type,i=e.xField,n=e.yField,a=e.colorField,o=e.shapeField,l=e.sizeField,s=e.styleField,u=e.rawFields,c=u===void 0?[]:u,f=[];if(r==="color")f=Ou.__spreadArrays([a||i],c);else if(r==="shape")f=Ou.__spreadArrays([o||i],c);else if(r==="size")f=Ou.__spreadArrays([l||i],c);else{f=Ou.__spreadArrays([i,n,a,o,l,s],c);var h=["x","y","color","shape","size","style"].indexOf(r),v=f[h];f.splice(h,1),f.unshift(v)}var d=qa.uniq(f.filter(function(x){return!!x})),p=t==="line"&&[i,n].includes(d.join("*"))?"":d.join("*");return{mappingFields:d,tileMappingField:p}}_r.getMappingField=Jv;function ef(e,r){if(!!r)return function(){for(var t=[],i=0;i<arguments.length;i++)t[i]=arguments[i];var n={};return e.forEach(function(a,o){n[a]=t[o]}),delete n.undefined,r(n)}}_r.getMappingFunction=ef;function VSt(e){var r=e.chart,t=e.options,i=t.type,n=t.args,a=t.mapping,o=t.xField,l=t.yField,s=t.colorField,u=t.shapeField,c=t.sizeField,f=t.tooltipFields,h=t.label,v=t.state,d=t.customInfo;if(!a)return e;var p=a.color,x=a.shape,m=a.size,_=a.style,b=a.tooltip,w=r[i](n).position(o+"*"+l);if(qa.isString(p))s?w.color(s,p):w.color(p);else if(qa.isFunction(p)){var S=Jv(t,"color"),M=S.mappingFields,F=S.tileMappingField;w.color(F,ef(M,p))}else s&&w.color(s,p);if(qa.isString(x))u?w.shape(u,[x]):w.shape(x);else if(qa.isFunction(x)){var O=Jv(t,"shape"),M=O.mappingFields,F=O.tileMappingField;w.shape(F,ef(M,x))}else u&&w.shape(u,x);if(qa.isNumber(m))c?w.size(c,m):w.size(m);else if(qa.isFunction(m)){var L=Jv(t,"size"),M=L.mappingFields,F=L.tileMappingField;w.size(F,ef(M,m))}else c&&w.size(c,m);if(qa.isFunction(_)){var D=Jv(t,"style"),M=D.mappingFields,F=D.tileMappingField;w.style(F,ef(M,_))}else qa.isObject(_)&&w.style(_);if(f===!1?w.tooltip(!1):qa.isEmpty(f)||w.tooltip(f.join("*"),ef(f,b)),h===!1)w.label(!1);else if(h){var k=h.callback,H=h.fields,B=Ou.__rest(h,["callback","fields"]);w.label({fields:H||[l],callback:k,cfg:zSt.transformLabel(B)})}return v&&w.state(v),d&&w.customInfo(d),[o,l].filter(function(j){return j!==s}).forEach(function(j){r.legend(j,!1)}),Ou.__assign(Ou.__assign({},e),{ext:{geometry:w}})}_r.geometry=VSt;Object.defineProperty(D_,"__esModule",{value:!0});D_.area=void 0;var jSt=V,HSt=Li,YSt=mt,WSt=_r;function XSt(e){var r=e.options,t=r.area,i=r.xField,n=r.yField,a=r.seriesField,o=r.smooth,l=r.tooltip,s=HSt.getTooltipMapping(l,[i,n,a]),u=s.fields,c=s.formatter;return t?WSt.geometry(YSt.deepAssign({},e,{options:{type:"area",colorField:a,tooltipFields:u,mapping:jSt.__assign({shape:o?"smooth":"area",tooltip:c},t)}})):e}D_.area=XSt;var $_={};Object.defineProperty($_,"__esModule",{value:!0});$_.line=void 0;var USt=Y,qSt=Li,ZSt=mt,QSt=_r;function KSt(e){var r=e.options,t=r.line,i=r.stepType,n=r.xField,a=r.yField,o=r.seriesField,l=r.smooth,s=r.connectNulls,u=r.tooltip,c=qSt.getTooltipMapping(u,[n,a,o]),f=c.fields,h=c.formatter;return t?QSt.geometry(ZSt.deepAssign({},e,{options:{type:"line",colorField:o,tooltipFields:f,mapping:USt.deepMix({shape:i||(l?"smooth":"line"),tooltip:h},t),args:{connectNulls:s}}})):e}$_.line=KSt;var k_={};Object.defineProperty(k_,"__esModule",{value:!0});k_.point=void 0;var JSt=V,tAt=Li,eAt=mt,rAt=_r;function iAt(e){var r=e.options,t=r.point,i=r.xField,n=r.yField,a=r.seriesField,o=r.sizeField,l=r.shapeField,s=r.tooltip,u=tAt.getTooltipMapping(s,[i,n,a,o,l]),c=u.fields,f=u.formatter;return t?rAt.geometry(eAt.deepAssign({},e,{options:{type:"point",colorField:a,shapeField:l,tooltipFields:c,mapping:JSt.__assign({tooltip:f},t)}})):e}k_.point=iAt;var R_={};Object.defineProperty(R_,"__esModule",{value:!0});R_.interval=void 0;var ES=V,nAt=me,JB=Y,QW=mt,aAt=Li,oAt=_r;function lAt(e){var r=e.chart,t=e.options,i=e.ext,n=t.seriesField,a=t.isGroup,o=t.isStack,l=t.marginRatio,s=t.widthRatio,u=t.groupField,c=t.theme,f=[];if(n&&(a&&f.push({type:"dodge",dodgeBy:u||n,marginRatio:l}),o&&f.push({type:"stack",marginRatio:l})),f.length&&(i==null?void 0:i.geometry)){var h=i==null?void 0:i.geometry;h.adjust(f)}return JB.isNil(s)||r.theme(QW.deepAssign({},JB.isObject(c)?c:nAt.getTheme(c),{columnWidthRatio:s})),e}function sAt(e){var r=e.options,t=r.xField,i=r.yField,n=r.interval,a=r.seriesField,o=r.tooltip,l=r.minColumnWidth,s=r.maxColumnWidth,u=r.columnBackground,c=r.dodgePadding,f=r.intervalPadding,h=aAt.getTooltipMapping(o,[t,i,a]),v=h.fields,d=h.formatter,p=(n?oAt.geometry(QW.deepAssign({},e,{options:{type:"interval",colorField:a,tooltipFields:v,mapping:ES.__assign({tooltip:d},n),args:{dodgePadding:c,intervalPadding:f,minColumnWidth:l,maxColumnWidth:s,background:u}}})):e).ext;return lAt(ES.__assign(ES.__assign({},e),{ext:p}))}R_.interval=sAt;var xg={};Object.defineProperty(xg,"__esModule",{value:!0});xg.polygon=void 0;var uAt=V,cAt=Li,fAt=mt,hAt=_r;function vAt(e){var r=e.options,t=r.polygon,i=r.xField,n=r.yField,a=r.seriesField,o=r.tooltip,l=cAt.getTooltipMapping(o,[i,n,a]),s=l.fields,u=l.formatter;return t?hAt.geometry(fAt.deepAssign({},e,{options:{type:"polygon",colorField:a,tooltipFields:s,mapping:uAt.__assign({tooltip:u},t)}})):e}xg.polygon=vAt;var B_={};Object.defineProperty(B_,"__esModule",{value:!0});B_.edge=void 0;var dAt=V,pAt=Li,gAt=mt,yAt=_r;function mAt(e){var r=e.options,t=r.edge,i=r.xField,n=r.yField,a=r.seriesField,o=r.tooltip,l=pAt.getTooltipMapping(o,[i,n,a]),s=l.fields,u=l.formatter;return t?yAt.geometry(gAt.deepAssign({},e,{options:{type:"edge",colorField:a,tooltipFields:s,mapping:dAt.__assign({tooltip:u},t)}})):e}B_.edge=mAt;var N_={};Object.defineProperty(N_,"__esModule",{value:!0});N_.schema=void 0;var xAt=V,_At=Li,bAt=mt,wAt=_r;function CAt(e){var r=e.options,t=r.schema,i=r.xField,n=r.yField,a=r.seriesField,o=r.tooltip,l=_At.getTooltipMapping(o,[i,n,a]),s=l.fields,u=l.formatter;return t?wAt.geometry(bAt.deepAssign({},e,{options:{type:"schema",colorField:a,tooltipFields:s,mapping:xAt.__assign({tooltip:u},t)}})):e}N_.schema=CAt;var G_={};Object.defineProperty(G_,"__esModule",{value:!0});G_.violin=void 0;var SAt=V,AAt=Li,TAt=mt,MAt=_r;function EAt(e){var r=e.options,t=r.violin,i=r.xField,n=r.yField,a=r.seriesField,o=r.sizeField,l=r.tooltip,s=AAt.getTooltipMapping(l,[i,n,a,o]),u=s.fields,c=s.formatter;return t?MAt.geometry(TAt.deepAssign({},e,{options:{type:"violin",colorField:a,tooltipFields:u,mapping:SAt.__assign({tooltip:c},t)}})):e}G_.violin=EAt;(function(e){Object.defineProperty(e,"__esModule",{value:!0});var r=D_;Object.defineProperty(e,"area",{enumerable:!0,get:function(){return r.area}});var t=$_;Object.defineProperty(e,"line",{enumerable:!0,get:function(){return t.line}});var i=k_;Object.defineProperty(e,"point",{enumerable:!0,get:function(){return i.point}});var n=R_;Object.defineProperty(e,"interval",{enumerable:!0,get:function(){return n.interval}});var a=xg;Object.defineProperty(e,"polygon",{enumerable:!0,get:function(){return a.polygon}});var o=B_;Object.defineProperty(e,"edge",{enumerable:!0,get:function(){return o.edge}});var l=N_;Object.defineProperty(e,"schema",{enumerable:!0,get:function(){return l.schema}});var s=G_;Object.defineProperty(e,"violin",{enumerable:!0,get:function(){return s.violin}})})(Lr);var rP={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=e.DEFAULT_COLOR=void 0,e.DEFAULT_COLOR=["#FAAD14","#E8EDF3"],e.DEFAULT_OPTIONS={percent:.2,color:e.DEFAULT_COLOR,animation:{}}})(rP);var Rh={};Object.defineProperty(Rh,"__esModule",{value:!0});Rh.getProgressData=void 0;var FAt=Y,OAt=bs;function PAt(e){var r=FAt.clamp(OAt.isRealNumber(e)?e:0,0,1);return[{type:"current",percent:r},{type:"target",percent:1-r}]}Rh.getProgressData=PAt;Object.defineProperty(ec,"__esModule",{value:!0});ec.adaptor=ec.geometry=void 0;var IAt=Y,KW=mt,l0=Qe,LAt=Lr,DAt=rP,$At=Rh;function JW(e){var r=e.chart,t=e.options,i=t.percent,n=t.progressStyle,a=t.color,o=t.barWidthRatio;r.data($At.getProgressData(i));var l=KW.deepAssign({},e,{options:{xField:"1",yField:"percent",seriesField:"type",isStack:!0,widthRatio:o,interval:{style:n,color:IAt.isString(a)?[a,DAt.DEFAULT_COLOR[1]]:a},args:{zIndexReversed:!0}}});return LAt.interval(l),r.tooltip(!1),r.axis(!1),r.legend(!1),e}ec.geometry=JW;function kAt(e){var r=e.chart;return r.coordinate("rect").transpose(),e}function RAt(e){return KW.flow(JW,l0.scale({}),kAt,l0.animation,l0.theme,l0.annotation())(e)}ec.adaptor=RAt;Object.defineProperty(_O,"__esModule",{value:!0});var t4=_O.Progress=void 0,BAt=V,NAt=ae,GAt=ec,zAt=rP,VAt=Rh,jAt=function(e){BAt.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="process",t}return r.getDefaultOptions=function(){return zAt.DEFAULT_OPTIONS},r.prototype.changeData=function(t){this.updateOption({percent:t}),this.chart.changeData(VAt.getProgressData(t))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return GAt.adaptor},r}(NAt.Plot);t4=_O.Progress=jAt;var DT=globalThis&&globalThis.__assign||function(){return DT=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},DT.apply(this,arguments)},HAt=Qt(t4,"ProgressChart",function(e){return DT({data:e.percent,color:"#5B8FF9"},e)}),iP={},ih={};Object.defineProperty(ih,"__esModule",{value:!0});ih.adaptor=ih.statistic=void 0;var tN=V,eN=Y,$T=mt,s0=Qe,YAt=ec;function WAt(e){var r=e.chart,t=e.options,i=t.innerRadius,n=t.radius;return r.coordinate("theta",{innerRadius:i,radius:n}),e}function e4(e,r){var t=e.chart,i=e.options,n=i.innerRadius,a=i.statistic,o=i.percent,l=i.meta;if(t.getController("annotation").clear(!0),n&&a){var s=eN.get(l,["percent","formatter"])||function(c){return(c*100).toFixed(2)+"%"},u=a.content;u&&(u=$T.deepAssign({},u,{content:eN.isNil(u.content)?s(o):u.content})),$T.renderStatistic(t,{statistic:tN.__assign(tN.__assign({},a),{content:u}),plotType:"ring-progress"},{percent:o})}return r&&t.render(!0),e}ih.statistic=e4;function XAt(e){return $T.flow(YAt.geometry,s0.scale({}),WAt,e4,s0.animation,s0.theme,s0.annotation())(e)}ih.adaptor=XAt;var z_={};Object.defineProperty(z_,"__esModule",{value:!0});z_.DEFAULT_OPTIONS=void 0;z_.DEFAULT_OPTIONS={percent:.2,innerRadius:.8,radius:.98,color:["#FAAD14","#E8EDF3"],statistic:{title:!1,content:{style:{fontSize:"14px",fontWeight:300,fill:"#4D4D4D",textAlign:"center",textBaseline:"middle"}}},animation:{}};Object.defineProperty(iP,"__esModule",{value:!0});var r4=iP.RingProgress=void 0,UAt=V,Wc=me,qAt=ae,ZAt=Rh,rN=ih,QAt=z_,KAt=function(e){UAt.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="ring-process",t}return r.getDefaultOptions=function(){return QAt.DEFAULT_OPTIONS},r.prototype.changeData=function(t){this.chart.emit(Wc.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_DATA,Wc.Event.fromData(this.chart,Wc.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_DATA,null)),this.updateOption({percent:t}),this.chart.data(ZAt.getProgressData(t)),rN.statistic({chart:this.chart,options:this.options},!0),this.chart.emit(Wc.VIEW_LIFE_CIRCLE.AFTER_CHANGE_DATA,Wc.Event.fromData(this.chart,Wc.VIEW_LIFE_CIRCLE.AFTER_CHANGE_DATA,null))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return rN.adaptor},r}(qAt.Plot);r4=iP.RingProgress=KAt;var kT=globalThis&&globalThis.__assign||function(){return kT=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},kT.apply(this,arguments)},JAt=Qt(r4,"RingProgressChart",function(e){return kT({data:e.percent,color:"#5B8FF9"},e)}),nP={},vl={};Object.defineProperty(vl,"__esModule",{value:!0});vl.getTinyData=void 0;var tTt=Y;function eTt(e){return tTt.map(e||[],function(r,t){return{x:""+t,y:r}})}vl.getTinyData=eTt;var i4={},Bh={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=e.DEFAULT_TOOLTIP_OPTIONS=e.Y_FIELD=e.X_FIELD=void 0;var r=V,t=Y;e.X_FIELD="x",e.Y_FIELD="y",e.DEFAULT_TOOLTIP_OPTIONS={showTitle:!1,shared:!0,showMarkers:!1,customContent:function(i,n){return""+t.get(n,[0,"data","y"],0)},containerTpl:'<div class="g2-tooltip"><div class="g2-tooltip-list"></div></div>',itemTpl:"<span>{value}</span>",domStyles:{"g2-tooltip":{padding:"2px 4px",fontSize:"10px"}},showCrosshairs:!0,crosshairs:{type:"x"}},e.DEFAULT_OPTIONS={appendPadding:2,tooltip:r.__assign({},e.DEFAULT_TOOLTIP_OPTIONS),animation:{}}})(Bh);var Ss={};Object.defineProperty(Ss,"__esModule",{value:!0});Ss.adaptor=Ss.meta=void 0;var rf=Qe,Md=mt,FS=Lr,wu=Bh,n4=vl,rTt=fo;function iTt(e){var r=e.chart,t=e.options,i=t.data,n=t.color,a=t.areaStyle,o=t.point,l=t.line,s=o==null?void 0:o.state,u=n4.getTinyData(i);r.data(u);var c=Md.deepAssign({},e,{options:{xField:wu.X_FIELD,yField:wu.Y_FIELD,area:{color:n,style:a},line:l,point:o}}),f=Md.deepAssign({},c,{options:{tooltip:!1}}),h=Md.deepAssign({},c,{options:{tooltip:!1,state:s}});return FS.area(c),FS.line(f),FS.point(h),r.axis(!1),r.legend(!1),e}function a4(e){var r,t,i=e.options,n=i.xAxis,a=i.yAxis,o=i.data,l=n4.getTinyData(o);return Md.flow(rf.scale((r={},r[wu.X_FIELD]=n,r[wu.Y_FIELD]=a,r),(t={},t[wu.X_FIELD]={type:"cat"},t[wu.Y_FIELD]=rTt.adjustYMetaByZero(l,wu.Y_FIELD),t)))(e)}Ss.meta=a4;function nTt(e){return Md.flow(rf.pattern("areaStyle"),iTt,a4,rf.tooltip,rf.theme,rf.animation,rf.annotation())(e)}Ss.adaptor=nTt;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=e.meta=void 0;var r=Qe,t=mt,i=Lr,n=Bh,a=vl,o=Ss;Object.defineProperty(e,"meta",{enumerable:!0,get:function(){return o.meta}});function l(u){var c=u.chart,f=u.options,h=f.data,v=f.color,d=f.columnStyle,p=f.columnWidthRatio,x=a.getTinyData(h);c.data(x);var m=t.deepAssign({},u,{options:{xField:n.X_FIELD,yField:n.Y_FIELD,widthRatio:p,interval:{style:d,color:v}}});return i.interval(m),c.axis(!1),c.legend(!1),c.interaction("element-active"),u}function s(u){return t.flow(r.theme,r.pattern("columnStyle"),l,o.meta,r.tooltip,r.animation,r.annotation())(u)}e.adaptor=s})(i4);var o4={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=e.DEFAULT_TOOLTIP_OPTIONS=void 0;var r=V,t=Y;e.DEFAULT_TOOLTIP_OPTIONS={showTitle:!1,shared:!0,showMarkers:!1,customContent:function(i,n){return""+t.get(n,[0,"data","y"],0)},containerTpl:'<div class="g2-tooltip"><div class="g2-tooltip-list"></div></div>',itemTpl:"<span>{value}</span>",domStyles:{"g2-tooltip":{padding:"2px 4px",fontSize:"10px"}}},e.DEFAULT_OPTIONS={appendPadding:2,tooltip:r.__assign({},e.DEFAULT_TOOLTIP_OPTIONS),animation:{}}})(o4);Object.defineProperty(nP,"__esModule",{value:!0});var l4=nP.TinyColumn=void 0,aTt=V,oTt=ae,lTt=vl,iN=i4,sTt=o4,uTt=function(e){aTt.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="tiny-column",t}return r.getDefaultOptions=function(){return sTt.DEFAULT_OPTIONS},r.prototype.changeData=function(t){this.updateOption({data:t});var i=this,n=i.chart,a=i.options;iN.meta({chart:n,options:a}),n.changeData(lTt.getTinyData(t))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return iN.adaptor},r}(oTt.Plot);l4=nP.TinyColumn=uTt;var cTt=function(e){var r=He(e);if(!K(r.yField)){var t=r.data.map(function(i){return i[r.yField]}).filter(function(i){return!K(i)});t&&t.length&&ve(r,"data",t)}return ve(r,"tooltip",!1),r},fTt=Qt(l4,"TinyColumnChart",cTt),aP={},V_={};Object.defineProperty(V_,"__esModule",{value:!0});V_.DEFAULT_OPTIONS=void 0;var hTt=V,vTt=Bh;V_.DEFAULT_OPTIONS={appendPadding:2,tooltip:hTt.__assign({},vTt.DEFAULT_TOOLTIP_OPTIONS),color:"l(90) 0:#E5EDFE 1:#ffffff",areaStyle:{fillOpacity:.6},line:{size:1,color:"#5B8FF9"},animation:{}};Object.defineProperty(aP,"__esModule",{value:!0});var s4=aP.TinyArea=void 0,dTt=V,pTt=ae,gTt=vl,nN=Ss,yTt=V_,mTt=function(e){dTt.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="tiny-area",t}return r.getDefaultOptions=function(){return yTt.DEFAULT_OPTIONS},r.prototype.changeData=function(t){this.updateOption({data:t});var i=this,n=i.chart,a=i.options;nN.meta({chart:n,options:a}),n.changeData(gTt.getTinyData(t))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return nN.adaptor},r}(pTt.Plot);s4=aP.TinyArea=mTt;var RT=globalThis&&globalThis.__assign||function(){return RT=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},RT.apply(this,arguments)},xTt=globalThis&&globalThis.__rest||function(e,r){var t={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&r.indexOf(i)<0&&(t[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,i=Object.getOwnPropertySymbols(e);n<i.length;n++)r.indexOf(i[n])<0&&Object.prototype.propertyIsEnumerable.call(e,i[n])&&(t[i[n]]=e[i[n]]);return t},_Tt=Qt(s4,"TinyAreaChart",function(e){var r=He(e),t=r.xField,i=r.yField,n=r.data,a=xTt(r,["xField","yField","data"]);return t&&i&&n&&(a.data=n.map(function(o){return o[i]})),RT({},a)}),oP={},u4={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=e.meta=void 0;var r=mt,t=Qe,i=Lr,n=Ss;Object.defineProperty(e,"meta",{enumerable:!0,get:function(){return n.meta}});var a=vl,o=Bh;function l(u){var c=u.chart,f=u.options,h=f.data,v=f.color,d=f.lineStyle,p=f.point,x=p==null?void 0:p.state,m=a.getTinyData(h);c.data(m);var _=r.deepAssign({},u,{options:{xField:o.X_FIELD,yField:o.Y_FIELD,line:{color:v,style:d},point:p}}),b=r.deepAssign({},_,{options:{tooltip:!1,state:x}});return i.line(_),i.point(b),c.axis(!1),c.legend(!1),u}function s(u){return r.flow(l,n.meta,t.theme,t.tooltip,t.animation,t.annotation())(u)}e.adaptor=s})(u4);Object.defineProperty(oP,"__esModule",{value:!0});var c4=oP.TinyLine=void 0,bTt=V,wTt=ae,aN=u4,CTt=Bh,STt=vl,ATt=function(e){bTt.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="tiny-line",t}return r.getDefaultOptions=function(){return CTt.DEFAULT_OPTIONS},r.prototype.changeData=function(t){this.updateOption({data:t});var i=this,n=i.chart,a=i.options;aN.meta({chart:n,options:a}),n.changeData(STt.getTinyData(t))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return aN.adaptor},r}(wTt.Plot);c4=oP.TinyLine=ATt;var Sx=globalThis&&globalThis.__assign||function(){return Sx=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Sx.apply(this,arguments)},TTt=function(e){var r=He(e);if(!K(r.yField)){var t=r.data.map(function(a){return a[r.yField]}).filter(function(a){return!K(a)});t&&t.length&&ve(r,"data",t)}var i=kt(r,"size");if(!K(i)){var n=kt(r,"lineStyle",{});ve(r,"lineStyle",Sx(Sx({},n),{lineWidth:i}))}return ve(r,"tooltip",!1),r},MTt=Qt(c4,"TinyLineChart",TTt),ETt=Object.freeze(Object.defineProperty({__proto__:null,ProgressChart:HAt,RingProgressChart:JAt,TinyColumnChart:fTt,TinyAreaChart:_Tt,TinyLineChart:MTt},Symbol.toStringTag,{value:"Module"})),lP={},dn={};Object.defineProperty(dn,"__esModule",{value:!0});dn.adaptor=dn.adjust=dn.legend=dn.axis=dn.meta=void 0;var Ax=V,f4=Y,kl=Qe,Ed=mt,OS=Lr,h4=mt,FTt=fo;function OTt(e){var r=e.chart,t=e.options,i=t.data,n=t.color,a=t.lineStyle,o=t.lineShape,l=t.point,s=t.area,u=t.seriesField,c=l==null?void 0:l.state;r.data(i);var f=Ed.deepAssign({},e,{options:{shapeField:u,line:{color:n,style:a,shape:o},point:l&&Ax.__assign({color:n,shape:"circle"},l),area:s&&Ax.__assign({color:n},s),label:void 0}}),h=Ed.deepAssign({},f,{options:{tooltip:!1,state:c}}),v=Ed.deepAssign({},f,{options:{tooltip:!1,state:c}});return OS.line(f),OS.point(h),OS.area(v),e}function v4(e){var r,t,i=e.options,n=i.xAxis,a=i.yAxis,o=i.xField,l=i.yField,s=i.data;return h4.flow(kl.scale((r={},r[o]=n,r[l]=a,r),(t={},t[o]={type:"cat"},t[l]=FTt.adjustYMetaByZero(s,l),t)))(e)}dn.meta=v4;function PTt(e){var r=e.chart,t=e.options,i=t.reflect;if(i){var n=i;f4.isArray(n)||(n=[n]);var a=n.map(function(o){return["reflect",o]});r.coordinate({type:"rect",actions:a})}return e}function d4(e){var r=e.chart,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.yField;return i===!1?r.axis(a,!1):r.axis(a,i),n===!1?r.axis(o,!1):r.axis(o,n),e}dn.axis=d4;function p4(e){var r=e.chart,t=e.options,i=t.legend,n=t.seriesField;return i&&n?r.legend(n,i):i===!1&&r.legend(!1),e}dn.legend=p4;function ITt(e){var r=e.chart,t=e.options,i=t.label,n=t.yField,a=Ed.findGeometry(r,"line");if(!i)a.label(!1);else{var o=i.callback,l=Ax.__rest(i,["callback"]);a.label({fields:[n],callback:o,cfg:Ax.__assign({layout:[{type:"limit-in-plot"},{type:"path-adjust-position"},{type:"point-adjust-position"},{type:"limit-in-plot",cfg:{action:"hide"}}]},Ed.transformLabel(l))})}return e}function g4(e){var r=e.chart,t=e.options,i=t.isStack;return i&&f4.each(r.geometries,function(n){n.adjust("stack")}),e}dn.adjust=g4;function LTt(e){return h4.flow(OTt,v4,g4,kl.theme,PTt,d4,p4,kl.tooltip,ITt,kl.slider,kl.interaction,kl.animation,kl.annotation(),kl.limitInPlot)(e)}dn.adaptor=LTt;var j_={};Object.defineProperty(j_,"__esModule",{value:!0});j_.DEFAULT_OPTIONS=void 0;var DTt=ae,$Tt=mt;j_.DEFAULT_OPTIONS=$Tt.deepAssign({},DTt.Plot.getDefaultOptions(),{tooltip:{shared:!0,showMarkers:!0,showCrosshairs:!0,crosshairs:{type:"x"}},legend:{position:"top-left"},isStack:!1});var H_={};Object.defineProperty(H_,"__esModule",{value:!0});H_.MarkerActiveAction=void 0;var kTt=V,Iv=Y,RTt=me,BTt=function(e){kTt.__extends(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.active=function(){var t=this.getView(),i=this.context.event;if(i.data){var n=i.data.items,a=t.geometries.filter(function(o){return o.type==="point"});Iv.each(a,function(o){Iv.each(o.elements,function(l){var s=Iv.findIndex(n,function(u){return u.data===l.data})!==-1;l.setState("active",s)})})}},r.prototype.reset=function(){var t=this.getView(),i=t.geometries.filter(function(n){return n.type==="point"});Iv.each(i,function(n){Iv.each(n.elements,function(a){a.setState("active",!1)})})},r.prototype.getView=function(){return this.context.view},r}(RTt.InteractionAction);H_.MarkerActiveAction=BTt;var y4=me,NTt=H_;y4.registerAction("marker-active",NTt.MarkerActiveAction);y4.registerInteraction("marker-active",{start:[{trigger:"tooltip:show",action:"marker-active:active"}],end:[{trigger:"tooltip:hide",action:"marker-active:reset"}]});Object.defineProperty(lP,"__esModule",{value:!0});var sP=lP.Line=void 0,GTt=V,zTt=ae,oN=dn,VTt=j_,jTt=function(e){GTt.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="line",t}return r.getDefaultOptions=function(){return VTt.DEFAULT_OPTIONS},r.prototype.changeData=function(t){this.updateOption({data:t});var i=this,n=i.chart,a=i.options;oN.meta({chart:n,options:a}),this.chart.changeData(t)},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return oN.adaptor},r}(zTt.Plot);sP=lP.Line=jTt;var m4=function(e){var r=He(e);return Fr(r,"point"),r.point===!0&&(r.point={}),r},HTt=Qt(sP,"LineChart",m4),uP={},nh={},pn={},cP={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.DrillDownAction=e.HIERARCHY_DATA_TRANSFORM_PARAMS=e.DEFAULT_BREAD_CRUMB_CONFIG=e.BREAD_CRUMB_NAME=e.PADDING_TOP=void 0;var r=V,t=me,i=Y,n=fg,a=4,o=0;e.PADDING_TOP=5,e.BREAD_CRUMB_NAME="drilldown-bread-crumb",e.DEFAULT_BREAD_CRUMB_CONFIG={position:"top-left",dividerText:"/",textStyle:{fontSize:12,fill:"rgba(0, 0, 0, 0.65)",cursor:"pointer"},activeTextStyle:{fill:"#87B5FF"}},e.HIERARCHY_DATA_TRANSFORM_PARAMS="hierarchy-data-transform-params";var l=function(s){r.__extends(u,s);function u(){var c=s!==null&&s.apply(this,arguments)||this;return c.name="drill-down",c.historyCache=[],c.breadCrumbGroup=null,c.breadCrumbCfg=e.DEFAULT_BREAD_CRUMB_CONFIG,c}return u.prototype.click=function(){var c=i.get(this.context,["event","data","data"]);if(!c)return!1;this.drill(c),this.drawBreadCrumb()},u.prototype.resetPosition=function(){if(!!this.breadCrumbGroup){var c=this.context.view.getCoordinate(),f=this.breadCrumbGroup,h=f.getBBox(),v=this.getButtonCfg().position,d={x:c.start.x,y:c.end.y-(h.height+e.PADDING_TOP*2)};c.isPolar&&(d={x:0,y:0}),v==="bottom-left"&&(d={x:c.start.x,y:c.start.y});var p=t.Util.transform(null,[["t",d.x+o,d.y+h.height+e.PADDING_TOP]]);f.setMatrix(p)}},u.prototype.back=function(){i.size(this.historyCache)&&this.backTo(this.historyCache.slice(0,-1))},u.prototype.reset=function(){this.historyCache[0]&&this.backTo(this.historyCache.slice(0,1)),this.historyCache=[],this.hideCrumbGroup()},u.prototype.drill=function(c){var f=this.context.view,h=i.get(f,["interactions","drill-down","cfg","transformData"],function(m){return m}),v=h(r.__assign({data:c.data},c[e.HIERARCHY_DATA_TRANSFORM_PARAMS]));f.changeData(v);for(var d=[],p=c;p;){var x=p.data;d.unshift({id:x.name+"_"+p.height+"_"+p.depth,name:x.name,children:h(r.__assign({data:x},c[e.HIERARCHY_DATA_TRANSFORM_PARAMS]))}),p=p.parent}this.historyCache=(this.historyCache||[]).slice(0,-1).concat(d)},u.prototype.backTo=function(c){if(!(!c||c.length<=0)){var f=this.context.view,h=i.last(c).children;f.changeData(h),c.length>1?(this.historyCache=c,this.drawBreadCrumb()):(this.historyCache=[],this.hideCrumbGroup())}},u.prototype.getButtonCfg=function(){var c=this.context.view,f=i.get(c,["interactions","drill-down","cfg","drillDownConfig"]);return n.deepAssign(this.breadCrumbCfg,f==null?void 0:f.breadCrumb,this.cfg)},u.prototype.drawBreadCrumb=function(){this.drawBreadCrumbGroup(),this.resetPosition(),this.breadCrumbGroup.show()},u.prototype.drawBreadCrumbGroup=function(){var c=this,f=this.getButtonCfg(),h=this.historyCache;this.breadCrumbGroup?this.breadCrumbGroup.clear():this.breadCrumbGroup=this.context.view.foregroundGroup.addGroup({name:e.BREAD_CRUMB_NAME});var v=0;h.forEach(function(d,p){var x=c.breadCrumbGroup.addShape({type:"text",id:d.id,name:e.BREAD_CRUMB_NAME+"_"+d.name+"_text",attrs:r.__assign(r.__assign({text:p===0&&!i.isNil(f.rootText)?f.rootText:d.name},f.textStyle),{x:v,y:0})}),m=x.getBBox();if(v+=m.width+a,x.on("click",function(w){var S,M=w.target.get("id");if(M!==((S=i.last(h))===null||S===void 0?void 0:S.id)){var F=h.slice(0,h.findIndex(function(O){return O.id===M})+1);c.backTo(F)}}),x.on("mouseenter",function(w){var S,M=w.target.get("id");M!==((S=i.last(h))===null||S===void 0?void 0:S.id)?x.attr(f.activeTextStyle):x.attr({cursor:"default"})}),x.on("mouseleave",function(){x.attr(f.textStyle)}),p<h.length-1){var _=c.breadCrumbGroup.addShape({type:"text",name:f.name+"_"+d.name+"_divider",attrs:r.__assign(r.__assign({text:f.dividerText},f.textStyle),{x:v,y:0})}),b=_.getBBox();v+=b.width+a}})},u.prototype.hideCrumbGroup=function(){this.breadCrumbGroup&&this.breadCrumbGroup.hide()},u.prototype.destroy=function(){this.breadCrumbGroup&&this.breadCrumbGroup.remove(),s.prototype.destroy.call(this)},u}(t.Action);e.DrillDownAction=l})(cP);var ah={};function YTt(e,r){return e.parent===r.parent?1:2}function WTt(e){return e.reduce(XTt,0)/e.length}function XTt(e,r){return e+r.x}function UTt(e){return 1+e.reduce(qTt,0)}function qTt(e,r){return Math.max(e,r.y)}function ZTt(e){for(var r;r=e.children;)e=r[0];return e}function QTt(e){for(var r;r=e.children;)e=r[r.length-1];return e}function KTt(){var e=YTt,r=1,t=1,i=!1;function n(a){var o,l=0;a.eachAfter(function(h){var v=h.children;v?(h.x=WTt(v),h.y=UTt(v)):(h.x=o?l+=e(h,o):0,h.y=0,o=h)});var s=ZTt(a),u=QTt(a),c=s.x-e(s,u)/2,f=u.x+e(u,s)/2;return a.eachAfter(i?function(h){h.x=(h.x-a.x)*r,h.y=(a.y-h.y)*t}:function(h){h.x=(h.x-c)/(f-c)*r,h.y=(1-(a.y?h.y/a.y:1))*t})}return n.separation=function(a){return arguments.length?(e=a,n):e},n.size=function(a){return arguments.length?(i=!1,r=+a[0],t=+a[1],n):i?null:[r,t]},n.nodeSize=function(a){return arguments.length?(i=!0,r=+a[0],t=+a[1],n):i?[r,t]:null},n}function JTt(e){var r=0,t=e.children,i=t&&t.length;if(!i)r=1;else for(;--i>=0;)r+=t[i].value;e.value=r}function tMt(){return this.eachAfter(JTt)}function eMt(e,r){let t=-1;for(const i of this)e.call(r,i,++t,this);return this}function rMt(e,r){for(var t=this,i=[t],n,a,o=-1;t=i.pop();)if(e.call(r,t,++o,this),n=t.children)for(a=n.length-1;a>=0;--a)i.push(n[a]);return this}function iMt(e,r){for(var t=this,i=[t],n=[],a,o,l,s=-1;t=i.pop();)if(n.push(t),a=t.children)for(o=0,l=a.length;o<l;++o)i.push(a[o]);for(;t=n.pop();)e.call(r,t,++s,this);return this}function nMt(e,r){let t=-1;for(const i of this)if(e.call(r,i,++t,this))return i}function aMt(e){return this.eachAfter(function(r){for(var t=+e(r.data)||0,i=r.children,n=i&&i.length;--n>=0;)t+=i[n].value;r.value=t})}function oMt(e){return this.eachBefore(function(r){r.children&&r.children.sort(e)})}function lMt(e){for(var r=this,t=sMt(r,e),i=[r];r!==t;)r=r.parent,i.push(r);for(var n=i.length;e!==t;)i.splice(n,0,e),e=e.parent;return i}function sMt(e,r){if(e===r)return e;var t=e.ancestors(),i=r.ancestors(),n=null;for(e=t.pop(),r=i.pop();e===r;)n=e,e=t.pop(),r=i.pop();return n}function uMt(){for(var e=this,r=[e];e=e.parent;)r.push(e);return r}function cMt(){return Array.from(this)}function fMt(){var e=[];return this.eachBefore(function(r){r.children||e.push(r)}),e}function hMt(){var e=this,r=[];return e.each(function(t){t!==e&&r.push({source:t.parent,target:t})}),r}function*vMt(){var e=this,r,t=[e],i,n,a;do for(r=t.reverse(),t=[];e=r.pop();)if(yield e,i=e.children)for(n=0,a=i.length;n<a;++n)t.push(i[n]);while(t.length)}function Nh(e,r){e instanceof Map?(e=[void 0,e],r===void 0&&(r=gMt)):r===void 0&&(r=pMt);for(var t=new oh(e),i,n=[t],a,o,l,s;i=n.pop();)if((o=r(i.data))&&(s=(o=Array.from(o)).length))for(i.children=o,l=s-1;l>=0;--l)n.push(a=o[l]=new oh(o[l])),a.parent=i,a.depth=i.depth+1;return t.eachBefore(x4)}function dMt(){return Nh(this).eachBefore(yMt)}function pMt(e){return e.children}function gMt(e){return Array.isArray(e)?e[1]:null}function yMt(e){e.data.value!==void 0&&(e.value=e.data.value),e.data=e.data.data}function x4(e){var r=0;do e.height=r;while((e=e.parent)&&e.height<++r)}function oh(e){this.data=e,this.depth=this.height=0,this.parent=null}oh.prototype=Nh.prototype={constructor:oh,count:tMt,each:eMt,eachAfter:iMt,eachBefore:rMt,find:nMt,sum:aMt,sort:oMt,path:lMt,ancestors:uMt,descendants:cMt,leaves:fMt,links:hMt,copy:dMt,[Symbol.iterator]:vMt};function mMt(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function xMt(e){for(var r=e.length,t,i;r;)i=Math.random()*r--|0,t=e[r],e[r]=e[i],e[i]=t;return e}function _4(e){for(var r=0,t=(e=xMt(Array.from(e))).length,i=[],n,a;r<t;)n=e[r],a&&b4(a,n)?++r:(a=bMt(i=_Mt(i,n)),r=0);return a}function _Mt(e,r){var t,i;if(PS(r,e))return[r];for(t=0;t<e.length;++t)if(u0(r,e[t])&&PS(td(e[t],r),e))return[e[t],r];for(t=0;t<e.length-1;++t)for(i=t+1;i<e.length;++i)if(u0(td(e[t],e[i]),r)&&u0(td(e[t],r),e[i])&&u0(td(e[i],r),e[t])&&PS(w4(e[t],e[i],r),e))return[e[t],e[i],r];throw new Error}function u0(e,r){var t=e.r-r.r,i=r.x-e.x,n=r.y-e.y;return t<0||t*t<i*i+n*n}function b4(e,r){var t=e.r-r.r+Math.max(e.r,r.r,1)*1e-9,i=r.x-e.x,n=r.y-e.y;return t>0&&t*t>i*i+n*n}function PS(e,r){for(var t=0;t<r.length;++t)if(!b4(e,r[t]))return!1;return!0}function bMt(e){switch(e.length){case 1:return wMt(e[0]);case 2:return td(e[0],e[1]);case 3:return w4(e[0],e[1],e[2])}}function wMt(e){return{x:e.x,y:e.y,r:e.r}}function td(e,r){var t=e.x,i=e.y,n=e.r,a=r.x,o=r.y,l=r.r,s=a-t,u=o-i,c=l-n,f=Math.sqrt(s*s+u*u);return{x:(t+a+s/f*c)/2,y:(i+o+u/f*c)/2,r:(f+n+l)/2}}function w4(e,r,t){var i=e.x,n=e.y,a=e.r,o=r.x,l=r.y,s=r.r,u=t.x,c=t.y,f=t.r,h=i-o,v=i-u,d=n-l,p=n-c,x=s-a,m=f-a,_=i*i+n*n-a*a,b=_-o*o-l*l+s*s,w=_-u*u-c*c+f*f,S=v*d-h*p,M=(d*w-p*b)/(S*2)-i,F=(p*x-d*m)/S,O=(v*b-h*w)/(S*2)-n,L=(h*m-v*x)/S,D=F*F+L*L-1,k=2*(a+M*F+O*L),H=M*M+O*O-a*a,B=-(D?(k+Math.sqrt(k*k-4*D*H))/(2*D):H/k);return{x:i+M+F*B,y:n+O+L*B,r:B}}function lN(e,r,t){var i=e.x-r.x,n,a,o=e.y-r.y,l,s,u=i*i+o*o;u?(a=r.r+t.r,a*=a,s=e.r+t.r,s*=s,a>s?(n=(u+s-a)/(2*u),l=Math.sqrt(Math.max(0,s/u-n*n)),t.x=e.x-n*i-l*o,t.y=e.y-n*o+l*i):(n=(u+a-s)/(2*u),l=Math.sqrt(Math.max(0,a/u-n*n)),t.x=r.x+n*i-l*o,t.y=r.y+n*o+l*i)):(t.x=r.x+t.r,t.y=r.y)}function sN(e,r){var t=e.r+r.r-1e-6,i=r.x-e.x,n=r.y-e.y;return t>0&&t*t>i*i+n*n}function uN(e){var r=e._,t=e.next._,i=r.r+t.r,n=(r.x*t.r+t.x*r.r)/i,a=(r.y*t.r+t.y*r.r)/i;return n*n+a*a}function c0(e){this._=e,this.next=null,this.previous=null}function C4(e){if(!(n=(e=mMt(e)).length))return 0;var r,t,i,n,a,o,l,s,u,c,f;if(r=e[0],r.x=0,r.y=0,!(n>1))return r.r;if(t=e[1],r.x=-t.r,t.x=r.r,t.y=0,!(n>2))return r.r+t.r;lN(t,r,i=e[2]),r=new c0(r),t=new c0(t),i=new c0(i),r.next=i.previous=t,t.next=r.previous=i,i.next=t.previous=r;t:for(l=3;l<n;++l){lN(r._,t._,i=e[l]),i=new c0(i),s=t.next,u=r.previous,c=t._.r,f=r._.r;do if(c<=f){if(sN(s._,i._)){t=s,r.next=t,t.previous=r,--l;continue t}c+=s._.r,s=s.next}else{if(sN(u._,i._)){r=u,r.next=t,t.previous=r,--l;continue t}f+=u._.r,u=u.previous}while(s!==u.next);for(i.previous=r,i.next=t,r.next=t.previous=t=i,a=uN(r);(i=i.next)!==t;)(o=uN(i))<a&&(r=i,a=o);t=r.next}for(r=[t._],i=t;(i=i.next)!==t;)r.push(i._);for(i=_4(r),l=0;l<n;++l)r=e[l],r.x-=i.x,r.y-=i.y;return i.r}function CMt(e){return C4(e),e}function SMt(e){return e==null?null:Tx(e)}function Tx(e){if(typeof e!="function")throw new Error;return e}function Cu(){return 0}function nf(e){return function(){return e}}function AMt(e){return Math.sqrt(e.value)}function S4(){var e=null,r=1,t=1,i=Cu;function n(a){return a.x=r/2,a.y=t/2,e?a.eachBefore(cN(e)).eachAfter(IS(i,.5)).eachBefore(fN(1)):a.eachBefore(cN(AMt)).eachAfter(IS(Cu,1)).eachAfter(IS(i,a.r/Math.min(r,t))).eachBefore(fN(Math.min(r,t)/(2*a.r))),a}return n.radius=function(a){return arguments.length?(e=SMt(a),n):e},n.size=function(a){return arguments.length?(r=+a[0],t=+a[1],n):[r,t]},n.padding=function(a){return arguments.length?(i=typeof a=="function"?a:nf(+a),n):i},n}function cN(e){return function(r){r.children||(r.r=Math.max(0,+e(r)||0))}}function IS(e,r){return function(t){if(i=t.children){var i,n,a=i.length,o=e(t)*r||0,l;if(o)for(n=0;n<a;++n)i[n].r+=o;if(l=C4(i),o)for(n=0;n<a;++n)i[n].r-=o;t.r=l+o}}}function fN(e){return function(r){var t=r.parent;r.r*=e,t&&(r.x=t.x+e*r.x,r.y=t.y+e*r.y)}}function A4(e){e.x0=Math.round(e.x0),e.y0=Math.round(e.y0),e.x1=Math.round(e.x1),e.y1=Math.round(e.y1)}function _g(e,r,t,i,n){for(var a=e.children,o,l=-1,s=a.length,u=e.value&&(i-r)/e.value;++l<s;)o=a[l],o.y0=t,o.y1=n,o.x0=r,o.x1=r+=o.value*u}function T4(){var e=1,r=1,t=0,i=!1;function n(o){var l=o.height+1;return o.x0=o.y0=t,o.x1=e,o.y1=r/l,o.eachBefore(a(r,l)),i&&o.eachBefore(A4),o}function a(o,l){return function(s){s.children&&_g(s,s.x0,o*(s.depth+1)/l,s.x1,o*(s.depth+2)/l);var u=s.x0,c=s.y0,f=s.x1-t,h=s.y1-t;f<u&&(u=f=(u+f)/2),h<c&&(c=h=(c+h)/2),s.x0=u,s.y0=c,s.x1=f,s.y1=h}}return n.round=function(o){return arguments.length?(i=!!o,n):i},n.size=function(o){return arguments.length?(e=+o[0],r=+o[1],n):[e,r]},n.padding=function(o){return arguments.length?(t=+o,n):t},n}var TMt={depth:-1},hN={};function MMt(e){return e.id}function EMt(e){return e.parentId}function FMt(){var e=MMt,r=EMt;function t(i){var n=Array.from(i),a=n.length,o,l,s,u,c,f,h,v=new Map;for(l=0;l<a;++l)o=n[l],c=n[l]=new oh(o),(f=e(o,l,i))!=null&&(f+="")&&(h=c.id=f,v.set(h,v.has(h)?hN:c)),(f=r(o,l,i))!=null&&(f+="")&&(c.parent=f);for(l=0;l<a;++l)if(c=n[l],f=c.parent){if(u=v.get(f),!u)throw new Error("missing: "+f);if(u===hN)throw new Error("ambiguous: "+f);u.children?u.children.push(c):u.children=[c],c.parent=u}else{if(s)throw new Error("multiple roots");s=c}if(!s)throw new Error("no root");if(s.parent=TMt,s.eachBefore(function(d){d.depth=d.parent.depth+1,--a}).eachBefore(x4),s.parent=null,a>0)throw new Error("cycle");return s}return t.id=function(i){return arguments.length?(e=Tx(i),t):e},t.parentId=function(i){return arguments.length?(r=Tx(i),t):r},t}function OMt(e,r){return e.parent===r.parent?1:2}function LS(e){var r=e.children;return r?r[0]:e.t}function DS(e){var r=e.children;return r?r[r.length-1]:e.t}function PMt(e,r,t){var i=t/(r.i-e.i);r.c-=i,r.s+=t,e.c+=i,r.z+=t,r.m+=t}function IMt(e){for(var r=0,t=0,i=e.children,n=i.length,a;--n>=0;)a=i[n],a.z+=r,a.m+=r,r+=a.s+(t+=a.c)}function LMt(e,r,t){return e.a.parent===r.parent?e.a:t}function F0(e,r){this._=e,this.parent=null,this.children=null,this.A=null,this.a=this,this.z=0,this.m=0,this.c=0,this.s=0,this.t=null,this.i=r}F0.prototype=Object.create(oh.prototype);function DMt(e){for(var r=new F0(e,0),t,i=[r],n,a,o,l;t=i.pop();)if(a=t._.children)for(t.children=new Array(l=a.length),o=l-1;o>=0;--o)i.push(n=t.children[o]=new F0(a[o],o)),n.parent=t;return(r.parent=new F0(null,0)).children=[r],r}function $Mt(){var e=OMt,r=1,t=1,i=null;function n(u){var c=DMt(u);if(c.eachAfter(a),c.parent.m=-c.z,c.eachBefore(o),i)u.eachBefore(s);else{var f=u,h=u,v=u;u.eachBefore(function(_){_.x<f.x&&(f=_),_.x>h.x&&(h=_),_.depth>v.depth&&(v=_)});var d=f===h?1:e(f,h)/2,p=d-f.x,x=r/(h.x+d+p),m=t/(v.depth||1);u.eachBefore(function(_){_.x=(_.x+p)*x,_.y=_.depth*m})}return u}function a(u){var c=u.children,f=u.parent.children,h=u.i?f[u.i-1]:null;if(c){IMt(u);var v=(c[0].z+c[c.length-1].z)/2;h?(u.z=h.z+e(u._,h._),u.m=u.z-v):u.z=v}else h&&(u.z=h.z+e(u._,h._));u.parent.A=l(u,h,u.parent.A||f[0])}function o(u){u._.x=u.z+u.parent.m,u.m+=u.parent.m}function l(u,c,f){if(c){for(var h=u,v=u,d=c,p=h.parent.children[0],x=h.m,m=v.m,_=d.m,b=p.m,w;d=DS(d),h=LS(h),d&&h;)p=LS(p),v=DS(v),v.a=u,w=d.z+_-h.z-x+e(d._,h._),w>0&&(PMt(LMt(d,u,f),u,w),x+=w,m+=w),_+=d.m,x+=h.m,b+=p.m,m+=v.m;d&&!DS(v)&&(v.t=d,v.m+=_-m),h&&!LS(p)&&(p.t=h,p.m+=x-b,f=u)}return f}function s(u){u.x*=r,u.y=u.depth*t}return n.separation=function(u){return arguments.length?(e=u,n):e},n.size=function(u){return arguments.length?(i=!1,r=+u[0],t=+u[1],n):i?null:[r,t]},n.nodeSize=function(u){return arguments.length?(i=!0,r=+u[0],t=+u[1],n):i?[r,t]:null},n}function Y_(e,r,t,i,n){for(var a=e.children,o,l=-1,s=a.length,u=e.value&&(n-t)/e.value;++l<s;)o=a[l],o.x0=r,o.x1=i,o.y0=t,o.y1=t+=o.value*u}var M4=(1+Math.sqrt(5))/2;function E4(e,r,t,i,n,a){for(var o=[],l=r.children,s,u,c=0,f=0,h=l.length,v,d,p=r.value,x,m,_,b,w,S,M;c<h;){v=n-t,d=a-i;do x=l[f++].value;while(!x&&f<h);for(m=_=x,S=Math.max(d/v,v/d)/(p*e),M=x*x*S,w=Math.max(_/M,M/m);f<h;++f){if(x+=u=l[f].value,u<m&&(m=u),u>_&&(_=u),M=x*x*S,b=Math.max(_/M,M/m),b>w){x-=u;break}w=b}o.push(s={value:x,dice:v<d,children:l.slice(c,f)}),s.dice?_g(s,t,i,n,p?i+=d*x/p:a):Y_(s,t,i,p?t+=v*x/p:n,a),p-=x,c=f}return o}var F4=function e(r){function t(i,n,a,o,l){E4(r,i,n,a,o,l)}return t.ratio=function(i){return e((i=+i)>1?i:1)},t}(M4);function O4(){var e=F4,r=!1,t=1,i=1,n=[0],a=Cu,o=Cu,l=Cu,s=Cu,u=Cu;function c(h){return h.x0=h.y0=0,h.x1=t,h.y1=i,h.eachBefore(f),n=[0],r&&h.eachBefore(A4),h}function f(h){var v=n[h.depth],d=h.x0+v,p=h.y0+v,x=h.x1-v,m=h.y1-v;x<d&&(d=x=(d+x)/2),m<p&&(p=m=(p+m)/2),h.x0=d,h.y0=p,h.x1=x,h.y1=m,h.children&&(v=n[h.depth+1]=a(h)/2,d+=u(h)-v,p+=o(h)-v,x-=l(h)-v,m-=s(h)-v,x<d&&(d=x=(d+x)/2),m<p&&(p=m=(p+m)/2),e(h,d,p,x,m))}return c.round=function(h){return arguments.length?(r=!!h,c):r},c.size=function(h){return arguments.length?(t=+h[0],i=+h[1],c):[t,i]},c.tile=function(h){return arguments.length?(e=Tx(h),c):e},c.padding=function(h){return arguments.length?c.paddingInner(h).paddingOuter(h):c.paddingInner()},c.paddingInner=function(h){return arguments.length?(a=typeof h=="function"?h:nf(+h),c):a},c.paddingOuter=function(h){return arguments.length?c.paddingTop(h).paddingRight(h).paddingBottom(h).paddingLeft(h):c.paddingTop()},c.paddingTop=function(h){return arguments.length?(o=typeof h=="function"?h:nf(+h),c):o},c.paddingRight=function(h){return arguments.length?(l=typeof h=="function"?h:nf(+h),c):l},c.paddingBottom=function(h){return arguments.length?(s=typeof h=="function"?h:nf(+h),c):s},c.paddingLeft=function(h){return arguments.length?(u=typeof h=="function"?h:nf(+h),c):u},c}function kMt(e,r,t,i,n){var a=e.children,o,l=a.length,s,u=new Array(l+1);for(u[0]=s=o=0;o<l;++o)u[o+1]=s+=a[o].value;c(0,l,e.value,r,t,i,n);function c(f,h,v,d,p,x,m){if(f>=h-1){var _=a[f];_.x0=d,_.y0=p,_.x1=x,_.y1=m;return}for(var b=u[f],w=v/2+b,S=f+1,M=h-1;S<M;){var F=S+M>>>1;u[F]<w?S=F+1:M=F}w-u[S-1]<u[S]-w&&f+1<S&&--S;var O=u[S]-b,L=v-O;if(x-d>m-p){var D=v?(d*L+x*O)/v:x;c(f,S,O,d,p,D,m),c(S,h,L,D,p,x,m)}else{var k=v?(p*L+m*O)/v:m;c(f,S,O,d,p,x,k),c(S,h,L,d,k,x,m)}}}function RMt(e,r,t,i,n){(e.depth&1?Y_:_g)(e,r,t,i,n)}var BMt=function e(r){function t(i,n,a,o,l){if((s=i._squarify)&&s.ratio===r)for(var s,u,c,f,h=-1,v,d=s.length,p=i.value;++h<d;){for(u=s[h],c=u.children,f=u.value=0,v=c.length;f<v;++f)u.value+=c[f].value;u.dice?_g(u,n,a,o,p?a+=(l-a)*u.value/p:l):Y_(u,n,a,p?n+=(o-n)*u.value/p:o,l),p-=u.value}else i._squarify=s=E4(r,i,n,a,o,l),s.ratio=r}return t.ratio=function(i){return e((i=+i)>1?i:1)},t}(M4),BT=Object.freeze(Object.defineProperty({__proto__:null,cluster:KTt,hierarchy:Nh,pack:S4,packSiblings:CMt,packEnclose:_4,partition:T4,stratify:FMt,tree:$Mt,treemap:O4,treemapBinary:kMt,treemapDice:_g,treemapSlice:Y_,treemapSliceDice:RMt,treemapSquarify:F4,treemapResquarify:BMt},Symbol.toStringTag,{value:"Module"})),NMt=br(BT),P4={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.getAllNodes=e.getField=e.NODE_ANCESTORS_FIELD=e.CHILD_NODE_COUNT=e.NODE_INDEX_FIELD=void 0;var r=Y;e.NODE_INDEX_FIELD="nodeIndex",e.CHILD_NODE_COUNT="childNodeCount",e.NODE_ANCESTORS_FIELD="nodeAncestor";var t="Invalid field: it must be a string!";function i(a,o){var l=a.field,s=a.fields;if(r.isString(l))return l;if(r.isArray(l))return console.warn(t),l[0];if(console.warn(t+" will try to get fields instead."),r.isString(s))return s;if(r.isArray(s)&&s.length)return s[0];if(o)return o;throw new TypeError(t)}e.getField=i;function n(a){var o=[];if(a&&a.each){var l,s;a.each(function(u){var c,f;u.parent!==l?(l=u.parent,s=0):s+=1;var h=r.filter((((c=u.ancestors)===null||c===void 0?void 0:c.call(u))||[]).map(function(v){return o.find(function(d){return d.name===v.name})||v}),function(v){var d=v.depth;return d>0&&d<u.depth});u[e.NODE_ANCESTORS_FIELD]=h,u[e.CHILD_NODE_COUNT]=((f=u.children)===null||f===void 0?void 0:f.length)||0,u[e.NODE_INDEX_FIELD]=s,o.push(u)})}else a&&a.eachNode&&a.eachNode(function(u){o.push(u)});return o}e.getAllNodes=n})(P4);Object.defineProperty(ah,"__esModule",{value:!0});ah.treemap=ah.getTileMethod=void 0;var GMt=V,Mx=GMt.__importStar(NMt),vN=Y,dN=P4,zMt={field:"value",tile:"treemapSquarify",size:[1,1],round:!1,ignoreParentValue:!0,padding:0,paddingInner:0,paddingOuter:0,paddingTop:0,paddingRight:0,paddingBottom:0,paddingLeft:0,as:["x","y"],sort:function(e,r){return r.value-e.value},ratio:.5*(1+Math.sqrt(5))};function I4(e,r){return e==="treemapSquarify"?Mx[e].ratio(r):Mx[e]}ah.getTileMethod=I4;function VMt(e,r){r=vN.assign({},zMt,r);var t=r.as;if(!vN.isArray(t)||t.length!==2)throw new TypeError('Invalid as: it must be an array with 2 strings (e.g. [ "x", "y" ])!');var i;try{i=dN.getField(r)}catch(u){console.warn(u)}var n=I4(r.tile,r.ratio),a=function(u){return Mx.treemap().tile(n).size(r.size).round(r.round).padding(r.padding).paddingInner(r.paddingInner).paddingOuter(r.paddingOuter).paddingTop(r.paddingTop).paddingRight(r.paddingRight).paddingBottom(r.paddingBottom).paddingLeft(r.paddingLeft)(Mx.hierarchy(u).sum(function(c){return r.ignoreParentValue&&c.children?0:c[i]}).sort(r.sort))},o=a(e),l=t[0],s=t[1];return o.each(function(u){u[l]=[u.x0,u.x1,u.x1,u.x0],u[s]=[u.y1,u.y1,u.y0,u.y0],["x0","x1","y0","y1"].forEach(function(c){t.indexOf(c)===-1&&delete u[c]})}),dN.getAllNodes(o)}ah.treemap=VMt;Object.defineProperty(pn,"__esModule",{value:!0});pn.transformData=pn.resetDrillDown=pn.enableDrillInteraction=pn.enableInteraction=pn.findInteraction=void 0;var $S=V,fP=Y,jMt=cP,HMt=ah;function L4(e,r){if(!!fP.isArray(e))return e.find(function(t){return t.type===r})}pn.findInteraction=L4;function D4(e,r){var t=L4(e,r);return t&&t.enable!==!1}pn.enableInteraction=D4;function YMt(e){var r=e.interactions,t=e.drilldown;return fP.get(t,"enabled")||D4(r,"treemap-drill-down")}pn.enableDrillInteraction=YMt;function WMt(e){var r=e.interactions["drill-down"];if(!!r){var t=r.context.actions.find(function(i){return i.name==="drill-down-action"});t.reset()}}pn.resetDrillDown=WMt;function XMt(e){var r=e.data,t=e.colorField,i=e.enableDrillDown,n=e.hierarchyConfig,a=HMt.treemap(r,$S.__assign($S.__assign({},n),{type:"hierarchy.treemap",field:"value",as:["x","y"]})),o=[];return a.forEach(function(l){if(l.depth===0||i&&l.depth!==1||!i&&l.children)return null;var s=l.ancestors().map(function(h){return{data:h.data,height:h.height,value:h.value}}),u=i&&fP.isArray(r.path)?s.concat(r.path.slice(1)):s,c=Object.assign({},l.data,$S.__assign({x:l.x,y:l.y,depth:l.depth,value:l.value,path:u},l));if(!l.data[t]&&l.parent){var f=l.ancestors().find(function(h){return h.data[t]});c[t]=f==null?void 0:f.data[t]}else c[t]=l.data[t];c[jMt.HIERARCHY_DATA_TRANSFORM_PARAMS]={hierarchyConfig:n,colorField:t,enableDrillDown:i},o.push(c)}),o}pn.transformData=XMt;Object.defineProperty(nh,"__esModule",{value:!0});nh.adaptor=nh.interaction=void 0;var UMt=V,qMt=Y,ZMt=xg,af=Qe,QMt=$s,W_=mt,KMt=ho,lh=pn;function JMt(e){var r=e.options,t=r.colorField;return W_.deepAssign({options:{rawFields:["value"],tooltip:{fields:["name","value",t,"path"],formatter:function(i){return{name:i.name,value:i.value}}}}},e)}function tEt(e){var r=e.chart,t=e.options,i=t.color,n=t.colorField,a=t.rectStyle,o=t.hierarchyConfig,l=t.rawFields,s=lh.transformData({data:t.data,colorField:t.colorField,enableDrillDown:lh.enableDrillInteraction(t),hierarchyConfig:o});return r.data(s),ZMt.polygon(W_.deepAssign({},e,{options:{xField:"x",yField:"y",seriesField:n,rawFields:l,polygon:{color:i,style:a}}})),r.coordinate().reflect("y"),e}function eEt(e){var r=e.chart;return r.axis(!1),e}function rEt(e){var r=e.drilldown,t=e.interactions,i=t===void 0?[]:t,n=lh.enableDrillInteraction(e);return n?W_.deepAssign({},e,{interactions:UMt.__spreadArrays(i,[{type:"drill-down",cfg:{drillDownConfig:r,transformData:lh.transformData}}])}):e}function $4(e){var r=e.chart,t=e.options,i=t.interactions,n=t.drilldown;af.interaction({chart:r,options:rEt(t)});var a=lh.findInteraction(i,"view-zoom");a&&(a.enable!==!1?r.getCanvas().on("mousewheel",function(l){l.preventDefault()}):r.getCanvas().off("mousewheel"));var o=lh.enableDrillInteraction(t);return o&&(r.appendPadding=KMt.getAdjustAppendPadding(r.appendPadding,qMt.get(n,["breadCrumb","position"]))),e}nh.interaction=$4;function iEt(e){return W_.flow(JMt,af.theme,QMt.pattern("rectStyle"),tEt,eEt,af.legend,af.tooltip,$4,af.animation,af.annotation())(e)}nh.adaptor=iEt;var X_={};Object.defineProperty(X_,"__esModule",{value:!0});X_.DEFAULT_OPTIONS=void 0;X_.DEFAULT_OPTIONS={colorField:"name",rectStyle:{lineWidth:1,stroke:"#fff"},hierarchyConfig:{tile:"treemapSquarify"},label:{fields:["name"],layout:{type:"limit-in-shape"}},tooltip:{showMarkers:!1,showTitle:!1},drilldown:{enabled:!1,breadCrumb:{position:"bottom-left",rootText:"\u521D\u59CB",dividerText:"/",textStyle:{fontSize:12,fill:"rgba(0, 0, 0, 0.65)",cursor:"pointer"},activeTextStyle:{fill:"#87B5FF"}}}};var nEt=me;nEt.registerInteraction("drag-move",{start:[{trigger:"plot:mousedown",action:"scale-translate:start"}],processing:[{trigger:"plot:mousemove",action:"scale-translate:translate",throttle:{wait:100,leading:!0,trailing:!1}}],end:[{trigger:"plot:mouseup",action:"scale-translate:end"}]});var hP={};Object.defineProperty(hP,"__esModule",{value:!0});hP.isParentNode=void 0;var k4=me,pN=Y,aEt=cP;function NT(e){var r=pN.get(e,["event","data","data"],{});return pN.isArray(r.children)&&r.children.length>0}hP.isParentNode=NT;function gN(e){var r=e.view.getCoordinate(),t=r.innerRadius;if(t){var i=e.event,n=i.x,a=i.y,o=r.center,l=o.x,s=o.y,u=r.getRadius()*t,c=Math.sqrt(Math.pow(l-n,2)+Math.pow(s-a,2));return c<u}return!1}k4.registerAction("drill-down-action",aEt.DrillDownAction);k4.registerInteraction("drill-down",{showEnable:[{trigger:"element:mouseenter",action:"cursor:pointer",isEnable:NT},{trigger:"element:mouseleave",action:"cursor:default"},{trigger:"element:mouseleave",action:"cursor:pointer",isEnable:gN}],start:[{trigger:"element:click",isEnable:NT,action:["drill-down-action:click"]},{trigger:"afterchangesize",action:["drill-down-action:resetPosition"]},{trigger:"click",isEnable:gN,action:["drill-down-action:back"]}]});Object.defineProperty(uP,"__esModule",{value:!0});var R4=uP.Treemap=void 0,oEt=V,lEt=ae,sEt=nh,uEt=X_,kS=pn,cEt=function(e){oEt.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="treemap",t}return r.getDefaultOptions=function(){return uEt.DEFAULT_OPTIONS},r.prototype.changeData=function(t){var i=this.options,n=i.colorField,a=i.interactions,o=i.hierarchyConfig;this.updateOption({data:t});var l=kS.transformData({data:t,colorField:n,enableDrillDown:kS.enableInteraction(a,"treemap-drill-down"),hierarchyConfig:o});this.chart.changeData(l),kS.resetDrillDown(this.chart)},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return sEt.adaptor},r}(lEt.Plot);R4=uP.Treemap=cEt;var B4=function(e,r,t){if(t===void 0&&(t=1),t>r)delete e.children;else{var i=e.children;i&&i.length&&i.forEach(function(n){B4(n,r,t+1)})}},fEt=function(e){var r=He(e),t=I(r,"maxLevel",2);if(!K(t)&&!(t<1)){var i=I(r,"data",{});B4(i,t),jt(r,"data",i),jt(r,"maxLevel",t)}return r},hEt=Qt(R4,"TreemapChart",fEt),vEt=Qt(sP,"StepLineChart",function(e){return e.stepType=e.stepType||e.step||"hv",m4(e)}),vP={},_n={};Object.defineProperty(_n,"__esModule",{value:!0});_n.getDataWhetherPecentage=_n.getDeepPercent=_n.percent=void 0;var Ex=V,_f=Y,Fx=bs;function N4(e,r,t,i){var n=_f.reduce(e,function(a,o){var l=o[t],s=a.has(l)?a.get(l):0,u=o[r];return s=Fx.isRealNumber(u)?s+u:s,a.set(l,s),a},new Map);return _f.map(e,function(a){var o,l=a[r],s=a[t],u=Fx.isRealNumber(l)?l/n.get(s):0;return Ex.__assign(Ex.__assign({},a),(o={},o[i]=u,o))})}_n.percent=N4;function dEt(e,r,t,i){var n=_f.reduce(e,function(a,o){var l=_f.reduce(t,function(c,f){return""+c+o[f]},""),s=a.has(l)?a.get(l):0,u=o[r];return s=Fx.isRealNumber(u)?s+u:s,a.set(l,s),a},new Map);return _f.map(e,function(a){var o,l=a[r],s=_f.reduce(t,function(c,f){return""+c+a[f]},""),u=Fx.isRealNumber(l)?l/n.get(s):0;return Ex.__assign(Ex.__assign({},a),(o={},o[i]=u,o))})}_n.getDeepPercent=dEt;function pEt(e,r,t,i,n){return n?N4(e,r,t,i):e}_n.getDataWhetherPecentage=pEt;var G4={},Aa={},U_={},bg={};Object.defineProperty(bg,"__esModule",{value:!0});bg.conversionTagFormatter=void 0;var yN=Y;function gEt(e,r){return!yN.isNumber(e)||!yN.isNumber(r)?"-":e===r?"100%":e===0?"\u221E":r===0?"-\u221E":(100*r/e).toFixed(2)+"%"}bg.conversionTagFormatter=gEt;Object.defineProperty(U_,"__esModule",{value:!0});U_.conversionTag=void 0;var Ox=V,O0=Y,yEt=me,z4=mt,mEt=bg;function xEt(e,r){return z4.deepAssign({size:r?32:80,spacing:r?8:12,offset:r?32:0,arrow:e.arrow!==!1&&{headSize:12,style:{fill:"rgba(0, 0, 0, 0.05)"}},text:e.text!==!1&&{style:{fontSize:12,fill:"rgba(0, 0, 0, 0.85)",textAlign:"center",textBaseline:"middle"},formatter:mEt.conversionTagFormatter}},e)}function Px(e,r){return O0.map(r.getModel().points,function(t){return e.convertPoint(t)})}function _Et(e,r,t){var i=e.view,n=e.geometry,a=e.group,o=e.options,l=e.horizontal,s=o.offset,u=o.size,c=o.arrow,f=i.getCoordinate(),h=Px(f,r)[l?3:0],v=Px(f,t)[l?0:3],d=v.y-h.y,p=v.x-h.x;if(typeof c!="boolean"){var x=c.headSize,m=o.spacing,_;l?(p-x)/2<m?(m=Math.max(1,(p-x)/2),_=[[h.x+m,h.y-s],[h.x+m,h.y-s-u],[v.x-m,v.y-s-u/2]]):_=[[h.x+m,h.y-s],[h.x+m,h.y-s-u],[v.x-m-x,v.y-s-u],[v.x-m,v.y-s-u/2],[v.x-m-x,v.y-s]]:(d-x)/2<m?(m=Math.max(1,(d-x)/2),_=[[h.x+s,h.y+m],[h.x+s+u,h.y+m],[v.x+s+u/2,v.y-m]]):_=[[h.x+s,h.y+m],[h.x+s+u,h.y+m],[v.x+s+u,v.y-m-x],[v.x+s+u/2,v.y-m],[v.x+s,v.y-m-x]],a.addShape("polygon",{id:i.id+"-conversion-tag-arrow-"+n.getElementId(r.getModel().mappingData),name:"conversion-tag-arrow",origin:{element:r,nextElement:t},attrs:Ox.__assign(Ox.__assign({},c.style||{}),{points:_})})}}function bEt(e,r,t){var i,n,a,o=e.view,l=e.geometry,s=e.group,u=e.options,c=e.field,f=e.horizontal,h=u.offset,v=u.size;if(typeof u.text!="boolean"){var d=o.getCoordinate(),p=((i=u.text)===null||i===void 0?void 0:i.formatter)&&((n=u.text)===null||n===void 0?void 0:n.formatter(r.getData()[c],t.getData()[c])),x=Px(d,r)[f?3:0],m=Px(d,t)[f?0:3],_=s.addShape("text",{id:o.id+"-conversion-tag-text-"+l.getElementId(r.getModel().mappingData),name:"conversion-tag-text",origin:{element:r,nextElement:t},attrs:Ox.__assign(Ox.__assign({},((a=u.text)===null||a===void 0?void 0:a.style)||{}),{text:p,x:f?(x.x+m.x)/2:x.x+h+v/2,y:f?x.y-h-v/2:(x.y+m.y)/2})});if(f){var b=m.x-x.x,w=_.getBBox().width;if(w>b){var S=w/p.length,M=Math.max(1,Math.ceil(b/S)-1),F=p.slice(0,M)+"...";_.attr("text",F)}}}}function wEt(e,r,t){_Et(e,r,t),bEt(e,r,t)}function CEt(e,r,t){return r===void 0&&(r=!0),t===void 0&&(t=!1),function(i){var n=i.options,a=i.chart,o=n.conversionTag,l=n.theme;return o&&!t&&(a.theme(z4.deepAssign({},O0.isObject(l)?l:yEt.getTheme(l),{columnWidthRatio:1/3})),a.annotation().shape({render:function(s,u){var c=s.addGroup({id:a.id+"-conversion-tag-group",name:"conversion-tag-group"}),f=O0.find(a.geometries,function(d){return d.type==="interval"}),h={view:u,geometry:f,group:c,field:e,horizontal:r,options:xEt(o,r)},v=r?f.elements:f.elements.slice().reverse();O0.each(v,function(d,p){p>0&&wEt(h,v[p-1],d)})}})),i}}U_.conversionTag=CEt;var q_={};Object.defineProperty(q_,"__esModule",{value:!0});q_.connectedArea=void 0;var V4=me,Vu={hover:"__interval-connected-area-hover__",click:"__interval-connected-area-click__"},dP=function(e,r){return e==="hover"?[{trigger:"interval:mouseenter",action:["element-highlight-by-color:highlight","element-link-by-color:link"],arg:[null,{style:r}]}]:[{trigger:"interval:click",action:["element-highlight-by-color:clear","element-highlight-by-color:highlight","element-link-by-color:clear","element-link-by-color:unlink","element-link-by-color:link"],arg:[null,null,null,null,{style:r}]}]};V4.registerInteraction(Vu.hover,{start:dP(Vu.hover),end:[{trigger:"interval:mouseleave",action:["element-highlight-by-color:reset","element-link-by-color:unlink"]}]});V4.registerInteraction(Vu.click,{start:dP(Vu.click),end:[{trigger:"document:mousedown",action:["element-highlight-by-color:clear","element-link-by-color:clear"]}]});function SEt(e){return e===void 0&&(e=!1),function(r){var t=r.chart,i=r.options,n=i.connectedArea,a=function(){t.removeInteraction(Vu.hover),t.removeInteraction(Vu.click)};if(!e&&n){var o=n.trigger||"hover";a(),t.interaction(Vu[o],{start:dP(o,n.style)})}else a();return r}}q_.connectedArea=SEt;var wg={},Z_={},j4={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ButtonAction=e.BUTTON_ACTION_CONFIG=void 0;var r=V,t=me,i=Y,n=mt,a=10,o=5;e.BUTTON_ACTION_CONFIG={padding:[8,10],text:"reset",textStyle:{default:{x:0,y:0,fontSize:12,fill:"#333333",cursor:"pointer"}},buttonStyle:{default:{fill:"#f7f7f7",stroke:"#cccccc",cursor:"pointer"},active:{fill:"#e6e6e6"}}};var l=function(s){r.__extends(u,s);function u(){var c=s!==null&&s.apply(this,arguments)||this;return c.buttonGroup=null,c.buttonCfg=r.__assign({name:"button"},e.BUTTON_ACTION_CONFIG),c}return u.prototype.getButtonCfg=function(){var c=this.context.view,f=i.get(c,["interactions","filter-action","cfg","buttonConfig"]);return n.deepAssign(this.buttonCfg,f,this.cfg)},u.prototype.drawButton=function(){var c=this.getButtonCfg(),f=this.context.view.foregroundGroup.addGroup({name:c.name}),h=this.drawText(f);this.drawBackground(f,h.getBBox()),this.buttonGroup=f},u.prototype.drawText=function(c){var f,h=this.getButtonCfg();return c.addShape({type:"text",name:"button-text",attrs:r.__assign({text:h.text},(f=h.textStyle)===null||f===void 0?void 0:f.default)})},u.prototype.drawBackground=function(c,f){var h,v=this.getButtonCfg(),d=n.normalPadding(v.padding),p=c.addShape({type:"rect",name:"button-rect",attrs:r.__assign({x:f.x-d[3],y:f.y-d[0],width:f.width+d[1]+d[3],height:f.height+d[0]+d[2]},(h=v.buttonStyle)===null||h===void 0?void 0:h.default)});return p.toBack(),c.on("mouseenter",function(){var x;p.attr((x=v.buttonStyle)===null||x===void 0?void 0:x.active)}),c.on("mouseleave",function(){var x;p.attr((x=v.buttonStyle)===null||x===void 0?void 0:x.default)}),p},u.prototype.resetPosition=function(){var c=this.context.view,f=c.getCoordinate(),h=f.convert({x:1,y:1}),v=this.buttonGroup,d=v.getBBox(),p=t.Util.transform(null,[["t",h.x-d.width-a,h.y+d.height+o]]);v.setMatrix(p)},u.prototype.show=function(){this.buttonGroup||this.drawButton(),this.resetPosition(),this.buttonGroup.show()},u.prototype.hide=function(){this.buttonGroup&&this.buttonGroup.hide()},u.prototype.destroy=function(){var c=this.buttonGroup;c&&c.remove(),s.prototype.destroy.call(this)},u}(t.Action);e.ButtonAction=l})(j4);Object.defineProperty(Z_,"__esModule",{value:!0});Z_.getInteractionCfg=void 0;var ks=me,AEt=j4;ks.registerAction("brush-reset-button",AEt.ButtonAction,{name:"brush-reset-button"});ks.registerInteraction("filter-action",{});function ko(e){return e.isInPlot()}function gc(e,r,t){var i=r||"rect";switch(e){case"brush":return{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"mousedown",isEnable:ko,action:["brush:start",i+"-mask:start",i+"-mask:show"],arg:[null,{maskStyle:t==null?void 0:t.style}]}],processing:[{trigger:"mousemove",isEnable:ko,action:[i+"-mask:resize"]}],end:[{trigger:"mouseup",isEnable:ko,action:["brush:filter","brush:end",i+"-mask:end",i+"-mask:hide","brush-reset-button:show"]}],rollback:[{trigger:"brush-reset-button:click",action:["brush:reset","brush-reset-button:hide","cursor:crosshair"]}]};case"brush-highlight":return{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"mask:mouseenter",action:"cursor:move"},{trigger:"plot:mouseleave",action:"cursor:default"},{trigger:"mask:mouseleave",action:"cursor:crosshair"}],start:[{trigger:"plot:mousedown",isEnable:function(n){return!n.isInShape("mask")},action:[i+"-mask:start",i+"-mask:show"],arg:[{maskStyle:t==null?void 0:t.style}]},{trigger:"mask:dragstart",action:[i+"-mask:moveStart"]}],processing:[{trigger:"plot:mousemove",action:[i+"-mask:resize"]},{trigger:"mask:drag",action:[i+"-mask:move"]},{trigger:"mask:change",action:["element-range-highlight:highlight"]}],end:[{trigger:"plot:mouseup",action:[i+"-mask:end"]},{trigger:"mask:dragend",action:[i+"-mask:moveEnd"]},{trigger:"document:mouseup",isEnable:function(n){return!n.isInPlot()},action:["element-range-highlight:clear",i+"-mask:end",i+"-mask:hide"]}],rollback:[{trigger:"dblclick",action:["element-range-highlight:clear",i+"-mask:hide"]}]};case"brush-x":return{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"mousedown",isEnable:ko,action:["brush-x:start",i+"-mask:start",i+"-mask:show"],arg:[null,{maskStyle:t==null?void 0:t.style}]}],processing:[{trigger:"mousemove",isEnable:ko,action:[i+"-mask:resize"]}],end:[{trigger:"mouseup",isEnable:ko,action:["brush-x:filter","brush-x:end",i+"-mask:end",i+"-mask:hide"]}],rollback:[{trigger:"dblclick",action:["brush-x:reset"]}]};case"brush-x-highlight":return{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"mask:mouseenter",action:"cursor:move"},{trigger:"plot:mouseleave",action:"cursor:default"},{trigger:"mask:mouseleave",action:"cursor:crosshair"}],start:[{trigger:"plot:mousedown",isEnable:function(n){return!n.isInShape("mask")},action:[i+"-mask:start",i+"-mask:show"],arg:[{maskStyle:t==null?void 0:t.style}]},{trigger:"mask:dragstart",action:[i+"-mask:moveStart"]}],processing:[{trigger:"plot:mousemove",action:[i+"-mask:resize"]},{trigger:"mask:drag",action:[i+"-mask:move"]},{trigger:"mask:change",action:["element-range-highlight:highlight"]}],end:[{trigger:"plot:mouseup",action:[i+"-mask:end"]},{trigger:"mask:dragend",action:[i+"-mask:moveEnd"]},{trigger:"document:mouseup",isEnable:function(n){return!n.isInPlot()},action:["element-range-highlight:clear",i+"-mask:end",i+"-mask:hide"]}],rollback:[{trigger:"dblclick",action:["element-range-highlight:clear",i+"-mask:hide"]}]};case"brush-y":return{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"mousedown",isEnable:ko,action:["brush-y:start",i+"-mask:start",i+"-mask:show"],arg:[null,{maskStyle:t==null?void 0:t.style}]}],processing:[{trigger:"mousemove",isEnable:ko,action:[i+"-mask:resize"]}],end:[{trigger:"mouseup",isEnable:ko,action:["brush-y:filter","brush-y:end",i+"-mask:end",i+"-mask:hide"]}],rollback:[{trigger:"dblclick",action:["brush-y:reset"]}]};case"brush-y-highlight":return{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"mask:mouseenter",action:"cursor:move"},{trigger:"plot:mouseleave",action:"cursor:default"},{trigger:"mask:mouseleave",action:"cursor:crosshair"}],start:[{trigger:"plot:mousedown",isEnable:function(n){return!n.isInShape("mask")},action:[i+"-mask:start",i+"-mask:show"],arg:[{maskStyle:t==null?void 0:t.style}]},{trigger:"mask:dragstart",action:[i+"-mask:moveStart"]}],processing:[{trigger:"plot:mousemove",action:[i+"-mask:resize"]},{trigger:"mask:drag",action:[i+"-mask:move"]},{trigger:"mask:change",action:["element-range-highlight:highlight"]}],end:[{trigger:"plot:mouseup",action:[i+"-mask:end"]},{trigger:"mask:dragend",action:[i+"-mask:moveEnd"]},{trigger:"document:mouseup",isEnable:function(n){return!n.isInPlot()},action:["element-range-highlight:clear",i+"-mask:end",i+"-mask:hide"]}],rollback:[{trigger:"dblclick",action:["element-range-highlight:clear",i+"-mask:hide"]}]};default:return{}}}Z_.getInteractionCfg=gc;ks.registerInteraction("brush",gc("brush"));ks.registerInteraction("brush-highlight",gc("brush-highlight"));ks.registerInteraction("brush-x",gc("brush-x","x-rect"));ks.registerInteraction("brush-y",gc("brush-y","y-rect"));ks.registerInteraction("brush-x-highlight",gc("brush-x-highlight","x-rect"));ks.registerInteraction("brush-y-highlight",gc("brush-y-highlight","y-rect"));Object.defineProperty(wg,"__esModule",{value:!0});wg.brushInteraction=void 0;var TEt=Y,MEt=Z_,EEt=mt,mN=["brush","brush-x","brush-y","brush-highlight","brush-x-highlight","brush-y-highlight"];function FEt(e){var r=e.options,t=r.brush,i=TEt.filter(r.interactions||[],function(n){return mN.indexOf(n.type)===-1});return t!=null&&t.enabled&&(mN.forEach(function(n){var a,o=!1;switch(t.type){case"x-rect":o=n===(t.action==="highlight"?"brush-x-highlight":"brush-x");break;case"y-rect":o=n===(t.action==="highlight"?"brush-y-highlight":"brush-y");break;default:o=n===(t.action==="highlight"?"brush-highlight":"brush");break}var l={type:n,enable:o};(((a=t.mask)===null||a===void 0?void 0:a.style)||t.type)&&(l.cfg=MEt.getInteractionCfg(n,t.type,t.mask)),i.push(l)}),(t==null?void 0:t.action)!=="highlight"&&i.push({type:"filter-action",cfg:{buttonConfig:t.button}})),EEt.deepAssign({},e,{options:{interactions:i}})}wg.brushInteraction=FEt;Object.defineProperty(Aa,"__esModule",{value:!0});Aa.adaptor=Aa.legend=Aa.meta=void 0;var gn=V,RS=Y,No=Qe,OEt=U_,PEt=q_,IEt=Lr,LEt=$s,DEt=wg,rc=mt,xN=_n;function $Et(e){var r=e.options,t=r.legend,i=r.seriesField,n=r.isStack;return i?t!==!1&&(t=gn.__assign({position:n?"right-top":"top-left"},t)):t=!1,e.options.legend=t,e}function kEt(e){var r=e.chart,t=e.options,i=t.data,n=t.columnStyle,a=t.color,o=t.columnWidthRatio,l=t.isPercent,s=t.isGroup,u=t.isStack,c=t.xField,f=t.yField,h=t.seriesField,v=t.groupField,d=t.tooltip,p=t.shape,x=l&&s&&u?xN.getDeepPercent(i,f,[c,v],f):xN.getDataWhetherPecentage(i,f,c,f,l),m=[];u&&h&&!s?x.forEach(function(w){var S=m.find(function(M){return M[c]===w[c]&&M[h]===w[h]});S?S[f]+=w[f]||0:m.push(gn.__assign({},w))}):m=x,r.data(m);var _=l?gn.__assign({formatter:function(w){return{name:s&&u?w[h]+" - "+w[v]:w[h]||w[c],value:(Number(w[f])*100).toFixed(2)+"%"}}},d):d,b=rc.deepAssign({},e,{options:{data:m,widthRatio:o,tooltip:_,interval:{shape:p,style:n,color:a}}});return IEt.interval(b),b}function H4(e){var r,t,i=e.options,n=i.xAxis,a=i.yAxis,o=i.xField,l=i.yField,s=i.data,u=i.isPercent,c=u?{max:1,min:0,minLimit:0,maxLimit:1}:{};return rc.flow(No.scale((r={},r[o]=n,r[l]=a,r),(t={},t[o]={type:"cat"},t[l]=gn.__assign(gn.__assign({},rc.adjustYMetaByZero(s,l)),c),t)))(e)}Aa.meta=H4;function REt(e){var r=e.chart,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.yField;return i===!1?r.axis(a,!1):r.axis(a,i),n===!1?r.axis(o,!1):r.axis(o,n),e}function Y4(e){var r=e.chart,t=e.options,i=t.legend,n=t.seriesField;return i&&n?r.legend(n,i):i===!1&&r.legend(!1),e}Aa.legend=Y4;function BEt(e){var r=e.chart,t=e.options,i=t.label,n=t.yField,a=t.isRange,o=rc.findGeometry(r,"interval");if(!i)o.label(!1);else{var l=i.callback,s=gn.__rest(i,["callback"]);o.label({fields:[n],callback:l,cfg:gn.__assign({layout:s!=null&&s.position?void 0:[{type:"interval-adjust-position"},{type:"interval-hide-overlap"},{type:"adjust-color"},{type:"limit-in-plot",cfg:{action:"hide"}}]},rc.transformLabel(a?gn.__assign({content:function(u){var c;return(c=u[n])===null||c===void 0?void 0:c.join("-")}},s):s))})}return e}function NEt(e){var r=e.chart,t=e.options,i=t.tooltip,n=t.isGroup,a=t.isStack,o=t.groupField,l=t.data,s=t.xField,u=t.yField,c=t.seriesField;if(i===!1)r.tooltip(!1);else{var f=i;if(n&&a){var h=(f==null?void 0:f.formatter)||function(v){return{name:v[c]+" - "+v[o],value:v[u]}};f=gn.__assign(gn.__assign({},f),{customItems:function(v){var d=[];return RS.each(v,function(p){var x=RS.filter(l,function(m){return RS.isMatch(m,rc.pick(p.data,[s,c]))});x.forEach(function(m){d.push(gn.__assign(gn.__assign(gn.__assign({},p),{value:m[u],data:m,mappingData:{_origin:m}}),h(m)))})}),d}})}r.tooltip(f)}return e}function GEt(e,r){r===void 0&&(r=!1);var t=e.options,i=t.seriesField;return rc.flow($Et,No.theme,LEt.pattern("columnStyle"),No.state,kEt,H4,REt,Y4,NEt,No.slider,No.scrollbar,BEt,DEt.brushInteraction,No.interaction,No.animation,No.annotation(),OEt.conversionTag(t.yField,!r,!!i),PEt.connectedArea(!t.isStack),No.limitInPlot)(e)}Aa.adaptor=GEt;var Cg={};Object.defineProperty(Cg,"__esModule",{value:!0});Cg.transformBarData=void 0;function zEt(e){return e&&e.slice().reverse()}Cg.transformBarData=zEt;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=void 0;var r=V,t=Aa,i=Cg,n=Aa;Object.defineProperty(e,"meta",{enumerable:!0,get:function(){return n.meta}});function a(o){var l=o.chart,s=o.options,u=s.xField,c=s.yField,f=s.xAxis,h=s.yAxis,v=s.barStyle,d=s.barWidthRatio,p=s.label,x=s.data,m=s.seriesField,_=s.isStack,b=s.minBarWidth,w=s.maxBarWidth;p&&!p.position&&(p.position="left",p.layout||(p.layout=[{type:"interval-adjust-position"},{type:"interval-hide-overlap"},{type:"adjust-color"},{type:"limit-in-plot",cfg:{action:"hide"}}]));var S=s.legend;m?S!==!1&&(S=r.__assign({position:_?"top-left":"right-top",reversed:!_},S||{})):S=!1,o.options.legend=S;var M=s.tooltip;return m&&M!==!1&&(M=r.__assign({reversed:!_},M||{})),o.options.tooltip=M,l.coordinate().transpose(),t.adaptor({chart:l,options:r.__assign(r.__assign({},s),{label:p,xField:c,yField:u,xAxis:h,yAxis:f,columnStyle:v,columnWidthRatio:d,minColumnWidth:b,maxColumnWidth:w,columnBackground:s.barBackground,data:i.transformBarData(x)})},!0)}e.adaptor=a})(G4);var Q_={};Object.defineProperty(Q_,"__esModule",{value:!0});Q_.DEFAULT_OPTIONS=void 0;var VEt=ae,jEt=mt;Q_.DEFAULT_OPTIONS=jEt.deepAssign({},VEt.Plot.getDefaultOptions(),{barWidthRatio:.6,marginRatio:1/32,tooltip:{shared:!0,showMarkers:!1,offset:20},interactions:[{type:"active-region"}]});Object.defineProperty(vP,"__esModule",{value:!0});var Gh=vP.Bar=void 0,BS=V,HEt=ae,YEt=_n,_N=G4,WEt=Q_,XEt=Cg,UEt=function(e){BS.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="bar",t}return r.getDefaultOptions=function(){return WEt.DEFAULT_OPTIONS},r.prototype.changeData=function(t){this.updateOption({data:t});var i=this,n=i.chart,a=i.options,o=a.xField,l=a.yField,s=a.isPercent,u=BS.__assign(BS.__assign({},a),{xField:l,yField:o});_N.meta({chart:n,options:u}),n.changeData(YEt.getDataWhetherPecentage(XEt.transformBarData(t),o,l,o,s))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return _N.adaptor},r}(HEt.Plot);Gh=vP.Bar=UEt;var qEt=globalThis&&globalThis.__rest||function(e,r){var t={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&r.indexOf(i)<0&&(t[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,i=Object.getOwnPropertySymbols(e);n<i.length;n++)r.indexOf(i[n])<0&&Object.prototype.propertyIsEnumerable.call(e,i[n])&&(t[i[n]]=e[i[n]]);return t},K_=function(e){var r=He(e),t=r.barSize,i=qEt(r,["barSize"]);return $a([{sourceKey:"stackField",targetKey:"seriesField",notice:"stackField\u662F\u65E7\u7248API\uFF0C\u5373\u5C06\u5E9F\u5F03 \u8BF7\u4F7F\u7528seriesField\u66FF\u4EE3"},{sourceKey:"colorField",targetKey:"seriesField",notice:"colorField\u662F\u65E7\u7248API\uFF0C\u5373\u5C06\u5E9F\u5F03 \u8BF7\u4F7F\u7528seriesField\u66FF\u4EE3"}],i),K(t)||(i.minBarWidth=t,i.maxBarWidth=t),i},ZEt=Qt(Gh,"BarChart",K_),QEt=Qt(Gh,"StackedBarChart",function(e){return ft(e,{isStack:!0}),K_(e)}),KEt=globalThis&&globalThis.__rest||function(e,r){var t={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&r.indexOf(i)<0&&(t[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,i=Object.getOwnPropertySymbols(e);n<i.length;n++)r.indexOf(i[n])<0&&Object.prototype.propertyIsEnumerable.call(e,i[n])&&(t[i[n]]=e[i[n]]);return t},JEt=[{sourceKey:"colorField",targetKey:"seriesField",notice:"colorField \u662F g2@1.0\u7684\u5C5E\u6027\uFF0C\u5373\u5C06\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528seriesField\u66FF\u4EE3"}],tFt=Qt(Gh,"GroupedBarChart",function(e){var r=He(e),t=r.barSize,i=KEt(r,["barSize"]);return $a(JEt,i),K(t)||(i.minBarWidth=t,i.maxBarWidth=t),ft(e,{isGroup:!0}),i}),eFt=Qt(Gh,"PercentStackedBarChart",function(e){return ft(e,{isPercent:!0,isStack:!0}),K_(e)}),rFt=Qt(Gh,"RangeBarChart",function(e){return ft(e,{isRange:!0}),K_(e)}),pP={},W4={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.adaptor=e.meta=void 0;var r=V,t=Y,i=Qe,n=mt,a=Lr,o=mt,l=_n,s=dn;Object.defineProperty(e,"meta",{enumerable:!0,get:function(){return s.meta}});function u(v){var d=v.chart,p=v.options,x=p.data,m=p.areaStyle,_=p.color,b=p.point,w=p.line,S=p.isPercent,M=p.xField,F=p.yField,O=p.tooltip,L=p.seriesField,D=p.startOnZero,k=b==null?void 0:b.state,H=l.getDataWhetherPecentage(x,F,M,F,S);d.data(H);var B=S?r.__assign({formatter:function(G){return{name:G[L]||G[M],value:(Number(G[F])*100).toFixed(2)+"%"}}},O):O,j=o.deepAssign({},v,{options:{area:{color:_,style:m},line:w&&r.__assign({color:_},w),point:b&&r.__assign({color:_},b),tooltip:B,label:void 0,args:{startOnZero:D}}}),U=o.deepAssign({options:{line:{size:2}}},j,{options:{sizeField:L,tooltip:!1}}),R=o.deepAssign({},j,{options:{tooltip:!1,state:k}});return a.area(j),a.line(U),a.point(R),v}function c(v){var d=v.chart,p=v.options,x=p.label,m=p.yField,_=n.findGeometry(d,"area");if(!x)_.label(!1);else{var b=x.callback,w=r.__rest(x,["callback"]);_.label({fields:[m],callback:b,cfg:r.__assign({layout:[{type:"limit-in-plot"},{type:"path-adjust-position"},{type:"point-adjust-position"},{type:"limit-in-plot",cfg:{action:"hide"}}]},o.transformLabel(w))})}return v}function f(v){var d=v.chart,p=v.options,x=p.isStack,m=p.isPercent,_=p.seriesField;return(m||x)&&_&&t.each(d.geometries,function(b){b.adjust("stack")}),v}function h(v){return o.flow(i.theme,i.pattern("areaStyle"),u,s.meta,f,s.axis,s.legend,i.tooltip,c,i.slider,i.annotation(),i.interaction,i.animation,i.limitInPlot)(v)}e.adaptor=h})(W4);var J_={};Object.defineProperty(J_,"__esModule",{value:!0});J_.DEFAULT_OPTIONS=void 0;var iFt=ae,nFt=mt;J_.DEFAULT_OPTIONS=nFt.deepAssign({},iFt.Plot.getDefaultOptions(),{tooltip:{shared:!0,showMarkers:!0,showCrosshairs:!0,crosshairs:{type:"x"}},isStack:!0,line:{},legend:{position:"top-left"}});Object.defineProperty(pP,"__esModule",{value:!0});var tb=pP.Area=void 0,aFt=V,oFt=ae,lFt=_n,bN=W4,sFt=J_,uFt=function(e){aFt.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="area",t}return r.getDefaultOptions=function(){return sFt.DEFAULT_OPTIONS},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.changeData=function(t){this.updateOption({data:t});var i=this.options,n=i.isPercent,a=i.xField,o=i.yField,l=this,s=l.chart,u=l.options;bN.meta({chart:s,options:u}),this.chart.changeData(lFt.getDataWhetherPecentage(t,o,a,o,n))},r.prototype.getSchemaAdaptor=function(){return bN.adaptor},r}(oFt.Plot);tb=pP.Area=uFt;var gP=function(e){var r=He(e);return Fr(r,"line"),Fr(r,"point"),r.isStack=K(r.isStack)?!1:r.isStack,$a([{sourceKey:"stackField",targetKey:"seriesField",notice:"stackField\u662F\u65E7\u7248api\uFF0C\u5373\u5C06\u5E9F\u5F03 \u8BF7\u4F7F\u7528seriesField\u66FF\u4EE3"}],r),r},cFt=Qt(tb,"AreaChart",gP),fFt=Qt(tb,"StackedAreaChart",function(e){return ft(e,{isStack:!0}),gP(e)}),hFt=Qt(tb,"PercentStackedAreaChart",function(e){return ft(e,{isPercent:!0}),gP(e)}),yP={},eb={};Object.defineProperty(eb,"__esModule",{value:!0});eb.DEFAULT_OPTIONS=void 0;var vFt=ae,dFt=mt;eb.DEFAULT_OPTIONS=dFt.deepAssign({},vFt.Plot.getDefaultOptions(),{columnWidthRatio:.6,marginRatio:1/32,tooltip:{shared:!0,showMarkers:!1,offset:20},interactions:[{type:"active-region"}]});Object.defineProperty(yP,"__esModule",{value:!0});var zh=yP.Column=void 0,pFt=V,gFt=ae,yFt=_n,wN=Aa,mFt=eb,xFt=function(e){pFt.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="column",t}return r.getDefaultOptions=function(){return mFt.DEFAULT_OPTIONS},r.prototype.changeData=function(t){this.updateOption({data:t});var i=this.options,n=i.yField,a=i.xField,o=i.isPercent,l=this,s=l.chart,u=l.options;wN.meta({chart:s,options:u}),this.chart.changeData(yFt.getDataWhetherPecentage(t,n,a,n,o))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return wN.adaptor},r}(gFt.Plot);zh=yP.Column=xFt;var _Ft=globalThis&&globalThis.__rest||function(e,r){var t={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&r.indexOf(i)<0&&(t[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,i=Object.getOwnPropertySymbols(e);n<i.length;n++)r.indexOf(i[n])<0&&Object.prototype.propertyIsEnumerable.call(e,i[n])&&(t[i[n]]=e[i[n]]);return t},bFt=[{sourceKey:"colorField",targetKey:"seriesField",notice:"colorField \u662F g2@1.0\u7684\u5C5E\u6027\uFF0C\u5373\u5C06\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528seriesField\u66FF\u4EE3"},{sourceKey:"stackField",targetKey:"seriesField",notice:"colorField\u662F\u65E7\u7248API\uFF0C\u5373\u5C06\u5E9F\u5F03 \u8BF7\u4F7F\u7528seriesField\u66FF\u4EE3"}],rb=function(e){var r=He(e),t=r.columnSize,i=_Ft(r,["columnSize"]);return $a(bFt,i),K(t)||(i.minColumnWidth=t,i.maxColumnWidth=t),i},wFt=Qt(zh,"ColumnChart",rb),CFt=globalThis&&globalThis.__rest||function(e,r){var t={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&r.indexOf(i)<0&&(t[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,i=Object.getOwnPropertySymbols(e);n<i.length;n++)r.indexOf(i[n])<0&&Object.prototype.propertyIsEnumerable.call(e,i[n])&&(t[i[n]]=e[i[n]]);return t},SFt=Qt(zh,"GroupedColumnChart",function(e){var r=He(e),t=r.columnSize,i=CFt(r,["columnSize"]);return K(t)||(i.minColumnWidth=t,i.maxColumnWidth=t),ft(e,{isGroup:!0}),i}),AFt=Qt(zh,"StackedColumnChart",function(e){return ft(e,{isStack:!0}),rb(e)}),TFt=Qt(zh,"RangeColumnChart",function(e){return ft(e,{isRange:!0}),rb(e)}),MFt=Qt(zh,"PercentStackedColumnChart",function(e){return ft(e,{isPercent:!0,isStack:!0}),rb(e)}),mP={},oo={},Sg={};Object.defineProperty(Sg,"__esModule",{value:!0});Sg.DEFAULT_OPTIONS=void 0;var EFt=ae,FFt=mt;Sg.DEFAULT_OPTIONS=FFt.deepAssign({},EFt.Plot.getDefaultOptions(),{legend:{position:"right"},tooltip:{shared:!1,showTitle:!1,showMarkers:!1},label:{layout:{type:"limit-in-plot",cfg:{action:"ellipsis"}}},pieStyle:{stroke:"white",lineWidth:1},statistic:{title:{style:{fontWeight:300,color:"#4B535E",textAlign:"center",fontSize:"20px",lineHeight:1}},content:{style:{fontWeight:"bold",color:"rgba(44,53,66,0.85)",textAlign:"center",fontSize:"32px",lineHeight:1}}},theme:{components:{annotation:{text:{animate:!1}}}}});var tl={};Object.defineProperty(tl,"__esModule",{value:!0});tl.isAllZero=tl.adaptOffset=tl.getTotalValue=void 0;var Ix=Y,OFt=mt;function PFt(e,r){var t=null;return Ix.each(e,function(i){typeof i[r]=="number"&&(t+=i[r])}),t}tl.getTotalValue=PFt;function IFt(e,r){var t;switch(e){case"inner":return t="-30%",Ix.isString(r)&&r.endsWith("%")?parseFloat(r)*.01>0?t:r:r<0?r:t;case"outer":return t=12,Ix.isString(r)&&r.endsWith("%")?parseFloat(r)*.01<0?t:r:r>0?r:t;default:return r}}tl.adaptOffset=IFt;function LFt(e,r){return Ix.every(OFt.processIllegalData(e,r),function(t){return t[r]===0})}tl.isAllZero=LFt;var X4={},ib={},Ag={};Object.defineProperty(Ag,"__esModule",{value:!0});Ag.transform=void 0;var CN=V,DFt=me,$Ft=[1,0,0,0,1,0,0,0,1];function kFt(e,r){var t=r?CN.__spreadArrays(r):CN.__spreadArrays($Ft);return DFt.Util.transform(t,e)}Ag.transform=kFt;Object.defineProperty(ib,"__esModule",{value:!0});ib.PieLegendAction=void 0;var RFt=V,NS=me,BFt=Y,SN=Ag,NFt=function(e){RFt.__extends(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getActiveElements=function(){var t=NS.Util.getDelegationObject(this.context);if(t){var i=this.context.view,n=t.component,a=t.item,o=n.get("field");if(o){var l=i.geometries[0].elements;return l.filter(function(s){return s.getModel().data[o]===a.value})}}return[]},r.prototype.getActiveElementLabels=function(){var t=this.context.view,i=this.getActiveElements(),n=t.geometries[0].labelsContainer.getChildren();return n.filter(function(a){return i.find(function(o){return BFt.isEqual(o.getData(),a.get("data"))})})},r.prototype.transfrom=function(t){t===void 0&&(t=7.5);var i=this.getActiveElements(),n=this.getActiveElementLabels();i.forEach(function(a,o){var l=n[o],s=a.geometry.coordinate;if(s.isPolar&&s.isTransposed){var u=NS.Util.getAngle(a.getModel(),s),c=u.startAngle,f=u.endAngle,h=(c+f)/2,v=t,d=v*Math.cos(h),p=v*Math.sin(h);a.shape.setMatrix(SN.transform([["t",d,p]])),l.setMatrix(SN.transform([["t",d,p]]))}})},r.prototype.active=function(){this.transfrom()},r.prototype.reset=function(){this.transfrom(0)},r}(NS.Action);ib.PieLegendAction=NFt;var nb={},ab={};Object.defineProperty(ab,"__esModule",{value:!0});ab.getCurrentElement=void 0;function GFt(e){var r=e.event,t,i=r.target;return i&&(t=i.get("element")),t}ab.getCurrentElement=GFt;Object.defineProperty(nb,"__esModule",{value:!0});nb.StatisticAction=void 0;var zFt=V,AN=me,Lv=Y,VFt=ba,jFt=ab,HFt=function(e){zFt.__extends(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getAnnotations=function(t){var i=t||this.context.view;return i.getController("annotation").option},r.prototype.getInitialAnnotation=function(){return this.initialAnnotation},r.prototype.init=function(){var t=this,i=this.context.view;i.removeInteraction("tooltip"),i.on("afterchangesize",function(){var n=t.getAnnotations(i);t.initialAnnotation=n})},r.prototype.change=function(t){var i=this.context,n=i.view,a=i.event;this.initialAnnotation||(this.initialAnnotation=this.getAnnotations());var o=Lv.get(a,["data","data"]);if(a.type.match("legend-item")){var l=AN.Util.getDelegationObject(this.context),s=n.getGroupedFields()[0];if(l&&s){var u=l.item;o=n.getData().find(function(v){return v[s]===u.value})}}if(o){var c=Lv.get(t,"annotations",[]),f=Lv.get(t,"statistic",{});n.getController("annotation").clear(!0),Lv.each(c,function(v){typeof v=="object"&&n.annotation()[v.type](v)}),VFt.renderStatistic(n,{statistic:f,plotType:"pie"},o),n.render(!0)}var h=jFt.getCurrentElement(this.context);h&&h.shape.toFront()},r.prototype.reset=function(){var t=this.context.view,i=t.getController("annotation");i.clear(!0);var n=this.getInitialAnnotation();Lv.each(n,function(a){t.annotation()[a.type](a)}),t.render(!0)},r}(AN.Action);nb.StatisticAction=HFt;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.PIE_STATISTIC=void 0;var r=me,t=ib,i=nb;e.PIE_STATISTIC="pie-statistic",r.registerAction(e.PIE_STATISTIC,i.StatisticAction),r.registerInteraction("pie-statistic-active",{start:[{trigger:"element:mouseenter",action:"pie-statistic:change"}],end:[{trigger:"element:mouseleave",action:"pie-statistic:reset"}]}),r.registerAction("pie-legend",t.PieLegendAction),r.registerInteraction("pie-legend-active",{start:[{trigger:"legend-item:mouseenter",action:"pie-legend:active"}],end:[{trigger:"legend-item:mouseleave",action:"pie-legend:reset"}]})})(X4);Object.defineProperty(oo,"__esModule",{value:!0});oo.adaptor=oo.interaction=oo.pieAnnotation=oo.transformStatisticOptions=void 0;var Ho=V,Ai=Y,ed=Qe,YFt=_r,TN=Lr,WFt=$s,XFt=_s,Mi=mt,UFt=Sg,ob=tl,qFt=X4;function ZFt(e){var r=e.chart,t=e.options,i=t.data,n=t.angleField,a=t.colorField,o=t.color,l=t.pieStyle,s=Mi.processIllegalData(i,n);if(ob.isAllZero(s,n)){var u="$$percentage$$";s=s.map(function(f){var h;return Ho.__assign(Ho.__assign({},f),(h={},h[u]=1/s.length,h))}),r.data(s);var c=Mi.deepAssign({},e,{options:{xField:"1",yField:u,seriesField:a,isStack:!0,interval:{color:o,style:l},args:{zIndexReversed:!0}}});TN.interval(c)}else{r.data(s);var c=Mi.deepAssign({},e,{options:{xField:"1",yField:n,seriesField:a,isStack:!0,interval:{color:o,style:l},args:{zIndexReversed:!0}}});TN.interval(c)}return e}function QFt(e){var r,t=e.chart,i=e.options,n=i.meta,a=i.colorField,o=Mi.deepAssign({},n);return t.scale(o,(r={},r[a]={type:"cat"},r)),e}function KFt(e){var r=e.chart,t=e.options,i=t.radius,n=t.innerRadius,a=t.startAngle,o=t.endAngle;return r.coordinate({type:"theta",cfg:{radius:i,innerRadius:n,startAngle:a,endAngle:o}}),e}function JFt(e){var r=e.chart,t=e.options,i=t.label,n=t.colorField,a=t.angleField,o=r.geometries[0];if(!i)o.label(!1);else{var l=i.callback,s=Ho.__rest(i,["callback"]),u=Mi.transformLabel(s);if(u.content){var c=u.content;u.content=function(d,p,x){var m=d[n],_=d[a],b=r.getScaleByField(a),w=b==null?void 0:b.scale(_);return Ai.isFunction(c)?c(Ho.__assign(Ho.__assign({},d),{percent:w}),p,x):Ai.isString(c)?Mi.template(c,{value:_,name:m,percentage:Ai.isNumber(w)&&!Ai.isNil(_)?(w*100).toFixed(2)+"%":null}):c}}var f={inner:"",outer:"pie-outer",spider:"pie-spider"},h=u.type?f[u.type]:"pie-outer",v=u.layout?Ai.isArray(u.layout)?u.layout:[u.layout]:[];u.layout=(h?[{type:h}]:[]).concat(v),o.label({fields:n?[a,n]:[a],callback:l,cfg:Ho.__assign(Ho.__assign({},u),{offset:ob.adaptOffset(u.type,u.offset),type:"pie"})})}return e}function xP(e){var r=e.innerRadius,t=e.statistic,i=e.angleField,n=e.colorField,a=e.meta,o=e.locale,l=XFt.getLocale(o);if(r&&t){var s=Mi.deepAssign({},UFt.DEFAULT_OPTIONS.statistic,t),u=s.title,c=s.content;return u!==!1&&(u=Mi.deepAssign({},{formatter:function(f){return f?f[n]:Ai.isNil(u.content)?l.get(["statistic","total"]):u.content}},u)),c!==!1&&(c=Mi.deepAssign({},{formatter:function(f,h){var v=f?f[i]:ob.getTotalValue(h,i),d=Ai.get(a,[i,"formatter"])||function(p){return p};return f||Ai.isNil(c.content)?d(v):c.content}},c)),Mi.deepAssign({},{statistic:{title:u,content:c}},e)}return e}oo.transformStatisticOptions=xP;function U4(e){var r=e.chart,t=e.options,i=xP(t),n=i.innerRadius,a=i.statistic;return r.getController("annotation").clear(!0),Mi.flow(ed.annotation())(e),n&&a&&Mi.renderStatistic(r,{statistic:a,plotType:"pie"}),e}oo.pieAnnotation=U4;function tOt(e){var r=e.chart,t=e.options,i=t.tooltip,n=t.colorField,a=t.angleField,o=t.data;if(i===!1)r.tooltip(i);else if(r.tooltip(Mi.deepAssign({},i,{shared:!1})),ob.isAllZero(o,a)){var l=Ai.get(i,"fields"),s=Ai.get(i,"formatter");Ai.isEmpty(Ai.get(i,"fields"))&&(l=[n,a],s=s||function(u){return{name:u[n],value:Ai.toString(u[a])}}),r.geometries[0].tooltip(l.join("*"),YFt.getMappingFunction(l,s))}return e}function q4(e){var r=e.chart,t=e.options,i=xP(t),n=i.interactions,a=i.statistic,o=i.annotations;return Ai.each(n,function(l){var s,u;if(l.enable===!1)r.removeInteraction(l.type);else if(l.type==="pie-statistic-active"){var c=[];!((s=l.cfg)===null||s===void 0)&&s.start||(c=[{trigger:"element:mouseenter",action:qFt.PIE_STATISTIC+":change",arg:{statistic:a,annotations:o}}]),Ai.each((u=l.cfg)===null||u===void 0?void 0:u.start,function(f){c.push(Ho.__assign(Ho.__assign({},f),{arg:{statistic:a,annotations:o}}))}),r.interaction(l.type,Mi.deepAssign({},l.cfg,{start:c}))}else r.interaction(l.type,l.cfg||{})}),e}oo.interaction=q4;function eOt(e){return Mi.flow(WFt.pattern("pieStyle"),ZFt,QFt,ed.theme,KFt,ed.legend,tOt,JFt,ed.state,U4,q4,ed.animation)(e)}oo.adaptor=eOt;Object.defineProperty(mP,"__esModule",{value:!0});var _P=mP.Pie=void 0,rOt=V,Xc=me,iOt=ae,MN=mt,EN=oo,nOt=Sg,FN=tl,aOt=function(e){rOt.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="pie",t}return r.getDefaultOptions=function(){return nOt.DEFAULT_OPTIONS},r.prototype.changeData=function(t){this.chart.emit(Xc.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_DATA,Xc.Event.fromData(this.chart,Xc.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_DATA,null));var i=this.options,n=this.options.angleField,a=MN.processIllegalData(i.data,n),o=MN.processIllegalData(t,n);FN.isAllZero(a,n)||FN.isAllZero(o,n)?this.update({data:t}):(this.updateOption({data:t}),this.chart.data(o),EN.pieAnnotation({chart:this.chart,options:this.options}),this.chart.render(!0)),this.chart.emit(Xc.VIEW_LIFE_CIRCLE.AFTER_CHANGE_DATA,Xc.Event.fromData(this.chart,Xc.VIEW_LIFE_CIRCLE.AFTER_CHANGE_DATA,null))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return EN.adaptor},r}(iOt.Plot);_P=mP.Pie=aOt;var oOt=Qt(_P,"PieChart",He),bP={},lb={};Object.defineProperty(lb,"__esModule",{value:!0});lb.adaptor=void 0;var lOt=V,sOt=Y,Z4=mt,wP=mt,Rl=Qe,uOt=_r,cOt=Li;function fOt(e){var r=e.chart,t=e.options,i=t.data,n=t.type,a=t.xField,o=t.yField,l=t.colorField,s=t.sizeField,u=t.sizeRatio,c=t.shape,f=t.color,h=t.tooltip,v=t.heatmapStyle;r.data(i);var d="polygon";n==="density"&&(d="heatmap");var p=cOt.getTooltipMapping(h,[a,o,l]),x=p.fields,m=p.formatter,_=1;return(u||u===0)&&(!c&&!s?console.warn("sizeRatio is not in effect: Must define shape or sizeField first"):u<0||u>1?console.warn("sizeRatio is not in effect: It must be a number in [0,1]"):_=u),uOt.geometry(Z4.deepAssign({},e,{options:{type:d,colorField:l,tooltipFields:x,shapeField:s||"",label:void 0,mapping:{tooltip:m,shape:c&&(s?function(b){var w=i.map(function(F){return F[s]}),S=Math.min.apply(Math,w),M=Math.max.apply(Math,w);return[c,(sOt.get(b,s)-S)/(M-S),_]}:function(){return[c,1,_]}),color:f||l&&r.getTheme().sequenceColors.join("-"),style:v}}})),e}function hOt(e){var r,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.yField;return wP.flow(Rl.scale((r={},r[a]=i,r[o]=n,r)))(e)}function vOt(e){var r=e.chart,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.yField;return i===!1?r.axis(a,!1):r.axis(a,i),n===!1?r.axis(o,!1):r.axis(o,n),e}function dOt(e){var r=e.chart,t=e.options,i=t.legend,n=t.colorField,a=t.sizeField,o=t.sizeLegend,l=i!==!1;return n&&r.legend(n,l?i:!1),a&&r.legend(a,o===void 0?i:o),!l&&!o&&r.legend(!1),e}function pOt(e){var r=e.chart,t=e.options,i=t.label,n=t.colorField,a=t.type,o=Z4.findGeometry(r,a==="density"?"heatmap":"polygon");if(!i)o.label(!1);else if(n){var l=i.callback,s=lOt.__rest(i,["callback"]);o.label({fields:[n],callback:l,cfg:wP.transformLabel(s)})}return e}function gOt(e){var r=e.chart,t=e.options,i=t.coordinate,n=t.reflect;return i&&r.coordinate({type:i.type||"rect",cfg:i.cfg}),n&&r.coordinate().reflect(n),e}function yOt(e){return wP.flow(Rl.theme,Rl.pattern("heatmapStyle"),hOt,gOt,fOt,vOt,dOt,Rl.tooltip,pOt,Rl.annotation(),Rl.interaction,Rl.animation,Rl.state)(e)}lb.adaptor=yOt;var sb={};Object.defineProperty(sb,"__esModule",{value:!0});sb.DEFAULT_OPTIONS=void 0;var mOt=ae,xOt=mt;sb.DEFAULT_OPTIONS=xOt.deepAssign({},mOt.Plot.getDefaultOptions(),{type:"polygon",legend:!1,coordinate:{type:"rect"},xAxis:{tickLine:null,line:null,grid:{alignTick:!1,line:{style:{lineWidth:1,lineDash:null,stroke:"#f0f0f0"}}}},yAxis:{grid:{alignTick:!1,line:{style:{lineWidth:1,lineDash:null,stroke:"#f0f0f0"}}}}});var GS=V,_Ot=me;_Ot.registerShape("polygon","circle",{draw:function(e,r){var t,i,n=e.x,a=e.y,o=this.parsePoints(e.points),l=Math.abs(o[2].x-o[1].x),s=Math.abs(o[1].y-o[0].y),u=Math.min(l,s)/2,c=Number(e.shape[1]),f=Number(e.shape[2]),h=Math.sqrt(f),v=u*h*Math.sqrt(c),d=((t=e.style)===null||t===void 0?void 0:t.fill)||e.color||((i=e.defaultStyle)===null||i===void 0?void 0:i.fill),p=r.addShape("circle",{attrs:GS.__assign(GS.__assign(GS.__assign({x:n,y:a,r:v},e.defaultStyle),e.style),{fill:d})});return p}});var zS=V,bOt=me;bOt.registerShape("polygon","square",{draw:function(e,r){var t,i,n=e.x,a=e.y,o=this.parsePoints(e.points),l=Math.abs(o[2].x-o[1].x),s=Math.abs(o[1].y-o[0].y),u=Math.min(l,s),c=Number(e.shape[1]),f=Number(e.shape[2]),h=Math.sqrt(f),v=u*h*Math.sqrt(c),d=((t=e.style)===null||t===void 0?void 0:t.fill)||e.color||((i=e.defaultStyle)===null||i===void 0?void 0:i.fill),p=r.addShape("rect",{attrs:zS.__assign(zS.__assign(zS.__assign({x:n-v/2,y:a-v/2,width:v,height:v},e.defaultStyle),e.style),{fill:d})});return p}});Object.defineProperty(bP,"__esModule",{value:!0});var ub=bP.Heatmap=void 0,wOt=V,COt=ae,SOt=lb,AOt=sb,TOt=function(e){wOt.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="heatmap",t}return r.getDefaultOptions=function(){return AOt.DEFAULT_OPTIONS},r.prototype.getSchemaAdaptor=function(){return SOt.adaptor},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r}(COt.Plot);ub=bP.Heatmap=TOt;var MOt=Qt(ub,"DensityHeatmapChartChart",function(e){var r=He(e);return $a([{sourceKey:"radius",targetKey:"sizeRatio",notice:"radius \u8BF7\u4F7F\u7528sizeRatio\u66FF\u4EE3"}],r),jt(r,"type","density"),r}),EOt=globalThis&&globalThis.__rest||function(e,r){var t={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&r.indexOf(i)<0&&(t[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,i=Object.getOwnPropertySymbols(e);n<i.length;n++)r.indexOf(i[n])<0&&Object.prototype.propertyIsEnumerable.call(e,i[n])&&(t[i[n]]=e[i[n]]);return t},FOt=Qt(ub,"HeatmapChart",function(e){var r=He(e),t=r.shapeType,i=EOt(r,["shapeType"]);return t&&(i.heatmapStyle=t,Df.warn(!1,"shapeType\u662Fg2plot@1.0\u7684\u5C5E\u6027\uFF0C\u5373\u5C06\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528 `heatmapStyle` \u66FF\u4EE3")),!i.shape&&i.sizeField&&(i.shape="square"),i}),CP={},sh={},yn={},as={};Object.defineProperty(as,"__esModule",{value:!0});as.functor=as.transform=as.wordCloud=void 0;var SP=Y,OOt={font:function(){return"serif"},padding:1,size:[500,500],spiral:"archimedean",timeInterval:3e3};function POt(e,r){return r=SP.assign({},OOt,r),Q4(e,r)}as.wordCloud=POt;function Q4(e,r){var t=HOt();["font","fontSize","fontWeight","padding","rotate","size","spiral","timeInterval","random"].forEach(function(s){SP.isNil(r[s])||t[s](r[s])}),t.words(e),r.imageMask&&t.createMask(r.imageMask);var i=t.start(),n=i._tags;n.forEach(function(s){s.x+=r.size[0]/2,s.y+=r.size[1]/2});var a=r.size,o=a[0],l=a[1];return n.push({text:"",value:0,x:0,y:0,opacity:0}),n.push({text:"",value:0,x:o,y:l,opacity:0}),n}as.transform=Q4;var VS=Math.PI/180,rd=1<<11>>5,P0=1<<11;function IOt(e){return e.text}function LOt(){return"serif"}function ON(){return"normal"}function DOt(e){return e.value}function $Ot(){return~~(Math.random()*2)*90}function kOt(){return 1}function ROt(e,r,t,i){if(!r.sprite){var n=e.context,a=e.ratio;n.clearRect(0,0,(rd<<5)/a,P0/a);var o=0,l=0,s=0,u=t.length;for(--i;++i<u;){r=t[i],n.save(),n.font=r.style+" "+r.weight+" "+~~((r.size+1)/a)+"px "+r.font;var c=n.measureText(r.text+"m").width*a,f=r.size<<1;if(r.rotate){var h=Math.sin(r.rotate*VS),v=Math.cos(r.rotate*VS),d=c*v,p=c*h,x=f*v,m=f*h;c=Math.max(Math.abs(d+m),Math.abs(d-m))+31>>5<<5,f=~~Math.max(Math.abs(p+x),Math.abs(p-x))}else c=c+31>>5<<5;if(f>s&&(s=f),o+c>=rd<<5&&(o=0,l+=s,s=0),l+f>=P0)break;n.translate((o+(c>>1))/a,(l+(f>>1))/a),r.rotate&&n.rotate(r.rotate*VS),n.fillText(r.text,0,0),r.padding&&(n.lineWidth=2*r.padding,n.strokeText(r.text,0,0)),n.restore(),r.width=c,r.height=f,r.xoff=o,r.yoff=l,r.x1=c>>1,r.y1=f>>1,r.x0=-r.x1,r.y0=-r.y1,r.hasText=!0,o+=c}for(var _=n.getImageData(0,0,(rd<<5)/a,P0/a).data,b=[];--i>=0;)if(r=t[i],!!r.hasText){for(var c=r.width,w=c>>5,f=r.y1-r.y0,S=0;S<f*w;S++)b[S]=0;if(o=r.xoff,o==null)return;l=r.yoff;for(var M=0,F=-1,O=0;O<f;O++){for(var S=0;S<c;S++){var L=w*O+(S>>5),D=_[(l+O)*(rd<<5)+(o+S)<<2]?1<<31-S%32:0;b[L]|=D,M|=D}M?F=O:(r.y0++,f--,O--,l++)}r.y1=r.y0+F,r.sprite=b.slice(0,(r.y1-r.y0)*w)}}}function BOt(e,r,t){t>>=5;for(var i=e.sprite,n=e.width>>5,a=e.x-(n<<4),o=a&127,l=32-o,s=e.y1-e.y0,u=(e.y+e.y0)*t+(a>>5),c,f=0;f<s;f++){c=0;for(var h=0;h<=n;h++)if((c<<l|(h<n?(c=i[f*n+h])>>>o:0))&r[u+h])return!0;u+=t}return!1}function NOt(e,r){var t=e[0],i=e[1];r.x+r.x0<t.x&&(t.x=r.x+r.x0),r.y+r.y0<t.y&&(t.y=r.y+r.y0),r.x+r.x1>i.x&&(i.x=r.x+r.x1),r.y+r.y1>i.y&&(i.y=r.y+r.y1)}function GOt(e,r){return e.x+e.x1>r[0].x&&e.x+e.x0<r[1].x&&e.y+e.y1>r[0].y&&e.y+e.y0<r[1].y}function K4(e){var r=e[0]/e[1];return function(t){return[r*(t*=.1)*Math.cos(t),t*Math.sin(t)]}}function zOt(e){var r=4,t=r*e[0]/e[1],i=0,n=0;return function(a){var o=a<0?-1:1;switch(Math.sqrt(1+4*o*a)-o&3){case 0:i+=t;break;case 1:n+=r;break;case 2:i-=t;break;default:n-=r;break}return[i,n]}}function PN(e){for(var r=[],t=-1;++t<e;)r[t]=0;return r}function VOt(){return document.createElement("canvas")}function gu(e){return SP.isFunction(e)?e:function(){return e}}as.functor=gu;var jOt={archimedean:K4,rectangular:zOt};function HOt(){var e=[256,256],r=LOt,t=DOt,i=ON,n=$Ot,a=kOt,o=K4,l=Math.random,s=[],u=1/0,c=IOt,f=ON,h=VOt,v={};v.start=function(){var x=e[0],m=e[1],_=d(h()),b=v.board?v.board:PN((e[0]>>5)*e[1]),w=s.length,S=[],M=s.map(function(D,k,H){return D.text=c.call(this,D,k,H),D.font=r.call(this,D,k,H),D.style=f.call(this,D,k,H),D.weight=i.call(this,D,k,H),D.rotate=n.call(this,D,k,H),D.size=~~t.call(this,D,k,H),D.padding=a.call(this,D,k,H),D}).sort(function(D,k){return k.size-D.size}),F=-1,O=v.board?[{x:0,y:0},{x,y:m}]:null;L();function L(){for(var D=Date.now();Date.now()-D<u&&++F<w;){var k=M[F];k.x=x*(l()+.5)>>1,k.y=m*(l()+.5)>>1,ROt(_,k,M,F),k.hasText&&p(b,k,O)&&(S.push(k),O?v.hasImage||NOt(O,k):O=[{x:k.x+k.x0,y:k.y+k.y0},{x:k.x+k.x1,y:k.y+k.y1}],k.x-=e[0]>>1,k.y-=e[1]>>1)}v._tags=S,v._bounds=O}return v};function d(x){x.width=x.height=1;var m=Math.sqrt(x.getContext("2d").getImageData(0,0,1,1).data.length>>2);x.width=(rd<<5)/m,x.height=P0/m;var _=x.getContext("2d");return _.fillStyle=_.strokeStyle="red",_.textAlign="center",{context:_,ratio:m}}function p(x,m,_){for(var b=m.x,w=m.y,S=Math.sqrt(e[0]*e[0]+e[1]*e[1]),M=o(e),F=l()<.5?1:-1,O,L=-F,D,k;(O=M(L+=F))&&(D=~~O[0],k=~~O[1],!(Math.min(Math.abs(D),Math.abs(k))>=S));)if(m.x=b+D,m.y=w+k,!(m.x+m.x0<0||m.y+m.y0<0||m.x+m.x1>e[0]||m.y+m.y1>e[1])&&(!_||!BOt(m,x,e[0]))&&(!_||GOt(m,_))){for(var H=m.sprite,B=m.width>>5,j=e[0]>>5,U=m.x-(B<<4),R=U&127,G=32-R,N=m.y1-m.y0,W=void 0,q=(m.y+m.y0)*j+(U>>5),tt=0;tt<N;tt++){W=0;for(var ot=0;ot<=B;ot++)x[q+ot]|=W<<G|(ot<B?(W=H[tt*B+ot])>>>R:0);q+=j}return delete m.sprite,!0}return!1}return v.createMask=function(x){var m=document.createElement("canvas"),_=e[0],b=e[1];if(!(!_||!b)){var w=_>>5,S=PN((_>>5)*b);m.width=_,m.height=b;var M=m.getContext("2d");M.drawImage(x,0,0,x.width,x.height,0,0,_,b);for(var F=M.getImageData(0,0,_,b).data,O=0;O<b;O++)for(var L=0;L<_;L++){var D=w*O+(L>>5),k=O*_+L<<2,H=F[k]>=250&&F[k+1]>=250&&F[k+2]>=250,B=H?1<<31-L%32:0;S[D]|=B}v.board=S,v.hasImage=!0}},v.timeInterval=function(x){u=x==null?1/0:x},v.words=function(x){s=x},v.size=function(x){e=[+x[0],+x[1]]},v.font=function(x){r=gu(x)},v.fontWeight=function(x){i=gu(x)},v.rotate=function(x){n=gu(x)},v.spiral=function(x){o=jOt[x]||x},v.fontSize=function(x){t=gu(x)},v.padding=function(x){a=gu(x)},v.random=function(x){l=gu(x)},v}Object.defineProperty(yn,"__esModule",{value:!0});yn.getSingleKeyValues=yn.getFontSizeMapping=yn.processImageMask=yn.getSize=yn.transform=void 0;var jS=V,op=Y,IN=ho,Pu=mt,Dv=as;function YOt(e){var r=e.options,t=e.chart,i=t,n=i.width,a=i.height,o=i.padding,l=i.appendPadding,s=i.ele,u=r.data,c=r.imageMask,f=r.wordField,h=r.weightField,v=r.colorField,d=r.wordStyle,p=r.timeInterval,x=r.random,m=r.spiral,_=r.autoFit,b=_===void 0?!0:_,w=r.placementStrategy;if(!u||!u.length)return[];var S=d.fontFamily,M=d.fontWeight,F=d.padding,O=d.fontSize,L=eX(u,h),D=[ZOt(L),QOt(L)],k=u.map(function(j){return{text:j[f],value:j[h],color:j[v],datum:j}}),H={imageMask:c,font:S,fontSize:tX(O,D),fontWeight:M,size:J4({width:n,height:a,padding:o,appendPadding:l,autoFit:b,container:s}),padding:F,timeInterval:p,random:x,spiral:m,rotate:UOt(r)};if(op.isFunction(w)){var B=k.map(function(j,U,R){return jS.__assign(jS.__assign(jS.__assign({},j),{hasText:!!j.text,font:Dv.functor(H.font)(j,U,R),weight:Dv.functor(H.fontWeight)(j,U,R),rotate:Dv.functor(H.rotate)(j,U,R),size:Dv.functor(H.fontSize)(j,U,R),style:"normal"}),w.call(t,j,U,R))});return B.push({text:"",value:0,x:0,y:0,opacity:0}),B.push({text:"",value:0,x:H.size[0],y:H.size[1],opacity:0}),B}return Dv.wordCloud(k,H)}yn.transform=YOt;function J4(e){var r=e.width,t=e.height,i=e.container,n=e.autoFit,a=e.padding,o=e.appendPadding;if(n){var l=Pu.getContainerSize(i);r=l.width,t=l.height}r=r||400,t=t||400;var s=WOt({padding:a,appendPadding:o}),u=s[0],c=s[1],f=s[2],h=s[3],v=[r-(h+c),t-(u+f)];return v}yn.getSize=J4;function WOt(e){var r=IN.normalPadding(e.padding),t=IN.normalPadding(e.appendPadding),i=r[0]+t[0],n=r[1]+t[1],a=r[2]+t[2],o=r[3]+t[3];return[i,n,a,o]}function XOt(e){return new Promise(function(r,t){if(e instanceof HTMLImageElement){r(e);return}if(op.isString(e)){var i=new Image;i.crossOrigin="anonymous",i.src=e,i.onload=function(){r(i)},i.onerror=function(){Pu.log(Pu.LEVEL.ERROR,!1,"image %s load failed !!!",e),t()};return}Pu.log(Pu.LEVEL.WARN,e===void 0,"The type of imageMask option must be String or HTMLImageElement."),t()})}yn.processImageMask=XOt;function tX(e,r){if(op.isFunction(e))return e;if(op.isArray(e)){var t=e[0],i=e[1];if(!r)return function(){return(i+t)/2};var n=r[0],a=r[1];return a===n?function(){return(i+t)/2}:function(l){var s=l.value;return(i-t)/(a-n)*(s-n)+t}}return function(){return e}}yn.getFontSizeMapping=tX;function eX(e,r){return e.map(function(t){return t[r]}).filter(function(t){return typeof t=="number"&&!isNaN(t)})}yn.getSingleKeyValues=eX;function UOt(e){var r=qOt(e),t=r.rotation,i=r.rotationSteps;if(!op.isArray(t))return t;var n=t[0],a=t[1],o=i===1?0:(a-n)/(i-1);return function(){return a===n?a:Math.floor(Math.random()*i)*o}}function qOt(e){var r=e.wordStyle.rotationSteps;return r<1&&(Pu.log(Pu.LEVEL.WARN,!1,"The rotationSteps option must be greater than or equal to 1."),r=1),{rotation:e.wordStyle.rotation,rotationSteps:r}}function ZOt(e){return Math.min.apply(Math,e)}function QOt(e){return Math.max.apply(Math,e)}var AP={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=e.WORD_CLOUD_COLOR_FIELD=void 0;var r=ae,t=mt;e.WORD_CLOUD_COLOR_FIELD="color",e.DEFAULT_OPTIONS=t.deepAssign({},r.Plot.getDefaultOptions(),{timeInterval:2e3,legend:!1,tooltip:{showTitle:!1,showMarkers:!1,showCrosshairs:!1,fields:["text","value",e.WORD_CLOUD_COLOR_FIELD],formatter:function(i){return{name:i.text,value:i.value}}},wordStyle:{fontFamily:"Verdana",fontWeight:"normal",padding:1,fontSize:[12,60],rotation:[0,90],rotationSteps:2,rotateRatio:.5}})})(AP);Object.defineProperty(sh,"__esModule",{value:!0});sh.adaptor=sh.legend=void 0;var KOt=V,LN=Y,of=Qe,TP=mt,JOt=Lr,tPt=yn,rX=AP;function ePt(e){var r=e.chart,t=e.options,i=t.colorField,n=t.color,a=tPt.transform(e);r.data(a);var o=TP.deepAssign({},e,{options:{xField:"x",yField:"y",seriesField:i&&rX.WORD_CLOUD_COLOR_FIELD,rawFields:LN.isFunction(n)&&KOt.__spreadArrays(LN.get(t,"rawFields",[]),["datum"]),point:{color:n,shape:"word-cloud"}}}),l=JOt.point(o).ext;return l.geometry.label(!1),r.coordinate().reflect("y"),r.axis(!1),e}function rPt(e){return TP.flow(of.scale({x:{nice:!1},y:{nice:!1}}))(e)}function iX(e){var r=e.chart,t=e.options,i=t.legend,n=t.colorField;return i===!1?r.legend(!1):n&&r.legend(rX.WORD_CLOUD_COLOR_FIELD,i),e}sh.legend=iX;function iPt(e){TP.flow(ePt,rPt,of.tooltip,iX,of.interaction,of.animation,of.theme,of.state)(e)}sh.adaptor=iPt;var DN=V,$N=me;$N.registerShape("point","word-cloud",{draw:function(e,r){var t=e.x,i=e.y,n=r.addShape("text",{attrs:DN.__assign(DN.__assign({},nPt(e)),{x:t,y:i})}),a=e.data.rotate;return typeof a=="number"&&$N.Util.rotate(n,a*Math.PI/180),n}});function nPt(e){return{fontSize:e.data.size,text:e.data.text,textAlign:"center",fontFamily:e.data.font,fontWeight:e.data.weight,fill:e.color||e.defaultStyle.stroke,textBaseline:"alphabetic"}}Object.defineProperty(CP,"__esModule",{value:!0});var nX=CP.WordCloud=void 0,HS=V,aPt=ae,oPt=sh,lPt=AP,kN=yn,sPt=function(e){HS.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="word-cloud",t}return r.getDefaultOptions=function(){return lPt.DEFAULT_OPTIONS},r.prototype.changeData=function(t){this.updateOption({data:t}),this.options.imageMask?this.render():this.chart.changeData(kN.transform({chart:this.chart,options:this.options}))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.render=function(){var t=this;return new Promise(function(i){var n=t.options.imageMask;if(!n){e.prototype.render.call(t),i();return}var a=function(o){t.options=HS.__assign(HS.__assign({},t.options),{imageMask:o||null}),e.prototype.render.call(t),i()};kN.processImageMask(n).then(a).catch(a)})},r.prototype.getSchemaAdaptor=function(){return oPt.adaptor},r.prototype.triggerResize=function(){var t=this;this.chart.destroyed||(this.execAdaptor(),window.setTimeout(function(){e.prototype.triggerResize.call(t)}))},r}(aPt.Plot);nX=CP.WordCloud=sPt;var GT=globalThis&&globalThis.__assign||function(){return GT=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},GT.apply(this,arguments)},RN=globalThis&&globalThis.__rest||function(e,r){var t={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&r.indexOf(i)<0&&(t[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,i=Object.getOwnPropertySymbols(e);n<i.length;n++)r.indexOf(i[n])<0&&Object.prototype.propertyIsEnumerable.call(e,i[n])&&(t[i[n]]=e[i[n]]);return t},uPt=Qt(nX,"WordCloudChart",function(e){var r=e.maskImage,t=e.wordField,i=t===void 0?"word":t,n=e.weightField,a=n===void 0?"weight":n,o=e.colorField,l=o===void 0?"word":o,s=e.selected,u=e.shuffle,c=e.interactions,f=c===void 0?[{type:"element-active"}]:c,h=e.onGetG2Instance,v=e.tooltip,d=e.wordStyle,p=e.onWordCloudHover,x=e.onWordCloudClick,m=RN(e,["maskImage","wordField","weightField","colorField","selected","shuffle","interactions","onGetG2Instance","tooltip","wordStyle","onWordCloudHover","onWordCloudClick"]),_=d.active,b=RN(d,["active"]);return GT({colorField:l,wordField:i,weightField:a,imageMask:r,random:u,interactions:f,wordStyle:b,tooltip:v&&!v.visible?!1:v,onGetG2Instance:function(w){if(h&&h(w),s>=0){var S=w.chart,M=rs();_&&Object.assign(M.geometries.point["hollow-circle"].active.style,_),S.on("afterrender",function(){S.geometries.length&&S.geometries[0].elements.forEach(function(F,O){O===s&&F.setState("active",!0)})}),S.on("plot:mousemove",function(F){if(!F.data){p&&p(void 0,void 0,F.event);return}var O=F.data.data,L=O.datum,D=O.x,k=O.y,H=O.width,B=O.height;p&&p(L,{x:D,y:k,w:H,h:B},F.event)}),S.on("plot:click",function(F){if(!F.data){x&&x(void 0,void 0,F.event);return}var O=F.data.data,L=O.datum,D=O.x,k=O.y,H=O.width,B=O.height;x&&x(L,{x:D,y:k,w:H,h:B},F.event)})}}},m)}),MP={},uh={};Object.defineProperty(uh,"__esModule",{value:!0});uh.adaptor=uh.legend=void 0;var cPt=V,YS=Y,Zl=mt,Bl=Qe,fPt=Lr;function hPt(e){var r=e.chart,t=e.options,i=t.data,n=t.sectorStyle,a=t.color;return r.data(i),Zl.flow(fPt.interval)(Zl.deepAssign({},e,{options:{marginRatio:1,interval:{style:n,color:a}}})),e}function vPt(e){var r=e.chart,t=e.options,i=t.label,n=t.xField,a=Zl.findGeometry(r,"interval");if(i===!1)a.label(!1);else if(YS.isObject(i)){var o=i.callback,l=i.fields,s=cPt.__rest(i,["callback","fields"]),u=s.offset,c=s.layout;(u===void 0||u>=0)&&(c=c?YS.isArray(c)?c:[c]:[],s.layout=YS.filter(c,function(f){return f.type!=="limit-in-shape"}),s.layout.length||delete s.layout),a.label({fields:l||[n],callback:o,cfg:Zl.transformLabel(s)})}else Zl.log(Zl.LEVEL.WARN,i===null,"the label option must be an Object."),a.label({fields:[n]});return e}function aX(e){var r=e.chart,t=e.options,i=t.legend,n=t.seriesField;return i===!1?r.legend(!1):n&&r.legend(n,i),e}uh.legend=aX;function dPt(e){var r=e.chart,t=e.options,i=t.radius,n=t.innerRadius,a=t.startAngle,o=t.endAngle;return r.coordinate({type:"polar",cfg:{radius:i,innerRadius:n,startAngle:a,endAngle:o}}),e}function pPt(e){var r,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.yField;return Zl.flow(Bl.scale((r={},r[a]=i,r[o]=n,r)))(e)}function gPt(e){var r=e.chart,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.yField;return i?r.axis(a,i):r.axis(a,!1),n?r.axis(o,n):r.axis(o,!1),e}function yPt(e){Zl.flow(Bl.pattern("sectorStyle"),hPt,pPt,vPt,dPt,gPt,aX,Bl.tooltip,Bl.interaction,Bl.animation,Bl.theme,Bl.annotation(),Bl.state)(e)}uh.adaptor=yPt;var cb={};Object.defineProperty(cb,"__esModule",{value:!0});cb.DEFAULT_OPTIONS=void 0;var mPt=ae,xPt=mt;cb.DEFAULT_OPTIONS=xPt.deepAssign({},mPt.Plot.getDefaultOptions(),{xAxis:!1,yAxis:!1,legend:{position:"right"},sectorStyle:{stroke:"#fff",lineWidth:1},label:{layout:{type:"limit-in-shape"}},tooltip:{shared:!0,showMarkers:!1},interactions:[{type:"active-region"}]});Object.defineProperty(MP,"__esModule",{value:!0});var fb=MP.Rose=void 0,_Pt=V,bPt=ae,wPt=uh,CPt=cb,SPt=function(e){_Pt.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="rose",t}return r.getDefaultOptions=function(){return CPt.DEFAULT_OPTIONS},r.prototype.changeData=function(t){this.updateOption({data:t}),this.chart.changeData(t)},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return wPt.adaptor},r}(bPt.Plot);fb=MP.Rose=SPt;var APt=[{sourceKey:"colorField",targetKey:"seriesField",notice:"colorField \u662F g2@1.0\u7684\u5C5E\u6027\uFF0C\u5373\u5C06\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528seriesField\u66FF\u4EE3"},{sourceKey:"categoryField",targetKey:"xField",notice:"categoryField \u662F g2@1.0\u7684\u5C5E\u6027\uFF0C\u5373\u5C06\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528xField\u66FF\u4EE3"},{sourceKey:"radiusField",targetKey:"yField",notice:"radiusField \u662F g2@1.0\u7684\u5C5E\u6027\uFF0C\u5373\u5C06\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528yFeild\u66FF\u4EE3"}],TPt=function(e){var r=He(e);return $a(APt,r),kt(r,"tooltip.visible")===!1&&ve(r,"tooltip",!1),kt(r,"label.visible")===!1&&ve(r,"label",!1),kt(r,"label.type")==="inner"&&(r.label.offset=-15,delete r.label.type),kt(r,"label.type")==="outer"&&delete r.label.type,r},MPt=Qt(fb,"RoseChart",TPt),oX={},ch={},Tg={},yc={};(function(e){var r;Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=e.PLOYGON_Y=e.PLOYGON_X=e.FUNNEL_TOTAL_PERCENT=e.FUNNEL_CONVERSATION=e.FUNNEL_MAPPING_VALUE=e.FUNNEL_PERCENT=void 0,e.FUNNEL_PERCENT="$$percentage$$",e.FUNNEL_MAPPING_VALUE="$$mappingValue$$",e.FUNNEL_CONVERSATION="$$conversion$$",e.FUNNEL_TOTAL_PERCENT="$$totalPercentage$$",e.PLOYGON_X="$$x$$",e.PLOYGON_Y="$$y$$",e.DEFAULT_OPTIONS={appendPadding:[0,80],minSize:0,maxSize:1,meta:(r={},r[e.FUNNEL_MAPPING_VALUE]={min:0,max:1,nice:!1},r),label:{style:{fill:"#fff",fontSize:12}},tooltip:{showTitle:!1,showMarkers:!1,shared:!1},conversionTag:{offsetX:10,offsetY:0,style:{fontSize:12,fill:"rgba(0,0,0,0.45)"}}}})(yc);var As={};Object.defineProperty(As,"__esModule",{value:!0});As.conversionTagComponent=As.transformData=void 0;var EPt=V,yu=Y,I0=yc;function FPt(e,r,t){var i=[],n=t.yField,a=t.maxSize,o=t.minSize,l=yu.get(yu.maxBy(r,n),[n]),s=yu.isNumber(a)?a:1,u=yu.isNumber(o)?o:0;return i=yu.map(e,function(c,f){var h=(c[n]||0)/l;return c[I0.FUNNEL_PERCENT]=h,c[I0.FUNNEL_MAPPING_VALUE]=(s-u)*h+u,c[I0.FUNNEL_CONVERSATION]=[yu.get(e,[f-1,n]),c[n]],c}),i}As.transformData=FPt;function OPt(e){return function(r){var t=r.chart,i=r.options,n=i.conversionTag,a=t.getOptions().data;if(n){var o=n.formatter;a.forEach(function(l,s){if(!(s<=0||Number.isNaN(l[I0.FUNNEL_MAPPING_VALUE]))){var u=e(l,s,a,{top:!0,text:{content:yu.isFunction(o)?o(l,a):o,offsetX:n.offsetX,offsetY:n.offsetY,position:"end",autoRotate:!1,style:EPt.__assign({textAlign:"start",textBaseline:"middle"},n.style)}});t.annotation().line(u)}})}return r}}As.conversionTagComponent=OPt;Object.defineProperty(Tg,"__esModule",{value:!0});Tg.basicFunnel=void 0;var BN=V,PPt=Y,lX=mt,IPt=Li,LPt=_r,L0=yc,sX=As;function DPt(e){var r=e.chart,t=e.options,i=t.data,n=i===void 0?[]:i,a=t.yField,o=t.maxSize,l=t.minSize,s=sX.transformData(n,n,{yField:a,maxSize:o,minSize:l});return r.data(s),e}function $Pt(e){var r=e.chart,t=e.options,i=t.xField,n=t.yField,a=t.color,o=t.tooltip,l=t.label,s=t.shape,u=s===void 0?"funnel":s,c=t.funnelStyle,f=t.state,h=IPt.getTooltipMapping(o,[i,n]),v=h.fields,d=h.formatter;LPt.geometry({chart:r,options:{type:"interval",xField:i,yField:L0.FUNNEL_MAPPING_VALUE,colorField:i,tooltipFields:PPt.isArray(v)&&v.concat([L0.FUNNEL_PERCENT,L0.FUNNEL_CONVERSATION]),mapping:{shape:u,tooltip:d,color:a,style:c},label:l,state:f}});var p=lX.findGeometry(e.chart,"interval");return p.adjust("symmetric"),e}function kPt(e){var r=e.chart,t=e.options,i=t.isTransposed;return r.coordinate({type:"rect",actions:i?[]:[["transpose"],["scale",1,-1]]}),e}function RPt(e){var r=e.options,t=r.maxSize,i=function(n,a,o,l){var s=t-(t-n[L0.FUNNEL_MAPPING_VALUE])/2;return BN.__assign(BN.__assign({},l),{start:[a-.5,s],end:[a-.5,s+.05]})};return sX.conversionTagComponent(i)(e),e}function BPt(e){return lX.flow(DPt,$Pt,kPt,RPt)(e)}Tg.basicFunnel=BPt;var hb={};Object.defineProperty(hb,"__esModule",{value:!0});hb.compareFunnel=void 0;var NPt=Y,Lx=mt,GPt=Li,zPt=_r,Fd=yc,uX=As;function VPt(e){var r,t=e.chart,i=e.options,n=i.data,a=n===void 0?[]:n,o=i.yField;return t.data(a),t.scale((r={},r[o]={sync:!0},r)),e}function jPt(e){var r=e.chart,t=e.options,i=t.data,n=t.xField,a=t.yField,o=t.color,l=t.compareField,s=t.isTransposed,u=t.tooltip,c=t.maxSize,f=t.minSize,h=t.label,v=t.funnelStyle,d=t.state;return r.facet("mirror",{fields:[l],transpose:!s,padding:s?0:[32,0,0,0],eachView:function(p,x){var m=s?x.rowIndex:x.columnIndex;s||p.coordinate({type:"rect",actions:[["transpose"],["scale",m===0?-1:1,-1]]});var _=uX.transformData(x.data,i,{yField:a,maxSize:c,minSize:f});p.data(_);var b=GPt.getTooltipMapping(u,[n,a,l]),w=b.fields,S=b.formatter,M=s?{offset:m===0?10:-23,position:m===0?"bottom":"top"}:{offset:10,position:"left",style:{textAlign:m===0?"end":"start"}};zPt.geometry({chart:p,options:{type:"interval",xField:n,yField:Fd.FUNNEL_MAPPING_VALUE,colorField:n,tooltipFields:NPt.isArray(w)&&w.concat([Fd.FUNNEL_PERCENT,Fd.FUNNEL_CONVERSATION]),mapping:{shape:"funnel",tooltip:S,color:o,style:v},label:h===!1?!1:Lx.deepAssign({},M,h),state:d}})}}),e}function HPt(e){var r=e.chart,t=e.options,i=t.conversionTag,n=t.isTransposed;return r.once("beforepaint",function(){r.views.forEach(function(a,o){var l=function(s,u,c,f){var h=o===0?-1:1;return Lx.deepAssign({},f,{start:[u-.5,s[Fd.FUNNEL_MAPPING_VALUE]],end:[u-.5,s[Fd.FUNNEL_MAPPING_VALUE]+.05],text:n?{style:{textAlign:"start"}}:{offsetX:i!==!1?h*i.offsetX:0,style:{textAlign:o===0?"end":"start"}}})};uX.conversionTagComponent(l)(Lx.deepAssign({},{chart:a,options:t}))})}),e}function YPt(e){return Lx.flow(VPt,jPt,HPt)(e)}hb.compareFunnel=YPt;var vb={};Object.defineProperty(vb,"__esModule",{value:!0});vb.facetFunnel=void 0;var cX=mt,WPt=Tg;function XPt(e){var r,t=e.chart,i=e.options,n=i.data,a=n===void 0?[]:n,o=i.yField;return t.data(a),t.scale((r={},r[o]={sync:!0},r)),e}function UPt(e){var r=e.chart,t=e.options,i=t.seriesField,n=t.isTransposed;return r.facet("rect",{fields:[i],padding:[n?0:32,10,0,10],eachView:function(a,o){WPt.basicFunnel(cX.deepAssign({},e,{chart:a,options:{data:o.data}}))}}),e}function qPt(e){return cX.flow(XPt,UPt)(e)}vb.facetFunnel=qPt;var db={};Object.defineProperty(db,"__esModule",{value:!0});db.dynamicHeightFunnel=void 0;var NN=V,id=Y,ZPt=mt,hi=yc,QPt=_r,KPt=Li,JPt=As;function tIt(e){var r=e.chart,t=e.options,i=t.data,n=i===void 0?[]:i,a=t.yField,o=id.reduce(n,function(u,c){return u+(c[a]||0)},0),l=id.maxBy(n,a)[a],s=id.map(n,function(u,c){var f=[],h=[];if(u[hi.FUNNEL_TOTAL_PERCENT]=(u[a]||0)/o,c){var v=n[c-1][hi.PLOYGON_X],d=n[c-1][hi.PLOYGON_Y];f[0]=v[3],h[0]=d[3],f[1]=v[2],h[1]=d[2]}else f[0]=-.5,h[0]=1,f[1]=.5,h[1]=1;return h[2]=h[1]-u[hi.FUNNEL_TOTAL_PERCENT],f[2]=(h[2]+1)/4,h[3]=h[2],f[3]=-f[2],u[hi.PLOYGON_X]=f,u[hi.PLOYGON_Y]=h,u[hi.FUNNEL_PERCENT]=(u[a]||0)/l,u[hi.FUNNEL_CONVERSATION]=[id.get(n,[c-1,a]),u[a]],u});return r.data(s),e}function eIt(e){var r=e.chart,t=e.options,i=t.xField,n=t.yField,a=t.color,o=t.tooltip,l=t.label,s=t.funnelStyle,u=t.state,c=KPt.getTooltipMapping(o,[i,n]),f=c.fields,h=c.formatter;return QPt.geometry({chart:r,options:{type:"polygon",xField:hi.PLOYGON_X,yField:hi.PLOYGON_Y,colorField:i,tooltipFields:id.isArray(f)&&f.concat([hi.FUNNEL_PERCENT,hi.FUNNEL_CONVERSATION]),label:l,state:u,mapping:{tooltip:h,color:a,style:s}}}),e}function rIt(e){var r=e.chart,t=e.options,i=t.isTransposed;return r.coordinate({type:"rect",actions:i?[["transpose"],["reflect","x"]]:[]}),e}function iIt(e){var r=function(t,i,n,a){return NN.__assign(NN.__assign({},a),{start:[t[hi.PLOYGON_X][1],t[hi.PLOYGON_Y][1]],end:[t[hi.PLOYGON_X][1]+.05,t[hi.PLOYGON_Y][1]]})};return JPt.conversionTagComponent(r)(e),e}function nIt(e){return ZPt.flow(tIt,eIt,rIt,iIt)(e)}db.dynamicHeightFunnel=nIt;Object.defineProperty(ch,"__esModule",{value:!0});ch.adaptor=ch.meta=void 0;var GN=Y,lf=Qe,aIt=_s,Dx=mt,oIt=bg,lIt=Tg,sIt=hb,uIt=vb,cIt=db,$v=yc;function fIt(e){var r=e.options,t=r.compareField,i=r.xField,n=r.yField,a=r.locale,o=r.funnelStyle,l=r.data,s=aIt.getLocale(a),u={label:t?{fields:[i,n,t,$v.FUNNEL_PERCENT,$v.FUNNEL_CONVERSATION],formatter:function(f){return""+f[n]}}:{fields:[i,n,$v.FUNNEL_PERCENT,$v.FUNNEL_CONVERSATION],offset:0,position:"middle",formatter:function(f){return f[i]+" "+f[n]}},tooltip:{title:i,formatter:function(f){return{name:f[i],value:f[n]}}},conversionTag:{formatter:function(f){return s.get(["conversionTag","label"])+": "+oIt.conversionTagFormatter.apply(void 0,f[$v.FUNNEL_CONVERSATION])}}},c;return(t||o)&&(c=function(f){return Dx.deepAssign({},t&&{lineWidth:1,stroke:"#fff"},GN.isFunction(o)?o(f):o)}),Dx.deepAssign({options:u},e,{options:{funnelStyle:c,data:GN.clone(l)}})}function hIt(e){var r=e.options,t=r.compareField,i=r.dynamicHeight,n=r.seriesField;return n?uIt.facetFunnel(e):t?sIt.compareFunnel(e):i?cIt.dynamicHeightFunnel(e):lIt.basicFunnel(e)}function fX(e){var r,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.yField;return Dx.flow(lf.scale((r={},r[a]=i,r[o]=n,r)))(e)}ch.meta=fX;function vIt(e){var r=e.chart;return r.axis(!1),e}function dIt(e){var r=e.chart,t=e.options,i=t.legend;return i===!1?r.legend(!1):r.legend(i),e}function pIt(e){return Dx.flow(fIt,hIt,fX,vIt,lf.tooltip,lf.interaction,dIt,lf.animation,lf.theme,lf.annotation())(e)}ch.adaptor=pIt;(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Funnel=e.FUNNEL_CONVERSATION_FIELD=void 0;var r=V,t=Y,i=ae,n=mt,a=ch,o=yc;Object.defineProperty(e,"FUNNEL_CONVERSATION_FIELD",{enumerable:!0,get:function(){return o.FUNNEL_CONVERSATION}});var l=function(s){r.__extends(u,s);function u(){var c=s!==null&&s.apply(this,arguments)||this;return c.type="funnel",c}return u.getDefaultOptions=function(){return o.DEFAULT_OPTIONS},u.prototype.getDefaultOptions=function(){return u.getDefaultOptions()},u.prototype.getSchemaAdaptor=function(){return a.adaptor},u.prototype.setState=function(c,f,h){h===void 0&&(h=!0);var v=n.getAllElementsRecursively(this.chart);t.each(v,function(d){f(d.getData())&&d.setState(c,h)})},u.prototype.getStates=function(){var c=n.getAllElementsRecursively(this.chart),f=[];return t.each(c,function(h){var v=h.getData(),d=h.getStates();t.each(d,function(p){f.push({data:v,state:p,geometry:h.geometry,element:h})})}),f},u.CONVERSATION_FIELD=o.FUNNEL_CONVERSATION,u.PERCENT_FIELD=o.FUNNEL_PERCENT,u.TOTAL_PERCENT_FIELD=o.FUNNEL_TOTAL_PERCENT,u}(i.Plot);e.Funnel=l})(oX);var gIt=Qt(oX.Funnel,"FunnelChart",function(e){var r=He(e);return $a([{sourceKey:"transpose",targetKey:"isTransposed",notice:"transpose \u5373\u5C06\u5E9F\u5F03 \u8BF7\u4F7F\u7528isTransposed\u66FF\u4EE3"}],r),r}),$x=globalThis&&globalThis.__assign||function(){return $x=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},$x.apply(this,arguments)},yIt=[{sourceKey:"stackField",targetKey:"seriesField",notice:"stackField \u662F g2@1.0\u7684\u5C5E\u6027\uFF0C\u5373\u5C06\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528seriesField\u66FF\u4EE3"},{sourceKey:"categoryField",targetKey:"xField",notice:"categoryField \u662F g2@1.0\u7684\u5C5E\u6027\uFF0C\u5373\u5C06\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528xField\u66FF\u4EE3"},{sourceKey:"radiusField",targetKey:"yField",notice:"radiusField \u662F g2@1.0\u7684\u5C5E\u6027\uFF0C\u5373\u5C06\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528yFeild\u66FF\u4EE3"}],mIt=function(e){var r=He(e);return $a(yIt,r),kt(r,"tooltip.visible")===!1&&ve(r,"tooltip",!1),kt(r,"label.visible")===!1&&ve(r,"label",!1),kt(r,"label.type")==="inner"&&(r.label.offset=-15,delete r.label.type),kt(r,"label.type")==="outer"&&delete r.label.type,$x($x({},r),{isStack:!0})},xIt=Qt(fb,"StackedRoseChart",mIt),kx=globalThis&&globalThis.__assign||function(){return kx=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},kx.apply(this,arguments)},_It=[{sourceKey:"groupField",targetKey:"seriesField",notice:"groupField \u662F g2@1.0\u7684\u5C5E\u6027\uFF0C\u5373\u5C06\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528seriesField\u66FF\u4EE3"},{sourceKey:"categoryField",targetKey:"xField",notice:"categoryField \u662F g2@1.0\u7684\u5C5E\u6027\uFF0C\u5373\u5C06\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528xField\u66FF\u4EE3"},{sourceKey:"radiusField",targetKey:"yField",notice:"radiusField \u662F g2@1.0\u7684\u5C5E\u6027\uFF0C\u5373\u5C06\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528yFeild\u66FF\u4EE3"}],bIt=function(e){var r=He(e);return $a(_It,r),I(r,"label.type")==="inner"&&(r.label.offset=-15,delete r.label.type),I(r,"label.type")==="outer"&&delete r.label.type,kx(kx({},r),{isGroup:!0})},wIt=Qt(fb,"GroupedRoseChart",bIt),EP={},pb={};Object.defineProperty(pb,"__esModule",{value:!0});pb.adaptor=void 0;var zT=V,mu=Qe,WS=Lr,ju=mt;function CIt(e){var r=e.chart,t=e.options,i=t.data,n=t.lineStyle,a=t.color,o=t.point,l=t.area;r.data(i);var s=ju.deepAssign({},e,{options:{line:{style:n,color:a},point:o&&zT.__assign({color:a},o),area:l&&zT.__assign({color:a},l),label:void 0}}),u=ju.deepAssign({},s,{options:{tooltip:!1}}),c=(o==null?void 0:o.state)||t.state,f=ju.deepAssign({},s,{options:{tooltip:!1,state:c}});return WS.line(s),WS.point(f),WS.area(u),e}function SIt(e){var r,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.yField;return ju.flow(mu.scale((r={},r[a]=i,r[o]=n,r)))(e)}function AIt(e){var r=e.chart,t=e.options,i=t.radius,n=t.startAngle,a=t.endAngle;return r.coordinate("polar",{radius:i,startAngle:n,endAngle:a}),e}function TIt(e){var r=e.chart,t=e.options,i=t.xField,n=t.xAxis,a=t.yField,o=t.yAxis;return r.axis(i,n),r.axis(a,o),e}function MIt(e){var r=e.chart,t=e.options,i=t.label,n=t.yField,a=ju.findGeometry(r,"line");if(!i)a.label(!1);else{var o=i.callback,l=zT.__rest(i,["callback"]);a.label({fields:[n],callback:o,cfg:ju.transformLabel(l)})}return e}function EIt(e){return ju.flow(CIt,SIt,mu.theme,AIt,TIt,mu.legend,mu.tooltip,MIt,mu.interaction,mu.animation,mu.annotation())(e)}pb.adaptor=EIt;var fh={};Object.defineProperty(fh,"__esModule",{value:!0});fh.RadarTooltipAction=fh.RadarTooltipController=void 0;var sf=V,Rx=me,zN=Y,hX=function(e){sf.__extends(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return Object.defineProperty(r.prototype,"name",{get:function(){return"radar-tooltip"},enumerable:!1,configurable:!0}),r.prototype.getTooltipItems=function(t){var i=this.getTooltipCfg(),n=i.shared,a=i.title,o=e.prototype.getTooltipItems.call(this,t);if(o.length>0){var l=this.view.geometries[0],s=l.dataArray,u=o[0].name,c=[];return s.forEach(function(f){f.forEach(function(h){var v=Rx.Util.getTooltipItems(h,l),d=v[0];if(!n&&d&&d.name===u){var p=zN.isNil(a)?u:a;c.push(sf.__assign(sf.__assign({},d),{name:d.title,title:p}))}else if(n&&d){var p=zN.isNil(a)?d.name||u:a;c.push(sf.__assign(sf.__assign({},d),{name:d.title,title:p}))}})}),c}return[]},r}(Rx.TooltipController);fh.RadarTooltipController=hX;Rx.registerComponentController("radar-tooltip",hX);var FIt=function(e){sf.__extends(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.init=function(){var t=this.context.view;t.removeInteraction("tooltip")},r.prototype.show=function(){var t=this.context.event,i=this.getTooltipController();i.showTooltip({x:t.x,y:t.y})},r.prototype.hide=function(){var t=this.getTooltipController();t.hideTooltip()},r.prototype.getTooltipController=function(){var t=this.context.view;return t.getController("radar-tooltip")},r}(Rx.Action);fh.RadarTooltipAction=FIt;var vX=me,OIt=fh;vX.registerAction("radar-tooltip",OIt.RadarTooltipAction);vX.registerInteraction("radar-tooltip",{start:[{trigger:"plot:mousemove",action:"radar-tooltip:show"}],end:[{trigger:"plot:mouseleave",action:"radar-tooltip:hide"}]});Object.defineProperty(EP,"__esModule",{value:!0});var dX=EP.Radar=void 0,PIt=V,IIt=ae,LIt=mt,DIt=pb,$It=function(e){PIt.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="radar",t}return r.prototype.changeData=function(t){this.updateOption({data:t}),this.chart.changeData(t)},r.prototype.getDefaultOptions=function(){return LIt.deepAssign({},e.prototype.getDefaultOptions.call(this),{xAxis:{label:{offset:15},grid:{line:{type:"line"}}},yAxis:{grid:{line:{type:"circle"}}},legend:{position:"top"},tooltip:{shared:!0,showCrosshairs:!0,showMarkers:!0,crosshairs:{type:"xy",line:{style:{stroke:"#565656",lineDash:[4]}},follow:!0}}})},r.prototype.getSchemaAdaptor=function(){return DIt.adaptor},r}(IIt.Plot);dX=EP.Radar=$It;var Od=globalThis&&globalThis.__assign||function(){return Od=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Od.apply(this,arguments)},kIt=[{sourceKey:"angleField",targetKey:"xField",notice:"angleField \u662F g2@1.0\u7684\u5C5E\u6027\uFF0C\u5373\u5C06\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528xField\u66FF\u4EE3"},{sourceKey:"radiusField",targetKey:"yField",notice:"radiusField \u662F g2@1.0\u7684\u5C5E\u6027\uFF0C\u5373\u5C06\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528yFeild\u66FF\u4EE3"},{sourceKey:"angleAxis",targetKey:"xAxis",notice:"angleAxis \u662F g2@1.0\u7684\u5C5E\u6027\uFF0C\u5373\u5C06\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528xAxis\u66FF\u4EE3"},{sourceKey:"radiusAxis",targetKey:"yAxis",notice:"radiusAxis \u662F g2@1.0\u7684\u5C5E\u6027\uFF0C\u5373\u5C06\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528yAxis\u66FF\u4EE3"}],RIt=function(e){return fi(e)||e?{fillOpacity:1,strokeOpacity:1}:{fillOpacity:0,strokeOpacity:0}},BIt=function(e){var r=kt(e,"line",{}),t=r.visible,i=r.size,n=r.style;ve(e,"lineStyle",Od(Od(Od({},n),{opacity:1,lineWidth:typeof i=="number"?i:2}),RIt(t)))},NIt=function(e){$a(kIt,e);var r=He(e);return kt(r,"area.visible")===!1&&ve(r,"area",!1),kt(r,"point.visible")===!1&&ve(r,"point",!1),BIt(r),(px(r.angleAxis)||px(r.radiusAxis))&&(r.angleAxis||(r.angleAxis={}),r.angleAxis.line=kt(r,"angleAxis.line",null),r.angleAxis.tickLine=kt(r,"angleAxis.tickLine",null)),kt(r,"tooltip.visible")===!1&&ve(r,"tooltip",!1),kt(r,"label.visible")===!1&&ve(r,"label",!1),kt(r,"yAxis.grid.line.type")==="line"&&ft(r,{xAxis:{line:null,tickLine:null}},r),r},GIt=Qt(dX,"RadarChart",NIt),FP={},hh={},Mg={};Object.defineProperty(Mg,"__esModule",{value:!0});Mg.getLiquidData=void 0;var zIt="liquid";function VIt(e){return[{percent:e,type:zIt}]}Mg.getLiquidData=VIt;Object.defineProperty(hh,"__esModule",{value:!0});hh.adaptor=hh.statistic=void 0;var VN=V,jN=Y,kv=Qe,Bx=mt,jIt=Lr,HIt=Mg;function YIt(e){var r=e.chart,t=e.options,i=t.percent,n=t.liquidStyle,a=t.radius,o=t.outline,l=t.wave,s=t.shape;r.scale({percent:{min:0,max:1}}),r.data(HIt.getLiquidData(i));var u=t.color||r.getTheme().defaultColor,c=Bx.deepAssign({},e,{options:{xField:"type",yField:"percent",widthRatio:a,interval:{color:u,style:n,shape:"liquid-fill-gauge"}}}),f=jIt.interval(c).ext,h=f.geometry,v=r.getTheme().background,d={radius:a,outline:o,wave:l,shape:s,background:v};return h.customInfo(d),r.legend(!1),r.axis(!1),r.tooltip(!1),e}function pX(e,r){var t=e.chart,i=e.options,n=i.statistic,a=i.percent,o=i.meta;t.getController("annotation").clear(!0);var l=jN.get(o,["percent","formatter"])||function(u){return(u*100).toFixed(2)+"%"},s=n.content;return s&&(s=Bx.deepAssign({},s,{content:jN.isNil(s.content)?l(a):s.content})),Bx.renderStatistic(t,{statistic:VN.__assign(VN.__assign({},n),{content:s}),plotType:"liquid"},{percent:a}),r&&t.render(!0),e}hh.statistic=pX;function WIt(e){return Bx.flow(kv.theme,kv.pattern("liquidStyle"),YIt,pX,kv.scale({}),kv.animation,kv.interaction)(e)}hh.adaptor=WIt;var gb={};Object.defineProperty(gb,"__esModule",{value:!0});gb.DEFAULT_OPTIONS=void 0;gb.DEFAULT_OPTIONS={radius:.9,statistic:{title:!1,content:{style:{opacity:.75,fontSize:"30px",lineHeight:"30px",textAlign:"center"}}},outline:{border:2,distance:0},wave:{count:3,length:192},shape:"circle"};var XIt=V,UIt=me,Pd=Y,qIt=Ag,HN=5e3;function YN(e,r,t){return e+(r-e)*t}function ZIt(e){var r=XIt.__assign({opacity:1},e.style);return e.color&&!r.fill&&(r.fill=e.color),r}function QIt(e){var r={fill:"#fff",fillOpacity:0,lineWidth:4},t=Pd.mix({},r,e.style);return e.color&&!t.stroke&&(t.stroke=e.color),Pd.isNumber(e.opacity)&&(t.opacity=t.strokeOpacity=e.opacity),t}function KIt(e,r,t,i){return r===0?[[e+1/2*t/Math.PI/2,i/2],[e+1/2*t/Math.PI,i],[e+t/4,i]]:r===1?[[e+1/2*t/Math.PI/2*(Math.PI-2),i],[e+1/2*t/Math.PI/2*(Math.PI-1),i/2],[e+t/4,0]]:r===2?[[e+1/2*t/Math.PI/2,-i/2],[e+1/2*t/Math.PI,-i],[e+t/4,-i]]:[[e+1/2*t/Math.PI/2*(Math.PI-2),-i],[e+1/2*t/Math.PI/2*(Math.PI-1),-i/2],[e+t/4,0]]}function JIt(e,r,t,i,n,a,o){for(var l=Math.ceil(2*e/t*4)*4,s=[],u=i;u<-Math.PI*2;)u+=Math.PI*2;for(;u>0;)u-=Math.PI*2;u=u/Math.PI/2*t;var c=a-e+u-e*2;s.push(["M",c,r]);for(var f=0,h=0;h<l;++h){var v=h%4,d=KIt(h*t/4,v,t,n);s.push(["C",d[0][0]+c,-d[0][1]+r,d[1][0]+c,-d[1][1]+r,d[2][0]+c,-d[2][1]+r]),h===l-1&&(f=d[2][0])}return s.push(["L",f+c,o+e]),s.push(["L",c,o+e]),s.push(["Z"]),s}function t2t(e,r,t,i,n,a,o,l,s){for(var u=n.fill,c=n.opacity,f=o.getBBox(),h=f.maxX-f.minX,v=f.maxY-f.minY,d=0;d<i;d++){var p=i<=1?0:d/(i-1),x=a.addShape("path",{name:"waterwave-path",attrs:{path:JIt(l,f.minY+v*t,s,0,h/32,e,r),fill:u,opacity:YN(.2,.9,p)*c}});try{var m=qIt.transform([["t",s,0]]);x.stopAnimate(),x.animate({matrix:m},{duration:YN(.5*HN,HN,p),repeat:!0})}catch{console.warn("off-screen group animate error!")}}}function e2t(e,r,t,i){var n=t*2/3,a=Math.max(n,i),o=n/2,l=e,s=o+r-a/2,u=Math.asin(o/((a-o)*.85)),c=Math.sin(u)*o,f=Math.cos(u)*o,h=l-f,v=s+c,d=e,p=s+o/Math.sin(u);return`
|
|
M `+h+" "+v+`
|
|
A `+o+" "+o+" 0 1 1 "+(h+f*2)+" "+v+`
|
|
Q `+d+" "+p+" "+e+" "+(r+a/2)+`
|
|
Q `+d+" "+p+" "+h+" "+v+`
|
|
Z
|
|
`}function r2t(e,r,t,i){var n=t/2,a=i/2;return`
|
|
M `+e+" "+(r-a)+`
|
|
a `+n+" "+a+" 0 1 0 0 "+a*2+`
|
|
a `+n+" "+a+" 0 1 0 0 "+-a*2+`
|
|
Z
|
|
`}function i2t(e,r,t,i){var n=i/2,a=t/2;return`
|
|
M `+e+" "+(r-n)+`
|
|
L `+(e+a)+" "+r+`
|
|
L `+e+" "+(r+n)+`
|
|
L `+(e-a)+" "+r+`
|
|
Z
|
|
`}function n2t(e,r,t,i){var n=i/2,a=t/2;return`
|
|
M `+e+" "+(r-n)+`
|
|
L `+(e+a)+" "+(r+n)+`
|
|
L `+(e-a)+" "+(r+n)+`
|
|
Z
|
|
`}function a2t(e,r,t,i){var n=.618,a=i/2,o=t/2*n;return`
|
|
M `+(e-o)+" "+(r-a)+`
|
|
L `+(e+o)+" "+(r-a)+`
|
|
L `+(e+o)+" "+(r+a)+`
|
|
L `+(e-o)+" "+(r+a)+`
|
|
Z
|
|
`}UIt.registerShape("interval","liquid-fill-gauge",{draw:function(e,r){var t=.5,i=.5,n=e.customInfo,a=n,o=a.radius,l=a.shape,s=a.background,u=n.outline,c=n.wave,f=u.border,h=u.distance,v=c.count,d=c.length,p=Pd.reduce(e.points,function(H,B){return Math.min(H,B.x)},1/0),x=this.parsePoint({x:t,y:i}),m=this.parsePoint({x:p,y:i}),_=x.x-m.x,b=Math.min(_,m.y*o),w=ZIt(e),S=QIt(Pd.mix({},e,u)),M=b-f/2,F={pin:e2t,circle:r2t,diamond:i2t,triangle:n2t,rect:a2t},O=typeof l=="function"?l:F[l]||F.circle,L=O(x.x,x.y,M*2,M*2),D=r.addGroup({name:"waves"}),k=D.setClip({type:"path",attrs:{path:L}});return t2t(x.x,x.y,1-e.points[1].y,v,w,D,k,b*2,d),r.addShape("path",{name:"distance",attrs:{path:L,fill:"transparent",lineWidth:f+h*2,stroke:s==="transparent"?"#fff":s}}),r.addShape("path",{name:"wrap",attrs:Pd.mix(S,{path:L,fill:"transparent",lineWidth:f})}),r}});Object.defineProperty(FP,"__esModule",{value:!0});var gX=FP.Liquid=void 0,o2t=V,Uc=me,l2t=ae,WN=hh,s2t=gb,u2t=Mg,c2t=function(e){o2t.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="liquid",t}return r.getDefaultOptions=function(){return s2t.DEFAULT_OPTIONS},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.changeData=function(t){this.chart.emit(Uc.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_DATA,Uc.Event.fromData(this.chart,Uc.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_DATA,null)),this.updateOption({percent:t}),this.chart.data(u2t.getLiquidData(t)),WN.statistic({chart:this.chart,options:this.options},!0),this.chart.emit(Uc.VIEW_LIFE_CIRCLE.AFTER_CHANGE_DATA,Uc.Event.fromData(this.chart,Uc.VIEW_LIFE_CIRCLE.AFTER_CHANGE_DATA,null))},r.prototype.getSchemaAdaptor=function(){return WN.adaptor},r}(l2t.Plot);gX=FP.Liquid=c2t;var VT=globalThis&&globalThis.__assign||function(){return VT=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},VT.apply(this,arguments)},f2t=globalThis&&globalThis.__rest||function(e,r){var t={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&r.indexOf(i)<0&&(t[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,i=Object.getOwnPropertySymbols(e);n<i.length;n++)r.indexOf(i[n])<0&&Object.prototype.propertyIsEnumerable.call(e,i[n])&&(t[i[n]]=e[i[n]]);return t},h2t=Qt(gX,"LiquidChart",function(e){var r=He(e);r.range;var t=r.min,i=t===void 0?0:t,n=r.max,a=n===void 0?1:n,o=r.value,l=f2t(r,["range","min","max","value"]);if(!K(o)){l.percent=o/(a-i);var s=I(l,"statistic.content.formatter");l.statistic!==null&&l.statistic!==!1&&ft(l,{statistic:{content:{formatter:function(){return pt(s)&&s(o),o}}}})}Fr(l,"statistic"),Fr(l,"statistic.title"),Fr(l,"statistic.content");var u=l.percent;return VT({data:u},l)}),OP={},Eg={};Object.defineProperty(Eg,"__esModule",{value:!0});Eg.binHistogram=void 0;var ha=Y;function XN(e,r,t){if(t===1)return[0,r];var i=Math.floor(e/r);return[r*i,r*(i+1)]}function v2t(e){return Math.ceil(Math.log(e.length)/Math.LN2)+1}function d2t(e,r,t,i,n){var a=ha.clone(e);ha.sortBy(a,r);var o=ha.valuesOfKey(a,r),l=ha.getRange(o),s=l.max-l.min,u=t;if(!t&&i&&(u=i>1?s/(i-1):l.max),!t&&!i){var c=v2t(o);u=s/c}var f={},h=ha.groupBy(a,n);ha.isEmpty(h)?ha.each(a,function(d){var p=d[r],x=XN(p,u,i),m=x[0]+"-"+x[1];ha.hasKey(f,m)||(f[m]={range:x,count:0}),f[m].count+=1}):Object.keys(h).forEach(function(d){ha.each(h[d],function(p){var x=p[r],m=XN(x,u,i),_=m[0]+"-"+m[1],b=_+"-"+d;ha.hasKey(f,b)||(f[b]={range:m,count:0},f[b][n]=d),f[b].count+=1})});var v=[];return ha.each(f,function(d){v.push(d)}),v}Eg.binHistogram=d2t;var yb={},el={};Object.defineProperty(el,"__esModule",{value:!0});el.DEFAULT_OPTIONS=el.HISTOGRAM_Y_FIELD=el.HISTOGRAM_X_FIELD=void 0;var p2t=ae,g2t=mt;el.HISTOGRAM_X_FIELD="range";el.HISTOGRAM_Y_FIELD="count";el.DEFAULT_OPTIONS=g2t.deepAssign({},p2t.Plot.getDefaultOptions(),{columnStyle:{stroke:"#FFFFFF"},tooltip:{shared:!0,showMarkers:!1},interactions:[{type:"active-region"}]});Object.defineProperty(yb,"__esModule",{value:!0});yb.adaptor=void 0;var y2t=V,uf=Qe,m2t=$s,yX=mt,PP=mt,x2t=Lr,_2t=Eg,Uo=el;function b2t(e){var r=e.chart,t=e.options,i=t.data,n=t.binField,a=t.binNumber,o=t.binWidth,l=t.color,s=t.stackField,u=t.legend,c=t.columnStyle,f=_2t.binHistogram(i,n,o,a,s);r.data(f);var h=yX.deepAssign({},e,{options:{xField:Uo.HISTOGRAM_X_FIELD,yField:Uo.HISTOGRAM_Y_FIELD,seriesField:s,isStack:!0,interval:{color:l,style:c}}});return x2t.interval(h),u&&s&&r.legend(s,u),e}function w2t(e){var r,t=e.options,i=t.xAxis,n=t.yAxis;return PP.flow(uf.scale((r={},r[Uo.HISTOGRAM_X_FIELD]=i,r[Uo.HISTOGRAM_Y_FIELD]=n,r)))(e)}function C2t(e){var r=e.chart,t=e.options,i=t.xAxis,n=t.yAxis;return i===!1?r.axis(Uo.HISTOGRAM_X_FIELD,!1):r.axis(Uo.HISTOGRAM_X_FIELD,i),n===!1?r.axis(Uo.HISTOGRAM_Y_FIELD,!1):r.axis(Uo.HISTOGRAM_Y_FIELD,n),e}function S2t(e){var r=e.chart,t=e.options,i=t.label,n=yX.findGeometry(r,"interval");if(!i)n.label(!1);else{var a=i.callback,o=y2t.__rest(i,["callback"]);n.label({fields:[Uo.HISTOGRAM_Y_FIELD],callback:a,cfg:PP.transformLabel(o)})}return e}function A2t(e){return PP.flow(uf.theme,m2t.pattern("columnStyle"),b2t,w2t,C2t,uf.state,S2t,uf.tooltip,uf.interaction,uf.animation)(e)}yb.adaptor=A2t;Object.defineProperty(OP,"__esModule",{value:!0});var mX=OP.Histogram=void 0,T2t=V,M2t=ae,E2t=Eg,F2t=yb,O2t=el,P2t=function(e){T2t.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="histogram",t}return r.getDefaultOptions=function(){return O2t.DEFAULT_OPTIONS},r.prototype.changeData=function(t){this.updateOption({data:t});var i=this.options,n=i.binField,a=i.binNumber,o=i.binWidth,l=i.stackField;this.chart.changeData(E2t.binHistogram(t,n,o,a,l))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return F2t.adaptor},r}(M2t.Plot);mX=OP.Histogram=P2t;var I2t=Qt(mX,"HistogramChart"),jT=globalThis&&globalThis.__assign||function(){return jT=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},jT.apply(this,arguments)},L2t=function(e){var r=He(e);return Fr(r,"statistic"),Fr(r,"statistic.title"),Fr(r,"statistic.content"),jT({innerRadius:.8},r)},D2t=Qt(_P,"DonutChart",L2t),IP={},vh={},Vi={};Object.defineProperty(Vi,"__esModule",{value:!0});Vi.DEFAULT_OPTIONS=Vi.IS_TOTAL=Vi.ABSOLUTE_FIELD=Vi.DIFF_FIELD=Vi.Y_FIELD=void 0;Vi.Y_FIELD="$$yField$$";Vi.DIFF_FIELD="$$diffField$$";Vi.ABSOLUTE_FIELD="$$absoluteField$$";Vi.IS_TOTAL="$$isTotal$$";Vi.DEFAULT_OPTIONS={label:{},leaderLine:{style:{lineWidth:1,stroke:"#8c8c8c",lineDash:[4,2]}},total:{style:{fill:"rgba(0, 0, 0, 0.25)"}},interactions:[{type:"element-active"}],risingFill:"#f4664a",fallingFill:"#30bf78",waterfallStyle:{fill:"rgba(0, 0, 0, 0.25)"},yAxis:{grid:{line:{style:{lineDash:[4,2]}}}}};var ic={};Object.defineProperty(ic,"__esModule",{value:!0});ic.transformData=ic.processData=void 0;var Nx=V,nd=Y,UN=mt,uu=Vi;function xX(e,r,t,i,n){var a,o=[];if(nd.reduce(e,function(s,u){var c;UN.log(UN.LEVEL.WARN,nd.isNumber(u[t]),u[t]+" is not a valid number");var f=nd.isUndefined(u[t])?null:u[t];return o.push(Nx.__assign(Nx.__assign({},u),(c={},c[i]=[s,s+f],c))),s+f},0),o.length&&n){var l=nd.get(o,[[e.length-1],i,[1]]);o.push((a={},a[r]=n.label,a[t]=l,a[i]=[0,l],a))}return o}ic.processData=xX;function $2t(e,r,t,i){var n=xX(e,r,t,uu.Y_FIELD,i);return n.map(function(a,o){var l;return nd.isObject(a)?Nx.__assign(Nx.__assign({},a),(l={},l[uu.ABSOLUTE_FIELD]=a[uu.Y_FIELD][1],l[uu.DIFF_FIELD]=a[uu.Y_FIELD][1]-a[uu.Y_FIELD][0],l[uu.IS_TOTAL]=o===e.length,l)):a})}ic.transformData=$2t;var XS=V,k2t=me,R2t=Y,B2t=mt;function N2t(e){for(var r=[],t=0;t<e.length;t++){var i=e[t];if(i){var n=t===0?"M":"L";r.push([n,i.x,i.y])}}var a=e[0];return r.push(["L",a.x,a.y]),r.push(["z"]),r}function G2t(e){return B2t.deepAssign({},e.defaultStyle,e.style,{fill:e.color})}k2t.registerShape("interval","waterfall",{draw:function(e,r){var t=e.customInfo,i=e.points,n=e.nextPoints,a=r.addGroup(),o=this.parsePath(N2t(i)),l=G2t(e);a.addShape("path",{attrs:XS.__assign(XS.__assign({},l),{path:o})});var s=R2t.get(t,"leaderLine");if(s&&n){var u=[["M",i[2].x,i[2].y],["L",n[0].x,n[0].y]];i[2].y===n[1].y&&(u[1]=["L",n[1].x,n[1].y]),u=this.parsePath(u),a.addShape("path",{attrs:XS.__assign({path:u},s.style||{})})}return a}});Object.defineProperty(vh,"__esModule",{value:!0});vh.adaptor=vh.tooltip=void 0;var _X=V,bf=Y,cf=Qe,z2t=Lr,bX=_s,rl=mt,wi=Vi,V2t=ic;function j2t(e){var r=e.options,t=r.locale,i=r.total,n=bX.getLocale(t).get(["waterfall","total"]);return i&&typeof i.label!="string"&&n&&(e.options.total.label=n),e}function H2t(e){var r=e.chart,t=e.options,i=t.data,n=t.xField,a=t.yField,o=t.total,l=t.leaderLine,s=t.columnWidthRatio,u=t.waterfallStyle,c=t.risingFill,f=t.fallingFill,h=t.color;r.data(V2t.transformData(i,n,a,o));var v=h||function(m){return bf.get(m,[wi.IS_TOTAL])?bf.get(o,["style","fill"],""):bf.get(m,[wi.Y_FIELD,1])-bf.get(m,[wi.Y_FIELD,0])>0?c:f},d=rl.deepAssign({},e,{options:{xField:n,yField:wi.Y_FIELD,seriesField:n,rawFields:[a,wi.DIFF_FIELD,wi.IS_TOTAL,wi.Y_FIELD],widthRatio:s,interval:{style:u,shape:"waterfall",color:v}}}),p=z2t.interval(d).ext,x=p.geometry;return x.customInfo({leaderLine:l}),e}function Y2t(e){var r,t,i=e.options,n=i.xAxis,a=i.yAxis,o=i.xField,l=i.yField,s=i.meta,u=rl.deepAssign({},{alias:l},bf.get(s,l));return rl.flow(cf.scale((r={},r[o]=n,r[l]=a,r[wi.Y_FIELD]=a,r),rl.deepAssign({},s,(t={},t[wi.Y_FIELD]=u,t[wi.DIFF_FIELD]=u,t[wi.ABSOLUTE_FIELD]=u,t))))(e)}function W2t(e){var r=e.chart,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.yField;return i===!1?r.axis(a,!1):r.axis(a,i),n===!1?(r.axis(o,!1),r.axis(wi.Y_FIELD,!1)):(r.axis(o,n),r.axis(wi.Y_FIELD,n)),e}function X2t(e){var r=e.chart,t=e.options,i=t.legend,n=t.total,a=t.risingFill,o=t.fallingFill,l=t.locale,s=bX.getLocale(l);if(i===!1)r.legend(!1);else{var u=[{name:s.get(["general","increase"]),value:"increase",marker:{symbol:"square",style:{r:5,fill:a}}},{name:s.get(["general","decrease"]),value:"decrease",marker:{symbol:"square",style:{r:5,fill:o}}}];n&&u.push({name:n.label||"",value:"total",marker:{symbol:"square",style:rl.deepAssign({},{r:5},bf.get(n,"style"))}}),r.legend(rl.deepAssign({},{custom:!0,position:"top",items:u},i)),r.removeInteraction("legend-filter")}return e}function U2t(e){var r=e.chart,t=e.options,i=t.label,n=t.labelMode,a=t.xField,o=rl.findGeometry(r,"interval");if(!i)o.label(!1);else{var l=i.callback,s=_X.__rest(i,["callback"]);o.label({fields:n==="absolute"?[wi.ABSOLUTE_FIELD,a]:[wi.DIFF_FIELD,a],callback:l,cfg:rl.transformLabel(s)})}return e}function wX(e){var r=e.chart,t=e.options,i=t.tooltip,n=t.xField,a=t.yField;if(i!==!1){r.tooltip(_X.__assign({showCrosshairs:!1,showMarkers:!1,shared:!0,fields:[a]},i));var o=r.geometries[0];i!=null&&i.formatter?o.tooltip(n+"*"+a,i.formatter):o.tooltip(a)}else r.tooltip(!1);return e}vh.tooltip=wX;function q2t(e){return rl.flow(j2t,cf.theme,H2t,Y2t,W2t,X2t,wX,U2t,cf.state,cf.interaction,cf.animation,cf.annotation())(e)}vh.adaptor=q2t;Object.defineProperty(IP,"__esModule",{value:!0});var CX=IP.Waterfall=void 0,Z2t=V,Q2t=ae,K2t=vh,J2t=Vi,tLt=ic,eLt=function(e){Z2t.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="waterfall",t}return r.getDefaultOptions=function(){return J2t.DEFAULT_OPTIONS},r.prototype.changeData=function(t){var i=this.options,n=i.xField,a=i.yField,o=i.total;this.updateOption({data:t}),this.chart.changeData(tLt.transformData(t,n,a,o))},r.prototype.getSchemaAdaptor=function(){return K2t.adaptor},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r}(Q2t.Plot);CX=IP.Waterfall=eLt;var rLt=Qt(CX,"WaterfallChart"),LP={},lo={},os={},Qa={exports:{}};(function(e,r){(function(t,i){i(r)})(kd,function(t){function i(B,j){return n(B)||a(B,j)||o()}function n(B){if(Array.isArray(B))return B}function a(B,j){var U=[],R=!0,G=!1,N=void 0;try{for(var W=B[Symbol.iterator](),q;!(R=(q=W.next()).done)&&(U.push(q.value),!(j&&U.length===j));R=!0);}catch(tt){G=!0,N=tt}finally{try{!R&&W.return!=null&&W.return()}finally{if(G)throw N}}return U}function o(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}function l(B,j,U,R){B=B.filter(function(dt,ht){var wt=j(dt,ht),gt=U(dt,ht);return wt!=null&&isFinite(wt)&>!=null&&isFinite(gt)}),R&&B.sort(function(dt,ht){return j(dt)-j(ht)});for(var G=B.length,N=new Float64Array(G),W=new Float64Array(G),q=0,tt=0,ot,st,Z,et=0;et<G;)Z=B[et],N[et]=ot=+j(Z,et,B),W[et]=st=+U(Z,et,B),++et,q+=(ot-q)/et,tt+=(st-tt)/et;for(var lt=0;lt<G;++lt)N[lt]-=q,W[lt]-=tt;return[N,W,q,tt]}function s(B,j,U,R){for(var G=0,N=0,W=B.length;N<W;N++){var q=B[N],tt=+j(q,N,B),ot=+U(q,N,B);tt!=null&&isFinite(tt)&&ot!=null&&isFinite(ot)&&R(tt,ot,G++)}}function u(B,j,U,R,G){var N=0,W=0;return s(B,j,U,function(q,tt){var ot=tt-G(q),st=tt-R;N+=ot*ot,W+=st*st}),1-N/W}function c(B){return Math.atan2(B[1][1]-B[0][1],B[1][0]-B[0][0])*180/Math.PI}function f(B){return[(B[0][0]+B[1][0])/2,(B[0][1]+B[1][1])/2]}function h(B,j,U){for(var R=Math.log(j-B)*Math.LOG10E+1|0,G=1*Math.pow(10,-R/2-1),N=1e4,W=[tt(B),tt(j)],q=0;ot(W)&&q<N;);return W;function tt(st){return[st,U(st)]}function ot(st){q++;for(var Z=st.length,et=!1,lt=0;lt<Z-1;lt++){var dt=st[lt],ht=st[lt+1],wt=f([dt,ht]),gt=tt(wt[0]),vt=c([dt,wt]),_t=c([dt,gt]),Bt=Math.abs(vt-_t);Bt>G&&(st.splice(lt+1,0,gt),et=!0)}return et}}function v(B,j,U,R){var G=R-B*B,N=Math.abs(G)<1e-24?0:(U-B*j)/G,W=j-N*B;return[W,N]}function d(){var B=function(N){return N[0]},j=function(N){return N[1]},U;function R(G){var N=0,W=0,q=0,tt=0,ot=0,st=0,Z=U?+U[0]:1/0,et=U?+U[1]:-1/0;s(G,B,j,function(_t,Bt){var qt=Math.log(Bt),Nt=_t*Bt;++N,W+=(Bt-W)/N,tt+=(Nt-tt)/N,st+=(_t*Nt-st)/N,q+=(Bt*qt-q)/N,ot+=(Nt*qt-ot)/N,U||(_t<Z&&(Z=_t),_t>et&&(et=_t))});var lt=v(tt/W,q/W,ot/W,st/W),dt=i(lt,2),ht=dt[0],wt=dt[1];ht=Math.exp(ht);var gt=function(Bt){return ht*Math.exp(wt*Bt)},vt=h(Z,et,gt);return vt.a=ht,vt.b=wt,vt.predict=gt,vt.rSquared=u(G,B,j,W,gt),vt}return R.domain=function(G){return arguments.length?(U=G,R):U},R.x=function(G){return arguments.length?(B=G,R):B},R.y=function(G){return arguments.length?(j=G,R):j},R}function p(){var B=function(N){return N[0]},j=function(N){return N[1]},U;function R(G){var N=0,W=0,q=0,tt=0,ot=0,st=U?+U[0]:1/0,Z=U?+U[1]:-1/0;s(G,B,j,function(vt,_t){++N,W+=(vt-W)/N,q+=(_t-q)/N,tt+=(vt*_t-tt)/N,ot+=(vt*vt-ot)/N,U||(vt<st&&(st=vt),vt>Z&&(Z=vt))});var et=v(W,q,tt,ot),lt=i(et,2),dt=lt[0],ht=lt[1],wt=function(_t){return ht*_t+dt},gt=[[st,wt(st)],[Z,wt(Z)]];return gt.a=ht,gt.b=dt,gt.predict=wt,gt.rSquared=u(G,B,j,q,wt),gt}return R.domain=function(G){return arguments.length?(U=G,R):U},R.x=function(G){return arguments.length?(B=G,R):B},R.y=function(G){return arguments.length?(j=G,R):j},R}function x(B){B.sort(function(U,R){return U-R});var j=B.length/2;return j%1===0?(B[j-1]+B[j])/2:B[Math.floor(j)]}var m=2,_=1e-12;function b(){var B=function(N){return N[0]},j=function(N){return N[1]},U=.3;function R(G){for(var N=l(G,B,j,!0),W=i(N,4),q=W[0],tt=W[1],ot=W[2],st=W[3],Z=q.length,et=Math.max(2,~~(U*Z)),lt=new Float64Array(Z),dt=new Float64Array(Z),ht=new Float64Array(Z).fill(1),wt=-1;++wt<=m;){for(var gt=[0,et-1],vt=0;vt<Z;++vt){for(var _t=q[vt],Bt=gt[0],qt=gt[1],Nt=_t-q[Bt]>q[qt]-_t?Bt:qt,pe=0,cr=0,ar=0,Ji=0,$r=0,tn=1/Math.abs(q[Nt]-_t||1),Yr=Bt;Yr<=qt;++Yr){var Wr=q[Yr],Ke=tt[Yr],At=w(Math.abs(_t-Wr)*tn)*ht[Yr],yi=Wr*At;pe+=At,cr+=yi,ar+=Ke*At,Ji+=Ke*yi,$r+=Wr*yi}var Hh=v(cr/pe,ar/pe,Ji/pe,$r/pe),_c=i(Hh,2),Yh=_c[0],bc=_c[1];lt[vt]=Yh+bc*_t,dt[vt]=Math.abs(tt[vt]-lt[vt]),S(q,vt+1,gt)}if(wt===m)break;var Bs=x(dt);if(Math.abs(Bs)<_)break;for(var dl=0,So,Ns;dl<Z;++dl)So=dt[dl]/(6*Bs),ht[dl]=So>=1?_:(Ns=1-So*So)*Ns}return M(q,lt,ot,st)}return R.bandwidth=function(G){return arguments.length?(U=G,R):U},R.x=function(G){return arguments.length?(B=G,R):B},R.y=function(G){return arguments.length?(j=G,R):j},R}function w(B){return(B=1-B*B*B)*B*B}function S(B,j,U){var R=B[j],G=U[0],N=U[1]+1;if(!(N>=B.length))for(;j>G&&B[N]-R<=R-B[G];)U[0]=++G,U[1]=N,++N}function M(B,j,U,R){for(var G=B.length,N=[],W=0,q=0,tt=[],ot;W<G;++W)ot=B[W]+U,tt[0]===ot?tt[1]+=(j[W]-tt[1])/++q:(q=0,tt[1]+=R,tt=[ot,j[W]],N.push(tt));return tt[1]+=R,N}function F(){var B=function(W){return W[0]},j=function(W){return W[1]},U=Math.E,R;function G(N){var W=0,q=0,tt=0,ot=0,st=0,Z=R?+R[0]:1/0,et=R?+R[1]:-1/0,lt=Math.log(U);s(N,B,j,function(Bt,qt){var Nt=Math.log(Bt)/lt;++W,q+=(Nt-q)/W,tt+=(qt-tt)/W,ot+=(Nt*qt-ot)/W,st+=(Nt*Nt-st)/W,R||(Bt<Z&&(Z=Bt),Bt>et&&(et=Bt))});var dt=v(q,tt,ot,st),ht=i(dt,2),wt=ht[0],gt=ht[1],vt=function(qt){return gt*Math.log(qt)/lt+wt},_t=h(Z,et,vt);return _t.a=gt,_t.b=wt,_t.predict=vt,_t.rSquared=u(N,B,j,tt,vt),_t}return G.domain=function(N){return arguments.length?(R=N,G):R},G.x=function(N){return arguments.length?(B=N,G):B},G.y=function(N){return arguments.length?(j=N,G):j},G.base=function(N){return arguments.length?(U=N,G):U},G}function O(){var B=function(N){return N[0]},j=function(N){return N[1]},U;function R(G){var N=l(G,B,j),W=i(N,4),q=W[0],tt=W[1],ot=W[2],st=W[3],Z=q.length,et=0,lt=0,dt=0,ht=0,wt=0,gt,vt,_t,Bt;for(gt=0;gt<Z;)vt=q[gt],_t=tt[gt++],Bt=vt*vt,et+=(Bt-et)/gt,lt+=(Bt*vt-lt)/gt,dt+=(Bt*Bt-dt)/gt,ht+=(vt*_t-ht)/gt,wt+=(Bt*_t-wt)/gt;var qt=0,Nt=0,pe=U?+U[0]:1/0,cr=U?+U[1]:-1/0;s(G,B,j,function(At,yi){Nt++,qt+=(yi-qt)/Nt,U||(At<pe&&(pe=At),At>cr&&(cr=At))});var ar=dt-et*et,Ji=et*ar-lt*lt,$r=(wt*et-ht*lt)/Ji,tn=(ht*ar-wt*lt)/Ji,Yr=-$r*et,Wr=function(yi){return yi=yi-ot,$r*yi*yi+tn*yi+Yr+st},Ke=h(pe,cr,Wr);return Ke.a=$r,Ke.b=tn-2*$r*ot,Ke.c=Yr-tn*ot+$r*ot*ot+st,Ke.predict=Wr,Ke.rSquared=u(G,B,j,qt,Wr),Ke}return R.domain=function(G){return arguments.length?(U=G,R):U},R.x=function(G){return arguments.length?(B=G,R):B},R.y=function(G){return arguments.length?(j=G,R):j},R}function L(){var B=function(W){return W[0]},j=function(W){return W[1]},U=3,R;function G(N){if(U===1){var W=p().x(B).y(j).domain(R)(N);return W.coefficients=[W.b,W.a],delete W.a,delete W.b,W}if(U===2){var q=O().x(B).y(j).domain(R)(N);return q.coefficients=[q.c,q.b,q.a],delete q.a,delete q.b,delete q.c,q}var tt=l(N,B,j),ot=i(tt,4),st=ot[0],Z=ot[1],et=ot[2],lt=ot[3],dt=st.length,ht=[],wt=[],gt=U+1,vt=0,_t=0,Bt=R?+R[0]:1/0,qt=R?+R[1]:-1/0;s(N,B,j,function(Wr,Ke){++_t,vt+=(Ke-vt)/_t,R||(Wr<Bt&&(Bt=Wr),Wr>qt&&(qt=Wr))});var Nt,pe,cr,ar,Ji;for(Nt=0;Nt<gt;++Nt){for(cr=0,ar=0;cr<dt;++cr)ar+=Math.pow(st[cr],Nt)*Z[cr];for(ht.push(ar),Ji=new Float64Array(gt),pe=0;pe<gt;++pe){for(cr=0,ar=0;cr<dt;++cr)ar+=Math.pow(st[cr],Nt+pe);Ji[pe]=ar}wt.push(Ji)}wt.push(ht);var $r=k(wt),tn=function(Ke){Ke-=et;var At=lt+$r[0]+$r[1]*Ke+$r[2]*Ke*Ke;for(Nt=3;Nt<gt;++Nt)At+=$r[Nt]*Math.pow(Ke,Nt);return At},Yr=h(Bt,qt,tn);return Yr.coefficients=D(gt,$r,-et,lt),Yr.predict=tn,Yr.rSquared=u(N,B,j,vt,tn),Yr}return G.domain=function(N){return arguments.length?(R=N,G):R},G.x=function(N){return arguments.length?(B=N,G):B},G.y=function(N){return arguments.length?(j=N,G):j},G.order=function(N){return arguments.length?(U=N,G):U},G}function D(B,j,U,R){var G=Array(B),N,W,q,tt;for(N=0;N<B;++N)G[N]=0;for(N=B-1;N>=0;--N)for(q=j[N],tt=1,G[N]+=q,W=1;W<=N;++W)tt*=(N+1-W)/W,G[N-W]+=q*Math.pow(U,W)*tt;return G[0]+=R,G}function k(B){var j=B.length-1,U=[],R,G,N,W,q;for(R=0;R<j;++R){for(W=R,G=R+1;G<j;++G)Math.abs(B[R][G])>Math.abs(B[R][W])&&(W=G);for(N=R;N<j+1;++N)q=B[N][R],B[N][R]=B[N][W],B[N][W]=q;for(G=R+1;G<j;++G)for(N=j;N>=R;N--)B[N][G]-=B[N][R]*B[R][G]/B[R][R]}for(G=j-1;G>=0;--G){for(q=0,N=G+1;N<j;++N)q+=B[N][G]*U[N];U[G]=(B[j][G]-q)/B[G][G]}return U}function H(){var B=function(N){return N[0]},j=function(N){return N[1]},U;function R(G){var N=0,W=0,q=0,tt=0,ot=0,st=0,Z=U?+U[0]:1/0,et=U?+U[1]:-1/0;s(G,B,j,function(_t,Bt){var qt=Math.log(_t),Nt=Math.log(Bt);++N,W+=(qt-W)/N,q+=(Nt-q)/N,tt+=(qt*Nt-tt)/N,ot+=(qt*qt-ot)/N,st+=(Bt-st)/N,U||(_t<Z&&(Z=_t),_t>et&&(et=_t))});var lt=v(W,q,tt,ot),dt=i(lt,2),ht=dt[0],wt=dt[1];ht=Math.exp(ht);var gt=function(Bt){return ht*Math.pow(Bt,wt)},vt=h(Z,et,gt);return vt.a=ht,vt.b=wt,vt.predict=gt,vt.rSquared=u(G,B,j,st,gt),vt}return R.domain=function(G){return arguments.length?(U=G,R):U},R.x=function(G){return arguments.length?(B=G,R):B},R.y=function(G){return arguments.length?(j=G,R):j},R}t.regressionExp=d,t.regressionLinear=p,t.regressionLoess=b,t.regressionLog=F,t.regressionPoly=L,t.regressionPow=H,t.regressionQuad=O,Object.defineProperty(t,"__esModule",{value:!0})})})(Qa,Qa.exports);Object.defineProperty(os,"__esModule",{value:!0});os.getMeta=os.getPath=os.getQuadrantDefaultConfig=void 0;var qc=V,cu=Qa.exports,Go=Y,iLt=mt,nLt={exp:cu.regressionExp,linear:cu.regressionLinear,loess:cu.regressionLoess,log:cu.regressionLog,poly:cu.regressionPoly,pow:cu.regressionPow,quad:cu.regressionQuad};function aLt(e,r){var t=10,i={regionStyle:[{position:{start:[e,"max"],end:["max",r]},style:{fill:"#d8d0c0",opacity:.4}},{position:{start:["min","max"],end:[e,r]},style:{fill:"#a3dda1",opacity:.4}},{position:{start:["min",r],end:[e,"min"]},style:{fill:"#d8d0c0",opacity:.4}},{position:{start:[e,r],end:["max","min"]},style:{fill:"#a3dda1",opacity:.4}}],lineStyle:{stroke:"#9ba29a",lineWidth:1},labelStyle:[{position:["max",r],offsetX:-t,offsetY:-t,style:{textAlign:"right",textBaseline:"bottom",fontSize:14,fill:"#ccc"}},{position:["min",r],offsetX:t,offsetY:-t,style:{textAlign:"left",textBaseline:"bottom",fontSize:14,fill:"#ccc"}},{position:["min",r],offsetX:t,offsetY:t,style:{textAlign:"left",textBaseline:"top",fontSize:14,fill:"#ccc"}},{position:["max",r],offsetX:-t,offsetY:t,style:{textAlign:"right",textBaseline:"top",fontSize:14,fill:"#ccc"}}]};return i}os.getQuadrantDefaultConfig=aLt;var oLt=function(e,r){var t=r.view,i=r.options,n=i.xField,a=i.yField,o=t.getScaleByField(n),l=t.getScaleByField(a),s=e.map(function(u){return t.getCoordinate().convert({x:o.scale(u[0]),y:l.scale(u[1])})});return iLt.getSplinePath(s,!1)};os.getPath=function(e){var r=e.options,t=r.xField,i=r.yField,n=r.data,a=r.regressionLine,o=a.type,l=o===void 0?"linear":o,s=a.algorithm,u;if(s)u=Go.isArray(s)?s:s(n);else{var c=nLt[l]().x(function(f){return f[t]}).y(function(f){return f[i]});u=c(n)}return oLt(u,e)};os.getMeta=function(e){var r,t=e.meta,i=t===void 0?{}:t,n=e.xField,a=e.yField,o=e.data,l=o[0][n],s=o[0][a],u=l>0,c=s>0;function f(h,v){var d=Go.get(i,[h]);function p(m){return Go.get(d,m)}var x={};return v==="x"?(Go.isNumber(l)&&(Go.isNumber(p("min"))||(x.min=u?0:l*2),Go.isNumber(p("max"))||(x.max=u?l*2:0)),x):(Go.isNumber(s)&&(Go.isNumber(p("min"))||(x.min=c?0:s*2),Go.isNumber(p("max"))||(x.max=c?s*2:0)),x)}return qc.__assign(qc.__assign({},i),(r={},r[n]=qc.__assign(qc.__assign({},i[n]),f(n,"x")),r[a]=qc.__assign(qc.__assign({},i[a]),f(a,"y")),r))};Object.defineProperty(lo,"__esModule",{value:!0});lo.adaptor=lo.tooltip=lo.meta=lo.transformOptions=void 0;var ls=V,lLt=Y,ya=mt,sLt=Lr,uLt=wg,Id=Qe,HT=mt,DP=os;function SX(e){var r=e.data,t=r===void 0?[]:r,i=e.xField,n=e.yField;if(t.length){for(var a=!0,o=!0,l=t[0],s=void 0,u=1;u<t.length&&(s=t[u],l[i]!==s[i]&&(a=!1),l[n]!==s[n]&&(o=!1),!(!a&&!o));u++)l=s;var c=[];a&&c.push(i),o&&c.push(n);var f=ya.pick(DP.getMeta(e),c);return ya.deepAssign({},e,{meta:f})}return e}lo.transformOptions=SX;function cLt(e){var r=e.chart,t=e.options,i=t.data,n=t.type,a=t.color,o=t.shape,l=t.pointStyle,s=t.shapeField,u=t.colorField,c=t.xField,f=t.yField,h=t.sizeField,v=t.size,d=t.tooltip;h&&(v||(v=[2,8]),lLt.isNumber(v)&&(v=[v,v])),d&&!d.fields&&(d=ls.__assign(ls.__assign({},d),{fields:[c,f,u,h,s]})),r.data(i),sLt.point(ya.deepAssign({},e,{options:{seriesField:u,point:{color:a,shape:o,size:v,style:l},tooltip:d}}));var p=HT.findGeometry(r,"point");return n&&p.adjust(n),e}function AX(e){var r,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.yField,l=SX(t);return ya.flow(Id.scale((r={},r[a]=i,r[o]=n,r)))(ya.deepAssign({},e,{options:l}))}lo.meta=AX;function fLt(e){var r=e.chart,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.yField;return r.axis(a,i),r.axis(o,n),e}function hLt(e){var r=e.chart,t=e.options,i=t.legend,n=t.colorField,a=t.shapeField,o=t.sizeField,l=t.shapeLegend,s=t.sizeLegend,u=i!==!1;return n&&r.legend(n,u?i:!1),a&&(l?r.legend(a,l):r.legend(a,l===!1?!1:i)),o&&r.legend(o,s||!1),!u&&!l&&!s&&r.legend(!1),e}function vLt(e){var r=e.chart,t=e.options,i=t.label,n=t.yField,a=HT.findGeometry(r,"point");if(!i)a.label(!1);else{var o=i.callback,l=ls.__rest(i,["callback"]);a.label({fields:[n],callback:o,cfg:HT.transformLabel(l)})}return e}function dLt(e){var r=e.options,t=r.quadrant,i=[];if(t){var n=t.xBaseline,a=n===void 0?0:n,o=t.yBaseline,l=o===void 0?0:o,s=t.labels,u=t.regionStyle,c=t.lineStyle,f=DP.getQuadrantDefaultConfig(a,l),h=new Array(4).join(",").split(",");h.forEach(function(v,d){i.push(ls.__assign(ls.__assign({type:"region",top:!1},f.regionStyle[d].position),{style:ya.deepAssign({},f.regionStyle[d].style,u==null?void 0:u[d])}),ls.__assign({type:"text",top:!0},ya.deepAssign({},f.labelStyle[d],s==null?void 0:s[d])))}),i.push({type:"line",top:!1,start:["min",l],end:["max",l],style:ya.deepAssign({},f.lineStyle,c)},{type:"line",top:!1,start:[a,"min"],end:[a,"max"],style:ya.deepAssign({},f.lineStyle,c)})}return ya.flow(Id.annotation(i))(e)}function pLt(e){var r=e.options,t=e.chart,i=r.regressionLine;if(i){var n=i.style,a=i.top,o=a===void 0?!1:a,l={stroke:"#9ba29a",lineWidth:2,opacity:.5};t.annotation().shape({top:o,render:function(s,u){var c=s.addGroup({id:t.id+"-regression-line",name:"regression-line-group"}),f=DP.getPath({view:u,options:r});c.addShape("path",{name:"regression-line",attrs:ls.__assign(ls.__assign({path:f},l),n)})}})}return e}function TX(e){var r=e.chart,t=e.options,i=t.tooltip;return i?r.tooltip(i):i===!1&&r.tooltip(!1),e}lo.tooltip=TX;function gLt(e){return ya.flow(cLt,AX,fLt,hLt,TX,vLt,uLt.brushInteraction,Id.interaction,dLt,Id.animation,Id.theme,pLt)(e)}lo.adaptor=gLt;var mb={};Object.defineProperty(mb,"__esModule",{value:!0});mb.DEFAULT_OPTIONS=void 0;var yLt=ae,mLt=mt;mb.DEFAULT_OPTIONS=mLt.deepAssign({},yLt.Plot.getDefaultOptions(),{size:4,tooltip:{showTitle:!1,showMarkers:!1,showCrosshairs:!0,crosshairs:{type:"xy"}}});Object.defineProperty(LP,"__esModule",{value:!0});var $P=LP.Scatter=void 0,US=V,qS=me,xLt=ae,_Lt=mt,Rv=lo,bLt=mb,wLt=function(e){US.__extends(r,e);function r(t,i){var n=e.call(this,t,i)||this;return n.type="scatter",n.on(qS.VIEW_LIFE_CIRCLE.BEFORE_RENDER,function(a){var o,l,s=n,u=s.options,c=s.chart;if(((o=a.data)===null||o===void 0?void 0:o.source)===qS.BRUSH_FILTER_EVENTS.FILTER){var f=n.chart.filterData(n.chart.getData());Rv.meta({chart:c,options:US.__assign(US.__assign({},u),{data:f})})}((l=a.data)===null||l===void 0?void 0:l.source)===qS.BRUSH_FILTER_EVENTS.RESET&&Rv.meta({chart:c,options:u})}),n}return r.getDefaultOptions=function(){return bLt.DEFAULT_OPTIONS},r.prototype.changeData=function(t){this.updateOption(Rv.transformOptions(_Lt.deepAssign({},this.options,{data:t})));var i=this,n=i.options,a=i.chart;Rv.meta({chart:a,options:n}),this.chart.changeData(t)},r.prototype.getSchemaAdaptor=function(){return Rv.adaptor},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r}(xLt.Plot);$P=LP.Scatter=wLt;var CLt=function(e){var r=He(e);kt(r,"pointSize")&&ve(r,"size",kt(r,"pointSize")),Fr(r,"quadrant");var t=kt(r,"quadrant.label"),i=kt(r,"quadrant.labels");if(!i&&t){var n=t.text,a=t.style;if(n&&n.length&&a){var o=n.map(function(u){return{style:a,content:u}});ve(r,"quadrant.labels",o)}}var l=kt(r,"regressionLine");if(!l){var s=kt(r,"trendline");Zt(s)&&kt(s,"visible")===!1?ve(r,"regressionLine",null):ve(r,"regressionLine",s)}return r},SLt=Qt($P,"ScatterChart",CLt),ALt=Qt($P,"BubbleChart",function(e){var r=He(e);return fi(kt(r,"pointSize"))||ve(r,"size",kt(r,"pointSize")),r}),kP={},dh={},Fg={};Object.defineProperty(Fg,"__esModule",{value:!0});Fg.transformData=void 0;function TLt(e){var r=e.data,t=e.xField,i=e.measureField,n=e.rangeField,a=e.targetField,o=e.layout,l=[],s=[];r.forEach(function(f,h){var v;f[n].sort(function(d,p){return d-p}),f[n].forEach(function(d,p){var x,m=p===0?d:f[n][p]-f[n][p-1];l.push((x={rKey:n+"_"+p},x[t]=t?f[t]:String(h),x[n]=m,x))}),f[i].forEach(function(d,p){var x;l.push((x={mKey:f[i].length>1?i+"_"+p:""+i},x[t]=t?f[t]:String(h),x[i]=d,x))}),l.push((v={tKey:""+a},v[t]=t?f[t]:String(h),v[a]=f[a],v)),s.push(f[n],f[i],f[a])});var u=Math.min.apply(Math,s.flat(1/0)),c=Math.max.apply(Math,s.flat(1/0));return u=u>0?0:u,o==="vertical"&&l.reverse(),{min:u,max:c,ds:l}}Fg.transformData=TLt;Object.defineProperty(dh,"__esModule",{value:!0});dh.adaptor=dh.meta=void 0;var Ld=V,Br=Y,ad=Qe,ss=mt,ZS=Lr,MLt=Fg;function ELt(e){var r=e.chart,t=e.options,i=t.bulletStyle,n=t.targetField,a=t.rangeField,o=t.measureField,l=t.xField,s=t.color,u=t.layout,c=t.size,f=t.label,h=MLt.transformData(t),v=h.min,d=h.max,p=h.ds;r.data(p);var x=ss.deepAssign({},e,{options:{xField:l,yField:a,seriesField:"rKey",isStack:!0,label:Br.get(f,"range"),interval:{color:Br.get(s,"range"),style:Br.get(i,"range"),size:Br.get(c,"range")}}});ZS.interval(x),r.geometries[0].tooltip(!1);var m=ss.deepAssign({},e,{options:{xField:l,yField:o,seriesField:"mKey",isStack:!0,label:Br.get(f,"measure"),interval:{color:Br.get(s,"measure"),style:Br.get(i,"measure"),size:Br.get(c,"measure")}}});ZS.interval(m);var _=ss.deepAssign({},e,{options:{xField:l,yField:n,seriesField:"tKey",label:Br.get(f,"target"),point:{color:Br.get(s,"target"),style:Br.get(i,"target"),size:Br.isFunction(Br.get(c,"target"))?function(b){return Br.get(c,"target")(b)/2}:Br.get(c,"target")/2,shape:u==="horizontal"?"line":"hyphen"}}});return ZS.point(_),u==="horizontal"&&r.coordinate().transpose(),Ld.__assign(Ld.__assign({},e),{ext:{data:{min:v,max:d}}})}function MX(e){var r,t,i=e.options,n=e.ext,a=i.xAxis,o=i.yAxis,l=i.targetField,s=i.rangeField,u=i.measureField,c=i.xField,f=n.data;return ss.flow(ad.scale((r={},r[c]=a,r[u]=o,r),(t={},t[u]={min:f==null?void 0:f.min,max:f==null?void 0:f.max,sync:!0},t[l]={sync:""+u},t[s]={sync:""+u},t)))(e)}dh.meta=MX;function FLt(e){var r=e.chart,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.measureField,l=t.rangeField,s=t.targetField;return r.axis(""+l,!1),r.axis(""+s,!1),i===!1?r.axis(""+a,!1):r.axis(""+a,i),n===!1?r.axis(""+o,!1):r.axis(""+o,n),e}function OLt(e){var r=e.chart,t=e.options,i=t.legend;return r.removeInteraction("legend-filter"),r.legend(i),r.legend("rKey",!1),r.legend("mKey",!1),r.legend("tKey",!1),e}function PLt(e){var r=e.chart,t=e.options,i=t.label,n=t.measureField,a=t.targetField,o=t.rangeField,l=r.geometries,s=l[0],u=l[1],c=l[2];return Br.get(i,"range")?s.label(""+o,Ld.__assign({layout:[{type:"limit-in-plot"}]},ss.transformLabel(i.range))):s.label(!1),Br.get(i,"measure")?u.label(""+n,Ld.__assign({layout:[{type:"limit-in-plot"}]},ss.transformLabel(i.measure))):u.label(!1),Br.get(i,"target")?c.label(""+a,Ld.__assign({layout:[{type:"limit-in-plot"}]},ss.transformLabel(i.target))):c.label(!1),e}function ILt(e){ss.flow(ELt,MX,FLt,OLt,ad.theme,PLt,ad.tooltip,ad.interaction,ad.animation)(e)}dh.adaptor=ILt;var xb={};Object.defineProperty(xb,"__esModule",{value:!0});xb.DEFAULT_OPTIONS=void 0;var LLt=ae,DLt=mt;xb.DEFAULT_OPTIONS=DLt.deepAssign({},LLt.Plot.getDefaultOptions(),{layout:"horizontal",size:{range:30,measure:20,target:20},xAxis:{tickLine:!1,line:null},bulletStyle:{range:{fillOpacity:.5}},label:{measure:{position:"right"}},tooltip:{showMarkers:!1}});Object.defineProperty(kP,"__esModule",{value:!0});var EX=kP.Bullet=void 0,$Lt=V,kLt=ae,qN=dh,RLt=Fg,BLt=xb,NLt=function(e){$Lt.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="bullet",t}return r.getDefaultOptions=function(){return BLt.DEFAULT_OPTIONS},r.prototype.changeData=function(t){this.updateOption({data:t});var i=RLt.transformData(this.options),n=i.min,a=i.max,o=i.ds;qN.meta({options:this.options,ext:{data:{min:n,max:a}},chart:this.chart}),this.chart.changeData(o)},r.prototype.getSchemaAdaptor=function(){return qN.adaptor},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r}(kLt.Plot);EX=kP.Bullet=NLt;var Su=globalThis&&globalThis.__assign||function(){return Su=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Su.apply(this,arguments)},GLt=function(e){var r=He(e);return fi(kt(e,"measureSize"))||ve(r,"size.measure",kt(e,"measureSize")),fi(kt(e,"rangeSize"))||ve(r,"size.range",kt(e,"rangeSize")),fi(kt(e,"markerSize"))||ve(r,"size.target",kt(e,"markerSize")),fi(kt(e,"measureColors"))||ve(r,"color.measure",kt(e,"measureColors")),fi(kt(e,"rangeColors"))||ve(r,"color.range",kt(e,"rangeColors")),fi(kt(e,"markerColors"))||ve(r,"color.target",kt(e,"markerColors")),fi(kt(e,"markerStyle"))||ve(r,"bulletStyle.target",kt(e,"markerStyle")),fi(kt(e,"xAxis.line"))&&ve(r,"xAxis.line",!1),fi(kt(e,"yAxis"))&&ve(r,"yAxis",!1),fi(kt(e,"measureField"))&&ve(r,"measureField","measures"),fi(kt(e,"rangeField"))&&ve(r,"rangeField","ranges"),fi(kt(e,"targetField"))&&ve(r,"targetField","target"),Df(!fi(kt(e,"rangeMax"))),sr(kt(e,"data"))&&ve(r,"data",e.data.map(function(t){var i={};return fi(kt(e,"rangeMax"))||(i={ranges:[kt(e,"rangeMax")]}),sr(t.targets)?Su(Su(Su({},i),{target:t.targets[0]}),t):Su(Su({},i),t)})),r},zLt=Qt(EX,"BulletChart",GLt);function It(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];return function(t){return e.reduce(function(i,n){return n(i)},t)}}function se(e,r){var t={};return e!==null&&typeof e=="object"&&r.forEach(function(i){var n=e[i];n!==void 0&&(t[i]=n)}),t}function FX(e,r){return r?Kr(r,function(t,i,n){return t.replace(new RegExp("{\\s*"+n+"\\s*}","g"),i)},e):e}var Fa;(function(e){e.ERROR="error",e.WARN="warn",e.INFO="log"})(Fa||(Fa={}));var VLt="AntV/G2Plot";function jLt(e){for(var r=[],t=1;t<arguments.length;t++)r[t-1]=arguments[t];var i=0;return VLt+": "+e.replace(/%s/g,function(){return""+r[i++]})}function ul(e,r,t){for(var i=[],n=3;n<arguments.length;n++)i[n-3]=arguments[n];r||console[e](jLt.apply(void 0,ye([t],i)))}function YT(e){if(!e)return{width:0,height:0};var r=getComputedStyle(e);return{width:(e.clientWidth||parseInt(r.width,10))-parseInt(r.paddingLeft,10)-parseInt(r.paddingRight,10),height:(e.clientHeight||parseInt(r.height,10))-parseInt(r.paddingTop,10)-parseInt(r.paddingBottom,10)}}function ei(e,r){return e.geometries.find(function(t){return t.type===r})}function Gx(e){return Kr(e.geometries,function(r,t){return r.concat(t.elements)},[])}function lp(e){return I(e,["views","length"],0)<=0?Gx(e):Kr(e.views,function(r,t){return r.concat(lp(t))},Gx(e))}function HLt(e){return I(e,["views","length"],0)<=0?e.geometries:Kr(e.views,function(r,t){return r.concat(t.geometries)},e.geometries)}function Yt(e,r){return e.views.find(function(t){return t.id===r})}function od(e){var r=e.parent;return r?r.views:[]}function ZN(e){return od(e).filter(function(r){return r!==e})}function Pr(e){if(!Zn(e,"Object"))return e;var r=A({},e);return r.formatter&&!r.content&&(r.content=r.formatter),r}function YLt(e,r){var t=[];if(e.length){t.push(["M",e[0].x,e[0].y]);for(var i=1,n=e.length;i<n;i+=1){var a=e[i];t.push(["L",a.x,a.y])}r&&t.push(["Z"])}return t}var WLt=function(e,r,t,i){var n=[],a,o,l=!!i,s,u;if(l){s=[1/0,1/0],u=[-1/0,-1/0];for(var c=0,f=e.length;c<f;c++){var h=e[c];s=Cr([0,0],s,h),u=Sr([0,0],u,h)}s=Cr([0,0],s,i[0]),u=Sr([0,0],u,i[1])}for(var c=0,v=e.length;c<v;c++){var h=e[c];if(t)a=e[c?c-1:v-1],o=e[(c+1)%v];else if(c===0||c===v-1){n.push(h);continue}else a=e[c-1],o=e[c+1];var d=[0,0];d=Kl(d,o,a),d=pi(d,d,r);var p=cs(h,a),x=cs(h,o),m=p+x;m!==0&&(p/=m,x/=m);var _=pi([0,0],d,-p),b=pi([0,0],d,x),w=ma([0,0],h,_),S=ma([0,0],h,b);l&&(w=Sr([0,0],w,s),w=Cr([0,0],w,u),S=Sr([0,0],S,s),S=Cr([0,0],S,u)),n.push(w),n.push(S)}return t&&n.push(n.shift()),n};function XLt(e,r,t){for(var i=!!r,n=[],a=0,o=e.length;a<o;a+=2)n.push([e[a],e[a+1]]);for(var l=WLt(n,.4,i,t),s=n.length,u=[],c,f,h,a=0;a<s-1;a++)c=l[a*2],f=l[a*2+1],h=n[a+1],u.push(["C",c[0],c[1],f[0],f[1],h[0],h[1]]);return i&&(c=l[s],f=l[s+1],h=n[0],u.push(["C",c[0],c[1],f[0],f[1],h[0],h[1]])),u}function ULt(e,r,t){var i=[],n=e[0],a=null;if(e.length<=2)return YLt(e,r);for(var o=0,l=e.length;o<l;o++){var s=e[o];(!a||!(a.x===s.x&&a.y===s.y))&&(i.push(s.x),i.push(s.y),a=s)}var u=t||[[0,0],[1,1]],c=XLt(i,r,u);return c.unshift(["M",n.x,n.y]),c}var qLt=5,ZLt={}.toString,OX=function(e,r){return ZLt.call(e)==="[object "+r+"]"},QLt=function(e){return OX(e,"Array")},KLt=function(e){return typeof e=="object"&&e!==null},QN=function(e){if(!KLt(e)||!OX(e,"Object"))return!1;for(var r=e;Object.getPrototypeOf(r)!==null;)r=Object.getPrototypeOf(r);return Object.getPrototypeOf(e)===r},PX=function(e,r,t,i){t=t||0,i=i||qLt;for(var n in r)if(Object.prototype.hasOwnProperty.call(r,n)){var a=r[n];a?QN(a)?(QN(e[n])||(e[n]={}),t<i?PX(e[n],a,t+1,i):e[n]=r[n]):QLt(a)?(e[n]=[],e[n]=e[n].concat(a)):e[n]=a:e[n]=a}},J=function(e){for(var r=[],t=1;t<arguments.length;t++)r[t-1]=arguments[t];for(var i=0;i<r.length;i+=1)PX(e,r[i]);return e};function KN(e){if(!e)return e;var r=e.match(/(([A-Z]{0,1}[a-z]*[^A-Z])|([A-Z]{1}))/g);return r.map(function(t){return t.toLowerCase()}).join("-")}function IX(e){var r={overflow:"hidden","white-space":"nowrap","text-overflow":"ellipsis",display:"flex",justifyContent:"center",alignItems:"center"},t=["stroke","lineWidth","shadowColor","strokeOpacity","shadowBlur","shadowOffsetX","shadowOffsetY","fill"];I(e,"fill")&&(r.color=e.fill);var i=se(e,t),n=i.shadowColor,a=i.shadowBlur,o=a===void 0?0:a,l=i.shadowOffsetX,s=l===void 0?0:l,u=i.shadowOffsetY,c=u===void 0?0:u;r["text-shadow"]=""+[n,s+"px",c+"px",o+"px"].join(" ");var f=se(e,t),h=f.stroke,v=f.lineWidth,d=v===void 0?0:v;return r["-webkit-text-stroke"]=""+[d+"px",h].join(" "),P(e,function(p,x){["fontSize"].includes(x)&&Mt(p)?r[KN(x)]=p+"px":x&&!t.includes(x)&&(r[KN(x)]=""+p)}),r}function LX(e,r){e.style["pointer-events"]="none",P(r,function(t,i){i&&t&&(e.style[i]=t)})}var _b=function(e,r,t){var i=r.statistic,n=r.plotType,a=i.title,o=i.content;[a,o].forEach(function(l,s){if(!!l){var u="";s===0?u=o?"translate(-50%, -100%)":"translate(-50%, -50%)":u=a?"translate(-50%, 0)":"translate(-50%, -50%)";var c=pt(l.style)?l.style(t):l.style;e.annotation().html(A({position:["50%","50%"],html:function(f,h){var v=h.getCoordinate(),d=0;if(n==="pie"||n==="ring-progress")d=v.getRadius()*v.innerRadius*2;else if(n==="liquid"){var p=I(h.geometries,[0,"elements",0,"shape"]);if(p){var x=p.find(function(w){return w.get("name")==="wrap"}),m=x.getCanvasBBox().width;d=m}}else d||(d=v.getWidth());LX(f,A({width:d+"px",transform:u},IX(c)));var _=h.getData();if(l.customHtml)return l.customHtml(f,h,t,_);var b=l.content;return l.formatter&&(b=l.formatter(t,_)),b?Ct(b)?b:""+b:"<div></div>"},key:(s===0?"top":"bottom")+"-statistic"},se(l,["offsetX","offsetY","rotate","style","formatter"])))}})},JLt=function(e,r,t){var i=r.statistic,n=i.title,a=i.content;[n,a].forEach(function(o){if(!!o){var l=pt(o.style)?o.style(t):o.style;e.annotation().html(A({position:["50%","100%"],html:function(s,u){var c=u.getCoordinate(),f=u.views[0].getCoordinate(),h=f.getCenter(),v=f.getRadius(),d=Math.max(Math.sin(f.startAngle),Math.sin(f.endAngle))*v,p=h.y+d-c.y.start-parseFloat(I(l,"fontSize",0)),x=c.getRadius()*c.innerRadius*2;LX(s,A({width:x+"px",transform:"translate(-50%, "+p+"px)"},IX(l)));var m=u.getData();if(o.customHtml)return o.customHtml(s,u,t,m);var _=o.content;return o.formatter&&(_=o.formatter(t,m)),_?Ct(_)?_:""+_:"<div></div>"}},se(o,["offsetX","offsetY","rotate","style","formatter"])))}})},QS;function tDt(){return QS||(QS=document.createElement("canvas").getContext("2d")),QS}uc(function(e,r){r===void 0&&(r={});var t=r.fontSize,i=r.fontFamily,n=i===void 0?"sans-serif":i,a=r.fontWeight,o=r.fontStyle,l=r.fontVariant,s=tDt();s.font=[o,a,l,t+"px",n].join(" ");var u=s.measureText(Ct(e)?e:"");return u.width},function(e,r){return r===void 0&&(r={}),ye([e],_h(r)).join("")});function nc(e){return typeof e=="number"&&!isNaN(e)}function eDt(e,r,t){var i=Math.min(r,t),n=Math.max(r,t);return e>=i&&e<=n}function RP(e,r){var t=e.filter(function(a){var o=I(a,[r]);return Mt(o)&&!isNaN(o)}),i=t.every(function(a){return I(a,[r])>=0}),n=t.every(function(a){return I(a,[r])<=0});return i?{min:0}:n?{max:0}:{}}function DX(e,r,t,i,n){if(n===void 0&&(n=[]),!Array.isArray(e))return{nodes:[],links:[]};var a=[],o={},l=-1;return e.forEach(function(s){var u=s[r],c=s[t],f=s[i],h=se(s,n);o[u]||(o[u]=A({id:++l,name:u},h)),o[c]||(o[c]=A({id:++l,name:c},h)),a.push(A({source:o[u].id,target:o[c].id,value:f},h))}),{nodes:Object.values(o).sort(function(s,u){return s.id-u.id}),links:a}}function ph(e,r){var t=jr(e,function(i){var n=i[r];return n===null||typeof n=="number"&&!isNaN(n)});return ul(Fa.WARN,t.length===e.length,"illegal data existed in chart data."),t}function Ts(e){if(Mt(e))return[e,e,e,e];if(it(e)){var r=e.length;if(r===1)return[e[0],e[0],e[0],e[0]];if(r===2)return[e[0],e[1],e[0],e[1]];if(r===3)return[e[0],e[1],e[2],e[1]];if(r===4)return e}return[0,0,0,0]}function bb(e,r,t){r===void 0&&(r="bottom"),t===void 0&&(t=25);var i=Ts(e),n=[r.startsWith("top")?t:0,r.startsWith("right")?t:0,r.startsWith("bottom")?t:0,r.startsWith("left")?t:0];return[i[0]+n[0],i[1]+n[1],i[2]+n[2],i[3]+n[3]]}function BP(e){var r=e.map(function(i){return Ts(i)}),t=[0,0,0,0];return r.length>0&&(t=t.map(function(i,n){return r.forEach(function(a,o){i+=r[o][n]}),i})),t}var rDt={locale:"en-US"},D0={};function $X(e,r){D0[e]=r}function wb(e){return{get:function(r,t){return FX(I(D0[e],r)||I(D0[rDt.locale],r)||I(D0["en-US"],r)||r,t)}}}var iDt={locale:"en-US",general:{increase:"Increase",decrease:"Decrease",root:"Root"},statistic:{total:"Total"},conversionTag:{label:"Rate"},legend:{},tooltip:{},slider:{},scrollbar:{},waterfall:{total:"Total"}},nDt={locale:"zh-CN",general:{increase:"\u589E\u52A0",decrease:"\u51CF\u5C11",root:"\u521D\u59CB"},statistic:{total:"\u603B\u8BA1"},conversionTag:{label:"\u8F6C\u5316\u7387"},legend:{},tooltip:{},slider:{},scrollbar:{},waterfall:{total:"\u603B\u8BA1"}},JN="data-chart-source-type",kX=["padding","appendPadding","renderer","pixelRatio","syncViewPadding","supportCSSTransform","limitInPlot"],Dt=function(e){X(r,e);function r(t,i){var n=e.call(this)||this;return n.container=typeof t=="string"?document.getElementById(t):t,n.options=J({},n.getDefaultOptions(),i),n.createG2(),n.bindEvents(),n}return r.getDefaultOptions=function(){return{renderer:"canvas",xAxis:{nice:!0,label:{autoRotate:!1,autoHide:{type:"equidistance",cfg:{minGap:6}}}},yAxis:{nice:!0,label:{autoHide:!0,autoRotate:!1}},animation:!0}},r.prototype.createG2=function(){var t=this.options,i=t.width,n=t.height,a=t.defaultInteractions;this.chart=new hW(A(A(A(A({container:this.container,autoFit:!1},this.getChartSize(i,n)),{localRefresh:!1}),se(this.options,kX)),{defaultInteractions:a})),this.container.setAttribute(JN,"G2Plot")},r.prototype.getChartSize=function(t,i){var n=YT(this.container);return{width:t||n.width||400,height:i||n.height||400}},r.prototype.bindEvents=function(){var t=this;this.chart&&this.chart.on("*",function(i){i!=null&&i.type&&t.emit(i.type,i)})},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.render=function(){this.chart.clear(),this.chart.options={data:[],animate:!0},this.chart.views=[],this.execAdaptor(),this.chart.render(),this.bindSizeSensor()},r.prototype.update=function(t){this.updateOption(t),this.render()},r.prototype.updateOption=function(t){this.options=J({},this.options,t)},r.prototype.setState=function(t,i,n){n===void 0&&(n=!0);var a=lp(this.chart);P(a,function(o){i(o.getData())&&o.setState(t,n)})},r.prototype.getStates=function(){var t=lp(this.chart),i=[];return P(t,function(n){var a=n.getData(),o=n.getStates();P(o,function(l){i.push({data:a,state:l,geometry:n.geometry,element:n})})}),i},r.prototype.changeData=function(t){this.update({data:t})},r.prototype.changeSize=function(t,i){this.chart.changeSize(t,i)},r.prototype.addAnnotations=function(t){var i=ye(t),n=this.chart.getController("annotation"),a=n.getComponents().map(function(s){return s.extra});n.clear(!0);for(var o=function(s){var u=a[s],c=i.findIndex(function(f){return f.id&&f.id===u.id});c!==-1&&(u=J({},u,i[c]),i.splice(c,1)),n.annotation(u)},l=0;l<a.length;l++)o(l);i.forEach(function(s){return n.annotation(s)}),this.chart.render(!0)},r.prototype.removeAnnotations=function(t){var i=this.chart.getController("annotation"),n=i.getComponents().map(function(l){return l.extra});i.clear(!0);for(var a=function(l){var s=n[l];t.find(function(u){return u.id&&u.id===s.id})||i.annotation(s)},o=0;o<n.length;o++)a(o);this.chart.render(!0)},r.prototype.destroy=function(){this.unbindSizeSensor(),this.chart.destroy(),this.off(),this.container.removeAttribute(JN)},r.prototype.execAdaptor=function(){var t=this.getSchemaAdaptor(),i=this.options,n=i.padding,a=i.appendPadding;this.chart.padding=n,this.chart.appendPadding=a,t({chart:this.chart,options:this.options})},r.prototype.triggerResize=function(){this.chart.forceFit()},r.prototype.bindSizeSensor=function(){var t=this;if(!this.unbind){var i=this.options.autoFit,n=i===void 0?!0:i;n&&(this.unbind=WW(this.container,function(){var a=YT(t.container),o=a.width,l=a.height;(o!==t.chart.width||l!==t.chart.height)&&t.triggerResize()}))}},r.prototype.unbindSizeSensor=function(){this.unbind&&(this.unbind(),this.unbind=void 0)},r}(yp),ji=["type","alias","tickCount","tickInterval","min","max","nice","minLimit","maxLimit","range","tickMethod","base","exponent","mask","sync"];function Cb(){return typeof window=="object"?window==null?void 0:window.devicePixelRatio:2}function NP(e,r){r===void 0&&(r=e);var t=document.createElement("canvas"),i=Cb();t.width=e*i,t.height=r*i,t.style.width=e+"px",t.style.height=r+"px";var n=t.getContext("2d");return n.scale(i,i),t}function GP(e,r,t,i){i===void 0&&(i=t);var n=r.backgroundColor,a=r.opacity;e.globalAlpha=a,e.fillStyle=n,e.beginPath(),e.fillRect(0,0,t,i),e.closePath()}function RX(e,r,t){var i=e+r;return t?i*2:i}function BX(e,r){var t=r?[[e*.25,e*.25],[e*.75,e*.75]]:[[e*.5,e*.5]];return t}function zP(e,r){var t=r*Math.PI/180,i={a:Math.cos(t)*(1/e),b:Math.sin(t)*(1/e),c:-Math.sin(t)*(1/e),d:Math.cos(t)*(1/e),e:0,f:0};return i}var aDt={size:6,padding:2,backgroundColor:"transparent",opacity:1,rotation:0,fill:"#fff",fillOpacity:.5,stroke:"transparent",lineWidth:0,isStagger:!0};function oDt(e,r,t,i){var n=r.size,a=r.fill,o=r.lineWidth,l=r.stroke,s=r.fillOpacity;e.beginPath(),e.globalAlpha=s,e.fillStyle=a,e.strokeStyle=l,e.lineWidth=o,e.arc(t,i,n/2,0,2*Math.PI,!1),e.fill(),o&&e.stroke(),e.closePath()}function lDt(e){var r=J({},aDt,e),t=r.size,i=r.padding,n=r.isStagger,a=r.rotation,o=RX(t,i,n),l=BX(o,n),s=NP(o,o),u=s.getContext("2d");GP(u,r,o);for(var c=0,f=l;c<f.length;c++){var h=f[c],v=h[0],d=h[1];oDt(u,r,v,d)}var p=u.createPattern(s,"repeat");if(p){var x=Cb(),m=zP(x,a);p.setTransform(m)}return p}var sDt={rotation:45,spacing:5,opacity:1,backgroundColor:"transparent",strokeOpacity:.5,stroke:"#fff",lineWidth:2};function uDt(e,r,t){var i=r.stroke,n=r.lineWidth,a=r.strokeOpacity,o=new Path2D(t);e.globalAlpha=a,e.lineCap="square",e.strokeStyle=n?i:"transparent",e.lineWidth=n,e.stroke(o)}function cDt(e){var r=J({},sDt,e),t=r.spacing,i=r.rotation,n=r.lineWidth,a=t+n||1,o=t+n||1,l=`
|
|
M 0 0 L `+a+` 0
|
|
M 0 `+o+" L "+a+" "+o+`
|
|
`,s=NP(a,o),u=s.getContext("2d");GP(u,r,a,o),uDt(u,r,l);var c=u.createPattern(s,"repeat");if(c){var f=Cb(),h=zP(f,i);c.setTransform(h)}return c}var fDt={size:6,padding:1,isStagger:!0,backgroundColor:"transparent",opacity:1,rotation:0,fill:"#fff",fillOpacity:.5,stroke:"transparent",lineWidth:0};function hDt(e,r,t,i){var n=r.stroke,a=r.size,o=r.fill,l=r.lineWidth,s=r.fillOpacity;e.globalAlpha=s,e.strokeStyle=n,e.lineWidth=l,e.fillStyle=o,e.strokeRect(t-a/2,i-a/2,a,a),e.fillRect(t-a/2,i-a/2,a,a)}function vDt(e){var r=J({},fDt,e),t=r.size,i=r.padding,n=r.isStagger,a=r.rotation,o=RX(t,i,n),l=BX(o,n),s=NP(o,o),u=s.getContext("2d");GP(u,r,o);for(var c=0,f=l;c<f.length;c++){var h=f[c],v=h[0],d=h[1];hDt(u,r,v,d)}var p=u.createPattern(s,"repeat");if(p){var x=Cb(),m=zP(x,a);p.setTransform(m)}return p}function dDt(e){var r=e.type,t=e.cfg,i;switch(r){case"dot":i=lDt(t);break;case"line":i=cDt(t);break;case"square":i=vDt(t);break}return i}function Sn(e){var r=this;return function(t){var i,n=t.options,a=t.chart,o=n.pattern;if(!o)return t;var l=function(s){for(var u,c,f,h=[],v=1;v<arguments.length;v++)h[v-1]=arguments[v];var d=a.getTheme().defaultColor,p=d,x=(c=(u=a.geometries)===null||u===void 0?void 0:u[0])===null||c===void 0?void 0:c.getAttribute("color");if(x){var m=x.getFields()[0],_=I(s,m);p=Fi.getMappingValue(x,_,((f=x.values)===null||f===void 0?void 0:f[0])||d)}var b=o;typeof o=="function"&&(b=o.call(r,s,p)),b instanceof CanvasPattern||(b=dDt(J({},{cfg:{backgroundColor:p}},b)));var w=n[e];return A(A({},typeof w=="function"?w.call.apply(w,ye([r,s],h)):w||{}),{fill:b||p})};return J({},t,{options:(i={},i[e]=l,i)})}}function Og(e){var r=e.chart,t=e.options,i=t.legend,n=t.colorField,a=t.seriesField;return i===!1?r.legend(!1):(n||a)&&r.legend(n||a,i),e}function Dr(e){var r=e.chart,t=e.options,i=t.tooltip;return i!==void 0&&r.tooltip(i),e}function Ae(e){var r=e.chart,t=e.options,i=t.interactions;return P(i,function(n){n.enable===!1?r.removeInteraction(n.type):r.interaction(n.type,n.cfg||{})}),e}function ce(e){var r=e.chart,t=e.options,i=t.animation;return typeof i=="boolean"?r.animate(i):r.animate(!0),P(r.geometries,function(n){n.animate(i)}),e}function ie(e){var r=e.chart,t=e.options,i=t.theme;return i&&r.theme(i),e}function Rs(e){var r=e.chart,t=e.options,i=t.state;return i&&P(r.geometries,function(n){n.state(i)}),e}function Sb(e){var r=e.chart,t=e.options,i=t.slider;return r.option("slider",i),e}function pDt(e){var r=e.chart,t=e.options,i=t.scrollbar;return r.option("scrollbar",i),e}function We(e,r){return function(t){var i=t.chart,n=t.options,a={};return P(e,function(o,l){a[l]=se(o,ji)}),a=J({},r,n.meta,a),i.scale(a),t}}function Xe(e){return function(r){var t=r.chart,i=r.options,n=t.getController("annotation");return P(ye(i.annotations||[],e||[]),function(a){n.annotation(a)}),r}}function ac(e){var r=e.chart,t=e.options,i=t.yAxis,n=t.limitInPlot,a=n;return Zt(i)&&K(n)&&(Object.values(se(i,["min","max","minLimit","maxLimit"])).some(function(o){return!K(o)})?a=!0:a=!1),r.limitInPlot=a,e}function ra(e,r){if(e===!1)return{fields:!1};var t=I(e,"fields"),i=I(e,"formatter");return i&&!t&&(t=r),{fields:t,formatter:i}}function f0(e,r){var t=e.type,i=e.xField,n=e.yField,a=e.colorField,o=e.shapeField,l=e.sizeField,s=e.styleField,u=e.rawFields,c=u===void 0?[]:u,f=[];if(r==="color")f=ye([a||i],c);else if(r==="shape")f=ye([o||i],c);else if(r==="size")f=ye([l||i],c);else{f=ye([i,n,a,o,l,s],c);var h=["x","y","color","shape","size","style"].indexOf(r),v=f[h];f.splice(h,1),f.unshift(v)}var d=us(f.filter(function(x){return!!x})),p=t==="line"&&[i,n].includes(d.join("*"))?"":d.join("*");return{mappingFields:d,tileMappingField:p}}function ff(e,r){if(!!r)return function(){for(var t=[],i=0;i<arguments.length;i++)t[i]=arguments[i];var n={};return e.forEach(function(a,o){n[a]=t[o]}),delete n.undefined,r(n)}}function Ki(e){var r=e.chart,t=e.options,i=t.type,n=t.args,a=t.mapping,o=t.xField,l=t.yField,s=t.colorField,u=t.shapeField,c=t.sizeField,f=t.tooltipFields,h=t.label,v=t.state,d=t.customInfo;if(!a)return e;var p=a.color,x=a.shape,m=a.size,_=a.style,b=a.tooltip,w=r[i](n).position(o+"*"+l);if(Ct(p))s?w.color(s,p):w.color(p);else if(pt(p)){var S=f0(t,"color"),M=S.mappingFields,F=S.tileMappingField;w.color(F,ff(M,p))}else s&&w.color(s,p);if(Ct(x))u?w.shape(u,[x]):w.shape(x);else if(pt(x)){var O=f0(t,"shape"),M=O.mappingFields,F=O.tileMappingField;w.shape(F,ff(M,x))}else u&&w.shape(u,x);if(Mt(m))c?w.size(c,m):w.size(m);else if(pt(m)){var L=f0(t,"size"),M=L.mappingFields,F=L.tileMappingField;w.size(F,ff(M,m))}else c&&w.size(c,m);if(pt(_)){var D=f0(t,"style"),M=D.mappingFields,F=D.tileMappingField;w.style(F,ff(M,_))}else Zt(_)&&w.style(_);if(f===!1?w.tooltip(!1):gi(f)||w.tooltip(f.join("*"),ff(f,b)),h===!1)w.label(!1);else if(h){var k=h.callback,H=h.fields,B=ue(h,["callback","fields"]);w.label({fields:H||[l],callback:k,cfg:Pr(B)})}return v&&w.state(v),d&&w.customInfo(d),[o,l].filter(function(j){return j!==s}).forEach(function(j){r.legend(j,!1)}),A(A({},e),{ext:{geometry:w}})}function Ab(e){var r=e.options,t=r.area,i=r.xField,n=r.yField,a=r.seriesField,o=r.smooth,l=r.tooltip,s=ra(l,[i,n,a]),u=s.fields,c=s.formatter;return t?Ki(J({},e,{options:{type:"area",colorField:a,tooltipFields:u,mapping:A({shape:o?"smooth":"area",tooltip:c},t)}})):e}function Vh(e){var r=e.options,t=r.line,i=r.stepType,n=r.xField,a=r.yField,o=r.seriesField,l=r.smooth,s=r.connectNulls,u=r.tooltip,c=ra(u,[n,a,o]),f=c.fields,h=c.formatter;return t?Ki(J({},e,{options:{type:"line",colorField:o,tooltipFields:f,mapping:ft({shape:i||(l?"smooth":"line"),tooltip:h},t),args:{connectNulls:s}}})):e}function An(e){var r=e.options,t=r.point,i=r.xField,n=r.yField,a=r.seriesField,o=r.sizeField,l=r.shapeField,s=r.tooltip,u=ra(s,[i,n,a,o,l]),c=u.fields,f=u.formatter;return t?Ki(J({},e,{options:{type:"point",colorField:a,shapeField:l,tooltipFields:c,mapping:A({tooltip:f},t)}})):e}function gDt(e){var r=e.chart,t=e.options,i=e.ext,n=t.seriesField,a=t.isGroup,o=t.isStack,l=t.marginRatio,s=t.widthRatio,u=t.groupField,c=t.theme,f=[];if(n&&(a&&f.push({type:"dodge",dodgeBy:u||n,marginRatio:l}),o&&f.push({type:"stack",marginRatio:l})),f.length&&(i==null?void 0:i.geometry)){var h=i==null?void 0:i.geometry;h.adjust(f)}return K(s)||r.theme(J({},Zt(c)?c:rs(c),{columnWidthRatio:s})),e}function ri(e){var r=e.options,t=r.xField,i=r.yField,n=r.interval,a=r.seriesField,o=r.tooltip,l=r.minColumnWidth,s=r.maxColumnWidth,u=r.columnBackground,c=r.dodgePadding,f=r.intervalPadding,h=ra(o,[t,i,a]),v=h.fields,d=h.formatter,p=(n?Ki(J({},e,{options:{type:"interval",colorField:a,tooltipFields:v,mapping:A({tooltip:d},n),args:{dodgePadding:c,intervalPadding:f,minColumnWidth:l,maxColumnWidth:s,background:u}}})):e).ext;return gDt(A(A({},e),{ext:p}))}function Tb(e){var r=e.options,t=r.polygon,i=r.xField,n=r.yField,a=r.seriesField,o=r.tooltip,l=ra(o,[i,n,a]),s=l.fields,u=l.formatter;return t?Ki(J({},e,{options:{type:"polygon",colorField:a,tooltipFields:s,mapping:A({tooltip:u},t)}})):e}function NX(e){var r=e.options,t=r.edge,i=r.xField,n=r.yField,a=r.seriesField,o=r.tooltip,l=ra(o,[i,n,a]),s=l.fields,u=l.formatter;return t?Ki(J({},e,{options:{type:"edge",colorField:a,tooltipFields:s,mapping:A({tooltip:u},t)}})):e}function VP(e){var r=e.options,t=r.schema,i=r.xField,n=r.yField,a=r.seriesField,o=r.tooltip,l=ra(o,[i,n,a]),s=l.fields,u=l.formatter;return t?Ki(J({},e,{options:{type:"schema",colorField:a,tooltipFields:s,mapping:A({tooltip:u},t)}})):e}function yDt(e){var r=e.options,t=r.violin,i=r.xField,n=r.yField,a=r.seriesField,o=r.sizeField,l=r.tooltip,s=ra(l,[i,n,a,o]),u=s.fields,c=s.formatter;return t?Ki(J({},e,{options:{type:"violin",colorField:a,tooltipFields:u,mapping:A({tooltip:c},t)}})):e}function mDt(e){var r=e.chart,t=e.options,i=t.data,n=t.color,a=t.lineStyle,o=t.lineShape,l=t.point,s=t.area,u=t.seriesField,c=l==null?void 0:l.state;r.data(i);var f=J({},e,{options:{shapeField:u,line:{color:n,style:a,shape:o},point:l&&A({color:n,shape:"circle"},l),area:s&&A({color:n},s),label:void 0}}),h=J({},f,{options:{tooltip:!1,state:c}}),v=J({},f,{options:{tooltip:!1,state:c}});return Vh(f),An(h),Ab(v),e}function Mb(e){var r,t,i=e.options,n=i.xAxis,a=i.yAxis,o=i.xField,l=i.yField,s=i.data;return It(We((r={},r[o]=n,r[l]=a,r),(t={},t[o]={type:"cat"},t[l]=RP(s,l),t)))(e)}function xDt(e){var r=e.chart,t=e.options,i=t.reflect;if(i){var n=i;it(n)||(n=[n]);var a=n.map(function(o){return["reflect",o]});r.coordinate({type:"rect",actions:a})}return e}function GX(e){var r=e.chart,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.yField;return i===!1?r.axis(a,!1):r.axis(a,i),n===!1?r.axis(o,!1):r.axis(o,n),e}function zX(e){var r=e.chart,t=e.options,i=t.legend,n=t.seriesField;return i&&n?r.legend(n,i):i===!1&&r.legend(!1),e}function _Dt(e){var r=e.chart,t=e.options,i=t.label,n=t.yField,a=ei(r,"line");if(!i)a.label(!1);else{var o=i.callback,l=ue(i,["callback"]);a.label({fields:[n],callback:o,cfg:A({layout:[{type:"limit-in-plot"},{type:"path-adjust-position"},{type:"point-adjust-position"},{type:"limit-in-plot",cfg:{action:"hide"}}]},Pr(l))})}return e}function bDt(e){var r=e.chart,t=e.options,i=t.isStack;return i&&P(r.geometries,function(n){n.adjust("stack")}),e}function VX(e){return It(mDt,Mb,bDt,ie,xDt,GX,zX,Dr,_Dt,Sb,Ae,ce,Xe(),ac)(e)}var wDt=J({},Dt.getDefaultOptions(),{tooltip:{shared:!0,showMarkers:!0,showCrosshairs:!0,crosshairs:{type:"x"}},legend:{position:"top-left"},isStack:!1}),CDt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.active=function(){var t=this.getView(),i=this.context.event;if(i.data){var n=i.data.items,a=t.geometries.filter(function(o){return o.type==="point"});P(a,function(o){P(o.elements,function(l){var s=lM(n,function(u){return u.data===l.data})!==-1;l.setState("active",s)})})}},r.prototype.reset=function(){var t=this.getView(),i=t.geometries.filter(function(n){return n.type==="point"});P(i,function(n){P(n.elements,function(a){a.setState("active",!1)})})},r.prototype.getView=function(){return this.context.view},r}(Ie);Et("marker-active",CDt);Lt("marker-active",{start:[{trigger:"tooltip:show",action:"marker-active:active"}],end:[{trigger:"tooltip:hide",action:"marker-active:reset"}]});var SDt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="line",t}return r.getDefaultOptions=function(){return wDt},r.prototype.changeData=function(t){this.updateOption({data:t});var i=this,n=i.chart,a=i.options;Mb({chart:n,options:a}),this.chart.changeData(t)},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return VX},r}(Dt);function jX(e,r,t,i){var n=Kr(e,function(a,o){var l=o[t],s=a.has(l)?a.get(l):0,u=o[r];return s=nc(u)?s+u:s,a.set(l,s),a},new Map);return je(e,function(a){var o,l=a[r],s=a[t],u=nc(l)?l/n.get(s):0;return A(A({},a),(o={},o[i]=u,o))})}function ADt(e,r,t,i){var n=Kr(e,function(a,o){var l=Kr(t,function(c,f){return""+c+o[f]},""),s=a.has(l)?a.get(l):0,u=o[r];return s=nc(u)?s+u:s,a.set(l,s),a},new Map);return je(e,function(a){var o,l=a[r],s=Kr(t,function(c,f){return""+c+a[f]},""),u=nc(l)?l/n.get(s):0;return A(A({},a),(o={},o[i]=u,o))})}function Pg(e,r,t,i,n){return n?jX(e,r,t,i):e}function TDt(e){var r=e.chart,t=e.options,i=t.data,n=t.areaStyle,a=t.color,o=t.point,l=t.line,s=t.isPercent,u=t.xField,c=t.yField,f=t.tooltip,h=t.seriesField,v=t.startOnZero,d=o==null?void 0:o.state,p=Pg(i,c,u,c,s);r.data(p);var x=s?A({formatter:function(w){return{name:w[h]||w[u],value:(Number(w[c])*100).toFixed(2)+"%"}}},f):f,m=J({},e,{options:{area:{color:a,style:n},line:l&&A({color:a},l),point:o&&A({color:a},o),tooltip:x,label:void 0,args:{startOnZero:v}}}),_=J({options:{line:{size:2}}},m,{options:{sizeField:h,tooltip:!1}}),b=J({},m,{options:{tooltip:!1,state:d}});return Ab(m),Vh(_),An(b),e}function MDt(e){var r=e.chart,t=e.options,i=t.label,n=t.yField,a=ei(r,"area");if(!i)a.label(!1);else{var o=i.callback,l=ue(i,["callback"]);a.label({fields:[n],callback:o,cfg:A({layout:[{type:"limit-in-plot"},{type:"path-adjust-position"},{type:"point-adjust-position"},{type:"limit-in-plot",cfg:{action:"hide"}}]},Pr(l))})}return e}function EDt(e){var r=e.chart,t=e.options,i=t.isStack,n=t.isPercent,a=t.seriesField;return(n||i)&&a&&P(r.geometries,function(o){o.adjust("stack")}),e}function HX(e){return It(ie,Sn("areaStyle"),TDt,Mb,EDt,GX,zX,Dr,MDt,Sb,Xe(),Ae,ce,ac)(e)}var FDt=J({},Dt.getDefaultOptions(),{tooltip:{shared:!0,showMarkers:!0,showCrosshairs:!0,crosshairs:{type:"x"}},isStack:!0,line:{},legend:{position:"top-left"}}),ODt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="area",t}return r.getDefaultOptions=function(){return FDt},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.changeData=function(t){this.updateOption({data:t});var i=this.options,n=i.isPercent,a=i.xField,o=i.yField,l=this,s=l.chart,u=l.options;Mb({chart:s,options:u}),this.chart.changeData(Pg(t,o,a,o,n))},r.prototype.getSchemaAdaptor=function(){return HX},r}(Dt);function YX(e,r){return!Mt(e)||!Mt(r)?"-":e===r?"100%":e===0?"\u221E":r===0?"-\u221E":(100*r/e).toFixed(2)+"%"}function PDt(e,r){return J({size:r?32:80,spacing:r?8:12,offset:r?32:0,arrow:e.arrow!==!1&&{headSize:12,style:{fill:"rgba(0, 0, 0, 0.05)"}},text:e.text!==!1&&{style:{fontSize:12,fill:"rgba(0, 0, 0, 0.85)",textAlign:"center",textBaseline:"middle"},formatter:YX}},e)}function zx(e,r){return je(r.getModel().points,function(t){return e.convertPoint(t)})}function IDt(e,r,t){var i=e.view,n=e.geometry,a=e.group,o=e.options,l=e.horizontal,s=o.offset,u=o.size,c=o.arrow,f=i.getCoordinate(),h=zx(f,r)[l?3:0],v=zx(f,t)[l?0:3],d=v.y-h.y,p=v.x-h.x;if(typeof c!="boolean"){var x=c.headSize,m=o.spacing,_;l?(p-x)/2<m?(m=Math.max(1,(p-x)/2),_=[[h.x+m,h.y-s],[h.x+m,h.y-s-u],[v.x-m,v.y-s-u/2]]):_=[[h.x+m,h.y-s],[h.x+m,h.y-s-u],[v.x-m-x,v.y-s-u],[v.x-m,v.y-s-u/2],[v.x-m-x,v.y-s]]:(d-x)/2<m?(m=Math.max(1,(d-x)/2),_=[[h.x+s,h.y+m],[h.x+s+u,h.y+m],[v.x+s+u/2,v.y-m]]):_=[[h.x+s,h.y+m],[h.x+s+u,h.y+m],[v.x+s+u,v.y-m-x],[v.x+s+u/2,v.y-m],[v.x+s,v.y-m-x]],a.addShape("polygon",{id:i.id+"-conversion-tag-arrow-"+n.getElementId(r.getModel().mappingData),name:"conversion-tag-arrow",origin:{element:r,nextElement:t},attrs:A(A({},c.style||{}),{points:_})})}}function LDt(e,r,t){var i,n,a,o=e.view,l=e.geometry,s=e.group,u=e.options,c=e.field,f=e.horizontal,h=u.offset,v=u.size;if(typeof u.text!="boolean"){var d=o.getCoordinate(),p=((i=u.text)===null||i===void 0?void 0:i.formatter)&&((n=u.text)===null||n===void 0?void 0:n.formatter(r.getData()[c],t.getData()[c])),x=zx(d,r)[f?3:0],m=zx(d,t)[f?0:3],_=s.addShape("text",{id:o.id+"-conversion-tag-text-"+l.getElementId(r.getModel().mappingData),name:"conversion-tag-text",origin:{element:r,nextElement:t},attrs:A(A({},((a=u.text)===null||a===void 0?void 0:a.style)||{}),{text:p,x:f?(x.x+m.x)/2:x.x+h+v/2,y:f?x.y-h-v/2:(x.y+m.y)/2})});if(f){var b=m.x-x.x,w=_.getBBox().width;if(w>b){var S=w/p.length,M=Math.max(1,Math.ceil(b/S)-1),F=p.slice(0,M)+"...";_.attr("text",F)}}}}function DDt(e,r,t){IDt(e,r,t),LDt(e,r,t)}function $Dt(e,r,t){return r===void 0&&(r=!0),t===void 0&&(t=!1),function(i){var n=i.options,a=i.chart,o=n.conversionTag,l=n.theme;return o&&!t&&(a.theme(J({},Zt(l)?l:rs(l),{columnWidthRatio:1/3})),a.annotation().shape({render:function(s,u){var c=s.addGroup({id:a.id+"-conversion-tag-group",name:"conversion-tag-group"}),f=Yn(a.geometries,function(d){return d.type==="interval"}),h={view:u,geometry:f,group:c,field:e,horizontal:r,options:PDt(o,r)},v=r?f.elements:f.elements.slice().reverse();P(v,function(d,p){p>0&&DDt(h,v[p-1],d)})}})),i}}var Hu={hover:"__interval-connected-area-hover__",click:"__interval-connected-area-click__"},jP=function(e,r){return e==="hover"?[{trigger:"interval:mouseenter",action:["element-highlight-by-color:highlight","element-link-by-color:link"],arg:[null,{style:r}]}]:[{trigger:"interval:click",action:["element-highlight-by-color:clear","element-highlight-by-color:highlight","element-link-by-color:clear","element-link-by-color:unlink","element-link-by-color:link"],arg:[null,null,null,null,{style:r}]}]};Lt(Hu.hover,{start:jP(Hu.hover),end:[{trigger:"interval:mouseleave",action:["element-highlight-by-color:reset","element-link-by-color:unlink"]}]});Lt(Hu.click,{start:jP(Hu.click),end:[{trigger:"document:mousedown",action:["element-highlight-by-color:clear","element-link-by-color:clear"]}]});function kDt(e){return e===void 0&&(e=!1),function(r){var t=r.chart,i=r.options,n=i.connectedArea,a=function(){t.removeInteraction(Hu.hover),t.removeInteraction(Hu.click)};if(!e&&n){var o=n.trigger||"hover";a(),t.interaction(Hu[o],{start:jP(o,n.style)})}else a();return r}}var RDt=10,BDt=5,NDt={padding:[8,10],text:"reset",textStyle:{default:{x:0,y:0,fontSize:12,fill:"#333333",cursor:"pointer"}},buttonStyle:{default:{fill:"#f7f7f7",stroke:"#cccccc",cursor:"pointer"},active:{fill:"#e6e6e6"}}},GDt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.buttonGroup=null,t.buttonCfg=A({name:"button"},NDt),t}return r.prototype.getButtonCfg=function(){var t=this.context.view,i=I(t,["interactions","filter-action","cfg","buttonConfig"]);return J(this.buttonCfg,i,this.cfg)},r.prototype.drawButton=function(){var t=this.getButtonCfg(),i=this.context.view.foregroundGroup.addGroup({name:t.name}),n=this.drawText(i);this.drawBackground(i,n.getBBox()),this.buttonGroup=i},r.prototype.drawText=function(t){var i,n=this.getButtonCfg();return t.addShape({type:"text",name:"button-text",attrs:A({text:n.text},(i=n.textStyle)===null||i===void 0?void 0:i.default)})},r.prototype.drawBackground=function(t,i){var n,a=this.getButtonCfg(),o=Ts(a.padding),l=t.addShape({type:"rect",name:"button-rect",attrs:A({x:i.x-o[3],y:i.y-o[0],width:i.width+o[1]+o[3],height:i.height+o[0]+o[2]},(n=a.buttonStyle)===null||n===void 0?void 0:n.default)});return l.toBack(),t.on("mouseenter",function(){var s;l.attr((s=a.buttonStyle)===null||s===void 0?void 0:s.active)}),t.on("mouseleave",function(){var s;l.attr((s=a.buttonStyle)===null||s===void 0?void 0:s.default)}),l},r.prototype.resetPosition=function(){var t=this.context.view,i=t.getCoordinate(),n=i.convert({x:1,y:1}),a=this.buttonGroup,o=a.getBBox(),l=Fi.transform(null,[["t",n.x-o.width-RDt,n.y+o.height+BDt]]);a.setMatrix(l)},r.prototype.show=function(){this.buttonGroup||this.drawButton(),this.resetPosition(),this.buttonGroup.show()},r.prototype.hide=function(){this.buttonGroup&&this.buttonGroup.hide()},r.prototype.destroy=function(){var t=this.buttonGroup;t&&t.remove(),e.prototype.destroy.call(this)},r}(Ie);Et("brush-reset-button",GDt,{name:"brush-reset-button"});Lt("filter-action",{});function Ro(e){return e.isInPlot()}function mc(e,r,t){var i=r||"rect";switch(e){case"brush":return{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"mousedown",isEnable:Ro,action:["brush:start",i+"-mask:start",i+"-mask:show"],arg:[null,{maskStyle:t==null?void 0:t.style}]}],processing:[{trigger:"mousemove",isEnable:Ro,action:[i+"-mask:resize"]}],end:[{trigger:"mouseup",isEnable:Ro,action:["brush:filter","brush:end",i+"-mask:end",i+"-mask:hide","brush-reset-button:show"]}],rollback:[{trigger:"brush-reset-button:click",action:["brush:reset","brush-reset-button:hide","cursor:crosshair"]}]};case"brush-highlight":return{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"mask:mouseenter",action:"cursor:move"},{trigger:"plot:mouseleave",action:"cursor:default"},{trigger:"mask:mouseleave",action:"cursor:crosshair"}],start:[{trigger:"plot:mousedown",isEnable:function(n){return!n.isInShape("mask")},action:[i+"-mask:start",i+"-mask:show"],arg:[{maskStyle:t==null?void 0:t.style}]},{trigger:"mask:dragstart",action:[i+"-mask:moveStart"]}],processing:[{trigger:"plot:mousemove",action:[i+"-mask:resize"]},{trigger:"mask:drag",action:[i+"-mask:move"]},{trigger:"mask:change",action:["element-range-highlight:highlight"]}],end:[{trigger:"plot:mouseup",action:[i+"-mask:end"]},{trigger:"mask:dragend",action:[i+"-mask:moveEnd"]},{trigger:"document:mouseup",isEnable:function(n){return!n.isInPlot()},action:["element-range-highlight:clear",i+"-mask:end",i+"-mask:hide"]}],rollback:[{trigger:"dblclick",action:["element-range-highlight:clear",i+"-mask:hide"]}]};case"brush-x":return{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"mousedown",isEnable:Ro,action:["brush-x:start",i+"-mask:start",i+"-mask:show"],arg:[null,{maskStyle:t==null?void 0:t.style}]}],processing:[{trigger:"mousemove",isEnable:Ro,action:[i+"-mask:resize"]}],end:[{trigger:"mouseup",isEnable:Ro,action:["brush-x:filter","brush-x:end",i+"-mask:end",i+"-mask:hide"]}],rollback:[{trigger:"dblclick",action:["brush-x:reset"]}]};case"brush-x-highlight":return{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"mask:mouseenter",action:"cursor:move"},{trigger:"plot:mouseleave",action:"cursor:default"},{trigger:"mask:mouseleave",action:"cursor:crosshair"}],start:[{trigger:"plot:mousedown",isEnable:function(n){return!n.isInShape("mask")},action:[i+"-mask:start",i+"-mask:show"],arg:[{maskStyle:t==null?void 0:t.style}]},{trigger:"mask:dragstart",action:[i+"-mask:moveStart"]}],processing:[{trigger:"plot:mousemove",action:[i+"-mask:resize"]},{trigger:"mask:drag",action:[i+"-mask:move"]},{trigger:"mask:change",action:["element-range-highlight:highlight"]}],end:[{trigger:"plot:mouseup",action:[i+"-mask:end"]},{trigger:"mask:dragend",action:[i+"-mask:moveEnd"]},{trigger:"document:mouseup",isEnable:function(n){return!n.isInPlot()},action:["element-range-highlight:clear",i+"-mask:end",i+"-mask:hide"]}],rollback:[{trigger:"dblclick",action:["element-range-highlight:clear",i+"-mask:hide"]}]};case"brush-y":return{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"plot:mouseleave",action:"cursor:default"}],start:[{trigger:"mousedown",isEnable:Ro,action:["brush-y:start",i+"-mask:start",i+"-mask:show"],arg:[null,{maskStyle:t==null?void 0:t.style}]}],processing:[{trigger:"mousemove",isEnable:Ro,action:[i+"-mask:resize"]}],end:[{trigger:"mouseup",isEnable:Ro,action:["brush-y:filter","brush-y:end",i+"-mask:end",i+"-mask:hide"]}],rollback:[{trigger:"dblclick",action:["brush-y:reset"]}]};case"brush-y-highlight":return{showEnable:[{trigger:"plot:mouseenter",action:"cursor:crosshair"},{trigger:"mask:mouseenter",action:"cursor:move"},{trigger:"plot:mouseleave",action:"cursor:default"},{trigger:"mask:mouseleave",action:"cursor:crosshair"}],start:[{trigger:"plot:mousedown",isEnable:function(n){return!n.isInShape("mask")},action:[i+"-mask:start",i+"-mask:show"],arg:[{maskStyle:t==null?void 0:t.style}]},{trigger:"mask:dragstart",action:[i+"-mask:moveStart"]}],processing:[{trigger:"plot:mousemove",action:[i+"-mask:resize"]},{trigger:"mask:drag",action:[i+"-mask:move"]},{trigger:"mask:change",action:["element-range-highlight:highlight"]}],end:[{trigger:"plot:mouseup",action:[i+"-mask:end"]},{trigger:"mask:dragend",action:[i+"-mask:moveEnd"]},{trigger:"document:mouseup",isEnable:function(n){return!n.isInPlot()},action:["element-range-highlight:clear",i+"-mask:end",i+"-mask:hide"]}],rollback:[{trigger:"dblclick",action:["element-range-highlight:clear",i+"-mask:hide"]}]};default:return{}}}Lt("brush",mc("brush"));Lt("brush-highlight",mc("brush-highlight"));Lt("brush-x",mc("brush-x","x-rect"));Lt("brush-y",mc("brush-y","y-rect"));Lt("brush-x-highlight",mc("brush-x-highlight","x-rect"));Lt("brush-y-highlight",mc("brush-y-highlight","y-rect"));var tG=["brush","brush-x","brush-y","brush-highlight","brush-x-highlight","brush-y-highlight"];function WX(e){var r=e.options,t=r.brush,i=jr(r.interactions||[],function(n){return tG.indexOf(n.type)===-1});return t!=null&&t.enabled&&(tG.forEach(function(n){var a,o=!1;switch(t.type){case"x-rect":o=n===(t.action==="highlight"?"brush-x-highlight":"brush-x");break;case"y-rect":o=n===(t.action==="highlight"?"brush-y-highlight":"brush-y");break;default:o=n===(t.action==="highlight"?"brush-highlight":"brush");break}var l={type:n,enable:o};(((a=t.mask)===null||a===void 0?void 0:a.style)||t.type)&&(l.cfg=mc(n,t.type,t.mask)),i.push(l)}),(t==null?void 0:t.action)!=="highlight"&&i.push({type:"filter-action",cfg:{buttonConfig:t.button}})),J({},e,{options:{interactions:i}})}function zDt(e){var r=e.options,t=r.legend,i=r.seriesField,n=r.isStack;return i?t!==!1&&(t=A({position:n?"right-top":"top-left"},t)):t=!1,e.options.legend=t,e}function VDt(e){var r=e.chart,t=e.options,i=t.data,n=t.columnStyle,a=t.color,o=t.columnWidthRatio,l=t.isPercent,s=t.isGroup,u=t.isStack,c=t.xField,f=t.yField,h=t.seriesField,v=t.groupField,d=t.tooltip,p=t.shape,x=l&&s&&u?ADt(i,f,[c,v],f):Pg(i,f,c,f,l),m=[];u&&h&&!s?x.forEach(function(w){var S=m.find(function(M){return M[c]===w[c]&&M[h]===w[h]});S?S[f]+=w[f]||0:m.push(A({},w))}):m=x,r.data(m);var _=l?A({formatter:function(w){return{name:s&&u?w[h]+" - "+w[v]:w[h]||w[c],value:(Number(w[f])*100).toFixed(2)+"%"}}},d):d,b=J({},e,{options:{data:m,widthRatio:o,tooltip:_,interval:{shape:p,style:n,color:a}}});return ri(b),b}function HP(e){var r,t,i=e.options,n=i.xAxis,a=i.yAxis,o=i.xField,l=i.yField,s=i.data,u=i.isPercent,c=u?{max:1,min:0,minLimit:0,maxLimit:1}:{};return It(We((r={},r[o]=n,r[l]=a,r),(t={},t[o]={type:"cat"},t[l]=A(A({},RP(s,l)),c),t)))(e)}function jDt(e){var r=e.chart,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.yField;return i===!1?r.axis(a,!1):r.axis(a,i),n===!1?r.axis(o,!1):r.axis(o,n),e}function HDt(e){var r=e.chart,t=e.options,i=t.legend,n=t.seriesField;return i&&n?r.legend(n,i):i===!1&&r.legend(!1),e}function YDt(e){var r=e.chart,t=e.options,i=t.label,n=t.yField,a=t.isRange,o=ei(r,"interval");if(!i)o.label(!1);else{var l=i.callback,s=ue(i,["callback"]);o.label({fields:[n],callback:l,cfg:A({layout:s!=null&&s.position?void 0:[{type:"interval-adjust-position"},{type:"interval-hide-overlap"},{type:"adjust-color"},{type:"limit-in-plot",cfg:{action:"hide"}}]},Pr(a?A({content:function(u){var c;return(c=u[n])===null||c===void 0?void 0:c.join("-")}},s):s))})}return e}function WDt(e){var r=e.chart,t=e.options,i=t.tooltip,n=t.isGroup,a=t.isStack,o=t.groupField,l=t.data,s=t.xField,u=t.yField,c=t.seriesField;if(i===!1)r.tooltip(!1);else{var f=i;if(n&&a){var h=(f==null?void 0:f.formatter)||function(v){return{name:v[c]+" - "+v[o],value:v[u]}};f=A(A({},f),{customItems:function(v){var d=[];return P(v,function(p){var x=jr(l,function(m){return oM(m,se(p.data,[s,c]))});x.forEach(function(m){d.push(A(A(A({},p),{value:m[u],data:m,mappingData:{_origin:m}}),h(m)))})}),d}})}r.tooltip(f)}return e}function Eb(e,r){r===void 0&&(r=!1);var t=e.options,i=t.seriesField;return It(zDt,ie,Sn("columnStyle"),Rs,VDt,HP,jDt,HDt,WDt,Sb,pDt,YDt,WX,Ae,ce,Xe(),$Dt(t.yField,!r,!!i),kDt(!t.isStack),ac)(e)}var XDt=J({},Dt.getDefaultOptions(),{columnWidthRatio:.6,marginRatio:1/32,tooltip:{shared:!0,showMarkers:!1,offset:20},interactions:[{type:"active-region"}]}),UDt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="column",t}return r.getDefaultOptions=function(){return XDt},r.prototype.changeData=function(t){this.updateOption({data:t});var i=this.options,n=i.yField,a=i.xField,o=i.isPercent,l=this,s=l.chart,u=l.options;HP({chart:s,options:u}),this.chart.changeData(Pg(t,n,a,n,o))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return Eb},r}(Dt);function XX(e){return e&&e.slice().reverse()}function UX(e){var r=e.chart,t=e.options,i=t.xField,n=t.yField,a=t.xAxis,o=t.yAxis,l=t.barStyle,s=t.barWidthRatio,u=t.label,c=t.data,f=t.seriesField,h=t.isStack,v=t.minBarWidth,d=t.maxBarWidth;u&&!u.position&&(u.position="left",u.layout||(u.layout=[{type:"interval-adjust-position"},{type:"interval-hide-overlap"},{type:"adjust-color"},{type:"limit-in-plot",cfg:{action:"hide"}}]));var p=t.legend;f?p!==!1&&(p=A({position:h?"top-left":"right-top",reversed:!h},p||{})):p=!1,e.options.legend=p;var x=t.tooltip;return f&&x!==!1&&(x=A({reversed:!h},x||{})),e.options.tooltip=x,r.coordinate().transpose(),Eb({chart:r,options:A(A({},t),{label:u,xField:n,yField:i,xAxis:o,yAxis:a,columnStyle:l,columnWidthRatio:s,minColumnWidth:v,maxColumnWidth:d,columnBackground:t.barBackground,data:XX(c)})},!0)}var qDt=J({},Dt.getDefaultOptions(),{barWidthRatio:.6,marginRatio:1/32,tooltip:{shared:!0,showMarkers:!1,offset:20},interactions:[{type:"active-region"}]}),ZDt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="bar",t}return r.getDefaultOptions=function(){return qDt},r.prototype.changeData=function(t){this.updateOption({data:t});var i=this,n=i.chart,a=i.options,o=a.xField,l=a.yField,s=a.isPercent,u=A(A({},a),{xField:l,yField:o});HP({chart:n,options:u}),n.changeData(Pg(XX(t),o,l,o,s))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return UX},r}(Dt),qX=J({},Dt.getDefaultOptions(),{legend:{position:"right"},tooltip:{shared:!1,showTitle:!1,showMarkers:!1},label:{layout:{type:"limit-in-plot",cfg:{action:"ellipsis"}}},pieStyle:{stroke:"white",lineWidth:1},statistic:{title:{style:{fontWeight:300,color:"#4B535E",textAlign:"center",fontSize:"20px",lineHeight:1}},content:{style:{fontWeight:"bold",color:"rgba(44,53,66,0.85)",textAlign:"center",fontSize:"32px",lineHeight:1}}},theme:{components:{annotation:{text:{animate:!1}}}}});function QDt(e,r){var t=null;return P(e,function(i){typeof i[r]=="number"&&(t+=i[r])}),t}function KDt(e,r){var t;switch(e){case"inner":return t="-30%",Ct(r)&&r.endsWith("%")?parseFloat(r)*.01>0?t:r:r<0?r:t;case"outer":return t=12,Ct(r)&&r.endsWith("%")?parseFloat(r)*.01<0?t:r:r>0?r:t;default:return r}}function Vx(e,r){return Zx(ph(e,r),function(t){return t[r]===0})}var JDt=[1,0,0,0,1,0,0,0,1];function WT(e,r){var t=r?ye(r):ye(JDt);return Fi.transform(t,e)}var t$t=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getActiveElements=function(){var t=Fi.getDelegationObject(this.context);if(t){var i=this.context.view,n=t.component,a=t.item,o=n.get("field");if(o){var l=i.geometries[0].elements;return l.filter(function(s){return s.getModel().data[o]===a.value})}}return[]},r.prototype.getActiveElementLabels=function(){var t=this.context.view,i=this.getActiveElements(),n=t.geometries[0].labelsContainer.getChildren();return n.filter(function(a){return i.find(function(o){return Ge(o.getData(),a.get("data"))})})},r.prototype.transfrom=function(t){t===void 0&&(t=7.5);var i=this.getActiveElements(),n=this.getActiveElementLabels();i.forEach(function(a,o){var l=n[o],s=a.geometry.coordinate;if(s.isPolar&&s.isTransposed){var u=Fi.getAngle(a.getModel(),s),c=u.startAngle,f=u.endAngle,h=(c+f)/2,v=t,d=v*Math.cos(h),p=v*Math.sin(h);a.shape.setMatrix(WT([["t",d,p]])),l.setMatrix(WT([["t",d,p]]))}})},r.prototype.active=function(){this.transfrom()},r.prototype.reset=function(){this.transfrom(0)},r}(Ie);function e$t(e){var r=e.event,t,i=r.target;return i&&(t=i.get("element")),t}var r$t=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getAnnotations=function(t){var i=t||this.context.view;return i.getController("annotation").option},r.prototype.getInitialAnnotation=function(){return this.initialAnnotation},r.prototype.init=function(){var t=this,i=this.context.view;i.removeInteraction("tooltip"),i.on("afterchangesize",function(){var n=t.getAnnotations(i);t.initialAnnotation=n})},r.prototype.change=function(t){var i=this.context,n=i.view,a=i.event;this.initialAnnotation||(this.initialAnnotation=this.getAnnotations());var o=I(a,["data","data"]);if(a.type.match("legend-item")){var l=Fi.getDelegationObject(this.context),s=n.getGroupedFields()[0];if(l&&s){var u=l.item;o=n.getData().find(function(v){return v[s]===u.value})}}if(o){var c=I(t,"annotations",[]),f=I(t,"statistic",{});n.getController("annotation").clear(!0),P(c,function(v){typeof v=="object"&&n.annotation()[v.type](v)}),_b(n,{statistic:f,plotType:"pie"},o),n.render(!0)}var h=e$t(this.context);h&&h.shape.toFront()},r.prototype.reset=function(){var t=this.context.view,i=t.getController("annotation");i.clear(!0);var n=this.getInitialAnnotation();P(n,function(a){t.annotation()[a.type](a)}),t.render(!0)},r}(Ie),ZX="pie-statistic";Et(ZX,r$t);Lt("pie-statistic-active",{start:[{trigger:"element:mouseenter",action:"pie-statistic:change"}],end:[{trigger:"element:mouseleave",action:"pie-statistic:reset"}]});Et("pie-legend",t$t);Lt("pie-legend-active",{start:[{trigger:"legend-item:mouseenter",action:"pie-legend:active"}],end:[{trigger:"legend-item:mouseleave",action:"pie-legend:reset"}]});function i$t(e){var r=e.chart,t=e.options,i=t.data,n=t.angleField,a=t.colorField,o=t.color,l=t.pieStyle,s=ph(i,n);if(Vx(s,n)){var u="$$percentage$$";s=s.map(function(f){var h;return A(A({},f),(h={},h[u]=1/s.length,h))}),r.data(s);var c=J({},e,{options:{xField:"1",yField:u,seriesField:a,isStack:!0,interval:{color:o,style:l},args:{zIndexReversed:!0}}});ri(c)}else{r.data(s);var c=J({},e,{options:{xField:"1",yField:n,seriesField:a,isStack:!0,interval:{color:o,style:l},args:{zIndexReversed:!0}}});ri(c)}return e}function n$t(e){var r,t=e.chart,i=e.options,n=i.meta,a=i.colorField,o=J({},n);return t.scale(o,(r={},r[a]={type:"cat"},r)),e}function a$t(e){var r=e.chart,t=e.options,i=t.radius,n=t.innerRadius,a=t.startAngle,o=t.endAngle;return r.coordinate({type:"theta",cfg:{radius:i,innerRadius:n,startAngle:a,endAngle:o}}),e}function o$t(e){var r=e.chart,t=e.options,i=t.label,n=t.colorField,a=t.angleField,o=r.geometries[0];if(!i)o.label(!1);else{var l=i.callback,s=ue(i,["callback"]),u=Pr(s);if(u.content){var c=u.content;u.content=function(d,p,x){var m=d[n],_=d[a],b=r.getScaleByField(a),w=b==null?void 0:b.scale(_);return pt(c)?c(A(A({},d),{percent:w}),p,x):Ct(c)?FX(c,{value:_,name:m,percentage:Mt(w)&&!K(_)?(w*100).toFixed(2)+"%":null}):c}}var f={inner:"",outer:"pie-outer",spider:"pie-spider"},h=u.type?f[u.type]:"pie-outer",v=u.layout?it(u.layout)?u.layout:[u.layout]:[];u.layout=(h?[{type:h}]:[]).concat(v),o.label({fields:n?[a,n]:[a],callback:l,cfg:A(A({},u),{offset:KDt(u.type,u.offset),type:"pie"})})}return e}function QX(e){var r=e.innerRadius,t=e.statistic,i=e.angleField,n=e.colorField,a=e.meta,o=e.locale,l=wb(o);if(r&&t){var s=J({},qX.statistic,t),u=s.title,c=s.content;return u!==!1&&(u=J({},{formatter:function(f){return f?f[n]:K(u.content)?l.get(["statistic","total"]):u.content}},u)),c!==!1&&(c=J({},{formatter:function(f,h){var v=f?f[i]:QDt(h,i),d=I(a,[i,"formatter"])||function(p){return p};return f||K(c.content)?d(v):c.content}},c)),J({},{statistic:{title:u,content:c}},e)}return e}function KX(e){var r=e.chart,t=e.options,i=QX(t),n=i.innerRadius,a=i.statistic;return r.getController("annotation").clear(!0),It(Xe())(e),n&&a&&_b(r,{statistic:a,plotType:"pie"}),e}function l$t(e){var r=e.chart,t=e.options,i=t.tooltip,n=t.colorField,a=t.angleField,o=t.data;if(i===!1)r.tooltip(i);else if(r.tooltip(J({},i,{shared:!1})),Vx(o,a)){var l=I(i,"fields"),s=I(i,"formatter");gi(I(i,"fields"))&&(l=[n,a],s=s||function(u){return{name:u[n],value:Fs(u[a])}}),r.geometries[0].tooltip(l.join("*"),ff(l,s))}return e}function s$t(e){var r=e.chart,t=e.options,i=QX(t),n=i.interactions,a=i.statistic,o=i.annotations;return P(n,function(l){var s,u;if(l.enable===!1)r.removeInteraction(l.type);else if(l.type==="pie-statistic-active"){var c=[];!((s=l.cfg)===null||s===void 0)&&s.start||(c=[{trigger:"element:mouseenter",action:ZX+":change",arg:{statistic:a,annotations:o}}]),P((u=l.cfg)===null||u===void 0?void 0:u.start,function(f){c.push(A(A({},f),{arg:{statistic:a,annotations:o}}))}),r.interaction(l.type,J({},l.cfg,{start:c}))}else r.interaction(l.type,l.cfg||{})}),e}function JX(e){return It(Sn("pieStyle"),i$t,n$t,ie,a$t,Og,l$t,o$t,Rs,KX,s$t,ce)(e)}var u$t=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="pie",t}return r.getDefaultOptions=function(){return qX},r.prototype.changeData=function(t){this.chart.emit(Gt.BEFORE_CHANGE_DATA,$e.fromData(this.chart,Gt.BEFORE_CHANGE_DATA,null));var i=this.options,n=this.options.angleField,a=ph(i.data,n),o=ph(t,n);Vx(a,n)||Vx(o,n)?this.update({data:t}):(this.updateOption({data:t}),this.chart.data(o),KX({chart:this.chart,options:this.options}),this.chart.render(!0)),this.chart.emit(Gt.AFTER_CHANGE_DATA,$e.fromData(this.chart,Gt.AFTER_CHANGE_DATA,null))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return JX},r}(Dt);function c$t(e){var r=e.chart,t=e.options,i=t.data,n=t.sectorStyle,a=t.color;return r.data(i),It(ri)(J({},e,{options:{marginRatio:1,interval:{style:n,color:a}}})),e}function f$t(e){var r=e.chart,t=e.options,i=t.label,n=t.xField,a=ei(r,"interval");if(i===!1)a.label(!1);else if(Zt(i)){var o=i.callback,l=i.fields,s=ue(i,["callback","fields"]),u=s.offset,c=s.layout;(u===void 0||u>=0)&&(c=c?it(c)?c:[c]:[],s.layout=jr(c,function(f){return f.type!=="limit-in-shape"}),s.layout.length||delete s.layout),a.label({fields:l||[n],callback:o,cfg:Pr(s)})}else ul(Fa.WARN,i===null,"the label option must be an Object."),a.label({fields:[n]});return e}function h$t(e){var r=e.chart,t=e.options,i=t.legend,n=t.seriesField;return i===!1?r.legend(!1):n&&r.legend(n,i),e}function v$t(e){var r=e.chart,t=e.options,i=t.radius,n=t.innerRadius,a=t.startAngle,o=t.endAngle;return r.coordinate({type:"polar",cfg:{radius:i,innerRadius:n,startAngle:a,endAngle:o}}),e}function d$t(e){var r,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.yField;return It(We((r={},r[a]=i,r[o]=n,r)))(e)}function p$t(e){var r=e.chart,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.yField;return i?r.axis(a,i):r.axis(a,!1),n?r.axis(o,n):r.axis(o,!1),e}function g$t(e){It(Sn("sectorStyle"),c$t,d$t,f$t,v$t,p$t,h$t,Dr,Ae,ce,ie,Xe(),Rs)(e)}var y$t=J({},Dt.getDefaultOptions(),{xAxis:!1,yAxis:!1,legend:{position:"right"},sectorStyle:{stroke:"#fff",lineWidth:1},label:{layout:{type:"limit-in-shape"}},tooltip:{shared:!0,showMarkers:!1},interactions:[{type:"active-region"}]});(function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="rose",t}return r.getDefaultOptions=function(){return y$t},r.prototype.changeData=function(t){this.updateOption({data:t}),this.chart.changeData(t)},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return g$t},r})(Dt);var m$t={font:function(){return"serif"},padding:1,size:[500,500],spiral:"archimedean",timeInterval:3e3};function x$t(e,r){return r=Kt({},m$t,r),_$t(e,r)}function _$t(e,r){var t=L$t();["font","fontSize","fontWeight","padding","rotate","size","spiral","timeInterval","random"].forEach(function(s){K(r[s])||t[s](r[s])}),t.words(e),r.imageMask&&t.createMask(r.imageMask);var i=t.start(),n=i._tags;n.forEach(function(s){s.x+=r.size[0]/2,s.y+=r.size[1]/2});var a=r.size,o=a[0],l=a[1];return n.push({text:"",value:0,x:0,y:0,opacity:0}),n.push({text:"",value:0,x:o,y:l,opacity:0}),n}var KS=Math.PI/180,ld=1<<11>>5,$0=1<<11;function b$t(e){return e.text}function w$t(){return"serif"}function eG(){return"normal"}function C$t(e){return e.value}function S$t(){return~~(Math.random()*2)*90}function A$t(){return 1}function T$t(e,r,t,i){if(!r.sprite){var n=e.context,a=e.ratio;n.clearRect(0,0,(ld<<5)/a,$0/a);var o=0,l=0,s=0,u=t.length;for(--i;++i<u;){r=t[i],n.save(),n.font=r.style+" "+r.weight+" "+~~((r.size+1)/a)+"px "+r.font;var c=n.measureText(r.text+"m").width*a,f=r.size<<1;if(r.rotate){var h=Math.sin(r.rotate*KS),v=Math.cos(r.rotate*KS),d=c*v,p=c*h,x=f*v,m=f*h;c=Math.max(Math.abs(d+m),Math.abs(d-m))+31>>5<<5,f=~~Math.max(Math.abs(p+x),Math.abs(p-x))}else c=c+31>>5<<5;if(f>s&&(s=f),o+c>=ld<<5&&(o=0,l+=s,s=0),l+f>=$0)break;n.translate((o+(c>>1))/a,(l+(f>>1))/a),r.rotate&&n.rotate(r.rotate*KS),n.fillText(r.text,0,0),r.padding&&(n.lineWidth=2*r.padding,n.strokeText(r.text,0,0)),n.restore(),r.width=c,r.height=f,r.xoff=o,r.yoff=l,r.x1=c>>1,r.y1=f>>1,r.x0=-r.x1,r.y0=-r.y1,r.hasText=!0,o+=c}for(var _=n.getImageData(0,0,(ld<<5)/a,$0/a).data,b=[];--i>=0;)if(r=t[i],!!r.hasText){for(var c=r.width,w=c>>5,f=r.y1-r.y0,S=0;S<f*w;S++)b[S]=0;if(o=r.xoff,o==null)return;l=r.yoff;for(var M=0,F=-1,O=0;O<f;O++){for(var S=0;S<c;S++){var L=w*O+(S>>5),D=_[(l+O)*(ld<<5)+(o+S)<<2]?1<<31-S%32:0;b[L]|=D,M|=D}M?F=O:(r.y0++,f--,O--,l++)}r.y1=r.y0+F,r.sprite=b.slice(0,(r.y1-r.y0)*w)}}}function M$t(e,r,t){t>>=5;for(var i=e.sprite,n=e.width>>5,a=e.x-(n<<4),o=a&127,l=32-o,s=e.y1-e.y0,u=(e.y+e.y0)*t+(a>>5),c,f=0;f<s;f++){c=0;for(var h=0;h<=n;h++)if((c<<l|(h<n?(c=i[f*n+h])>>>o:0))&r[u+h])return!0;u+=t}return!1}function E$t(e,r){var t=e[0],i=e[1];r.x+r.x0<t.x&&(t.x=r.x+r.x0),r.y+r.y0<t.y&&(t.y=r.y+r.y0),r.x+r.x1>i.x&&(i.x=r.x+r.x1),r.y+r.y1>i.y&&(i.y=r.y+r.y1)}function F$t(e,r){return e.x+e.x1>r[0].x&&e.x+e.x0<r[1].x&&e.y+e.y1>r[0].y&&e.y+e.y0<r[1].y}function t6(e){var r=e[0]/e[1];return function(t){return[r*(t*=.1)*Math.cos(t),t*Math.sin(t)]}}function O$t(e){var r=4,t=r*e[0]/e[1],i=0,n=0;return function(a){var o=a<0?-1:1;switch(Math.sqrt(1+4*o*a)-o&3){case 0:i+=t;break;case 1:n+=r;break;case 2:i-=t;break;default:n-=r;break}return[i,n]}}function rG(e){for(var r=[],t=-1;++t<e;)r[t]=0;return r}function P$t(){return document.createElement("canvas")}function to(e){return pt(e)?e:function(){return e}}var I$t={archimedean:t6,rectangular:O$t};function L$t(){var e=[256,256],r=w$t,t=C$t,i=eG,n=S$t,a=A$t,o=t6,l=Math.random,s=[],u=1/0,c=b$t,f=eG,h=P$t,v={};v.start=function(){var x=e[0],m=e[1],_=d(h()),b=v.board?v.board:rG((e[0]>>5)*e[1]),w=s.length,S=[],M=s.map(function(D,k,H){return D.text=c.call(this,D,k,H),D.font=r.call(this,D,k,H),D.style=f.call(this,D,k,H),D.weight=i.call(this,D,k,H),D.rotate=n.call(this,D,k,H),D.size=~~t.call(this,D,k,H),D.padding=a.call(this,D,k,H),D}).sort(function(D,k){return k.size-D.size}),F=-1,O=v.board?[{x:0,y:0},{x,y:m}]:null;L();function L(){for(var D=Date.now();Date.now()-D<u&&++F<w;){var k=M[F];k.x=x*(l()+.5)>>1,k.y=m*(l()+.5)>>1,T$t(_,k,M,F),k.hasText&&p(b,k,O)&&(S.push(k),O?v.hasImage||E$t(O,k):O=[{x:k.x+k.x0,y:k.y+k.y0},{x:k.x+k.x1,y:k.y+k.y1}],k.x-=e[0]>>1,k.y-=e[1]>>1)}v._tags=S,v._bounds=O}return v};function d(x){x.width=x.height=1;var m=Math.sqrt(x.getContext("2d").getImageData(0,0,1,1).data.length>>2);x.width=(ld<<5)/m,x.height=$0/m;var _=x.getContext("2d");return _.fillStyle=_.strokeStyle="red",_.textAlign="center",{context:_,ratio:m}}function p(x,m,_){for(var b=m.x,w=m.y,S=Math.sqrt(e[0]*e[0]+e[1]*e[1]),M=o(e),F=l()<.5?1:-1,O,L=-F,D,k;(O=M(L+=F))&&(D=~~O[0],k=~~O[1],!(Math.min(Math.abs(D),Math.abs(k))>=S));)if(m.x=b+D,m.y=w+k,!(m.x+m.x0<0||m.y+m.y0<0||m.x+m.x1>e[0]||m.y+m.y1>e[1])&&(!_||!M$t(m,x,e[0]))&&(!_||F$t(m,_))){for(var H=m.sprite,B=m.width>>5,j=e[0]>>5,U=m.x-(B<<4),R=U&127,G=32-R,N=m.y1-m.y0,W=void 0,q=(m.y+m.y0)*j+(U>>5),tt=0;tt<N;tt++){W=0;for(var ot=0;ot<=B;ot++)x[q+ot]|=W<<G|(ot<B?(W=H[tt*B+ot])>>>R:0);q+=j}return delete m.sprite,!0}return!1}return v.createMask=function(x){var m=document.createElement("canvas"),_=e[0],b=e[1];if(!(!_||!b)){var w=_>>5,S=rG((_>>5)*b);m.width=_,m.height=b;var M=m.getContext("2d");M.drawImage(x,0,0,x.width,x.height,0,0,_,b);for(var F=M.getImageData(0,0,_,b).data,O=0;O<b;O++)for(var L=0;L<_;L++){var D=w*O+(L>>5),k=O*_+L<<2,H=F[k]>=250&&F[k+1]>=250&&F[k+2]>=250,B=H?1<<31-L%32:0;S[D]|=B}v.board=S,v.hasImage=!0}},v.timeInterval=function(x){u=x==null?1/0:x},v.words=function(x){s=x},v.size=function(x){e=[+x[0],+x[1]]},v.font=function(x){r=to(x)},v.fontWeight=function(x){i=to(x)},v.rotate=function(x){n=to(x)},v.spiral=function(x){o=I$t[x]||x},v.fontSize=function(x){t=to(x)},v.padding=function(x){a=to(x)},v.random=function(x){l=to(x)},v}function e6(e){var r=e.options,t=e.chart,i=t,n=i.width,a=i.height,o=i.padding,l=i.appendPadding,s=i.ele,u=r.data,c=r.imageMask,f=r.wordField,h=r.weightField,v=r.colorField,d=r.wordStyle,p=r.timeInterval,x=r.random,m=r.spiral,_=r.autoFit,b=_===void 0?!0:_,w=r.placementStrategy;if(!u||!u.length)return[];var S=d.fontFamily,M=d.fontWeight,F=d.padding,O=d.fontSize,L=B$t(u,h),D=[z$t(L),V$t(L)],k=u.map(function(j){return{text:j[f],value:j[h],color:j[v],datum:j}}),H={imageMask:c,font:S,fontSize:R$t(O,D),fontWeight:M,size:D$t({width:n,height:a,padding:o,appendPadding:l,autoFit:b,container:s}),padding:F,timeInterval:p,random:x,spiral:m,rotate:N$t(r)};if(pt(w)){var B=k.map(function(j,U,R){return A(A(A({},j),{hasText:!!j.text,font:to(H.font)(j,U,R),weight:to(H.fontWeight)(j,U,R),rotate:to(H.rotate)(j,U,R),size:to(H.fontSize)(j,U,R),style:"normal"}),w.call(t,j,U,R))});return B.push({text:"",value:0,x:0,y:0,opacity:0}),B.push({text:"",value:0,x:H.size[0],y:H.size[1],opacity:0}),B}return x$t(k,H)}function D$t(e){var r=e.width,t=e.height,i=e.container,n=e.autoFit,a=e.padding,o=e.appendPadding;if(n){var l=YT(i);r=l.width,t=l.height}r=r||400,t=t||400;var s=$$t({padding:a,appendPadding:o}),u=s[0],c=s[1],f=s[2],h=s[3],v=[r-(h+c),t-(u+f)];return v}function $$t(e){var r=Ts(e.padding),t=Ts(e.appendPadding),i=r[0]+t[0],n=r[1]+t[1],a=r[2]+t[2],o=r[3]+t[3];return[i,n,a,o]}function k$t(e){return new Promise(function(r,t){if(e instanceof HTMLImageElement){r(e);return}if(Ct(e)){var i=new Image;i.crossOrigin="anonymous",i.src=e,i.onload=function(){r(i)},i.onerror=function(){ul(Fa.ERROR,!1,"image %s load failed !!!",e),t()};return}ul(Fa.WARN,e===void 0,"The type of imageMask option must be String or HTMLImageElement."),t()})}function R$t(e,r){if(pt(e))return e;if(it(e)){var t=e[0],i=e[1];if(!r)return function(){return(i+t)/2};var n=r[0],a=r[1];return a===n?function(){return(i+t)/2}:function(l){var s=l.value;return(i-t)/(a-n)*(s-n)+t}}return function(){return e}}function B$t(e,r){return e.map(function(t){return t[r]}).filter(function(t){return typeof t=="number"&&!isNaN(t)})}function N$t(e){var r=G$t(e),t=r.rotation,i=r.rotationSteps;if(!it(t))return t;var n=t[0],a=t[1],o=i===1?0:(a-n)/(i-1);return function(){return a===n?a:Math.floor(Math.random()*i)*o}}function G$t(e){var r=e.wordStyle.rotationSteps;return r<1&&(ul(Fa.WARN,!1,"The rotationSteps option must be greater than or equal to 1."),r=1),{rotation:e.wordStyle.rotation,rotationSteps:r}}function z$t(e){return Math.min.apply(Math,e)}function V$t(e){return Math.max.apply(Math,e)}var YP="color",j$t=J({},Dt.getDefaultOptions(),{timeInterval:2e3,legend:!1,tooltip:{showTitle:!1,showMarkers:!1,showCrosshairs:!1,fields:["text","value",YP],formatter:function(e){return{name:e.text,value:e.value}}},wordStyle:{fontFamily:"Verdana",fontWeight:"normal",padding:1,fontSize:[12,60],rotation:[0,90],rotationSteps:2,rotateRatio:.5}});function H$t(e){var r=e.chart,t=e.options,i=t.colorField,n=t.color,a=e6(e);r.data(a);var o=J({},e,{options:{xField:"x",yField:"y",seriesField:i&&YP,rawFields:pt(n)&&ye(I(t,"rawFields",[]),["datum"]),point:{color:n,shape:"word-cloud"}}}),l=An(o).ext;return l.geometry.label(!1),r.coordinate().reflect("y"),r.axis(!1),e}function Y$t(e){return It(We({x:{nice:!1},y:{nice:!1}}))(e)}function W$t(e){var r=e.chart,t=e.options,i=t.legend,n=t.colorField;return i===!1?r.legend(!1):n&&r.legend(YP,i),e}function X$t(e){It(H$t,Y$t,Dr,W$t,Ae,ce,ie,Rs)(e)}te("point","word-cloud",{draw:function(e,r){var t=e.x,i=e.y,n=r.addShape("text",{attrs:A(A({},U$t(e)),{x:t,y:i})}),a=e.data.rotate;return typeof a=="number"&&Fi.rotate(n,a*Math.PI/180),n}});function U$t(e){return{fontSize:e.data.size,text:e.data.text,textAlign:"center",fontFamily:e.data.font,fontWeight:e.data.weight,fill:e.color||e.defaultStyle.stroke,textBaseline:"alphabetic"}}(function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="word-cloud",t}return r.getDefaultOptions=function(){return j$t},r.prototype.changeData=function(t){this.updateOption({data:t}),this.options.imageMask?this.render():this.chart.changeData(e6({chart:this.chart,options:this.options}))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.render=function(){var t=this;return new Promise(function(i){var n=t.options.imageMask;if(!n){e.prototype.render.call(t),i();return}var a=function(o){t.options=A(A({},t.options),{imageMask:o||null}),e.prototype.render.call(t),i()};k$t(n).then(a).catch(a)})},r.prototype.getSchemaAdaptor=function(){return X$t},r.prototype.triggerResize=function(){var t=this;this.chart.destroyed||(this.execAdaptor(),window.setTimeout(function(){e.prototype.triggerResize.call(t)}))},r})(Dt);var q$t={exp:Qa.exports.regressionExp,linear:Qa.exports.regressionLinear,loess:Qa.exports.regressionLoess,log:Qa.exports.regressionLog,poly:Qa.exports.regressionPoly,pow:Qa.exports.regressionPow,quad:Qa.exports.regressionQuad};function Z$t(e,r){var t=10,i={regionStyle:[{position:{start:[e,"max"],end:["max",r]},style:{fill:"#d8d0c0",opacity:.4}},{position:{start:["min","max"],end:[e,r]},style:{fill:"#a3dda1",opacity:.4}},{position:{start:["min",r],end:[e,"min"]},style:{fill:"#d8d0c0",opacity:.4}},{position:{start:[e,r],end:["max","min"]},style:{fill:"#a3dda1",opacity:.4}}],lineStyle:{stroke:"#9ba29a",lineWidth:1},labelStyle:[{position:["max",r],offsetX:-t,offsetY:-t,style:{textAlign:"right",textBaseline:"bottom",fontSize:14,fill:"#ccc"}},{position:["min",r],offsetX:t,offsetY:-t,style:{textAlign:"left",textBaseline:"bottom",fontSize:14,fill:"#ccc"}},{position:["min",r],offsetX:t,offsetY:t,style:{textAlign:"left",textBaseline:"top",fontSize:14,fill:"#ccc"}},{position:["max",r],offsetX:-t,offsetY:t,style:{textAlign:"right",textBaseline:"top",fontSize:14,fill:"#ccc"}}]};return i}var Q$t=function(e,r){var t=r.view,i=r.options,n=i.xField,a=i.yField,o=t.getScaleByField(n),l=t.getScaleByField(a),s=e.map(function(u){return t.getCoordinate().convert({x:o.scale(u[0]),y:l.scale(u[1])})});return ULt(s,!1)},K$t=function(e){var r=e.options,t=r.xField,i=r.yField,n=r.data,a=r.regressionLine,o=a.type,l=o===void 0?"linear":o,s=a.algorithm,u;if(s)u=it(s)?s:s(n);else{var c=q$t[l]().x(function(f){return f[t]}).y(function(f){return f[i]});u=c(n)}return Q$t(u,e)},J$t=function(e){var r,t=e.meta,i=t===void 0?{}:t,n=e.xField,a=e.yField,o=e.data,l=o[0][n],s=o[0][a],u=l>0,c=s>0;function f(h,v){var d=I(i,[h]);function p(m){return I(d,m)}var x={};return v==="x"?(Mt(l)&&(Mt(p("min"))||(x.min=u?0:l*2),Mt(p("max"))||(x.max=u?l*2:0)),x):(Mt(s)&&(Mt(p("min"))||(x.min=c?0:s*2),Mt(p("max"))||(x.max=c?s*2:0)),x)}return A(A({},i),(r={},r[n]=A(A({},i[n]),f(n,"x")),r[a]=A(A({},i[a]),f(a,"y")),r))};function r6(e){var r=e.data,t=r===void 0?[]:r,i=e.xField,n=e.yField;if(t.length){for(var a=!0,o=!0,l=t[0],s=void 0,u=1;u<t.length&&(s=t[u],l[i]!==s[i]&&(a=!1),l[n]!==s[n]&&(o=!1),!(!a&&!o));u++)l=s;var c=[];a&&c.push(i),o&&c.push(n);var f=se(J$t(e),c);return J({},e,{meta:f})}return e}function tkt(e){var r=e.chart,t=e.options,i=t.data,n=t.type,a=t.color,o=t.shape,l=t.pointStyle,s=t.shapeField,u=t.colorField,c=t.xField,f=t.yField,h=t.sizeField,v=t.size,d=t.tooltip;h&&(v||(v=[2,8]),Mt(v)&&(v=[v,v])),d&&!d.fields&&(d=A(A({},d),{fields:[c,f,u,h,s]})),r.data(i),An(J({},e,{options:{seriesField:u,point:{color:a,shape:o,size:v,style:l},tooltip:d}}));var p=ei(r,"point");return n&&p.adjust(n),e}function k0(e){var r,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.yField,l=r6(t);return It(We((r={},r[a]=i,r[o]=n,r)))(J({},e,{options:l}))}function ekt(e){var r=e.chart,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.yField;return r.axis(a,i),r.axis(o,n),e}function rkt(e){var r=e.chart,t=e.options,i=t.legend,n=t.colorField,a=t.shapeField,o=t.sizeField,l=t.shapeLegend,s=t.sizeLegend,u=i!==!1;return n&&r.legend(n,u?i:!1),a&&(l?r.legend(a,l):r.legend(a,l===!1?!1:i)),o&&r.legend(o,s||!1),!u&&!l&&!s&&r.legend(!1),e}function ikt(e){var r=e.chart,t=e.options,i=t.label,n=t.yField,a=ei(r,"point");if(!i)a.label(!1);else{var o=i.callback,l=ue(i,["callback"]);a.label({fields:[n],callback:o,cfg:Pr(l)})}return e}function nkt(e){var r=e.options,t=r.quadrant,i=[];if(t){var n=t.xBaseline,a=n===void 0?0:n,o=t.yBaseline,l=o===void 0?0:o,s=t.labels,u=t.regionStyle,c=t.lineStyle,f=Z$t(a,l),h=new Array(4).join(",").split(",");h.forEach(function(v,d){i.push(A(A({type:"region",top:!1},f.regionStyle[d].position),{style:J({},f.regionStyle[d].style,u==null?void 0:u[d])}),A({type:"text",top:!0},J({},f.labelStyle[d],s==null?void 0:s[d])))}),i.push({type:"line",top:!1,start:["min",l],end:["max",l],style:J({},f.lineStyle,c)},{type:"line",top:!1,start:[a,"min"],end:[a,"max"],style:J({},f.lineStyle,c)})}return It(Xe(i))(e)}function akt(e){var r=e.options,t=e.chart,i=r.regressionLine;if(i){var n=i.style,a=i.top,o=a===void 0?!1:a,l={stroke:"#9ba29a",lineWidth:2,opacity:.5};t.annotation().shape({top:o,render:function(s,u){var c=s.addGroup({id:t.id+"-regression-line",name:"regression-line-group"}),f=K$t({view:u,options:r});c.addShape("path",{name:"regression-line",attrs:A(A({path:f},l),n)})}})}return e}function okt(e){var r=e.chart,t=e.options,i=t.tooltip;return i?r.tooltip(i):i===!1&&r.tooltip(!1),e}function i6(e){return It(tkt,k0,ekt,rkt,okt,ikt,WX,Ae,nkt,ce,ie,akt)(e)}var lkt=J({},Dt.getDefaultOptions(),{size:4,tooltip:{showTitle:!1,showMarkers:!1,showCrosshairs:!0,crosshairs:{type:"xy"}}});Lt("drag-move",{start:[{trigger:"plot:mousedown",action:"scale-translate:start"}],processing:[{trigger:"plot:mousemove",action:"scale-translate:translate",throttle:{wait:100,leading:!0,trailing:!1}}],end:[{trigger:"plot:mouseup",action:"scale-translate:end"}]});var skt=function(e){X(r,e);function r(t,i){var n=e.call(this,t,i)||this;return n.type="scatter",n.on(Gt.BEFORE_RENDER,function(a){var o,l,s=n,u=s.options,c=s.chart;if(((o=a.data)===null||o===void 0?void 0:o.source)===bi.FILTER){var f=n.chart.filterData(n.chart.getData());k0({chart:c,options:A(A({},u),{data:f})})}((l=a.data)===null||l===void 0?void 0:l.source)===bi.RESET&&k0({chart:c,options:u})}),n}return r.getDefaultOptions=function(){return lkt},r.prototype.changeData=function(t){this.updateOption(r6(J({},this.options,{data:t})));var i=this,n=i.options,a=i.chart;k0({chart:a,options:n}),this.chart.changeData(t)},r.prototype.getSchemaAdaptor=function(){return i6},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r}(Dt);function ukt(e){var r=e.chart,t=e.options,i=t.data,n=t.lineStyle,a=t.color,o=t.point,l=t.area;r.data(i);var s=J({},e,{options:{line:{style:n,color:a},point:o&&A({color:a},o),area:l&&A({color:a},l),label:void 0}}),u=J({},s,{options:{tooltip:!1}}),c=(o==null?void 0:o.state)||t.state,f=J({},s,{options:{tooltip:!1,state:c}});return Vh(s),An(f),Ab(u),e}function ckt(e){var r,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.yField;return It(We((r={},r[a]=i,r[o]=n,r)))(e)}function fkt(e){var r=e.chart,t=e.options,i=t.radius,n=t.startAngle,a=t.endAngle;return r.coordinate("polar",{radius:i,startAngle:n,endAngle:a}),e}function hkt(e){var r=e.chart,t=e.options,i=t.xField,n=t.xAxis,a=t.yField,o=t.yAxis;return r.axis(i,n),r.axis(a,o),e}function vkt(e){var r=e.chart,t=e.options,i=t.label,n=t.yField,a=ei(r,"line");if(!i)a.label(!1);else{var o=i.callback,l=ue(i,["callback"]);a.label({fields:[n],callback:o,cfg:Pr(l)})}return e}function dkt(e){return It(ukt,ckt,ie,fkt,hkt,Og,Dr,vkt,Ae,ce,Xe())(e)}var pkt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return Object.defineProperty(r.prototype,"name",{get:function(){return"radar-tooltip"},enumerable:!1,configurable:!0}),r.prototype.getTooltipItems=function(t){var i=this.getTooltipCfg(),n=i.shared,a=i.title,o=e.prototype.getTooltipItems.call(this,t);if(o.length>0){var l=this.view.geometries[0],s=l.dataArray,u=o[0].name,c=[];return s.forEach(function(f){f.forEach(function(h){var v=Fi.getTooltipItems(h,l),d=v[0];if(!n&&d&&d.name===u){var p=K(a)?u:a;c.push(A(A({},d),{name:d.title,title:p}))}else if(n&&d){var p=K(a)?d.name||u:a;c.push(A(A({},d),{name:d.title,title:p}))}})}),c}return[]},r}(PO);Ds("radar-tooltip",pkt);var gkt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.init=function(){var t=this.context.view;t.removeInteraction("tooltip")},r.prototype.show=function(){var t=this.context.event,i=this.getTooltipController();i.showTooltip({x:t.x,y:t.y})},r.prototype.hide=function(){var t=this.getTooltipController();t.hideTooltip()},r.prototype.getTooltipController=function(){var t=this.context.view;return t.getController("radar-tooltip")},r}(Ie);Et("radar-tooltip",gkt);Lt("radar-tooltip",{start:[{trigger:"plot:mousemove",action:"radar-tooltip:show"}],end:[{trigger:"plot:mouseleave",action:"radar-tooltip:hide"}]});(function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="radar",t}return r.prototype.changeData=function(t){this.updateOption({data:t}),this.chart.changeData(t)},r.prototype.getDefaultOptions=function(){return J({},e.prototype.getDefaultOptions.call(this),{xAxis:{label:{offset:15},grid:{line:{type:"line"}}},yAxis:{grid:{line:{type:"circle"}}},legend:{position:"top"},tooltip:{shared:!0,showCrosshairs:!0,showMarkers:!0,crosshairs:{type:"xy",line:{style:{stroke:"#565656",lineDash:[4]}},follow:!0}}})},r.prototype.getSchemaAdaptor=function(){return dkt},r})(Dt);var gh;(function(e){e.Left="Left",e.Right="Right"})(gh||(gh={}));var oc;(function(e){e.Line="line",e.Column="column"})(oc||(oc={}));var Tn="left-axes-view",Mn="right-axes-view",n6={nice:!0,label:{autoHide:!0,autoRotate:!1}},ykt=A(A({},n6),{position:"left"}),mkt=A(A({},n6),{position:"right",grid:null});function XT(e){return I(e,"geometry")===oc.Line}function WP(e){return I(e,"geometry")===oc.Column}function iG(e,r,t){return WP(t)?J({},{geometry:oc.Column,label:t.label&&t.isRange?{content:function(i){var n;return(n=i[r])===null||n===void 0?void 0:n.join("-")}}:void 0},t):A({geometry:oc.Line},t)}function nG(e,r){var t=e[0],i=e[1];if(it(r)){var n=r[0],a=r[1];return[n,a]}var o=I(r,t),l=I(r,i);return[o,l]}function aG(e,r){return r===gh.Left?e===!1?!1:J({},ykt,e):r===gh.Right?e===!1?!1:J({},mkt,e):e}function oG(e){var r=e.view,t=e.geometryOption,i=e.yField,n=e.legend,a=I(n,"marker"),o=ei(r,XT(t)?"line":"interval");if(!t.seriesField){var l=I(r,"options.scales."+i+".alias")||i,s=o.getAttribute("color"),u=r.getTheme().defaultColor;s&&(u=Fi.getMappingValue(s,l,I(s,["values",0],u)));var c=(pt(a)?a:!gi(a)&&J({},{style:{stroke:u,fill:u}},a))||(XT(t)?{symbol:function(h,v,d){return[["M",h-d,v],["L",h+d,v]]},style:{lineWidth:2,r:6,stroke:u}}:{symbol:"square",style:{fill:u}});return[{value:i,name:l,marker:c,isGeometry:!0,viewId:r.id}]}var f=o.getGroupAttributes();return Kr(f,function(h,v){var d=Fi.getLegendItems(r,o,v,r.getTheme(),a);return h.concat(d)},[])}function xkt(e){var r=e.options,t=e.chart,i=r.geometryOption,n=i.isStack,a=i.color,o=i.seriesField,l=i.groupField,s=i.isGroup,u=["xField","yField"];if(XT(i)){Vh(J({},e,{options:A(A(A({},se(r,u)),i),{line:{color:i.color,style:i.lineStyle}})})),An(J({},e,{options:A(A(A({},se(r,u)),i),{point:i.point&&A({color:a,shape:"circle"},i.point)})}));var c=[];s&&c.push({type:"dodge",dodgeBy:l||o,customOffset:0}),n&&c.push({type:"stack"}),c.length&&P(t.geometries,function(f){f.adjust(c)})}return WP(i)&&Eb(J({},e,{options:A(A(A({},se(r,u)),i),{widthRatio:i.columnWidthRatio,interval:A(A({},se(i,["color"])),{style:i.columnStyle})})})),e}var lG=function(e,r){var t=r[0],i=r[1],n=e.getOptions().data,a=e.getXScale(),o=yr(n);if(!(!a||!o)){var l=Xn(n,a.field),s=l,u=yr(s),c=Math.floor(t*(u-1)),f=Math.floor(i*(u-1));e.filter(a.field,function(h){var v=s.indexOf(h);return v>-1?eDt(v,c,f):!0}),e.render(!0)}};function _kt(e){var r,t=e.options,i=t.geometryOptions,n=i===void 0?[]:i,a=t.xField,o=t.yField,l=Zx(n,function(s){var u=s.geometry;return u===oc.Line||u===void 0});return J({},{options:{geometryOptions:[],meta:(r={},r[a]={type:"cat",sync:!0,range:l?[0,1]:void 0},r),tooltip:{showMarkers:l,showCrosshairs:l,shared:!0,crosshairs:{type:"x"}},interactions:l?[{type:"legend-visible-filter"}]:[{type:"legend-visible-filter"},{type:"active-region"}],legend:{position:"top-left"}}},e,{options:{yAxis:nG(o,t.yAxis),geometryOptions:[iG(a,o[0],n[0]),iG(a,o[1],n[1])],annotations:nG(o,t.annotations)}})}function bkt(e){var r,t,i=e.chart,n=e.options,a=n.geometryOptions,o={line:0,column:1},l=[{type:(r=a[0])===null||r===void 0?void 0:r.geometry,id:Tn},{type:(t=a[1])===null||t===void 0?void 0:t.geometry,id:Mn}];return l.sort(function(s,u){return-o[s.type]+o[u.type]}).forEach(function(s){return i.createView({id:s.id})}),e}function wkt(e){var r=e.chart,t=e.options,i=t.xField,n=t.yField,a=t.geometryOptions,o=t.data,l=t.tooltip,s=[A(A({},a[0]),{id:Tn,data:o[0],yField:n[0]}),A(A({},a[1]),{id:Mn,data:o[1],yField:n[1]})];return s.forEach(function(u){var c=u.id,f=u.data,h=u.yField,v=WP(u)&&u.isPercent,d=v?jX(f,h,i,h):f,p=Yt(r,c).data(d),x=v?A({formatter:function(m){return{name:m[u.seriesField]||h,value:(Number(m[h])*100).toFixed(2)+"%"}}},l):l;xkt({chart:p,options:{xField:i,yField:h,tooltip:x,geometryOption:u}})}),e}function Ckt(e){var r,t=e.chart,i=e.options,n=i.geometryOptions,a=((r=t.getTheme())===null||r===void 0?void 0:r.colors10)||[],o=0;return t.once("beforepaint",function(){P(n,function(l,s){var u=Yt(t,s===0?Tn:Mn);if(!l.color){var c=u.getGroupScales(),f=I(c,[0,"values","length"],1),h=a.slice(o,o+f).concat(s===0?[]:a);u.geometries.forEach(function(v){l.seriesField?v.color(l.seriesField,h):v.color(h[0])}),o+=f}}),t.render(!0)}),e}function Skt(e){var r,t,i=e.chart,n=e.options,a=n.xAxis,o=n.yAxis,l=n.xField,s=n.yField;return We((r={},r[l]=a,r[s[0]]=o[0],r))(J({},e,{chart:Yt(i,Tn)})),We((t={},t[l]=a,t[s[1]]=o[1],t))(J({},e,{chart:Yt(i,Mn)})),e}function Akt(e){var r=e.chart,t=e.options,i=Yt(r,Tn),n=Yt(r,Mn),a=t.xField,o=t.yField,l=t.xAxis,s=t.yAxis;return r.axis(a,!1),r.axis(o[0],!1),r.axis(o[1],!1),i.axis(a,l),i.axis(o[0],aG(s[0],gh.Left)),n.axis(a,!1),n.axis(o[1],aG(s[1],gh.Right)),e}function Tkt(e){var r=e.chart,t=e.options,i=t.tooltip,n=Yt(r,Tn),a=Yt(r,Mn);return r.tooltip(i),n.tooltip({shared:!0}),a.tooltip({shared:!0}),e}function Mkt(e){var r=e.chart;return Ae(J({},e,{chart:Yt(r,Tn)})),Ae(J({},e,{chart:Yt(r,Mn)})),e}function Ekt(e){var r=e.chart,t=e.options,i=t.annotations,n=I(i,[0]),a=I(i,[1]);return Xe(n)(J({},e,{chart:Yt(r,Tn),options:{annotations:n}})),Xe(a)(J({},e,{chart:Yt(r,Mn),options:{annotations:a}})),e}function Fkt(e){var r=e.chart;return ie(J({},e,{chart:Yt(r,Tn)})),ie(J({},e,{chart:Yt(r,Mn)})),ie(e),e}function Okt(e){var r=e.chart;return ce(J({},e,{chart:Yt(r,Tn)})),ce(J({},e,{chart:Yt(r,Mn)})),e}function Pkt(e){var r=e.chart,t=e.options,i=t.yAxis;return ac(J({},e,{chart:Yt(r,Tn),options:{yAxis:i[0]}})),ac(J({},e,{chart:Yt(r,Mn),options:{yAxis:i[1]}})),e}function Ikt(e){var r=e.chart,t=e.options,i=t.legend,n=t.geometryOptions,a=t.yField,o=t.data,l=Yt(r,Tn),s=Yt(r,Mn);if(i===!1)r.legend(!1);else if(Zt(i)&&i.custom===!0)r.legend(i);else{var u=I(n,[0,"legend"],i),c=I(n,[1,"legend"],i);r.once("beforepaint",function(){var f=o[0].length?oG({view:l,geometryOption:n[0],yField:a[0],legend:u}):[],h=o[1].length?oG({view:s,geometryOption:n[1],yField:a[1],legend:c}):[];r.legend(J({},i,{custom:!0,items:f.concat(h)}))}),n[0].seriesField&&l.legend(n[0].seriesField,u),n[1].seriesField&&s.legend(n[1].seriesField,c),r.on("legend-item:click",function(f){var h=I(f,"gEvent.delegateObject",{});if(h&&h.item){var v=h.item,d=v.value,p=v.isGeometry,x=v.viewId;if(p){var m=lM(a,function(w){return w===d});if(m>-1){var _=I(Yt(r,x),"geometries");P(_,function(w){w.changeVisible(!h.item.unchecked)})}}else{var b=I(r.getController("legend"),"option.items",[]);P(r.views,function(w){var S=w.getGroupScales();P(S,function(M){M.values&&M.values.indexOf(d)>-1&&w.filter(M.field,function(F){var O=Yn(b,function(L){return L.value===F});return!O.unchecked})}),r.render(!0)})}}})}return e}function Lkt(e){var r=e.chart,t=e.options,i=t.slider,n=Yt(r,Tn),a=Yt(r,Mn);return i&&(n.option("slider",i),n.on("slider:valuechanged",function(o){var l=o.event,s=l.value,u=l.originValue;Ge(s,u)||lG(a,s)}),r.once("afterpaint",function(){if(!Yu(i)){var o=i.start,l=i.end;(o||l)&&lG(a,[o,l])}})),e}function Dkt(e){return It(_kt,bkt,Fkt,wkt,Skt,Akt,Pkt,Tkt,Mkt,Ekt,Okt,Ckt,Ikt,Lkt)(e)}(function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="dual-axes",t}return r.prototype.getDefaultOptions=function(){return J({},e.prototype.getDefaultOptions.call(this),{yAxis:[],syncViewPadding:!0})},r.prototype.getSchemaAdaptor=function(){return Dkt},r})(Dt);var sp="x",If="y",a6={showTitle:!1,shared:!0,showMarkers:!1,customContent:function(e,r){return""+I(r,[0,"data","y"],0)},containerTpl:'<div class="g2-tooltip"><div class="g2-tooltip-list"></div></div>',itemTpl:"<span>{value}</span>",domStyles:{"g2-tooltip":{padding:"2px 4px",fontSize:"10px"}},showCrosshairs:!0,crosshairs:{type:"x"}},$kt={appendPadding:2,tooltip:A({},a6),animation:{}};function xc(e){return je(e||[],function(r,t){return{x:""+t,y:r}})}function kkt(e){var r=e.chart,t=e.options,i=t.data,n=t.color,a=t.areaStyle,o=t.point,l=t.line,s=o==null?void 0:o.state,u=xc(i);r.data(u);var c=J({},e,{options:{xField:sp,yField:If,area:{color:n,style:a},line:l,point:o}}),f=J({},c,{options:{tooltip:!1}}),h=J({},c,{options:{tooltip:!1,state:s}});return Ab(c),Vh(f),An(h),r.axis(!1),r.legend(!1),e}function jh(e){var r,t,i=e.options,n=i.xAxis,a=i.yAxis,o=i.data,l=xc(o);return It(We((r={},r[sp]=n,r[If]=a,r),(t={},t[sp]={type:"cat"},t[If]=RP(l,If),t)))(e)}function o6(e){return It(Sn("areaStyle"),kkt,jh,Dr,ie,ce,Xe())(e)}function Rkt(e){var r=e.chart,t=e.options,i=t.data,n=t.color,a=t.lineStyle,o=t.point,l=o==null?void 0:o.state,s=xc(i);r.data(s);var u=J({},e,{options:{xField:sp,yField:If,line:{color:n,style:a},point:o}}),c=J({},u,{options:{tooltip:!1,state:l}});return Vh(u),An(c),r.axis(!1),r.legend(!1),e}function l6(e){return It(Rkt,jh,ie,Dr,ce,Xe())(e)}var Bkt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="tiny-line",t}return r.getDefaultOptions=function(){return $kt},r.prototype.changeData=function(t){this.updateOption({data:t});var i=this,n=i.chart,a=i.options;jh({chart:n,options:a}),n.changeData(xc(t))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return l6},r}(Dt);function Nkt(e){var r=e.chart,t=e.options,i=t.data,n=t.color,a=t.columnStyle,o=t.columnWidthRatio,l=xc(i);r.data(l);var s=J({},e,{options:{xField:sp,yField:If,widthRatio:o,interval:{style:a,color:n}}});return ri(s),r.axis(!1),r.legend(!1),r.interaction("element-active"),e}function s6(e){return It(ie,Sn("columnStyle"),Nkt,jh,Dr,ce,Xe())(e)}var Gkt={showTitle:!1,shared:!0,showMarkers:!1,customContent:function(e,r){return""+I(r,[0,"data","y"],0)},containerTpl:'<div class="g2-tooltip"><div class="g2-tooltip-list"></div></div>',itemTpl:"<span>{value}</span>",domStyles:{"g2-tooltip":{padding:"2px 4px",fontSize:"10px"}}},zkt={appendPadding:2,tooltip:A({},Gkt),animation:{}},Vkt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="tiny-column",t}return r.getDefaultOptions=function(){return zkt},r.prototype.changeData=function(t){this.updateOption({data:t});var i=this,n=i.chart,a=i.options;jh({chart:n,options:a}),n.changeData(xc(t))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return s6},r}(Dt),jkt={appendPadding:2,tooltip:A({},a6),color:"l(90) 0:#E5EDFE 1:#ffffff",areaStyle:{fillOpacity:.6},line:{size:1,color:"#5B8FF9"},animation:{}},Hkt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="tiny-area",t}return r.getDefaultOptions=function(){return jkt},r.prototype.changeData=function(t){this.updateOption({data:t});var i=this,n=i.chart,a=i.options;jh({chart:n,options:a}),n.changeData(xc(t))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return o6},r}(Dt);function sG(e,r,t){if(t===1)return[0,r];var i=Math.floor(e/r);return[r*i,r*(i+1)]}function Ykt(e){return Math.ceil(Math.log(e.length)/Math.LN2)+1}function u6(e,r,t,i,n){var a=di(e);ZG(a,r);var o=Xn(a,r),l=sM(o),s=l.max-l.min,u=t;if(!t&&i&&(u=i>1?s/(i-1):l.max),!t&&!i){var c=Ykt(o);u=s/c}var f={},h=Xi(a,n);gi(h)?P(a,function(d){var p=d[r],x=sG(p,u,i),m=x[0]+"-"+x[1];po(f,m)||(f[m]={range:x,count:0}),f[m].count+=1}):Object.keys(h).forEach(function(d){P(h[d],function(p){var x=p[r],m=sG(x,u,i),_=m[0]+"-"+m[1],b=_+"-"+d;po(f,b)||(f[b]={range:m,count:0},f[b][n]=d),f[b].count+=1})});var v=[];return P(f,function(d){v.push(d)}),v}var jx="range",up="count",Wkt=J({},Dt.getDefaultOptions(),{columnStyle:{stroke:"#FFFFFF"},tooltip:{shared:!0,showMarkers:!1},interactions:[{type:"active-region"}]});function Xkt(e){var r=e.chart,t=e.options,i=t.data,n=t.binField,a=t.binNumber,o=t.binWidth,l=t.color,s=t.stackField,u=t.legend,c=t.columnStyle,f=u6(i,n,o,a,s);r.data(f);var h=J({},e,{options:{xField:jx,yField:up,seriesField:s,isStack:!0,interval:{color:l,style:c}}});return ri(h),u&&s&&r.legend(s,u),e}function Ukt(e){var r,t=e.options,i=t.xAxis,n=t.yAxis;return It(We((r={},r[jx]=i,r[up]=n,r)))(e)}function qkt(e){var r=e.chart,t=e.options,i=t.xAxis,n=t.yAxis;return i===!1?r.axis(jx,!1):r.axis(jx,i),n===!1?r.axis(up,!1):r.axis(up,n),e}function Zkt(e){var r=e.chart,t=e.options,i=t.label,n=ei(r,"interval");if(!i)n.label(!1);else{var a=i.callback,o=ue(i,["callback"]);n.label({fields:[up],callback:a,cfg:Pr(o)})}return e}function c6(e){return It(ie,Sn("columnStyle"),Xkt,Ukt,qkt,Rs,Zkt,Dr,Ae,ce)(e)}var Qkt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="histogram",t}return r.getDefaultOptions=function(){return Wkt},r.prototype.changeData=function(t){this.updateOption({data:t});var i=this.options,n=i.binField,a=i.binNumber,o=i.binWidth,l=i.stackField;this.chart.changeData(u6(t,n,o,a,l))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return c6},r}(Dt),f6=["#FAAD14","#E8EDF3"],Kkt={percent:.2,color:f6,animation:{}};function XP(e){var r=Ce(nc(e)?e:0,0,1);return[{type:"current",percent:r},{type:"target",percent:1-r}]}function h6(e){var r=e.chart,t=e.options,i=t.percent,n=t.progressStyle,a=t.color,o=t.barWidthRatio;r.data(XP(i));var l=J({},e,{options:{xField:"1",yField:"percent",seriesField:"type",isStack:!0,widthRatio:o,interval:{style:n,color:Ct(a)?[a,f6[1]]:a},args:{zIndexReversed:!0}}});return ri(l),r.tooltip(!1),r.axis(!1),r.legend(!1),e}function Jkt(e){var r=e.chart;return r.coordinate("rect").transpose(),e}function v6(e){return It(h6,We({}),Jkt,ce,ie,Xe())(e)}var tRt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="process",t}return r.getDefaultOptions=function(){return Kkt},r.prototype.changeData=function(t){this.updateOption({percent:t}),this.chart.changeData(XP(t))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return v6},r}(Dt);function eRt(e){var r=e.chart,t=e.options,i=t.innerRadius,n=t.radius;return r.coordinate("theta",{innerRadius:i,radius:n}),e}function d6(e,r){var t=e.chart,i=e.options,n=i.innerRadius,a=i.statistic,o=i.percent,l=i.meta;if(t.getController("annotation").clear(!0),n&&a){var s=I(l,["percent","formatter"])||function(c){return(c*100).toFixed(2)+"%"},u=a.content;u&&(u=J({},u,{content:K(u.content)?s(o):u.content})),_b(t,{statistic:A(A({},a),{content:u}),plotType:"ring-progress"},{percent:o})}return r&&t.render(!0),e}function p6(e){return It(h6,We({}),eRt,d6,ce,ie,Xe())(e)}var rRt={percent:.2,innerRadius:.8,radius:.98,color:["#FAAD14","#E8EDF3"],statistic:{title:!1,content:{style:{fontSize:"14px",fontWeight:300,fill:"#4D4D4D",textAlign:"center",textBaseline:"middle"}}},animation:{}},iRt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="ring-process",t}return r.getDefaultOptions=function(){return rRt},r.prototype.changeData=function(t){this.chart.emit(Gt.BEFORE_CHANGE_DATA,$e.fromData(this.chart,Gt.BEFORE_CHANGE_DATA,null)),this.updateOption({percent:t}),this.chart.data(XP(t)),d6({chart:this.chart,options:this.options},!0),this.chart.emit(Gt.AFTER_CHANGE_DATA,$e.fromData(this.chart,Gt.AFTER_CHANGE_DATA,null))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return p6},r}(Dt);function nRt(e){var r=e.chart,t=e.options,i=t.data,n=t.type,a=t.xField,o=t.yField,l=t.colorField,s=t.sizeField,u=t.sizeRatio,c=t.shape,f=t.color,h=t.tooltip,v=t.heatmapStyle;r.data(i);var d="polygon";n==="density"&&(d="heatmap");var p=ra(h,[a,o,l]),x=p.fields,m=p.formatter,_=1;return(u||u===0)&&(!c&&!s?console.warn("sizeRatio is not in effect: Must define shape or sizeField first"):u<0||u>1?console.warn("sizeRatio is not in effect: It must be a number in [0,1]"):_=u),Ki(J({},e,{options:{type:d,colorField:l,tooltipFields:x,shapeField:s||"",label:void 0,mapping:{tooltip:m,shape:c&&(s?function(b){var w=i.map(function(F){return F[s]}),S=Math.min.apply(Math,w),M=Math.max.apply(Math,w);return[c,(I(b,s)-S)/(M-S),_]}:function(){return[c,1,_]}),color:f||l&&r.getTheme().sequenceColors.join("-"),style:v}}})),e}function aRt(e){var r,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.yField;return It(We((r={},r[a]=i,r[o]=n,r)))(e)}function oRt(e){var r=e.chart,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.yField;return i===!1?r.axis(a,!1):r.axis(a,i),n===!1?r.axis(o,!1):r.axis(o,n),e}function lRt(e){var r=e.chart,t=e.options,i=t.legend,n=t.colorField,a=t.sizeField,o=t.sizeLegend,l=i!==!1;return n&&r.legend(n,l?i:!1),a&&r.legend(a,o===void 0?i:o),!l&&!o&&r.legend(!1),e}function sRt(e){var r=e.chart,t=e.options,i=t.label,n=t.colorField,a=t.type,o=ei(r,a==="density"?"heatmap":"polygon");if(!i)o.label(!1);else if(n){var l=i.callback,s=ue(i,["callback"]);o.label({fields:[n],callback:l,cfg:Pr(s)})}return e}function uRt(e){var r=e.chart,t=e.options,i=t.coordinate,n=t.reflect;return i&&r.coordinate({type:i.type||"rect",cfg:i.cfg}),n&&r.coordinate().reflect(n),e}function cRt(e){return It(ie,Sn("heatmapStyle"),aRt,uRt,nRt,oRt,lRt,Dr,sRt,Xe(),Ae,ce,Rs)(e)}var fRt=J({},Dt.getDefaultOptions(),{type:"polygon",legend:!1,coordinate:{type:"rect"},xAxis:{tickLine:null,line:null,grid:{alignTick:!1,line:{style:{lineWidth:1,lineDash:null,stroke:"#f0f0f0"}}}},yAxis:{grid:{alignTick:!1,line:{style:{lineWidth:1,lineDash:null,stroke:"#f0f0f0"}}}}});te("polygon","circle",{draw:function(e,r){var t,i,n=e.x,a=e.y,o=this.parsePoints(e.points),l=Math.abs(o[2].x-o[1].x),s=Math.abs(o[1].y-o[0].y),u=Math.min(l,s)/2,c=Number(e.shape[1]),f=Number(e.shape[2]),h=Math.sqrt(f),v=u*h*Math.sqrt(c),d=((t=e.style)===null||t===void 0?void 0:t.fill)||e.color||((i=e.defaultStyle)===null||i===void 0?void 0:i.fill),p=r.addShape("circle",{attrs:A(A(A({x:n,y:a,r:v},e.defaultStyle),e.style),{fill:d})});return p}});te("polygon","square",{draw:function(e,r){var t,i,n=e.x,a=e.y,o=this.parsePoints(e.points),l=Math.abs(o[2].x-o[1].x),s=Math.abs(o[1].y-o[0].y),u=Math.min(l,s),c=Number(e.shape[1]),f=Number(e.shape[2]),h=Math.sqrt(f),v=u*h*Math.sqrt(c),d=((t=e.style)===null||t===void 0?void 0:t.fill)||e.color||((i=e.defaultStyle)===null||i===void 0?void 0:i.fill),p=r.addShape("rect",{attrs:A(A(A({x:n-v/2,y:a-v/2,width:v,height:v},e.defaultStyle),e.style),{fill:d})});return p}});(function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="heatmap",t}return r.getDefaultOptions=function(){return fRt},r.prototype.getSchemaAdaptor=function(){return cRt},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r})(Dt);var JS,yh="$$range$$",hRt="low-q1-median-q3-high",vRt="$$y_outliers$$",g6="outliers_view",dRt=J({},Dt.getDefaultOptions(),{meta:(JS={},JS[yh]={min:0,alias:hRt},JS),interactions:[{type:"active-region"}],tooltip:{showMarkers:!1,shared:!0},boxStyle:{lineWidth:1}}),y6=function(e,r){var t=e;if(Array.isArray(r)){var i=r[0],n=r[1],a=r[2],o=r[3],l=r[4];t=je(e,function(s){return s[yh]=[s[i],s[n],s[a],s[o],s[l]],s})}return t};function pRt(e){var r=e.chart,t=e.options,i=t.xField,n=t.yField,a=t.groupField,o=t.color,l=t.tooltip,s=t.boxStyle;r.data(y6(t.data,n));var u=it(n)?yh:n,c=n?it(n)?n:[n]:[],f=l;f!==!1&&(f=J({},{fields:it(n)?n:[]},f));var h=VP(J({},e,{options:{xField:i,yField:u,seriesField:a,tooltip:f,rawFields:c,label:!1,schema:{shape:"box",color:o,style:s}}})).ext;return a&&h.geometry.adjust("dodge"),e}function gRt(e){var r=e.chart,t=e.options,i=t.xField,n=t.data,a=t.outliersField,o=t.outliersStyle,l=t.padding,s=t.label;if(!a)return e;var u=r.createView({padding:l,id:g6}),c=n.reduce(function(f,h){var v=h[a];return v.forEach(function(d){var p;return f.push(A(A({},h),(p={},p[a]=d,p)))}),f},[]);return u.data(c),An({chart:u,options:{xField:i,yField:a,point:{shape:"circle",style:o},label:s}}),u.axis(!1),e}function yRt(e){var r,t,i=e.chart,n=e.options,a=n.meta,o=n.xAxis,l=n.yAxis,s=n.xField,u=n.yField,c=n.outliersField,f=Array.isArray(u)?yh:u,h={};if(c){var v=vRt;h=(r={},r[c]={sync:v,nice:!0},r[f]={sync:v,nice:!0},r)}var d=J(h,a,(t={},t[s]=se(o,ji),t[f]=se(l,ji),t));return i.scale(d),e}function mRt(e){var r=e.chart,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.yField,l=Array.isArray(o)?yh:o;return i===!1?r.axis(a,!1):r.axis(a,i),n===!1?r.axis(yh,!1):r.axis(l,n),e}function xRt(e){var r=e.chart,t=e.options,i=t.legend,n=t.groupField;return n?i?r.legend(n,i):r.legend(n,{position:"bottom"}):r.legend(!1),e}function _Rt(e){return It(pRt,gRt,yRt,mRt,xRt,Dr,Ae,ce,ie)(e)}(function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="box",t}return r.getDefaultOptions=function(){return dRt},r.prototype.changeData=function(t){this.updateOption({data:t});var i=this.options.yField,n=this.chart.views.find(function(a){return a.id===g6});n&&n.data(t),this.chart.changeData(y6(t,i))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return _Rt},r})(Dt);var m6={exports:{}},x6={exports:{}};(function(e){var r=e.exports;e.exports.isNumber=function(t){return typeof t=="number"},e.exports.findMin=function(t){if(t.length===0)return 1/0;for(var i=t[0],n=1;n<t.length;n++)i=Math.min(i,t[n]);return i},e.exports.findMax=function(t){if(t.length===0)return-1/0;for(var i=t[0],n=1;n<t.length;n++)i=Math.max(i,t[n]);return i},e.exports.findMinMulti=function(t){for(var i=r.findMin(t[0]),n=1;n<t.length;n++)i=Math.min(i,r.findMin(t[n]));return i},e.exports.findMaxMulti=function(t){for(var i=r.findMax(t[0]),n=1;n<t.length;n++)i=Math.max(i,r.findMax(t[n]));return i},e.exports.inside=function(t,i,n){return t<=n&&n<=i}})(x6);(function(e){var r=50,t=2,i=Math.log(2),n=e.exports,a=x6.exports;function o(s){return 1-Math.abs(s)}e.exports.getUnifiedMinMax=function(s,u){return n.getUnifiedMinMaxMulti([s],u)},e.exports.getUnifiedMinMaxMulti=function(s,u){u=u||{};var c=!1,f=!1,h=a.isNumber(u.width)?u.width:t,v=a.isNumber(u.size)?u.size:r,d=a.isNumber(u.min)?u.min:(c=!0,a.findMinMulti(s)),p=a.isNumber(u.max)?u.max:(f=!0,a.findMaxMulti(s)),x=p-d,m=x/(v-1);return c&&(d=d-2*h*m),f&&(p=p+2*h*m),{min:d,max:p}},e.exports.create=function(s,u){if(u=u||{},!s||s.length===0)return[];var c=a.isNumber(u.size)?u.size:r,f=a.isNumber(u.width)?u.width:t,h=n.getUnifiedMinMax(s,{size:c,width:f,min:u.min,max:u.max}),v=h.min,d=h.max,p=d-v,x=p/(c-1);if(p===0)return[{x:v,y:1}];for(var m=[],_=0;_<c;_++)m.push({x:v+_*x,y:0});var b=function(k){return Math.floor((k-v)/x)},w=l(o,f),S=w[f],M=w[f-1]-w[f-2],F=0;s.forEach(function(k){var H=b(k);if(!(H+f<0||H-f>=m.length)){var B=Math.max(H-f,0),j=H,U=Math.min(H+f,m.length-1),R=B-(H-f),G=H+f-U,N=w[-f-1+R]||0,W=w[-f-1+G]||0,q=S/(S-N-W);R>0&&(F+=q*(R-1)*M);var tt=Math.max(0,H-f+1);a.inside(0,m.length-1,tt)&&(m[tt].y+=q*1*M),a.inside(0,m.length-1,j+1)&&(m[j+1].y-=q*2*M),a.inside(0,m.length-1,U+1)&&(m[U+1].y+=q*1*M)}});var O=F,L=0,D=0;return m.forEach(function(k){L+=k.y,O+=L,k.y=O,D+=O}),D>0&&m.forEach(function(k){k.y/=D}),m};function l(s,u){for(var c={},f=0,h=-u;h<=u;h++)f+=s(h/u),c[h]=f;return c}e.exports.getExpectedValueFromPdf=function(s){if(!(!s||s.length===0)){var u=0;return s.forEach(function(c){u+=c.x*c.y}),u}},e.exports.getXWithLeftTailArea=function(s,u){if(!(!s||s.length===0)){for(var c=0,f=0,h=0;h<s.length&&(f=h,c+=s[h].y,!(c>=u));h++);return s[f].x}},e.exports.getPerplexity=function(s){if(!(!s||s.length===0)){var u=0;return s.forEach(function(c){var f=Math.log(c.y);isFinite(f)&&(u+=c.y*f)}),u=-u/i,Math.pow(2,u)}}})(m6);var bRt=m6.exports;function uG(e,r){var t=e.length*r;if(e.length===0)throw new Error("quantile requires at least one data point.");if(r<0||r>1)throw new Error("quantiles must be between 0 and 1");return r===1?e[e.length-1]:r===0?e[0]:t%1!==0?e[Math.ceil(t)-1]:e.length%2===0?(e[t-1]+e[t])/2:e[t]}function Bv(e,r,t){var i=e[r];e[r]=e[t],e[t]=i}function R0(e,r,t,i){for(t=t||0,i=i||e.length-1;i>t;){if(i-t>600){var n=i-t+1,a=r-t+1,o=Math.log(n),l=.5*Math.exp(2*o/3),s=.5*Math.sqrt(o*l*(n-l)/n);a-n/2<0&&(s*=-1);var u=Math.max(t,Math.floor(r-a*l/n+s)),c=Math.min(i,Math.floor(r+(n-a)*l/n+s));R0(e,r,u,c)}var f=e[r],h=t,v=i;for(Bv(e,t,r),e[i]>f&&Bv(e,t,i);h<v;){for(Bv(e,h,v),h++,v--;e[h]<f;)h++;for(;e[v]>f;)v--}e[t]===f?Bv(e,t,v):(v++,Bv(e,v,i)),v<=r&&(t=v+1),r<=v&&(i=v-1)}}function Nv(e,r){var t=e.slice();if(Array.isArray(r)){wRt(t,r);for(var i=[],n=0;n<r.length;n++)i[n]=uG(t,r[n]);return i}else{var a=b6(t.length,r);return _6(t,a,0,t.length-1),uG(t,r)}}function _6(e,r,t,i){r%1===0?R0(e,r,t,i):(r=Math.floor(r),R0(e,r,t,i),R0(e,r+1,r+1,i))}function wRt(e,r){for(var t=[0],i=0;i<r.length;i++)t.push(b6(e.length,r[i]));t.push(e.length-1),t.sort(CRt);for(var n=[0,t.length-1];n.length;){var a=Math.ceil(n.pop()),o=Math.floor(n.pop());if(!(a-o<=1)){var l=Math.floor((o+a)/2);_6(e,t[l],Math.floor(t[o]),Math.ceil(t[a])),n.push(o,l,l,a)}}}function CRt(e,r){return e-r}function b6(e,r){var t=e*r;return r===1?e-1:r===0?0:t%1!==0?Math.ceil(t)-1:e%2===0?t-.5:t}var cG=function(e){return{low:Or(e),high:gr(e),q1:Nv(e,.25),q3:Nv(e,.75),median:Nv(e,[.5]),minMax:[Or(e),gr(e)],quantile:[Nv(e,.25),Nv(e,.75)]}},fG=function(e,r){var t=bRt.create(e,r);return{violinSize:t.map(function(i){return i.y}),violinY:t.map(function(i){return i.x})}},w6=function(e){var r=e.xField,t=e.yField,i=e.seriesField,n=e.data,a=e.kde,o={min:a.min,max:a.max,size:a.sampleSize,width:a.width};if(!i){var l=Xi(n,r);return Object.keys(l).map(function(c){var f=l[c],h=f.map(function(v){return v[t]});return A(A({x:c},fG(h,o)),cG(h))})}var s=[],u=Xi(n,i);return Object.keys(u).forEach(function(c){var f=Xi(u[c],r);return Object.keys(f).forEach(function(h){var v,d=f[h],p=d.map(function(x){return x[t]});s.push(A(A((v={x:h},v[i]=c,v),fG(p,o)),cG(p)))})}),s},Vn="x",Iu="violinY",SRt="violinSize",C6="minMax",S6="quantile",A6="median",UP="violin_view",ARt="min_max_view",TRt="quantile_view",MRt="median_view",ERt=J({},Dt.getDefaultOptions(),{syncViewPadding:!0,kde:{type:"triangular",sampleSize:32,width:3},violinStyle:{lineWidth:1,fillOpacity:.3,strokeOpacity:.75},xAxis:{grid:{line:null},tickLine:{alignTick:!1}},yAxis:{grid:{line:{style:{lineWidth:.5,lineDash:[4,4]}}}},legend:{position:"top-left"},tooltip:{showMarkers:!1}}),B0=["low","high","q1","q3","median"],N0=[{type:"dodge",marginRatio:1/32}];function FRt(e){var r=e.chart,t=e.options;return r.data(w6(t)),e}function ORt(e){var r=e.chart,t=e.options,i=t.seriesField,n=t.color,a=t.shape,o=a===void 0?"violin":a,l=t.violinStyle,s=t.tooltip,u=t.state,c=r.createView({id:UP});return yDt({chart:c,options:{xField:Vn,yField:Iu,seriesField:i||Vn,sizeField:SRt,tooltip:A({fields:B0},s),violin:{style:l,color:n,shape:o},state:u}}),c.geometries[0].adjust(N0),e}function PRt(e){var r=e.chart,t=e.options,i=t.seriesField,n=t.color,a=t.tooltip,o=t.box;if(o===!1)return e;var l=r.createView({id:ARt});ri({chart:l,options:{xField:Vn,yField:C6,seriesField:i||Vn,tooltip:A({fields:B0},a),state:typeof o=="object"?o.state:{},interval:{color:n,size:1,style:{lineWidth:0}}}}),l.geometries[0].adjust(N0);var s=r.createView({id:TRt});ri({chart:s,options:{xField:Vn,yField:S6,seriesField:i||Vn,tooltip:A({fields:B0},a),state:typeof o=="object"?o.state:{},interval:{color:n,size:8,style:{fillOpacity:1}}}}),s.geometries[0].adjust(N0);var u=r.createView({id:MRt});return An({chart:u,options:{xField:Vn,yField:A6,seriesField:i||Vn,tooltip:A({fields:B0},a),state:typeof o=="object"?o.state:{},point:{color:n,size:1,style:{fill:"white",lineWidth:0}}}}),u.geometries[0].adjust(N0),s.axis(!1),l.axis(!1),u.axis(!1),u.legend(!1),l.legend(!1),s.legend(!1),e}function IRt(e){var r,t=e.chart,i=e.options,n=i.meta,a=i.xAxis,o=i.yAxis,l={},s=J(l,n,(r={},r[Vn]=A(A({sync:!0},se(a,ji)),{type:"cat"}),r[Iu]=A({sync:!0},se(o,ji)),r[C6]=A({sync:Iu},se(o,ji)),r[S6]=A({sync:Iu},se(o,ji)),r[A6]=A({sync:Iu},se(o,ji)),r));return t.scale(s),e}function LRt(e){var r=e.chart,t=e.options,i=t.xAxis,n=t.yAxis,a=Yt(r,UP);return i===!1?a.axis(Vn,!1):a.axis(Vn,i),n===!1?a.axis(Iu,!1):a.axis(Iu,n),r.axis(!1),e}function DRt(e){var r=e.chart,t=e.options,i=t.legend,n=t.seriesField,a=t.shape;if(i===!1)r.legend(!1);else{var o=n||Vn,l=i1(i,["selected"]);(!a||!a.startsWith("hollow"))&&(I(l,["marker","style","lineWidth"])||jt(l,["marker","style","lineWidth"],0)),r.legend(o,l),I(i,"selected")&&P(r.views,function(s){return s.legend(o,i)})}return e}function $Rt(e){var r=e.chart,t=Yt(r,UP);return Xe()(A(A({},e),{chart:t})),e}function kRt(e){var r=e.chart,t=e.options,i=t.animation;return P(r.views,function(n){typeof i=="boolean"?n.animate(i):n.animate(!0),P(n.geometries,function(a){a.animate(i)})}),e}function RRt(e){return It(ie,FRt,ORt,PRt,IRt,Dr,LRt,DRt,Ae,$Rt,kRt)(e)}(function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="violin",t}return r.getDefaultOptions=function(){return ERt},r.prototype.changeData=function(t){this.updateOption({data:t}),this.chart.changeData(w6(this.options))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return RRt},r})(Dt);var BRt=function(e){return function(r,t){var i=[];return i[0]=e(r[0],t[0]),i[1]=e(r[1],t[1]),i[2]=e(r[2],t[2]),i}},hG={normal:function(e){return e},multiply:function(e,r){return e*r/255},screen:function(e,r){return 255*(1-(1-e/255)*(1-r/255))},overlay:function(e,r){return r<128?2*e*r/255:255*(1-2*(1-e/255)*(1-r/255))},darken:function(e,r){return e>r?r:e},lighten:function(e,r){return e>r?e:r},dodge:function(e,r){return e===255?255:(e=255*(r/255)/(1-e/255),e>255?255:e)},burn:function(e,r){return r===255?255:e===0?0:255*(1-Math.min(1,(1-r/255)/(e/255)))}},NRt=function(e){if(!hG[e])throw new Error("unknown blend mode "+e);return hG[e]};function GRt(e,r,t){t===void 0&&(t="normal");var i=BRt(NRt(t))(h0(e),h0(r)),n=h0(e),a=n[0],o=n[1],l=n[2],s=n[3],u=h0(r),c=u[0],f=u[1],h=u[2],v=u[3],d=Number((s+v*(1-s)).toFixed(2)),p=Math.round((s*(1-v)*(a/255)+s*v*(i[0]/255)+(1-s)*v*(c/255))/d*255),x=Math.round((s*(1-v)*(o/255)+s*v*(i[1]/255)+(1-s)*v*(f/255))/d*255),m=Math.round((s*(1-v)*(l/255)+s*v*(i[2]/255)+(1-s)*v*(h/255))/d*255);return"rgba("+p+", "+x+", "+m+", "+d+")"}function h0(e){var r=e.replace("/s+/g",""),t;return typeof r=="string"&&!r.startsWith("rgba")&&!r.startsWith("#")?t=Qo.rgb2arr(Qo.toRGB(r)).concat([1]):(r.startsWith("rgba")&&(t=r.replace("rgba(","").replace(")","").split(",")),r.startsWith("#")&&(t=Qo.rgb2arr(r).concat([1])),t.map(function(i,n){return n===3?Number(i):i|0}))}function zRt(e,r,t,i){i=i||{};var n=i.maxIterations||100,a=i.tolerance||1e-10,o=e(r),l=e(t),s=t-r;if(o*l>0)throw"Initial bisect points must have opposite signs";if(o===0)return r;if(l===0)return t;for(var u=0;u<n;++u){s/=2;var c=r+s,f=e(c);if(f*o>=0&&(r=c),Math.abs(s)<a||f===0)return c}return r+s}function UT(e){for(var r=new Array(e),t=0;t<e;++t)r[t]=0;return r}function vG(e,r){return UT(e).map(function(){return UT(r)})}function Lf(e,r){for(var t=0,i=0;i<e.length;++i)t+=e[i]*r[i];return t}function qT(e){return Math.sqrt(Lf(e,e))}function ZT(e,r,t){for(var i=0;i<r.length;++i)e[i]=r[i]*t}function Yo(e,r,t,i,n){for(var a=0;a<e.length;++a)e[a]=r*t[a]+i*n[a]}function T6(e,r,t){t=t||{};var i=t.maxIterations||r.length*200,n=t.nonZeroDelta||1.05,a=t.zeroDelta||.001,o=t.minErrorDelta||1e-6,l=t.minErrorDelta||1e-5,s=t.rho!==void 0?t.rho:1,u=t.chi!==void 0?t.chi:2,c=t.psi!==void 0?t.psi:-.5,f=t.sigma!==void 0?t.sigma:.5,h,v=r.length,d=new Array(v+1);d[0]=r,d[0].fx=e(r),d[0].id=0;for(var p=0;p<v;++p){var x=r.slice();x[p]=x[p]?x[p]*n:a,d[p+1]=x,d[p+1].fx=e(x),d[p+1].id=p+1}function m(H){for(var B=0;B<H.length;B++)d[v][B]=H[B];d[v].fx=H.fx}for(var _=function(H,B){return H.fx-B.fx},b=r.slice(),w=r.slice(),S=r.slice(),M=r.slice(),F=0;F<i;++F){if(d.sort(_),t.history){var O=d.map(function(H){var B=H.slice();return B.fx=H.fx,B.id=H.id,B});O.sort(function(H,B){return H.id-B.id}),t.history.push({x:d[0].slice(),fx:d[0].fx,simplex:O})}for(h=0,p=0;p<v;++p)h=Math.max(h,Math.abs(d[0][p]-d[1][p]));if(Math.abs(d[0].fx-d[v].fx)<o&&h<l)break;for(p=0;p<v;++p){b[p]=0;for(var L=0;L<v;++L)b[p]+=d[L][p];b[p]/=v}var D=d[v];if(Yo(w,1+s,b,-s,D),w.fx=e(w),w.fx<d[0].fx)Yo(M,1+u,b,-u,D),M.fx=e(M),M.fx<w.fx?m(M):m(w);else if(w.fx>=d[v-1].fx){var k=!1;if(w.fx>D.fx?(Yo(S,1+c,b,-c,D),S.fx=e(S),S.fx<D.fx?m(S):k=!0):(Yo(S,1-c*s,b,c*s,D),S.fx=e(S),S.fx<w.fx?m(S):k=!0),k){if(f>=1)break;for(p=1;p<d.length;++p)Yo(d[p],1-f,d[0],f,d[p]),d[p].fx=e(d[p])}}else m(w)}return d.sort(_),{fx:d[0].fx,x:d[0]}}function VRt(e,r,t,i,n,a,o){var l=t.fx,s=Lf(t.fxprime,r),u=l,c=l,f=s,h=0;n=n||1,a=a||1e-6,o=o||.1;function v(p,x,m){for(var _=0;_<16;++_)if(n=(p+x)/2,Yo(i.x,1,t.x,n,r),u=i.fx=e(i.x,i.fxprime),f=Lf(i.fxprime,r),u>l+a*n*s||u>=m)x=n;else{if(Math.abs(f)<=-o*s)return n;f*(x-p)>=0&&(x=p),p=n,m=u}return 0}for(var d=0;d<10;++d){if(Yo(i.x,1,t.x,n,r),u=i.fx=e(i.x,i.fxprime),f=Lf(i.fxprime,r),u>l+a*n*s||d&&u>=c)return v(h,n,c);if(Math.abs(f)<=-o*s)return n;if(f>=0)return v(n,h,u);c=u,h=n,n*=2}return n}function jRt(e,r,t){var i={x:r.slice(),fx:0,fxprime:r.slice()},n={x:r.slice(),fx:0,fxprime:r.slice()},a=r.slice(),o,l,s=1,u;t=t||{},u=t.maxIterations||r.length*20,i.fx=e(i.x,i.fxprime),o=i.fxprime.slice(),ZT(o,i.fxprime,-1);for(var c=0;c<u;++c){if(s=VRt(e,o,i,n,s),t.history&&t.history.push({x:i.x.slice(),fx:i.fx,fxprime:i.fxprime.slice(),alpha:s}),!s)ZT(o,i.fxprime,-1);else{Yo(a,1,n.fxprime,-1,i.fxprime);var f=Lf(i.fxprime,i.fxprime),h=Math.max(0,Lf(a,n.fxprime)/f);Yo(o,h,o,-1,n.fxprime),l=i,i=n,n=l}if(qT(i.fxprime)<=1e-5)break}return t.history&&t.history.push({x:i.x.slice(),fx:i.fx,fxprime:i.fxprime.slice(),alpha:s}),i}var M6=1e-10;function qP(e,r){var t=YRt(e),i=t.filter(function(F){return HRt(F,e)}),n=0,a=0,o,l=[];if(i.length>1){var s=O6(i);for(o=0;o<i.length;++o){var u=i[o];u.angle=Math.atan2(u.x-s.x,u.y-s.y)}i.sort(function(F,O){return O.angle-F.angle});var c=i[i.length-1];for(o=0;o<i.length;++o){var f=i[o];a+=(c.x+f.x)*(f.y-c.y);for(var h={x:(f.x+c.x)/2,y:(f.y+c.y)/2},v=null,d=0;d<f.parentIndex.length;++d)if(c.parentIndex.indexOf(f.parentIndex[d])>-1){var p=e[f.parentIndex[d]],x=Math.atan2(f.x-p.x,f.y-p.y),m=Math.atan2(c.x-p.x,c.y-p.y),_=m-x;_<0&&(_+=2*Math.PI);var b=m-_/2,w=Ta(h,{x:p.x+p.radius*Math.sin(b),y:p.y+p.radius*Math.cos(b)});w>p.radius*2&&(w=p.radius*2),(v===null||v.width>w)&&(v={circle:p,width:w,p1:f,p2:c})}v!==null&&(l.push(v),n+=QT(v.circle.radius,v.width),c=f)}}else{var S=e[0];for(o=1;o<e.length;++o)e[o].radius<S.radius&&(S=e[o]);var M=!1;for(o=0;o<e.length;++o)if(Ta(e[o],S)>Math.abs(S.radius-e[o].radius)){M=!0;break}M?n=a=0:(n=S.radius*S.radius*Math.PI,l.push({circle:S,p1:{x:S.x,y:S.y+S.radius},p2:{x:S.x-M6,y:S.y+S.radius},width:S.radius*2}))}return a/=2,r&&(r.area=n+a,r.arcArea=n,r.polygonArea=a,r.arcs=l,r.innerPoints=i,r.intersectionPoints=t),n+a}function HRt(e,r){for(var t=0;t<r.length;++t)if(Ta(e,r[t])>r[t].radius+M6)return!1;return!0}function YRt(e){for(var r=[],t=0;t<e.length;++t)for(var i=t+1;i<e.length;++i)for(var n=F6(e[t],e[i]),a=0;a<n.length;++a){var o=n[a];o.parentIndex=[t,i],r.push(o)}return r}function QT(e,r){return e*e*Math.acos(1-r/e)-(e-r)*Math.sqrt(r*(2*e-r))}function Ta(e,r){return Math.sqrt((e.x-r.x)*(e.x-r.x)+(e.y-r.y)*(e.y-r.y))}function E6(e,r,t){if(t>=e+r)return 0;if(t<=Math.abs(e-r))return Math.PI*Math.min(e,r)*Math.min(e,r);var i=e-(t*t-r*r+e*e)/(2*t),n=r-(t*t-e*e+r*r)/(2*t);return QT(e,i)+QT(r,n)}function F6(e,r){var t=Ta(e,r),i=e.radius,n=r.radius;if(t>=i+n||t<=Math.abs(i-n))return[];var a=(i*i-n*n+t*t)/(2*t),o=Math.sqrt(i*i-a*a),l=e.x+a*(r.x-e.x)/t,s=e.y+a*(r.y-e.y)/t,u=-(r.y-e.y)*(o/t),c=-(r.x-e.x)*(o/t);return[{x:l+u,y:s-c},{x:l-u,y:s+c}]}function O6(e){for(var r={x:0,y:0},t=0;t<e.length;++t)r.x+=e[t].x,r.y+=e[t].y;return r.x/=e.length,r.y/=e.length,r}function WRt(e,r){r=r||{},r.maxIterations=r.maxIterations||500;var t=r.initialLayout||ZRt,i=r.lossFunction||ZP;e=XRt(e);var n=t(e,r),a=[],o=[],l;for(l in n)n.hasOwnProperty(l)&&(a.push(n[l].x),a.push(n[l].y),o.push(l));for(var s=T6(function(f){for(var h={},v=0;v<o.length;++v){var d=o[v];h[d]={x:f[2*v],y:f[2*v+1],radius:n[d].radius}}return i(h,e)},a,r),u=s.x,c=0;c<o.length;++c)l=o[c],n[l].x=u[2*c],n[l].y=u[2*c+1];return n}var P6=1e-10;function KT(e,r,t){return Math.min(e,r)*Math.min(e,r)*Math.PI<=t+P6?Math.abs(e-r):zRt(function(i){return E6(e,r,i)-t},0,e+r)}function XRt(e){e=e.slice();var r=[],t={},i,n,a,o;for(i=0;i<e.length;++i){var l=e[i];l.sets.length==1?r.push(l.sets[0]):l.sets.length==2&&(a=l.sets[0],o=l.sets[1],t[[a,o]]=!0,t[[o,a]]=!0)}for(r.sort(function(s,u){return s>u?1:-1}),i=0;i<r.length;++i)for(a=r[i],n=i+1;n<r.length;++n)o=r[n],[a,o]in t||e.push({sets:[a,o],size:0});return e}function URt(e,r,t){var i=vG(r.length,r.length),n=vG(r.length,r.length);return e.filter(function(a){return a.sets.length==2}).map(function(a){var o=t[a.sets[0]],l=t[a.sets[1]],s=Math.sqrt(r[o].size/Math.PI),u=Math.sqrt(r[l].size/Math.PI),c=KT(s,u,a.size);i[o][l]=i[l][o]=c;var f=0;a.size+1e-10>=Math.min(r[o].size,r[l].size)?f=1:a.size<=1e-10&&(f=-1),n[o][l]=n[l][o]=f}),{distances:i,constraints:n}}function qRt(e,r,t,i){var n=0,a;for(a=0;a<r.length;++a)r[a]=0;for(a=0;a<t.length;++a)for(var o=e[2*a],l=e[2*a+1],s=a+1;s<t.length;++s){var u=e[2*s],c=e[2*s+1],f=t[a][s],h=i[a][s],v=(u-o)*(u-o)+(c-l)*(c-l),d=Math.sqrt(v),p=v-f*f;h>0&&d<=f||h<0&&d>=f||(n+=2*p*p,r[2*a]+=4*p*(o-u),r[2*a+1]+=4*p*(l-c),r[2*s]+=4*p*(u-o),r[2*s+1]+=4*p*(c-l))}return n}function ZRt(e,r){var t=KRt(e,r),i=r.lossFunction||ZP;if(e.length>=8){var n=QRt(e,r),a=i(n,e),o=i(t,e);a+1e-8<o&&(t=n)}return t}function QRt(e,r){r=r||{};var t=r.restarts||10,i=[],n={},a;for(a=0;a<e.length;++a){var o=e[a];o.sets.length==1&&(n[o.sets[0]]=i.length,i.push(o))}var l=URt(e,i,n),s=l.distances,u=l.constraints,c=qT(s.map(qT))/s.length;s=s.map(function(_){return _.map(function(b){return b/c})});var f=function(_,b){return qRt(_,b,s,u)},h,v;for(a=0;a<t;++a){var d=UT(s.length*2).map(Math.random);v=jRt(f,d,r),(!h||v.fx<h.fx)&&(h=v)}var p=h.x,x={};for(a=0;a<i.length;++a){var m=i[a];x[m.sets[0]]={x:p[2*a]*c,y:p[2*a+1]*c,radius:Math.sqrt(m.size/Math.PI)}}if(r.history)for(a=0;a<r.history.length;++a)ZT(r.history[a].x,c);return x}function KRt(e,r){for(var t=r&&r.lossFunction?r.lossFunction:ZP,i={},n={},a,o=0;o<e.length;++o){var l=e[o];l.sets.length==1&&(a=l.sets[0],i[a]={x:1e10,y:1e10,rowid:Object.keys(i).length,size:l.size,radius:Math.sqrt(l.size/Math.PI)},n[a]=[])}e=e.filter(function(R){return R.sets.length==2});for(var o=0;o<e.length;++o){var s=e[o],u=s.hasOwnProperty("weight")?s.weight:1,c=s.sets[0],f=s.sets[1];s.size+P6>=Math.min(i[c].size,i[f].size)&&(u=0),n[c].push({set:f,size:s.size,weight:u}),n[f].push({set:c,size:s.size,weight:u})}var h=[];for(a in n)if(n.hasOwnProperty(a)){for(var v=0,o=0;o<n[a].length;++o)v+=n[a][o].size*n[a][o].weight;h.push({set:a,size:v})}function d(R,G){return G.size-R.size}h.sort(d);var p={};function x(R){return R.set in p}function m(R,G){i[G].x=R.x,i[G].y=R.y,p[G]=!0}m({x:0,y:0},h[0].set);for(var o=1;o<h.length;++o){var _=h[o].set,b=n[_].filter(x);if(a=i[_],b.sort(d),b.length===0)throw"ERROR: missing pairwise overlap information";for(var w=[],S=0;S<b.length;++S){var M=i[b[S].set],F=KT(a.radius,M.radius,b[S].size);w.push({x:M.x+F,y:M.y}),w.push({x:M.x-F,y:M.y}),w.push({y:M.y+F,x:M.x}),w.push({y:M.y-F,x:M.x});for(var O=S+1;O<b.length;++O)for(var L=i[b[O].set],D=KT(a.radius,L.radius,b[O].size),k=F6({x:M.x,y:M.y,radius:F},{x:L.x,y:L.y,radius:D}),H=0;H<k.length;++H)w.push(k[H])}for(var B=1e50,j=w[0],S=0;S<w.length;++S){i[_].x=w[S].x,i[_].y=w[S].y;var U=t(i,e);U<B&&(B=U,j=w[S])}m(j,_)}return i}function ZP(e,r){var t=0;function i(c){return c.map(function(f){return e[f]})}for(var n=0;n<r.length;++n){var a=r[n],o=void 0;if(a.sets.length!=1){if(a.sets.length==2){var l=e[a.sets[0]],s=e[a.sets[1]];o=E6(l.radius,s.radius,Ta(l,s))}else o=qP(i(a.sets));var u=a.hasOwnProperty("weight")?a.weight:1;t+=u*(o-a.size)*(o-a.size)}}return t}function JRt(e){var r=function(t){var i=Math.max.apply(null,e.map(function(a){return a[t]+a.radius})),n=Math.min.apply(null,e.map(function(a){return a[t]-a.radius}));return{max:i,min:n}};return{xRange:r("x"),yRange:r("y")}}function tBt(e,r,t,i){var n=[],a=[];for(var o in e)e.hasOwnProperty(o)&&(a.push(o),n.push(e[o]));r-=2*i,t-=2*i;var l=JRt(n),s=l.xRange,u=l.yRange;if(s.max==s.min||u.max==u.min)return console.log("not scaling solution: zero size detected"),e;for(var c=r/(s.max-s.min),f=t/(u.max-u.min),h=Math.min(f,c),v=(r-(s.max-s.min)*h)/2,d=(t-(u.max-u.min)*h)/2,p={},x=0;x<n.length;++x){var m=n[x];p[a[x]]={radius:h*m.radius,x:i+v+(m.x-s.min)*h,y:i+d+(m.y-u.min)*h}}return p}function tA(e,r,t){var i=r[0].radius-Ta(r[0],e),n,a;for(n=1;n<r.length;++n)a=r[n].radius-Ta(r[n],e),a<=i&&(i=a);for(n=0;n<t.length;++n)a=Ta(t[n],e)-t[n].radius,a<=i&&(i=a);return i}function I6(e,r){var t=[],i;for(i=0;i<e.length;++i){var n=e[i];t.push({x:n.x,y:n.y}),t.push({x:n.x+n.radius/2,y:n.y}),t.push({x:n.x-n.radius/2,y:n.y}),t.push({x:n.x,y:n.y+n.radius/2}),t.push({x:n.x,y:n.y-n.radius/2})}var a=t[0],o=tA(t[0],e,r);for(i=1;i<t.length;++i){var l=tA(t[i],e,r);l>=o&&(a=t[i],o=l)}var s=T6(function(h){return-1*tA({x:h[0],y:h[1]},e,r)},[a.x,a.y],{maxIterations:500,minErrorDelta:1e-10}).x,u={x:s[0],y:s[1]},c=!0;for(i=0;i<e.length;++i)if(Ta(u,e[i])>e[i].radius){c=!1;break}for(i=0;i<r.length;++i)if(Ta(u,r[i])<r[i].radius){c=!1;break}if(!c)if(e.length==1)u={x:e[0].x,y:e[0].y};else{var f={};qP(e,f),f.arcs.length===0?u={x:0,y:-1e3,disjoint:!0}:f.arcs.length==1?u={x:f.arcs[0].circle.x,y:f.arcs[0].circle.y}:r.length?u=I6(e,[]):u=O6(f.arcs.map(function(h){return h.p1}))}return u}function eBt(e){var r={},t=[];for(var i in e)t.push(i),r[i]=[];for(var n=0;n<t.length;n++)for(var a=e[t[n]],o=n+1;o<t.length;++o){var l=e[t[o]],s=Ta(a,l);s+l.radius<=a.radius+1e-10?r[t[o]].push(t[n]):s+a.radius<=l.radius+1e-10&&r[t[n]].push(t[o])}return r}function rBt(e,r){for(var t={},i=eBt(e),n=0;n<r.length;++n){for(var a=r[n].sets,o={},l={},s=0;s<a.length;++s){o[a[s]]=!0;for(var u=i[a[s]],c=0;c<u.length;++c)l[u[c]]=!0}var f=[],h=[];for(var v in e)v in o?f.push(e[v]):v in l||h.push(e[v]);var d=I6(f,h);t[a]=d,d.disjoint&&r[n].size>0&&console.log("WARNING: area "+a+" not represented on screen")}return t}function iBt(e,r,t){var i=[],n=e-t,a=r;return i.push("M",n,a),i.push("A",t,t,0,1,0,n+2*t,a),i.push("A",t,t,0,1,0,n,a),i.join(" ")}function nBt(e){var r={};qP(e,r);var t=r.arcs;if(t.length===0)return"M 0 0";if(t.length==1){var i=t[0].circle;return iBt(i.x,i.y,i.radius)}else{for(var n=[`
|
|
M`,t[0].p2.x,t[0].p2.y],a=0;a<t.length;++a){var o=t[a],l=o.circle.radius,s=o.width>l;n.push(`
|
|
A`,l,l,0,s?1:0,1,o.p1.x,o.p1.y)}return n.join(" ")}}var il="id",JT="path",aBt={appendPadding:[10,0,20,0],blendMode:"multiply",tooltip:{showTitle:!1,showMarkers:!1,fields:["id","size"],formatter:function(e){return{name:e.id,value:e.size}}},legend:{position:"top-left"},label:{style:{textAlign:"center",fill:"#fff"}},interactions:[{type:"legend-filter",enable:!1}],state:{active:{style:{stroke:"#000"}},selected:{style:{stroke:"#000",lineWidth:2}},inactive:{style:{fillOpacity:.3,strokeOpacity:.3}}},defaultInteractions:["tooltip","venn-legend-active"]},oBt=uc(function(e,r,t,i){var n=new Map,a=e.length;return r.forEach(function(o,l){if(o[i].length===1)n.set(o[il],e[(l+a)%a]);else{var s=o[i].map(function(u){return n.get(u)});n.set(o[il],s.slice(1).reduce(function(u,c){return GRt(u,c,t)},s[0]))}}),n},function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];return JSON.stringify(e)});function lBt(e,r,t,i){i===void 0&&(i=0);var n=e.data,a=e.setsField,o=e.sizeField;if(n.length===0)return ul(Fa.WARN,!1,"warn: %s","\u6570\u636E\u4E0D\u80FD\u4E3A\u7A7A"),[];var l=n.map(function(f){var h;return A(A({},f),(h={sets:f[a]||[],size:f[o]},h[JT]="",h[il]="",h))});l.sort(function(f,h){return f.sets.length-h.sets.length});var s=WRt(l),u=tBt(s,r,t,i),c=rBt(u,l);return l.forEach(function(f){var h=f.sets,v=h.join(",");f[il]=v;var d=h.map(function(m){return u[m]}),p=nBt(d);/[zZ]$/.test(p)||(p+=" Z"),f[JT]=p;var x=c[v]||{x:0,y:0};Kt(f,x)}),l}function sBt(e,r){for(var t=0;t<r.length;t++)if(!e.includes(r[t]))return!1;return!0}function uBt(e){return J({},e.defaultStyle,{fill:e.color},e.style)}te("schema","venn",{draw:function(e,r){var t=e.data,i=c1(t[JT]),n=uBt(e),a=r.addGroup({name:"venn-shape"});a.addShape("path",{attrs:A(A({},n),{path:i}),name:"venn-path"});var o=e.customInfo,l=o.offsetX,s=o.offsetY,u=Fi.transform(null,[["t",l,s]]);return a.setMatrix(u),a},getMarker:function(e){var r=e.color;return{symbol:"circle",style:{lineWidth:0,stroke:r,fill:r,r:4}}}});var cBt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getLabelPoint=function(t,i,n){var a=t.data,o=a.x,l=a.y,s=t.customLabelInfo,u=s.offsetX,c=s.offsetY;return{content:t.content[n],x:o+u,y:l+c}},r}(gg);kh("venn",cBt);function Fb(e){if(!!e){var r=e.geometries[0].elements;r.forEach(function(t){t.shape.toFront()})}}var fBt=vg("element-active"),hBt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.syncElementsPos=function(){Fb(this.context.view)},r.prototype.active=function(){e.prototype.active.call(this),this.syncElementsPos()},r.prototype.toggle=function(){e.prototype.toggle.call(this),this.syncElementsPos()},r.prototype.reset=function(){e.prototype.reset.call(this),this.syncElementsPos()},r}(fBt),vBt=vg("element-highlight"),dBt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.syncElementsPos=function(){Fb(this.context.view)},r.prototype.highlight=function(){e.prototype.highlight.call(this),this.syncElementsPos()},r.prototype.toggle=function(){e.prototype.toggle.call(this),this.syncElementsPos()},r.prototype.clear=function(){e.prototype.clear.call(this),this.syncElementsPos()},r.prototype.reset=function(){e.prototype.reset.call(this),this.syncElementsPos()},r}(vBt),pBt=vg("element-selected"),gBt=vg("element-single-selected"),yBt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.syncElementsPos=function(){Fb(this.context.view)},r.prototype.selected=function(){e.prototype.selected.call(this),this.syncElementsPos()},r.prototype.toggle=function(){e.prototype.toggle.call(this),this.syncElementsPos()},r.prototype.reset=function(){e.prototype.reset.call(this),this.syncElementsPos()},r}(pBt),mBt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.syncElementsPos=function(){Fb(this.context.view)},r.prototype.selected=function(){e.prototype.selected.call(this),this.syncElementsPos()},r.prototype.toggle=function(){e.prototype.toggle.call(this),this.syncElementsPos()},r.prototype.reset=function(){e.prototype.reset.call(this),this.syncElementsPos()},r}(gBt);Et("venn-element-active",hBt);Et("venn-element-highlight",dBt);Et("venn-element-selected",yBt);Et("venn-element-single-selected",mBt);Lt("venn-element-active",{start:[{trigger:"element:mouseenter",action:"venn-element-active:active"}],end:[{trigger:"element:mouseleave",action:"venn-element-active:reset"}]});Lt("venn-element-highlight",{start:[{trigger:"element:mouseenter",action:"venn-element-highlight:highlight"}],end:[{trigger:"element:mouseleave",action:"venn-element-highlight:reset"}]});Lt("venn-element-selected",{start:[{trigger:"element:click",action:"venn-element-selected:toggle"}],rollback:[{trigger:"dblclick",action:["venn-element-selected:reset"]}]});Lt("venn-element-single-selected",{start:[{trigger:"element:click",action:"venn-element-single-selected:toggle"}],rollback:[{trigger:"dblclick",action:["venn-element-single-selected:reset"]}]});Lt("venn-legend-active",{start:[{trigger:"legend-item:mouseenter",action:["list-active:active","venn-element-active:active"]}],end:[{trigger:"legend-item:mouseleave",action:["list-active:reset","venn-element-active:reset"]}]});Lt("venn-legend-highlight",{start:[{trigger:"legend-item:mouseenter",action:["legend-item-highlight:highlight","venn-element-highlight:highlight"]}],end:[{trigger:"legend-item:mouseleave",action:["legend-item-highlight:reset","venn-element-highlight:reset"]}]});var xBt=40;function L6(e,r,t){var i=e.chart,n=e.options,a=n.blendMode,o=n.setsField,l=i.getTheme(),s=l.colors10,u=l.colors20,c=t;it(c)||(c=r.filter(function(h){return h[o].length===1}).length<=10?s:u);var f=oBt(c,r,a,o);return function(h){return f.get(h)||c[0]}}function _Bt(e,r){var t=e.options,i=t.color;if(typeof i!="function"){var n=typeof i=="string"?[i]:i,a=L6(e,r,n);return function(o){return a(o[il])}}return i}function bBt(e){var r=e.chart,t=e.options,i=t.legend,n=t.appendPadding,a=t.padding,o=Ts(n);return i!==!1&&(o=bb(n,I(i,"position"),xBt)),r.appendPadding=BP([o,a]),e}function wBt(e){var r=e.options,t=r.data;t||(ul(Fa.WARN,!1,"warn: %s","\u6570\u636E\u4E0D\u80FD\u4E3A\u7A7A"),t=[]);var i=t.filter(function(a){return a.sets.length===1}).map(function(a){return a.sets[0]}),n=t.filter(function(a){var o=a.sets;return sBt(i,o)});return Ge(n,t)||ul(Fa.WARN,!1,"warn: %s","\u4EA4\u96C6\u4E2D\u4E0D\u80FD\u51FA\u73B0\u4E0D\u5B58\u5728\u7684\u96C6\u5408, \u8BF7\u8F93\u5165\u5408\u6CD5\u6570\u636E"),ft({},e,{options:{data:n}})}function CBt(e){var r=e.chart,t=e.options,i=t.pointStyle,n=t.setsField,a=t.sizeField,o=Ts(r.appendPadding),l=o[0],s=o[1],u=o[2],c=o[3],f={offsetX:c,offsetY:l},h=r.viewBBox,v=h.width,d=h.height,p=lBt(t,Math.max(v-(s+c),0),Math.max(d-(l+u),0),0);r.data(p);var x=VP(J({},e,{options:{xField:"x",yField:"y",sizeField:a,seriesField:il,rawFields:[n,a],schema:{shape:"venn",style:i}}})).ext,m=x.geometry;m.customInfo(f);var _=_Bt(e,p);return typeof _=="function"&&m.color(il,function(b){var w=p.find(function(M){return M[il]===b}),S=L6(e,p)(b);return _(w,S)}),e}function SBt(e){var r=e.chart,t=e.options,i=t.label,n=Ts(r.appendPadding),a=n[0],o=n[3],l={offsetX:o,offsetY:a},s=ei(r,"schema");if(!i)s.label(!1);else{var u=i.callback,c=ue(i,["callback"]);s.label({fields:["id"],callback:u,cfg:ft({},Pr(c),{type:"venn",customLabelInfo:l})})}return e}function ABt(e){var r=e.chart,t=e.options,i=t.legend,n=t.sizeField;return r.legend(il,i),r.legend(n,!1),e}function TBt(e){var r=e.chart;return r.axis(!1),e}function MBt(e){var r=e.options,t=e.chart,i=r.interactions;if(i){var n={"legend-active":"venn-legend-active","legend-highlight":"venn-legend-highlight"};Ae(J({},e,{options:{interactions:i.map(function(a){return A(A({},a),{type:n[a.type]||a.type})})}}))}return t.removeInteraction("legend-active"),t.removeInteraction("legend-highlight"),e}function EBt(e){return It(bBt,ie,wBt,CBt,SBt,We({}),ABt,TBt,Dr,MBt,ce)(e)}(function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="venn",t}return r.getDefaultOptions=function(){return aBt},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return EBt},r.prototype.triggerResize=function(){this.chart.destroyed||(this.chart.forceFit(),this.chart.clear(),this.execAdaptor(),this.chart.render(!0))},r})(Dt);var cp="$$stock-range$$",Ob="trend",D6="up",$6="down",FBt={showMarkers:!1,showCrosshairs:!0,shared:!0,crosshairs:{type:"xy",follow:!0,text:function(e,r,t){var i;if(e==="x"){var n=t[0];i=n?n.title:r}else i=r;return{position:e==="y"?"start":"end",content:i,style:{fill:"#dfdfdf"}}},textBackground:{padding:[2,4],style:{fill:"#666"}}}},OBt=J({},Dt.getDefaultOptions(),{tooltip:FBt,interactions:[{type:"tooltip"}],legend:{position:"top-left"},risingFill:"#ef5350",fallingFill:"#26a69a"});function k6(e,r){return je(e,function(t){if(it(r)){var i=r[0],n=r[1],a=r[2],o=r[3];t[Ob]=t[i]<=t[n]?D6:$6,t[cp]=[t[i],t[n],t[a],t[o]]}return t})}function PBt(e){var r=e.chart,t=e.options,i=t.yField,n=t.data,a=t.risingFill,o=t.fallingFill,l=t.tooltip,s=t.stockStyle;r.data(k6(n,i));var u=l;return u!==!1&&(u=J({},{fields:i},u)),VP(J({},e,{options:{schema:{shape:"candle",color:[a,o],style:s},yField:cp,seriesField:Ob,rawFields:i,tooltip:u}})),e}function IBt(e){var r,t,i=e.chart,n=e.options,a=n.meta,o=n.xAxis,l=n.yAxis,s=n.xField,u=(r={},r[s]={type:"timeCat",tickCount:6},r[Ob]={values:[D6,$6]},r),c=J(u,a,(t={},t[s]=se(o,ji),t[cp]=se(l,ji),t));return i.scale(c),e}function LBt(e){var r=e.chart,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField;return i===!1?r.axis(a,!1):r.axis(a,i),n===!1?r.axis(cp,!1):r.axis(cp,n),e}function DBt(e){var r=e.chart,t=e.options,i=t.tooltip;return i!==!1?r.tooltip(i):r.tooltip(!1),e}function $Bt(e){var r=e.chart,t=e.options,i=t.legend;return i?r.legend(Ob,i):i===!1&&r.legend(!1),e}function kBt(e){It(ie,PBt,IBt,LBt,DBt,$Bt,Ae,ce,Xe(),Sb)(e)}(function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="stock",t}return r.getDefaultOptions=function(){return OBt},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return kBt},r.prototype.changeData=function(t){this.updateOption({data:t});var i=this.options.yField;this.chart.changeData(k6(t,i))},r})(Dt);var eA,Ms="$$percentage$$",Es="$$mappingValue$$",nl="$$conversion$$",tM="$$totalPercentage$$",fp="$$x$$",hp="$$y$$",RBt={appendPadding:[0,80],minSize:0,maxSize:1,meta:(eA={},eA[Es]={min:0,max:1,nice:!1},eA),label:{style:{fill:"#fff",fontSize:12}},tooltip:{showTitle:!1,showMarkers:!1,shared:!1},conversionTag:{offsetX:10,offsetY:0,style:{fontSize:12,fill:"rgba(0,0,0,0.45)"}}};function R6(e,r,t){var i=[],n=t.yField,a=t.maxSize,o=t.minSize,l=I(Qx(r,n),[n]),s=Mt(a)?a:1,u=Mt(o)?o:0;return i=je(e,function(c,f){var h=(c[n]||0)/l;return c[Ms]=h,c[Es]=(s-u)*h+u,c[nl]=[I(e,[f-1,n]),c[n]],c}),i}function QP(e){return function(r){var t=r.chart,i=r.options,n=i.conversionTag,a=t.getOptions().data;if(n){var o=n.formatter;a.forEach(function(l,s){if(!(s<=0||Number.isNaN(l[Es]))){var u=e(l,s,a,{top:!0,text:{content:pt(o)?o(l,a):o,offsetX:n.offsetX,offsetY:n.offsetY,position:"end",autoRotate:!1,style:A({textAlign:"start",textBaseline:"middle"},n.style)}});t.annotation().line(u)}})}return r}}function BBt(e){var r=e.chart,t=e.options,i=t.data,n=i===void 0?[]:i,a=t.yField,o=t.maxSize,l=t.minSize,s=R6(n,n,{yField:a,maxSize:o,minSize:l});return r.data(s),e}function NBt(e){var r=e.chart,t=e.options,i=t.xField,n=t.yField,a=t.color,o=t.tooltip,l=t.label,s=t.shape,u=s===void 0?"funnel":s,c=t.funnelStyle,f=t.state,h=ra(o,[i,n]),v=h.fields,d=h.formatter;Ki({chart:r,options:{type:"interval",xField:i,yField:Es,colorField:i,tooltipFields:it(v)&&v.concat([Ms,nl]),mapping:{shape:u,tooltip:d,color:a,style:c},label:l,state:f}});var p=ei(e.chart,"interval");return p.adjust("symmetric"),e}function GBt(e){var r=e.chart,t=e.options,i=t.isTransposed;return r.coordinate({type:"rect",actions:i?[]:[["transpose"],["scale",1,-1]]}),e}function zBt(e){var r=e.options,t=r.maxSize,i=function(n,a,o,l){var s=t-(t-n[Es])/2;return A(A({},l),{start:[a-.5,s],end:[a-.5,s+.05]})};return QP(i)(e),e}function B6(e){return It(BBt,NBt,GBt,zBt)(e)}function VBt(e){var r,t=e.chart,i=e.options,n=i.data,a=n===void 0?[]:n,o=i.yField;return t.data(a),t.scale((r={},r[o]={sync:!0},r)),e}function jBt(e){var r=e.chart,t=e.options,i=t.data,n=t.xField,a=t.yField,o=t.color,l=t.compareField,s=t.isTransposed,u=t.tooltip,c=t.maxSize,f=t.minSize,h=t.label,v=t.funnelStyle,d=t.state;return r.facet("mirror",{fields:[l],transpose:!s,padding:s?0:[32,0,0,0],eachView:function(p,x){var m=s?x.rowIndex:x.columnIndex;s||p.coordinate({type:"rect",actions:[["transpose"],["scale",m===0?-1:1,-1]]});var _=R6(x.data,i,{yField:a,maxSize:c,minSize:f});p.data(_);var b=ra(u,[n,a,l]),w=b.fields,S=b.formatter,M=s?{offset:m===0?10:-23,position:m===0?"bottom":"top"}:{offset:10,position:"left",style:{textAlign:m===0?"end":"start"}};Ki({chart:p,options:{type:"interval",xField:n,yField:Es,colorField:n,tooltipFields:it(w)&&w.concat([Ms,nl]),mapping:{shape:"funnel",tooltip:S,color:o,style:v},label:h===!1?!1:J({},M,h),state:d}})}}),e}function HBt(e){var r=e.chart,t=e.options,i=t.conversionTag,n=t.isTransposed;return r.once("beforepaint",function(){r.views.forEach(function(a,o){var l=function(s,u,c,f){var h=o===0?-1:1;return J({},f,{start:[u-.5,s[Es]],end:[u-.5,s[Es]+.05],text:n?{style:{textAlign:"start"}}:{offsetX:i!==!1?h*i.offsetX:0,style:{textAlign:o===0?"end":"start"}}})};QP(l)(J({},{chart:a,options:t}))})}),e}function YBt(e){return It(VBt,jBt,HBt)(e)}function WBt(e){var r,t=e.chart,i=e.options,n=i.data,a=n===void 0?[]:n,o=i.yField;return t.data(a),t.scale((r={},r[o]={sync:!0},r)),e}function XBt(e){var r=e.chart,t=e.options,i=t.seriesField,n=t.isTransposed;return r.facet("rect",{fields:[i],padding:[n?0:32,10,0,10],eachView:function(a,o){B6(J({},e,{chart:a,options:{data:o.data}}))}}),e}function UBt(e){return It(WBt,XBt)(e)}function qBt(e){var r=e.chart,t=e.options,i=t.data,n=i===void 0?[]:i,a=t.yField,o=Kr(n,function(u,c){return u+(c[a]||0)},0),l=Qx(n,a)[a],s=je(n,function(u,c){var f=[],h=[];if(u[tM]=(u[a]||0)/o,c){var v=n[c-1][fp],d=n[c-1][hp];f[0]=v[3],h[0]=d[3],f[1]=v[2],h[1]=d[2]}else f[0]=-.5,h[0]=1,f[1]=.5,h[1]=1;return h[2]=h[1]-u[tM],f[2]=(h[2]+1)/4,h[3]=h[2],f[3]=-f[2],u[fp]=f,u[hp]=h,u[Ms]=(u[a]||0)/l,u[nl]=[I(n,[c-1,a]),u[a]],u});return r.data(s),e}function ZBt(e){var r=e.chart,t=e.options,i=t.xField,n=t.yField,a=t.color,o=t.tooltip,l=t.label,s=t.funnelStyle,u=t.state,c=ra(o,[i,n]),f=c.fields,h=c.formatter;return Ki({chart:r,options:{type:"polygon",xField:fp,yField:hp,colorField:i,tooltipFields:it(f)&&f.concat([Ms,nl]),label:l,state:u,mapping:{tooltip:h,color:a,style:s}}}),e}function QBt(e){var r=e.chart,t=e.options,i=t.isTransposed;return r.coordinate({type:"rect",actions:i?[["transpose"],["reflect","x"]]:[]}),e}function KBt(e){var r=function(t,i,n,a){return A(A({},a),{start:[t[fp][1],t[hp][1]],end:[t[fp][1]+.05,t[hp][1]]})};return QP(r)(e),e}function JBt(e){return It(qBt,ZBt,QBt,KBt)(e)}function tNt(e){var r=e.options,t=r.compareField,i=r.xField,n=r.yField,a=r.locale,o=r.funnelStyle,l=r.data,s=wb(a),u={label:t?{fields:[i,n,t,Ms,nl],formatter:function(f){return""+f[n]}}:{fields:[i,n,Ms,nl],offset:0,position:"middle",formatter:function(f){return f[i]+" "+f[n]}},tooltip:{title:i,formatter:function(f){return{name:f[i],value:f[n]}}},conversionTag:{formatter:function(f){return s.get(["conversionTag","label"])+": "+YX.apply(void 0,f[nl])}}},c;return(t||o)&&(c=function(f){return J({},t&&{lineWidth:1,stroke:"#fff"},pt(o)?o(f):o)}),J({options:u},e,{options:{funnelStyle:c,data:di(l)}})}function eNt(e){var r=e.options,t=r.compareField,i=r.dynamicHeight,n=r.seriesField;return n?UBt(e):t?YBt(e):i?JBt(e):B6(e)}function rNt(e){var r,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.yField;return It(We((r={},r[a]=i,r[o]=n,r)))(e)}function iNt(e){var r=e.chart;return r.axis(!1),e}function nNt(e){var r=e.chart,t=e.options,i=t.legend;return i===!1?r.legend(!1):r.legend(i),e}function N6(e){return It(tNt,eNt,rNt,iNt,Dr,Ae,nNt,ce,ie,Xe())(e)}var aNt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="funnel",t}return r.getDefaultOptions=function(){return RBt},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return N6},r.prototype.setState=function(t,i,n){n===void 0&&(n=!0);var a=lp(this.chart);P(a,function(o){i(o.getData())&&o.setState(t,n)})},r.prototype.getStates=function(){var t=lp(this.chart),i=[];return P(t,function(n){var a=n.getData(),o=n.getStates();P(o,function(l){i.push({data:a,state:l,geometry:n.geometry,element:n})})}),i},r.CONVERSATION_FIELD=nl,r.PERCENT_FIELD=Ms,r.TOTAL_PERCENT_FIELD=tM,r}(Dt),oNt="liquid";function G6(e){return[{percent:e,type:oNt}]}function lNt(e){var r=e.chart,t=e.options,i=t.percent,n=t.liquidStyle,a=t.radius,o=t.outline,l=t.wave,s=t.shape;r.scale({percent:{min:0,max:1}}),r.data(G6(i));var u=t.color||r.getTheme().defaultColor,c=J({},e,{options:{xField:"type",yField:"percent",widthRatio:a,interval:{color:u,style:n,shape:"liquid-fill-gauge"}}}),f=ri(c).ext,h=f.geometry,v=r.getTheme().background,d={radius:a,outline:o,wave:l,shape:s,background:v};return h.customInfo(d),r.legend(!1),r.axis(!1),r.tooltip(!1),e}function z6(e,r){var t=e.chart,i=e.options,n=i.statistic,a=i.percent,o=i.meta;t.getController("annotation").clear(!0);var l=I(o,["percent","formatter"])||function(u){return(u*100).toFixed(2)+"%"},s=n.content;return s&&(s=J({},s,{content:K(s.content)?l(a):s.content})),_b(t,{statistic:A(A({},n),{content:s}),plotType:"liquid"},{percent:a}),r&&t.render(!0),e}function sNt(e){return It(ie,Sn("liquidStyle"),lNt,z6,We({}),ce,Ae)(e)}var uNt={radius:.9,statistic:{title:!1,content:{style:{opacity:.75,fontSize:"30px",lineHeight:"30px",textAlign:"center"}}},outline:{border:2,distance:0},wave:{count:3,length:192},shape:"circle"},dG=5e3;function pG(e,r,t){return e+(r-e)*t}function cNt(e){var r=A({opacity:1},e.style);return e.color&&!r.fill&&(r.fill=e.color),r}function fNt(e){var r={fill:"#fff",fillOpacity:0,lineWidth:4},t=Kt({},r,e.style);return e.color&&!t.stroke&&(t.stroke=e.color),Mt(e.opacity)&&(t.opacity=t.strokeOpacity=e.opacity),t}function hNt(e,r,t,i){return r===0?[[e+1/2*t/Math.PI/2,i/2],[e+1/2*t/Math.PI,i],[e+t/4,i]]:r===1?[[e+1/2*t/Math.PI/2*(Math.PI-2),i],[e+1/2*t/Math.PI/2*(Math.PI-1),i/2],[e+t/4,0]]:r===2?[[e+1/2*t/Math.PI/2,-i/2],[e+1/2*t/Math.PI,-i],[e+t/4,-i]]:[[e+1/2*t/Math.PI/2*(Math.PI-2),-i],[e+1/2*t/Math.PI/2*(Math.PI-1),-i/2],[e+t/4,0]]}function vNt(e,r,t,i,n,a,o){for(var l=Math.ceil(2*e/t*4)*4,s=[],u=i;u<-Math.PI*2;)u+=Math.PI*2;for(;u>0;)u-=Math.PI*2;u=u/Math.PI/2*t;var c=a-e+u-e*2;s.push(["M",c,r]);for(var f=0,h=0;h<l;++h){var v=h%4,d=hNt(h*t/4,v,t,n);s.push(["C",d[0][0]+c,-d[0][1]+r,d[1][0]+c,-d[1][1]+r,d[2][0]+c,-d[2][1]+r]),h===l-1&&(f=d[2][0])}return s.push(["L",f+c,o+e]),s.push(["L",c,o+e]),s.push(["Z"]),s}function dNt(e,r,t,i,n,a,o,l,s){for(var u=n.fill,c=n.opacity,f=o.getBBox(),h=f.maxX-f.minX,v=f.maxY-f.minY,d=0;d<i;d++){var p=i<=1?0:d/(i-1),x=a.addShape("path",{name:"waterwave-path",attrs:{path:vNt(l,f.minY+v*t,s,0,h/32,e,r),fill:u,opacity:pG(.2,.9,p)*c}});try{var m=WT([["t",s,0]]);x.stopAnimate(),x.animate({matrix:m},{duration:pG(.5*dG,dG,p),repeat:!0})}catch{console.warn("off-screen group animate error!")}}}function pNt(e,r,t,i){var n=t*2/3,a=Math.max(n,i),o=n/2,l=e,s=o+r-a/2,u=Math.asin(o/((a-o)*.85)),c=Math.sin(u)*o,f=Math.cos(u)*o,h=l-f,v=s+c,d=e,p=s+o/Math.sin(u);return`
|
|
M `+h+" "+v+`
|
|
A `+o+" "+o+" 0 1 1 "+(h+f*2)+" "+v+`
|
|
Q `+d+" "+p+" "+e+" "+(r+a/2)+`
|
|
Q `+d+" "+p+" "+h+" "+v+`
|
|
Z
|
|
`}function gNt(e,r,t,i){var n=t/2,a=i/2;return`
|
|
M `+e+" "+(r-a)+`
|
|
a `+n+" "+a+" 0 1 0 0 "+a*2+`
|
|
a `+n+" "+a+" 0 1 0 0 "+-a*2+`
|
|
Z
|
|
`}function yNt(e,r,t,i){var n=i/2,a=t/2;return`
|
|
M `+e+" "+(r-n)+`
|
|
L `+(e+a)+" "+r+`
|
|
L `+e+" "+(r+n)+`
|
|
L `+(e-a)+" "+r+`
|
|
Z
|
|
`}function mNt(e,r,t,i){var n=i/2,a=t/2;return`
|
|
M `+e+" "+(r-n)+`
|
|
L `+(e+a)+" "+(r+n)+`
|
|
L `+(e-a)+" "+(r+n)+`
|
|
Z
|
|
`}function xNt(e,r,t,i){var n=.618,a=i/2,o=t/2*n;return`
|
|
M `+(e-o)+" "+(r-a)+`
|
|
L `+(e+o)+" "+(r-a)+`
|
|
L `+(e+o)+" "+(r+a)+`
|
|
L `+(e-o)+" "+(r+a)+`
|
|
Z
|
|
`}te("interval","liquid-fill-gauge",{draw:function(e,r){var t=.5,i=.5,n=e.customInfo,a=n,o=a.radius,l=a.shape,s=a.background,u=n.outline,c=n.wave,f=u.border,h=u.distance,v=c.count,d=c.length,p=Kr(e.points,function(H,B){return Math.min(H,B.x)},1/0),x=this.parsePoint({x:t,y:i}),m=this.parsePoint({x:p,y:i}),_=x.x-m.x,b=Math.min(_,m.y*o),w=cNt(e),S=fNt(Kt({},e,u)),M=b-f/2,F={pin:pNt,circle:gNt,diamond:yNt,triangle:mNt,rect:xNt},O=typeof l=="function"?l:F[l]||F.circle,L=O(x.x,x.y,M*2,M*2),D=r.addGroup({name:"waves"}),k=D.setClip({type:"path",attrs:{path:L}});return dNt(x.x,x.y,1-e.points[1].y,v,w,D,k,b*2,d),r.addShape("path",{name:"distance",attrs:{path:L,fill:"transparent",lineWidth:f+h*2,stroke:s==="transparent"?"#fff":s}}),r.addShape("path",{name:"wrap",attrs:Kt(S,{path:L,fill:"transparent",lineWidth:f})}),r}});(function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="liquid",t}return r.getDefaultOptions=function(){return uNt},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.changeData=function(t){this.chart.emit(Gt.BEFORE_CHANGE_DATA,$e.fromData(this.chart,Gt.BEFORE_CHANGE_DATA,null)),this.updateOption({percent:t}),this.chart.data(G6(t)),z6({chart:this.chart,options:this.options},!0),this.chart.emit(Gt.AFTER_CHANGE_DATA,$e.fromData(this.chart,Gt.AFTER_CHANGE_DATA,null))},r.prototype.getSchemaAdaptor=function(){return sNt},r})(Dt);function V6(e){var r=e.data,t=e.xField,i=e.measureField,n=e.rangeField,a=e.targetField,o=e.layout,l=[],s=[];r.forEach(function(f,h){var v;f[n].sort(function(d,p){return d-p}),f[n].forEach(function(d,p){var x,m=p===0?d:f[n][p]-f[n][p-1];l.push((x={rKey:n+"_"+p},x[t]=t?f[t]:String(h),x[n]=m,x))}),f[i].forEach(function(d,p){var x;l.push((x={mKey:f[i].length>1?i+"_"+p:""+i},x[t]=t?f[t]:String(h),x[i]=d,x))}),l.push((v={tKey:""+a},v[t]=t?f[t]:String(h),v[a]=f[a],v)),s.push(f[n],f[i],f[a])});var u=Math.min.apply(Math,s.flat(1/0)),c=Math.max.apply(Math,s.flat(1/0));return u=u>0?0:u,o==="vertical"&&l.reverse(),{min:u,max:c,ds:l}}function _Nt(e){var r=e.chart,t=e.options,i=t.bulletStyle,n=t.targetField,a=t.rangeField,o=t.measureField,l=t.xField,s=t.color,u=t.layout,c=t.size,f=t.label,h=V6(t),v=h.min,d=h.max,p=h.ds;r.data(p);var x=J({},e,{options:{xField:l,yField:a,seriesField:"rKey",isStack:!0,label:I(f,"range"),interval:{color:I(s,"range"),style:I(i,"range"),size:I(c,"range")}}});ri(x),r.geometries[0].tooltip(!1);var m=J({},e,{options:{xField:l,yField:o,seriesField:"mKey",isStack:!0,label:I(f,"measure"),interval:{color:I(s,"measure"),style:I(i,"measure"),size:I(c,"measure")}}});ri(m);var _=J({},e,{options:{xField:l,yField:n,seriesField:"tKey",label:I(f,"target"),point:{color:I(s,"target"),style:I(i,"target"),size:pt(I(c,"target"))?function(b){return I(c,"target")(b)/2}:I(c,"target")/2,shape:u==="horizontal"?"line":"hyphen"}}});return An(_),u==="horizontal"&&r.coordinate().transpose(),A(A({},e),{ext:{data:{min:v,max:d}}})}function j6(e){var r,t,i=e.options,n=e.ext,a=i.xAxis,o=i.yAxis,l=i.targetField,s=i.rangeField,u=i.measureField,c=i.xField,f=n.data;return It(We((r={},r[c]=a,r[u]=o,r),(t={},t[u]={min:f==null?void 0:f.min,max:f==null?void 0:f.max,sync:!0},t[l]={sync:""+u},t[s]={sync:""+u},t)))(e)}function bNt(e){var r=e.chart,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.measureField,l=t.rangeField,s=t.targetField;return r.axis(""+l,!1),r.axis(""+s,!1),i===!1?r.axis(""+a,!1):r.axis(""+a,i),n===!1?r.axis(""+o,!1):r.axis(""+o,n),e}function wNt(e){var r=e.chart,t=e.options,i=t.legend;return r.removeInteraction("legend-filter"),r.legend(i),r.legend("rKey",!1),r.legend("mKey",!1),r.legend("tKey",!1),e}function CNt(e){var r=e.chart,t=e.options,i=t.label,n=t.measureField,a=t.targetField,o=t.rangeField,l=r.geometries,s=l[0],u=l[1],c=l[2];return I(i,"range")?s.label(""+o,A({layout:[{type:"limit-in-plot"}]},Pr(i.range))):s.label(!1),I(i,"measure")?u.label(""+n,A({layout:[{type:"limit-in-plot"}]},Pr(i.measure))):u.label(!1),I(i,"target")?c.label(""+a,A({layout:[{type:"limit-in-plot"}]},Pr(i.target))):c.label(!1),e}function SNt(e){It(_Nt,j6,bNt,wNt,ie,CNt,Dr,Ae,ce)(e)}var ANt=J({},Dt.getDefaultOptions(),{layout:"horizontal",size:{range:30,measure:20,target:20},xAxis:{tickLine:!1,line:null},bulletStyle:{range:{fillOpacity:.5}},label:{measure:{position:"right"}},tooltip:{showMarkers:!1}});(function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="bullet",t}return r.getDefaultOptions=function(){return ANt},r.prototype.changeData=function(t){this.updateOption({data:t});var i=V6(this.options),n=i.min,a=i.max,o=i.ds;j6({options:this.options,ext:{data:{min:n,max:a}},chart:this.chart}),this.chart.changeData(o)},r.prototype.getSchemaAdaptor=function(){return SNt},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r})(Dt);var H6="nodeIndex",Y6="childNodeCount",KP="nodeAncestor",rA="Invalid field: it must be a string!";function JP(e,r){var t=e.field,i=e.fields;if(Ct(t))return t;if(it(t))return console.warn(rA),t[0];if(console.warn(rA+" will try to get fields instead."),Ct(i))return i;if(it(i)&&i.length)return i[0];if(r)return r;throw new TypeError(rA)}function tI(e){var r=[];if(e&&e.each){var t,i;e.each(function(n){var a,o;n.parent!==t?(t=n.parent,i=0):i+=1;var l=jr((((a=n.ancestors)===null||a===void 0?void 0:a.call(n))||[]).map(function(s){return r.find(function(u){return u.name===s.name})||s}),function(s){var u=s.depth;return u>0&&u<n.depth});n[KP]=l,n[Y6]=((o=n.children)===null||o===void 0?void 0:o.length)||0,n[H6]=i,r.push(n)})}else e&&e.eachNode&&e.eachNode(function(n){r.push(n)});return r}var eI="ancestor-node",W6="value",vp="path",TNt=[vp,H6,KP,Y6,"name","depth","height"],MNt=J({},Dt.getDefaultOptions(),{innerRadius:0,radius:.85,hierarchyConfig:{field:"value"},tooltip:{shared:!0,showMarkers:!1,offset:20,showTitle:!1},sunburstStyle:{lineWidth:.5,stroke:"#FFF"},drilldown:{enabled:!0}}),gG=4,ENt=0,yG=5,mG="drilldown-bread-crumb",FNt={position:"top-left",dividerText:"/",textStyle:{fontSize:12,fill:"rgba(0, 0, 0, 0.65)",cursor:"pointer"},activeTextStyle:{fill:"#87B5FF"}},dp="hierarchy-data-transform-params",ONt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.name="drill-down",t.historyCache=[],t.breadCrumbGroup=null,t.breadCrumbCfg=FNt,t}return r.prototype.click=function(){var t=I(this.context,["event","data","data"]);if(!t)return!1;this.drill(t),this.drawBreadCrumb()},r.prototype.resetPosition=function(){if(!!this.breadCrumbGroup){var t=this.context.view.getCoordinate(),i=this.breadCrumbGroup,n=i.getBBox(),a=this.getButtonCfg().position,o={x:t.start.x,y:t.end.y-(n.height+yG*2)};t.isPolar&&(o={x:0,y:0}),a==="bottom-left"&&(o={x:t.start.x,y:t.start.y});var l=Fi.transform(null,[["t",o.x+ENt,o.y+n.height+yG]]);i.setMatrix(l)}},r.prototype.back=function(){yr(this.historyCache)&&this.backTo(this.historyCache.slice(0,-1))},r.prototype.reset=function(){this.historyCache[0]&&this.backTo(this.historyCache.slice(0,1)),this.historyCache=[],this.hideCrumbGroup()},r.prototype.drill=function(t){var i=this.context.view,n=I(i,["interactions","drill-down","cfg","transformData"],function(u){return u}),a=n(A({data:t.data},t[dp]));i.changeData(a);for(var o=[],l=t;l;){var s=l.data;o.unshift({id:s.name+"_"+l.height+"_"+l.depth,name:s.name,children:n(A({data:s},t[dp]))}),l=l.parent}this.historyCache=(this.historyCache||[]).slice(0,-1).concat(o)},r.prototype.backTo=function(t){if(!(!t||t.length<=0)){var i=this.context.view,n=nr(t).children;i.changeData(n),t.length>1?(this.historyCache=t,this.drawBreadCrumb()):(this.historyCache=[],this.hideCrumbGroup())}},r.prototype.getButtonCfg=function(){var t=this.context.view,i=I(t,["interactions","drill-down","cfg","drillDownConfig"]);return J(this.breadCrumbCfg,i==null?void 0:i.breadCrumb,this.cfg)},r.prototype.drawBreadCrumb=function(){this.drawBreadCrumbGroup(),this.resetPosition(),this.breadCrumbGroup.show()},r.prototype.drawBreadCrumbGroup=function(){var t=this,i=this.getButtonCfg(),n=this.historyCache;this.breadCrumbGroup?this.breadCrumbGroup.clear():this.breadCrumbGroup=this.context.view.foregroundGroup.addGroup({name:mG});var a=0;n.forEach(function(o,l){var s=t.breadCrumbGroup.addShape({type:"text",id:o.id,name:mG+"_"+o.name+"_text",attrs:A(A({text:l===0&&!K(i.rootText)?i.rootText:o.name},i.textStyle),{x:a,y:0})}),u=s.getBBox();if(a+=u.width+gG,s.on("click",function(h){var v,d=h.target.get("id");if(d!==((v=nr(n))===null||v===void 0?void 0:v.id)){var p=n.slice(0,n.findIndex(function(x){return x.id===d})+1);t.backTo(p)}}),s.on("mouseenter",function(h){var v,d=h.target.get("id");d!==((v=nr(n))===null||v===void 0?void 0:v.id)?s.attr(i.activeTextStyle):s.attr({cursor:"default"})}),s.on("mouseleave",function(){s.attr(i.textStyle)}),l<n.length-1){var c=t.breadCrumbGroup.addShape({type:"text",name:i.name+"_"+o.name+"_divider",attrs:A(A({text:i.dividerText},i.textStyle),{x:a,y:0})}),f=c.getBBox();a+=f.width+gG}})},r.prototype.hideCrumbGroup=function(){this.breadCrumbGroup&&this.breadCrumbGroup.hide()},r.prototype.destroy=function(){this.breadCrumbGroup&&this.breadCrumbGroup.remove(),e.prototype.destroy.call(this)},r}(Ie),PNt={field:"value",size:[1,1],round:!1,padding:0,sort:function(e,r){return r.value-e.value},as:["x","y"],ignoreParentValue:!0};function INt(e,r){r=Kt({},PNt,r);var t=r.as;if(!it(t)||t.length!==2)throw new TypeError('Invalid as: it must be an array with 2 strings (e.g. [ "x", "y" ])!');var i;try{i=JP(r)}catch(s){console.warn(s)}var n=function(s){return T4().size(r.size).round(r.round).padding(r.padding)(Nh(s).sum(function(u){return yr(u.children)?r.ignoreParentValue?0:u[i]-Kr(u.children,function(c,f){return c+f[i]},0):u[i]}).sort(r.sort))},a=n(e),o=t[0],l=t[1];return a.each(function(s){var u,c;s[o]=[s.x0,s.x1,s.x1,s.x0],s[l]=[s.y1,s.y1,s.y0,s.y0],s.name=s.name||((u=s.data)===null||u===void 0?void 0:u.name)||((c=s.data)===null||c===void 0?void 0:c.label),s.data.name=s.name,["x0","x1","y0","y1"].forEach(function(f){t.indexOf(f)===-1&&delete s[f]})}),tI(a)}var LNt={field:"value",tile:"treemapSquarify",size:[1,1],round:!1,ignoreParentValue:!0,padding:0,paddingInner:0,paddingOuter:0,paddingTop:0,paddingRight:0,paddingBottom:0,paddingLeft:0,as:["x","y"],sort:function(e,r){return r.value-e.value},ratio:.5*(1+Math.sqrt(5))};function DNt(e,r){return e==="treemapSquarify"?BT[e].ratio(r):BT[e]}function X6(e,r){r=Kt({},LNt,r);var t=r.as;if(!it(t)||t.length!==2)throw new TypeError('Invalid as: it must be an array with 2 strings (e.g. [ "x", "y" ])!');var i;try{i=JP(r)}catch(u){console.warn(u)}var n=DNt(r.tile,r.ratio),a=function(u){return O4().tile(n).size(r.size).round(r.round).padding(r.padding).paddingInner(r.paddingInner).paddingOuter(r.paddingOuter).paddingTop(r.paddingTop).paddingRight(r.paddingRight).paddingBottom(r.paddingBottom).paddingLeft(r.paddingLeft)(Nh(u).sum(function(c){return r.ignoreParentValue&&c.children?0:c[i]}).sort(r.sort))},o=a(e),l=t[0],s=t[1];return o.each(function(u){u[l]=[u.x0,u.x1,u.x1,u.x0],u[s]=[u.y1,u.y1,u.y0,u.y0],["x0","x1","y0","y1"].forEach(function(c){t.indexOf(c)===-1&&delete u[c]})}),tI(o)}function U6(e){var r=e.data,t=e.colorField,i=e.rawFields,n=e.hierarchyConfig,a=n===void 0?{}:n,o=a.activeDepth,l={partition:INt,treemap:X6},s=e.seriesField,u=e.type||"partition",c=l[u](r,A(A({field:s||"value"},i1(a,["activeDepth"])),{type:"hierarchy."+u,as:["x","y"]})),f=[];return c.forEach(function(h){var v,d,p,x,m,_;if(h.depth===0||o>0&&h.depth>o)return null;for(var b=h.data.name,w=A({},h);w.depth>1;)b=((d=w.parent.data)===null||d===void 0?void 0:d.name)+" / "+b,w=w.parent;var S=A(A(A({},se(h.data,ye(i||[],[a.field]))),(v={},v[vp]=b,v[eI]=w.data.name,v)),h);s&&(S[s]=h.data[s]||((x=(p=h.parent)===null||p===void 0?void 0:p.data)===null||x===void 0?void 0:x[s])),t&&(S[t]=h.data[t]||((_=(m=h.parent)===null||m===void 0?void 0:m.data)===null||_===void 0?void 0:_[t])),S.ext=a,S[dp]={hierarchyConfig:a,colorField:t,rawFields:i},f.push(S)}),f}function $Nt(e){var r=e.chart,t=e.options,i=t.color,n=t.colorField,a=n===void 0?eI:n,o=t.sunburstStyle,l=t.rawFields,s=l===void 0?[]:l,u=U6(t);r.data(u);var c;return o&&(c=function(f){return J({},{fillOpacity:Math.pow(.85,f.depth)},pt(o)?o(f):o)}),Tb(J({},e,{options:{xField:"x",yField:"y",seriesField:a,rawFields:us(ye(TNt,s)),polygon:{color:i,style:c}}})),e}function kNt(e){var r=e.chart;return r.axis(!1),e}function RNt(e){var r=e.chart;return r.legend(!1),e}function BNt(e){var r=e.chart,t=e.options,i=t.label,n=ei(r,"polygon");if(!i)n.label(!1);else{var a=i.fields,o=a===void 0?["name"]:a,l=i.callback,s=ue(i,["fields","callback"]);n.label({fields:o,callback:l,cfg:Pr(s)})}return e}function NNt(e){var r=e.chart,t=e.options,i=t.innerRadius,n=t.radius,a=t.reflect,o=r.coordinate({type:"polar",cfg:{innerRadius:i,radius:n}});return a&&o.reflect(a),e}function GNt(e){var r,t=e.options,i=t.hierarchyConfig,n=t.meta;return It(We({},(r={},r[W6]=I(n,I(i,["field"],"value")),r)))(e)}function zNt(e){var r=e.chart,t=e.options,i=t.tooltip;if(i===!1)r.tooltip(!1);else{var n=i;I(i,"fields")||(n=J({},{customItems:function(a){return a.map(function(o){var l=I(r.getOptions(),"scales"),s=I(l,[vp,"formatter"],function(c){return c}),u=I(l,[W6,"formatter"],function(c){return c});return A(A({},o),{name:s(o.data[vp]),value:u(o.data.value)})})}},n)),r.tooltip(n)}return e}function VNt(e){var r=e.drilldown,t=e.interactions,i=t===void 0?[]:t;return r!=null&&r.enabled?J({},e,{interactions:ye(i,[{type:"drill-down",cfg:{drillDownConfig:r,transformData:U6}}])}):e}function jNt(e){var r=e.chart,t=e.options,i=t.drilldown;return Ae({chart:r,options:VNt(t)}),i!=null&&i.enabled&&(r.appendPadding=bb(r.appendPadding,I(i,["breadCrumb","position"]))),e}function HNt(e){return It(ie,Sn("sunburstStyle"),$Nt,kNt,GNt,RNt,NNt,zNt,BNt,jNt,ce,Xe())(e)}function xG(e){var r=I(e,["event","data","data"],{});return it(r.children)&&r.children.length>0}function _G(e){var r=e.view.getCoordinate(),t=r.innerRadius;if(t){var i=e.event,n=i.x,a=i.y,o=r.center,l=o.x,s=o.y,u=r.getRadius()*t,c=Math.sqrt(Math.pow(l-n,2)+Math.pow(s-a,2));return c<u}return!1}Et("drill-down-action",ONt);Lt("drill-down",{showEnable:[{trigger:"element:mouseenter",action:"cursor:pointer",isEnable:xG},{trigger:"element:mouseleave",action:"cursor:default"},{trigger:"element:mouseleave",action:"cursor:pointer",isEnable:_G}],start:[{trigger:"element:click",isEnable:xG,action:["drill-down-action:click"]},{trigger:"afterchangesize",action:["drill-down-action:resetPosition"]},{trigger:"click",isEnable:_G,action:["drill-down-action:back"]}]});(function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="sunburst",t}return r.getDefaultOptions=function(){return MNt},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return HNt},r.SUNBURST_ANCESTOR_FIELD=eI,r.SUNBURST_PATH_FIELD=vp,r.NODE_ANCESTORS_FIELD=KP,r})(Dt);var v0,Hx="range",q6="type",Ql="percent",YNt="#f0f0f0",Z6="indicator-view",Q6="range-view",WNt={percent:0,range:{ticks:[]},innerRadius:.9,radius:.95,startAngle:-7/6*Math.PI,endAngle:1/6*Math.PI,syncViewPadding:!0,axis:{line:null,label:{offset:-24,style:{textAlign:"center",textBaseline:"middle"}},subTickLine:{length:-8},tickLine:{length:-12},grid:null},indicator:{pointer:{style:{lineWidth:5,lineCap:"round"}},pin:{style:{r:9.75,lineWidth:4.5,fill:"#fff"}}},statistic:{title:!1},meta:(v0={},v0[Hx]={sync:"v"},v0[Ql]={sync:"v",tickCount:5,tickInterval:.2},v0),animation:!1};function XNt(e,r){return e.map(function(t,i){var n;return n={},n[Hx]=t-(e[i-1]||0),n[q6]=""+i,n[Ql]=r,n}).filter(function(t){return!!t[Hx]})}function K6(e){var r;return[(r={},r[Ql]=Ce(e,0,1),r)]}function J6(e,r){var t=I(r,["ticks"],[]),i=yr(t)?t:[0,Ce(e,0,1),1];return XNt(i,e)}function UNt(e){var r=e.chart,t=e.options,i=t.percent,n=t.range,a=t.radius,o=t.innerRadius,l=t.startAngle,s=t.endAngle,u=t.axis,c=t.indicator,f=t.gaugeStyle,h=t.type,v=t.meter,d=n.color,p=n.width;if(c){var x=K6(i),m=r.createView({id:Z6});m.data(x),m.point().position(Ql+"*1").shape(c.shape||"gauge-indicator").customInfo({defaultColor:r.getTheme().defaultColor,indicator:c}),m.coordinate("polar",{startAngle:l,endAngle:s,radius:o*a}),m.axis(Ql,u),m.scale(Ql,se(u,ji))}var _=J6(i,t.range),b=r.createView({id:Q6});b.data(_);var w=Ct(d)?[d,YNt]:d,S=ri({chart:b,options:{xField:"1",yField:Hx,seriesField:q6,rawFields:[Ql],isStack:!0,interval:{color:w,style:f,shape:h==="meter"?"meter-gauge":null},args:{zIndexReversed:!0},minColumnWidth:p,maxColumnWidth:p}}).ext,M=S.geometry;return M.customInfo({meter:v}),b.coordinate("polar",{innerRadius:o,radius:a,startAngle:l,endAngle:s}).transpose(),e}function qNt(e){var r;return It(We((r={range:{min:0,max:1,maxLimit:1,minLimit:0}},r[Ql]={},r)))(e)}function tU(e,r){var t=e.chart,i=e.options,n=i.statistic,a=i.percent;if(t.getController("annotation").clear(!0),n){var o=n.content,l=void 0;o&&(l=J({},{content:(a*100).toFixed(2)+"%",style:{opacity:.75,fontSize:"30px",lineHeight:1,textAlign:"center",color:"rgba(44,53,66,0.85)"}},o)),JLt(t,{statistic:A(A({},n),{content:l})},{percent:a})}return r&&t.render(!0),e}function ZNt(e){var r=e.chart;return r.legend(!1),r.tooltip(!1),e}function eU(e){return It(ie,ce,UNt,qNt,tU,Ae,Xe(),ZNt)(e)}te("point","gauge-indicator",{draw:function(e,r){var t=e.customInfo,i=t.indicator,n=t.defaultColor,a=i,o=a.pointer,l=a.pin,s=r.addGroup(),u=this.parsePoint({x:0,y:0});return o&&s.addShape("line",{name:"pointer",attrs:A({x1:u.x,y1:u.y,x2:e.x,y2:e.y,stroke:n},o.style)}),l&&s.addShape("circle",{name:"pin",attrs:A({x:u.x,y:u.y,stroke:n},l.style)}),s}});te("interval","meter-gauge",{draw:function(e,r){var t=e.customInfo.meter,i=t===void 0?{}:t,n=i.steps,a=n===void 0?50:n,o=i.stepRatio,l=o===void 0?.5:o;a=a<1?1:a,l=Ce(l,0,1);var s=this.coordinate,u=s.startAngle,c=s.endAngle,f=0;if(l>0&&l<1){var h=c-u;f=h/a/(l/(1-l)+1-1/a)}for(var v=f/(1-l)*l,d=r.addGroup(),p=this.coordinate.getCenter(),x=this.coordinate.getRadius(),m=Fi.getAngle(e,this.coordinate),_=m.startAngle,b=m.endAngle,w=_;w<b;){var S=void 0,M=(w-u)%(v+f);M<v?S=w+(v-M):(w+=v+f-M,S=w+v);var F=Fi.getSectorPath(p.x,p.y,x,w,Math.min(S,b),x*this.coordinate.innerRadius);d.addShape("path",{name:"meter-gauge",attrs:{path:F,fill:e.color,stroke:e.color,lineWidth:.5}}),w=S+f}return d}});var QNt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="gauge",t}return r.getDefaultOptions=function(){return WNt},r.prototype.changeData=function(t){this.chart.emit(Gt.BEFORE_CHANGE_DATA,$e.fromData(this.chart,Gt.BEFORE_CHANGE_DATA,null)),this.updateOption({percent:t});var i=this.chart.views.find(function(a){return a.id===Z6});i&&i.data(K6(t));var n=this.chart.views.find(function(a){return a.id===Q6});n&&n.data(J6(t,this.options.range)),tU({chart:this.chart,options:this.options},!0),this.chart.emit(Gt.AFTER_CHANGE_DATA,$e.fromData(this.chart,Gt.AFTER_CHANGE_DATA,null))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return eU},r}(Dt),Hn="$$yField$$",Pb="$$diffField$$",rI="$$absoluteField$$",eM="$$isTotal$$",KNt={label:{},leaderLine:{style:{lineWidth:1,stroke:"#8c8c8c",lineDash:[4,2]}},total:{style:{fill:"rgba(0, 0, 0, 0.25)"}},interactions:[{type:"element-active"}],risingFill:"#f4664a",fallingFill:"#30bf78",waterfallStyle:{fill:"rgba(0, 0, 0, 0.25)"},yAxis:{grid:{line:{style:{lineDash:[4,2]}}}}};function JNt(e,r,t,i,n){var a,o=[];if(Kr(e,function(s,u){var c;ul(Fa.WARN,Mt(u[t]),u[t]+" is not a valid number");var f=Yl(u[t])?null:u[t];return o.push(A(A({},u),(c={},c[i]=[s,s+f],c))),s+f},0),o.length&&n){var l=I(o,[[e.length-1],i,[1]]);o.push((a={},a[r]=n.label,a[t]=l,a[i]=[0,l],a))}return o}function rU(e,r,t,i){var n=JNt(e,r,t,Hn,i);return n.map(function(a,o){var l;return Zt(a)?A(A({},a),(l={},l[rI]=a[Hn][1],l[Pb]=a[Hn][1]-a[Hn][0],l[eM]=o===e.length,l)):a})}function tGt(e){for(var r=[],t=0;t<e.length;t++){var i=e[t];if(i){var n=t===0?"M":"L";r.push([n,i.x,i.y])}}var a=e[0];return r.push(["L",a.x,a.y]),r.push(["z"]),r}function eGt(e){return J({},e.defaultStyle,e.style,{fill:e.color})}te("interval","waterfall",{draw:function(e,r){var t=e.customInfo,i=e.points,n=e.nextPoints,a=r.addGroup(),o=this.parsePath(tGt(i)),l=eGt(e);a.addShape("path",{attrs:A(A({},l),{path:o})});var s=I(t,"leaderLine");if(s&&n){var u=[["M",i[2].x,i[2].y],["L",n[0].x,n[0].y]];i[2].y===n[1].y&&(u[1]=["L",n[1].x,n[1].y]),u=this.parsePath(u),a.addShape("path",{attrs:A({path:u},s.style||{})})}return a}});function rGt(e){var r=e.options,t=r.locale,i=r.total,n=wb(t).get(["waterfall","total"]);return i&&typeof i.label!="string"&&n&&(e.options.total.label=n),e}function iGt(e){var r=e.chart,t=e.options,i=t.data,n=t.xField,a=t.yField,o=t.total,l=t.leaderLine,s=t.columnWidthRatio,u=t.waterfallStyle,c=t.risingFill,f=t.fallingFill,h=t.color;r.data(rU(i,n,a,o));var v=h||function(m){return I(m,[eM])?I(o,["style","fill"],""):I(m,[Hn,1])-I(m,[Hn,0])>0?c:f},d=J({},e,{options:{xField:n,yField:Hn,seriesField:n,rawFields:[a,Pb,eM,Hn],widthRatio:s,interval:{style:u,shape:"waterfall",color:v}}}),p=ri(d).ext,x=p.geometry;return x.customInfo({leaderLine:l}),e}function nGt(e){var r,t,i=e.options,n=i.xAxis,a=i.yAxis,o=i.xField,l=i.yField,s=i.meta,u=J({},{alias:l},I(s,l));return It(We((r={},r[o]=n,r[l]=a,r[Hn]=a,r),J({},s,(t={},t[Hn]=u,t[Pb]=u,t[rI]=u,t))))(e)}function aGt(e){var r=e.chart,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.yField;return i===!1?r.axis(a,!1):r.axis(a,i),n===!1?(r.axis(o,!1),r.axis(Hn,!1)):(r.axis(o,n),r.axis(Hn,n)),e}function oGt(e){var r=e.chart,t=e.options,i=t.legend,n=t.total,a=t.risingFill,o=t.fallingFill,l=t.locale,s=wb(l);if(i===!1)r.legend(!1);else{var u=[{name:s.get(["general","increase"]),value:"increase",marker:{symbol:"square",style:{r:5,fill:a}}},{name:s.get(["general","decrease"]),value:"decrease",marker:{symbol:"square",style:{r:5,fill:o}}}];n&&u.push({name:n.label||"",value:"total",marker:{symbol:"square",style:J({},{r:5},I(n,"style"))}}),r.legend(J({},{custom:!0,position:"top",items:u},i)),r.removeInteraction("legend-filter")}return e}function lGt(e){var r=e.chart,t=e.options,i=t.label,n=t.labelMode,a=t.xField,o=ei(r,"interval");if(!i)o.label(!1);else{var l=i.callback,s=ue(i,["callback"]);o.label({fields:n==="absolute"?[rI,a]:[Pb,a],callback:l,cfg:Pr(s)})}return e}function sGt(e){var r=e.chart,t=e.options,i=t.tooltip,n=t.xField,a=t.yField;if(i!==!1){r.tooltip(A({showCrosshairs:!1,showMarkers:!1,shared:!0,fields:[a]},i));var o=r.geometries[0];i!=null&&i.formatter?o.tooltip(n+"*"+a,i.formatter):o.tooltip(a)}else r.tooltip(!1);return e}function uGt(e){return It(rGt,ie,iGt,nGt,aGt,oGt,sGt,lGt,Rs,Ae,ce,Xe())(e)}(function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="waterfall",t}return r.getDefaultOptions=function(){return KNt},r.prototype.changeData=function(t){var i=this.options,n=i.xField,a=i.yField,o=i.total;this.updateOption({data:t}),this.chart.changeData(rU(t,n,a,o))},r.prototype.getSchemaAdaptor=function(){return uGt},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r})(Dt);function cGt(e,r,t){var i=t.map(function(o){return o[r]}).filter(function(o){return o!==void 0}),n=i.length>0?Math.max.apply(Math,i):0,a=Math.abs(e)%360;return a?n*360/a:n}function fGt(e,r,t){var i=[];return e.forEach(function(n){var a=i.find(function(o){return o[r]===n[r]});a?a[t]+=n[t]||null:i.push(A({},n))}),i}function hGt(e){var r=e.chart,t=e.options,i=t.barStyle,n=t.color,a=t.tooltip,o=t.colorField,l=t.type,s=t.xField,u=t.yField,c=t.data,f=ph(c,u);r.data(f);var h=J({},e,{options:{tooltip:a,seriesField:o,interval:{style:i,color:n,shape:l==="line"?"line":"intervel"},minColumnWidth:t.minBarWidth,maxColumnWidth:t.maxBarWidth,columnBackground:t.barBackground}});return ri(h),l==="line"&&An({chart:r,options:{xField:s,yField:u,seriesField:o,point:{shape:"circle",color:n}}}),e}function iU(e){var r,t=e.options,i=t.yField,n=t.xField,a=t.data,o=t.isStack,l=t.isGroup,s=t.colorField,u=t.maxAngle,c=o&&!l&&s?fGt(a,n,i):a,f=ph(c,i);return It(We((r={},r[i]={min:0,max:cGt(u,i,f)},r)))(e)}function vGt(e){var r=e.chart,t=e.options,i=t.radius,n=t.innerRadius,a=t.startAngle,o=t.endAngle;return r.coordinate({type:"polar",cfg:{radius:i,innerRadius:n,startAngle:a,endAngle:o}}).transpose(),e}function dGt(e){var r=e.chart,t=e.options,i=t.xField,n=t.xAxis;return r.axis(i,n),e}function pGt(e){var r=e.chart,t=e.options,i=t.label,n=t.yField,a=ei(r,"interval");if(!i)a.label(!1);else{var o=i.callback,l=ue(i,["callback"]);a.label({fields:[n],callback:o,cfg:A(A({},Pr(l)),{type:"polar"})})}return e}function gGt(e){return It(Sn("barStyle"),hGt,iU,dGt,vGt,Ae,ce,ie,Dr,Og,Xe(),pGt)(e)}var yGt=J({},Dt.getDefaultOptions(),{interactions:[{type:"element-active"}],legend:!1,tooltip:{showMarkers:!1},xAxis:{grid:null,tickLine:null,line:null},maxAngle:240});(function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="radial-bar",t}return r.getDefaultOptions=function(){return yGt},r.prototype.changeData=function(t){this.updateOption({data:t}),iU({chart:this.chart,options:this.options}),this.chart.changeData(t)},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return gGt},r})(Dt);var go="first-axes-view",yo="second-axes-view",Lu="series-field-key";function nU(e,r,t,i,n){var a=[];r.forEach(function(f){i.forEach(function(h){var v,d=(v={},v[e]=h[e],v[t]=f,v[f]=h[f],v);a.push(d)})});var o=Object.values(Xi(a,t)),l=o[0],s=l===void 0?[]:l,u=o[1],c=u===void 0?[]:u;return n?[s.reverse(),c.reverse()]:[s,c]}function qo(e){return e!=="vertical"}function mGt(e,r,t){var i=r[0],n=r[1],a=i.autoPadding,o=n.autoPadding,l=e.__axisPosition,s=l.layout,u=l.position;if(qo(s)&&u==="top"&&(i.autoPadding=t.instance(a.top,0,a.bottom,a.left),n.autoPadding=t.instance(o.top,a.left,o.bottom,0)),qo(s)&&u==="bottom"&&(i.autoPadding=t.instance(a.top,a.right/2+5,a.bottom,a.left),n.autoPadding=t.instance(o.top,o.right,o.bottom,a.right/2+5)),!qo(s)&&u==="bottom"){var c=a.left>=o.left?a.left:o.left;i.autoPadding=t.instance(a.top,a.right,a.bottom/2+5,c),n.autoPadding=t.instance(a.bottom/2+5,o.right,o.bottom,c)}if(!qo(s)&&u==="top"){var c=a.left>=o.left?a.left:o.left;i.autoPadding=t.instance(a.top,a.right,0,c),n.autoPadding=t.instance(0,o.right,a.top,c)}}function xGt(e){var r=e.chart,t=e.options,i=t.data,n=t.xField,a=t.yField,o=t.color,l=t.barStyle,s=t.widthRatio,u=t.legend,c=t.layout,f=nU(n,a,Lu,i,qo(c));u?r.legend(Lu,u):u===!1&&r.legend(!1);var h,v,d=f[0],p=f[1];qo(c)?(h=r.createView({region:{start:{x:0,y:0},end:{x:.5,y:1}},id:go}),h.coordinate().transpose().reflect("x"),v=r.createView({region:{start:{x:.5,y:0},end:{x:1,y:1}},id:yo}),v.coordinate().transpose(),h.data(d),v.data(p)):(h=r.createView({region:{start:{x:0,y:0},end:{x:1,y:.5}},id:go}),v=r.createView({region:{start:{x:0,y:.5},end:{x:1,y:1}},id:yo}),v.coordinate().reflect("y"),h.data(d),v.data(p));var x=J({},e,{chart:h,options:{widthRatio:s,xField:n,yField:a[0],seriesField:Lu,interval:{color:o,style:l}}});ri(x);var m=J({},e,{chart:v,options:{xField:n,yField:a[1],seriesField:Lu,widthRatio:s,interval:{color:o,style:l}}});return ri(m),e}function _Gt(e){var r,t,i,n=e.options,a=e.chart,o=n.xAxis,l=n.yAxis,s=n.xField,u=n.yField,c=Yt(a,go),f=Yt(a,yo),h={};return lc((n==null?void 0:n.meta)||{}).map(function(v){I(n==null?void 0:n.meta,[v,"alias"])&&(h[v]=n.meta[v].alias)}),a.scale((r={},r[Lu]={sync:!0,formatter:function(v){return I(h,v,v)}},r)),We((t={},t[s]=o,t[u[0]]=l[u[0]],t))(J({},e,{chart:c})),We((i={},i[s]=o,i[u[1]]=l[u[1]],i))(J({},e,{chart:f})),e}function bGt(e){var r=e.chart,t=e.options,i=t.xAxis,n=t.yAxis,a=t.xField,o=t.yField,l=t.layout,s=Yt(r,go),u=Yt(r,yo);return(i==null?void 0:i.position)==="bottom"?u.axis(a,A(A({},i),{label:{formatter:function(){return""}}})):u.axis(a,!1),i===!1?s.axis(a,!1):s.axis(a,A({position:qo(l)?"top":"bottom"},i)),n===!1?(s.axis(o[0],!1),u.axis(o[1],!1)):(s.axis(o[0],n[o[0]]),u.axis(o[1],n[o[1]])),r.__axisPosition={position:s.getOptions().axes[a].position,layout:l},e}function wGt(e){var r=e.chart;return Ae(J({},e,{chart:Yt(r,go)})),Ae(J({},e,{chart:Yt(r,yo)})),e}function CGt(e){var r=e.chart,t=e.options,i=t.yField,n=t.yAxis;return ac(J({},e,{chart:Yt(r,go),options:{yAxis:n[i[0]]}})),ac(J({},e,{chart:Yt(r,yo),options:{yAxis:n[i[1]]}})),e}function SGt(e){var r=e.chart;return ie(J({},e,{chart:Yt(r,go)})),ie(J({},e,{chart:Yt(r,yo)})),e}function AGt(e){var r=e.chart;return ce(J({},e,{chart:Yt(r,go)})),ce(J({},e,{chart:Yt(r,yo)})),e}function TGt(e){var r=this,t,i,n=e.chart,a=e.options,o=a.label,l=a.yField,s=a.layout,u=Yt(n,go),c=Yt(n,yo),f=ei(u,"interval"),h=ei(c,"interval");if(!o)f.label(!1),h.label(!1);else{var v=o.callback,d=ue(o,["callback"]);d.position||(d.position="middle"),d.offset===void 0&&(d.offset=2);var p=A({},d);if(qo(s)){var x=((t=p.style)===null||t===void 0?void 0:t.textAlign)||(d.position==="middle"?"center":"left");d.style=J({},d.style,{textAlign:x});var m={left:"right",right:"left",center:"center"};p.style=J({},p.style,{textAlign:m[x]})}else{var _={top:"bottom",bottom:"top",middle:"middle"};typeof d.position=="string"?d.position=_[d.position]:typeof d.position=="function"&&(d.position=function(){for(var S=[],M=0;M<arguments.length;M++)S[M]=arguments[M];return _[d.position.apply(r,S)]});var b=((i=p.style)===null||i===void 0?void 0:i.textBaseline)||"bottom";p.style=J({},p.style,{textBaseline:b});var w={top:"bottom",bottom:"top",middle:"middle"};d.style=J({},d.style,{textBaseline:w[b]})}f.label({fields:[l[0]],callback:v,cfg:Pr(p)}),h.label({fields:[l[1]],callback:v,cfg:Pr(d)})}return e}function MGt(e){return It(xGt,_Gt,bGt,CGt,SGt,TGt,Dr,wGt,AGt)(e)}(function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="bidirectional-bar",t}return r.getDefaultOptions=function(){return J({},e.getDefaultOptions.call(this),{syncViewPadding:mGt})},r.prototype.changeData=function(t){t===void 0&&(t=[]),this.chart.emit(Gt.BEFORE_CHANGE_DATA,$e.fromData(this.chart,Gt.BEFORE_CHANGE_DATA,null)),this.updateOption({data:t});var i=this.options,n=i.xField,a=i.yField,o=i.layout,l=nU(n,a,Lu,t,qo(o)),s=l[0],u=l[1],c=Yt(this.chart,go),f=Yt(this.chart,yo);c.data(s),f.data(u),this.chart.render(!0),this.chart.emit(Gt.AFTER_CHANGE_DATA,$e.fromData(this.chart,Gt.AFTER_CHANGE_DATA,null))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return MGt},r.SERIES_FIELD_KEY=Lu,r})(Dt);function aU(e,r){if(!!it(e))return e.find(function(t){return t.type===r})}function oU(e,r){var t=aU(e,r);return t&&t.enable!==!1}function iI(e){var r=e.interactions,t=e.drilldown;return I(t,"enabled")||oU(r,"treemap-drill-down")}function EGt(e){var r=e.interactions["drill-down"];if(!!r){var t=r.context.actions.find(function(i){return i.name==="drill-down-action"});t.reset()}}function nI(e){var r=e.data,t=e.colorField,i=e.enableDrillDown,n=e.hierarchyConfig,a=X6(r,A(A({},n),{type:"hierarchy.treemap",field:"value",as:["x","y"]})),o=[];return a.forEach(function(l){if(l.depth===0||i&&l.depth!==1||!i&&l.children)return null;var s=l.ancestors().map(function(h){return{data:h.data,height:h.height,value:h.value}}),u=i&&it(r.path)?s.concat(r.path.slice(1)):s,c=Object.assign({},l.data,A({x:l.x,y:l.y,depth:l.depth,value:l.value,path:u},l));if(!l.data[t]&&l.parent){var f=l.ancestors().find(function(h){return h.data[t]});c[t]=f==null?void 0:f.data[t]}else c[t]=l.data[t];c[dp]={hierarchyConfig:n,colorField:t,enableDrillDown:i},o.push(c)}),o}function FGt(e){var r=e.options,t=r.colorField;return J({options:{rawFields:["value"],tooltip:{fields:["name","value",t,"path"],formatter:function(i){return{name:i.name,value:i.value}}}}},e)}function OGt(e){var r=e.chart,t=e.options,i=t.color,n=t.colorField,a=t.rectStyle,o=t.hierarchyConfig,l=t.rawFields,s=nI({data:t.data,colorField:t.colorField,enableDrillDown:iI(t),hierarchyConfig:o});return r.data(s),Tb(J({},e,{options:{xField:"x",yField:"y",seriesField:n,rawFields:l,polygon:{color:i,style:a}}})),r.coordinate().reflect("y"),e}function PGt(e){var r=e.chart;return r.axis(!1),e}function IGt(e){var r=e.drilldown,t=e.interactions,i=t===void 0?[]:t,n=iI(e);return n?J({},e,{interactions:ye(i,[{type:"drill-down",cfg:{drillDownConfig:r,transformData:nI}}])}):e}function LGt(e){var r=e.chart,t=e.options,i=t.interactions,n=t.drilldown;Ae({chart:r,options:IGt(t)});var a=aU(i,"view-zoom");a&&(a.enable!==!1?r.getCanvas().on("mousewheel",function(l){l.preventDefault()}):r.getCanvas().off("mousewheel"));var o=iI(t);return o&&(r.appendPadding=bb(r.appendPadding,I(n,["breadCrumb","position"]))),e}function DGt(e){return It(FGt,ie,Sn("rectStyle"),OGt,PGt,Og,Dr,LGt,ce,Xe())(e)}var $Gt={colorField:"name",rectStyle:{lineWidth:1,stroke:"#fff"},hierarchyConfig:{tile:"treemapSquarify"},label:{fields:["name"],layout:{type:"limit-in-shape"}},tooltip:{showMarkers:!1,showTitle:!1},drilldown:{enabled:!1,breadCrumb:{position:"bottom-left",rootText:"\u521D\u59CB",dividerText:"/",textStyle:{fontSize:12,fill:"rgba(0, 0, 0, 0.65)",cursor:"pointer"},activeTextStyle:{fill:"#87B5FF"}}}};(function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="treemap",t}return r.getDefaultOptions=function(){return $Gt},r.prototype.changeData=function(t){var i=this.options,n=i.colorField,a=i.interactions,o=i.hierarchyConfig;this.updateOption({data:t});var l=nI({data:t,colorField:n,enableDrillDown:oU(a,"treemap-drill-down"),hierarchyConfig:o});this.chart.changeData(l),EGt(this.chart)},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return DGt},r})(Dt);function kGt(e){return e.target.depth}function RGt(e){return e.depth}function BGt(e,r){return r-1-e.height}function aI(e,r){return e.sourceLinks.length?e.depth:r-1}function NGt(e){return e.targetLinks.length?e.depth:e.sourceLinks.length?cM(e.sourceLinks,kGt)-1:0}function d0(e){return function(){return e}}function iA(e,r){for(var t=0,i=0;i<e.length;i++)t+=r(e[i]);return t}function nA(e,r){for(var t=-1/0,i=0;i<e.length;i++)t=Math.max(r(e[i]),t);return t}function GGt(e,r){for(var t=1/0,i=0;i<e.length;i++)t=Math.min(r(e[i]),t);return t}function bG(e,r){return Yx(e.source,r.source)||e.index-r.index}function wG(e,r){return Yx(e.target,r.target)||e.index-r.index}function Yx(e,r){return e.y0-r.y0}function aA(e){return e.value}function zGt(e){return e.index}function VGt(e){return e.nodes}function jGt(e){return e.links}function CG(e,r){var t=e.get(r);if(!t)throw new Error("missing: "+r);return t}function SG(e){for(var r=e.nodes,t=0,i=r;t<i.length;t++){for(var n=i[t],a=n.y0,o=a,l=0,s=n.sourceLinks;l<s.length;l++){var u=s[l];u.y0=a+u.width/2,a+=u.width}for(var c=0,f=n.targetLinks;c<f.length;c++){var u=f[c];u.y1=o+u.width/2,o+=u.width}}}function HGt(){var e=0,r=0,t=1,i=1,n=24,a=8,o,l=zGt,s=aI,u,c,f,h=VGt,v=jGt,d=6;function p(R){var G={nodes:h(R),links:v(R)};return x(G),m(G),_(G),b(G),M(G),SG(G),G}p.update=function(R){return SG(R),R},p.nodeId=function(R){return arguments.length?(l=typeof R=="function"?R:d0(R),p):l},p.nodeAlign=function(R){return arguments.length?(s=typeof R=="function"?R:d0(R),p):s},p.nodeDepth=function(R){return arguments.length?(u=R,p):u},p.nodeSort=function(R){return arguments.length?(c=R,p):c},p.nodeWidth=function(R){return arguments.length?(n=+R,p):n},p.nodePadding=function(R){return arguments.length?(a=o=+R,p):a},p.nodes=function(R){return arguments.length?(h=typeof R=="function"?R:d0(R),p):h},p.links=function(R){return arguments.length?(v=typeof R=="function"?R:d0(R),p):v},p.linkSort=function(R){return arguments.length?(f=R,p):f},p.size=function(R){return arguments.length?(e=r=0,t=+R[0],i=+R[1],p):[t-e,i-r]},p.extent=function(R){return arguments.length?(e=+R[0][0],t=+R[1][0],r=+R[0][1],i=+R[1][1],p):[[e,r],[t,i]]},p.iterations=function(R){return arguments.length?(d=+R,p):d};function x(R){var G=R.nodes,N=R.links;G.forEach(function(et,lt){et.index=lt,et.sourceLinks=[],et.targetLinks=[]});var W=new Map(G.map(function(et){return[l(et),et]}));if(N.forEach(function(et,lt){et.index=lt;var dt=et.source,ht=et.target;typeof dt!="object"&&(dt=et.source=CG(W,dt)),typeof ht!="object"&&(ht=et.target=CG(W,ht)),dt.sourceLinks.push(et),ht.targetLinks.push(et)}),f!=null)for(var q=0,tt=G;q<tt.length;q++){var ot=tt[q],st=ot.sourceLinks,Z=ot.targetLinks;st.sort(f),Z.sort(f)}}function m(R){for(var G=R.nodes,N=0,W=G;N<W.length;N++){var q=W[N];q.value=q.fixedValue===void 0?Math.max(iA(q.sourceLinks,aA),iA(q.targetLinks,aA)):q.fixedValue}}function _(R){for(var G=R.nodes,N=G.length,W=new Set(G),q=new Set,tt=0;W.size;){if(W.forEach(function(et){et.depth=tt;for(var lt=0,dt=et.sourceLinks;lt<dt.length;lt++){var ht=dt[lt].target;q.add(ht)}}),++tt>N)throw new Error("circular link");W=q,q=new Set}if(u)for(var ot=Math.max(nA(G,function(et){return et.depth})+1,0),st=void 0,Z=0;Z<G.length;Z++)st=G[Z],st.depth=u.call(null,st,ot)}function b(R){for(var G=R.nodes,N=G.length,W=new Set(G),q=new Set,tt=0;W.size;){if(W.forEach(function(ot){ot.height=tt;for(var st=0,Z=ot.targetLinks;st<Z.length;st++){var et=Z[st].source;q.add(et)}}),++tt>N)throw new Error("circular link");W=q,q=new Set}}function w(R){for(var G=R.nodes,N=Math.max(nA(G,function(ht){return ht.depth})+1,0),W=(t-e-n)/(N-1),q=new Array(N).fill(0).map(function(){return[]}),tt=0,ot=G;tt<ot.length;tt++){var st=ot[tt],Z=Math.max(0,Math.min(N-1,Math.floor(s.call(null,st,N))));st.layer=Z,st.x0=e+Z*W,st.x1=st.x0+n,q[Z]?q[Z].push(st):q[Z]=[st]}if(c)for(var et=0,lt=q;et<lt.length;et++){var dt=lt[et];dt.sort(c)}return q}function S(R){for(var G=GGt(R,function(wt){return(i-r-(wt.length-1)*o)/iA(wt,aA)}),N=0,W=R;N<W.length;N++){for(var q=W[N],tt=r,ot=0,st=q;ot<st.length;ot++){var Z=st[ot];Z.y0=tt,Z.y1=tt+Z.value*G,tt=Z.y1+o;for(var et=0,lt=Z.sourceLinks;et<lt.length;et++){var dt=lt[et];dt.width=dt.value*G}}tt=(i-tt+o)/(q.length+1);for(var ht=0;ht<q.length;++ht){var Z=q[ht];Z.y0+=tt*(ht+1),Z.y1+=tt*(ht+1)}B(q)}}function M(R){var G=w(R);o=Math.min(a,(i-r)/(nA(G,function(tt){return tt.length})-1)),S(G);for(var N=0;N<d;++N){var W=Math.pow(.99,N),q=Math.max(1-W,(N+1)/d);O(G,W,q),F(G,W,q)}}function F(R,G,N){for(var W=1,q=R.length;W<q;++W){for(var tt=R[W],ot=0,st=tt;ot<st.length;ot++){for(var Z=st[ot],et=0,lt=0,dt=0,ht=Z.targetLinks;dt<ht.length;dt++){var wt=ht[dt],gt=wt.source,vt=wt.value,_t=vt*(Z.layer-gt.layer);et+=j(gt,Z)*_t,lt+=_t}if(lt>0){var Bt=(et/lt-Z.y0)*G;Z.y0+=Bt,Z.y1+=Bt,H(Z)}}c===void 0&&tt.sort(Yx),tt.length&&L(tt,N)}}function O(R,G,N){for(var W=R.length,q=W-2;q>=0;--q){for(var tt=R[q],ot=0,st=tt;ot<st.length;ot++){for(var Z=st[ot],et=0,lt=0,dt=0,ht=Z.sourceLinks;dt<ht.length;dt++){var wt=ht[dt],gt=wt.target,vt=wt.value,_t=vt*(gt.layer-Z.layer);et+=U(Z,gt)*_t,lt+=_t}if(lt>0){var Bt=(et/lt-Z.y0)*G;Z.y0+=Bt,Z.y1+=Bt,H(Z)}}c===void 0&&tt.sort(Yx),tt.length&&L(tt,N)}}function L(R,G){var N=R.length>>1,W=R[N];k(R,W.y0-o,N-1,G),D(R,W.y1+o,N+1,G),k(R,i,R.length-1,G),D(R,r,0,G)}function D(R,G,N,W){for(;N<R.length;++N){var q=R[N],tt=(G-q.y0)*W;tt>1e-6&&(q.y0+=tt,q.y1+=tt),G=q.y1+o}}function k(R,G,N,W){for(;N>=0;--N){var q=R[N],tt=(q.y1-G)*W;tt>1e-6&&(q.y0-=tt,q.y1-=tt),G=q.y0-o}}function H(R){var G=R.sourceLinks,N=R.targetLinks;if(f===void 0){for(var W=0,q=N;W<q.length;W++){var tt=q[W].source.sourceLinks;tt.sort(wG)}for(var ot=0,st=G;ot<st.length;ot++){var Z=st[ot].target.targetLinks;Z.sort(bG)}}}function B(R){if(f===void 0)for(var G=0,N=R;G<N.length;G++){var W=N[G],q=W.sourceLinks,tt=W.targetLinks;q.sort(wG),tt.sort(bG)}}function j(R,G){for(var N=R.y0-(R.sourceLinks.length-1)*o/2,W=0,q=R.sourceLinks;W<q.length;W++){var tt=q[W],ot=tt.target,st=tt.width;if(ot===G)break;N+=st+o}for(var Z=0,et=G.targetLinks;Z<et.length;Z++){var lt=et[Z],ot=lt.source,st=lt.width;if(ot===R)break;N-=st}return N}function U(R,G){for(var N=G.y0-(G.targetLinks.length-1)*o/2,W=0,q=G.targetLinks;W<q.length;W++){var tt=q[W],ot=tt.source,st=tt.width;if(ot===R)break;N+=st+o}for(var Z=0,et=R.sourceLinks;Z<et.length;Z++){var lt=et[Z],ot=lt.target,st=lt.width;if(ot===G)break;N-=st}return N}return p}var YGt={left:RGt,right:BGt,center:NGt,justify:aI},WGt={nodeId:function(e){return e.index},nodeAlign:"justify",nodeWidth:.008,nodePadding:.03,nodeSort:void 0};function XGt(e){var r=Ct(e)?YGt[e]:pt(e)?e:null;return r||aI}function UGt(e){return Kt({},WGt,e)}function qGt(e,r){var t=UGt(e),i=t.nodeId,n=t.nodeSort,a=t.nodeAlign,o=t.nodeWidth,l=t.nodePadding,s=t.nodeDepth,u=HGt().nodeSort(n).nodeWidth(o).nodePadding(l).nodeDepth(s).nodeAlign(XGt(a)).extent([[0,0],[1,1]]).nodeId(i),c=u(r);return c.nodes.forEach(function(f){var h=f.x0,v=f.x1,d=f.y0,p=f.y1;f.x=[h,v,v,h],f.y=[d,d,p,p]}),c.links.forEach(function(f){var h=f.source,v=f.target,d=h.x1,p=v.x0;f.x=[d,d,p,p];var x=f.width/2;f.y=[f.y0+x,f.y0-x,f.y1+x,f.y1-x]}),c}function ZGt(e,r,t){var i=[];return e.forEach(function(n){var a=n[r],o=n[t];i.includes(a)||i.push(a),i.includes(o)||i.push(o)}),i}function QGt(e,r,t,i){var n={};return r.forEach(function(a){n[a]={},r.forEach(function(o){n[a][o]=0})}),e.forEach(function(a){n[a[t]][a[i]]=1}),n}function KGt(e,r,t){if(!it(e))return[];var i=[],n=ZGt(e,r,t),a=QGt(e,n,r,t),o={};n.forEach(function(s){o[s]=0});function l(s){o[s]=1,n.forEach(function(u){if(a[s][u]!=0)if(o[u]==1)i.push(s+"_"+u);else{if(o[u]==-1)return;l(u)}}),o[s]=-1}return n.forEach(function(s){o[s]!=-1&&l(s)}),i.length!==0&&console.warn("sankey data contains circle, "+i.length+" records removed.",i),e.filter(function(s){return i.findIndex(function(u){return u===s[r]+"_"+s[t]})<0})}function JGt(e,r,t){return nc(e)?e/t:r}function tzt(e,r,t){return nc(e)?e/t:r}function lU(e,r,t){var i=e.data,n=e.sourceField,a=e.targetField,o=e.weightField,l=e.nodeAlign,s=e.nodeSort,u=e.nodePadding,c=e.nodePaddingRatio,f=e.nodeWidth,h=e.nodeWidthRatio,v=e.nodeDepth,d=e.rawFields,p=d===void 0?[]:d,x=DX(KGt(i,n,a),n,a,o,p),m=qGt({nodeAlign:l,nodePadding:tzt(u,c,t),nodeWidth:JGt(f,h,r),nodeSort:s,nodeDepth:v},x),_=m.nodes,b=m.links;return{nodes:_.map(function(w){return A(A({},se(w,ye(["x","y","name"],p))),{isNode:!0})}),edges:b.map(function(w){return A(A({source:w.source.name,target:w.target.name,name:w.source.name||w.target.name},se(w,ye(["x","y","value"],p))),{isNode:!1})})}}var AG="x",TG="y",MG="name",oI="nodes",lI="edges";function ezt(e){var r=e.options,t=r.rawFields,i=t===void 0?[]:t;return J({},{options:{tooltip:{fields:us(ye(["name","source","target","value","isNode"],i))},label:{fields:us(ye(["x","name"],i))}}},e)}function rzt(e){var r=e.chart,t=e.options,i=t.color,n=t.nodeStyle,a=t.edgeStyle,o=t.label,l=t.tooltip,s=t.nodeState,u=t.edgeState;r.legend(!1),r.tooltip(l),r.axis(!1),r.coordinate().reflect("y");var c=lU(t,r.width,r.height),f=c.nodes,h=c.edges,v=r.createView({id:lI});v.data(h),NX({chart:v,options:{xField:AG,yField:TG,seriesField:MG,edge:{color:i,style:a,shape:"arc"},tooltip:l,state:u}});var d=r.createView({id:oI});return d.data(f),Tb({chart:d,options:{xField:AG,yField:TG,seriesField:MG,polygon:{color:i,style:n},label:o,tooltip:l,state:s}}),r.interaction("element-active"),r.scale({x:{sync:!0,nice:!0,min:0,max:1,minLimit:0,maxLimit:1},y:{sync:!0,nice:!0,min:0,max:1,minLimit:0,maxLimit:1},name:{sync:"color",type:"cat"}}),e}function izt(e){var r=e.chart,t=e.options,i=t.animation;typeof i=="boolean"?r.animate(i):r.animate(!0);var n=ye(r.views[0].geometries,r.views[1].geometries);return n.forEach(function(a){a.animate(i)}),e}function nzt(e){var r=e.chart,t=e.options,i=t.nodeDraggable,n="sankey-node-draggable";return i?r.interaction(n):r.removeInteraction(n),e}function azt(e){return It(ezt,rzt,Ae,nzt,izt,ie)(e)}var ozt=function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.isDragging=!1,t}return r.prototype.isNodeElement=function(){var t=I(this.context,"event.target");if(t){var i=t.get("element");return i&&i.getModel().data.isNode}return!1},r.prototype.getNodeView=function(){return Yt(this.context.view,oI)},r.prototype.getEdgeView=function(){return Yt(this.context.view,lI)},r.prototype.getCurrentDatumIdx=function(t){return this.getNodeView().geometries[0].elements.indexOf(t)},r.prototype.start=function(){if(this.isNodeElement()){this.prevPoint={x:I(this.context,"event.x"),y:I(this.context,"event.y")};var t=this.context.event.target.get("element"),i=this.getCurrentDatumIdx(t);if(i===-1)return;this.currentElementIdx=i,this.context.isDragging=!0,this.isDragging=!0,this.prevNodeAnimateCfg=this.getNodeView().getOptions().animate,this.prevEdgeAnimateCfg=this.getEdgeView().getOptions().animate,this.getNodeView().animate(!1),this.getEdgeView().animate(!1)}},r.prototype.translate=function(){if(this.isDragging){var t=this.context.view,i={x:I(this.context,"event.x"),y:I(this.context,"event.y")},n=i.x-this.prevPoint.x,a=i.y-this.prevPoint.y,o=this.getNodeView(),l=o.geometries[0].elements[this.currentElementIdx];if(l&&l.getModel()){var s=l.getModel().data,u=o.getOptions().data,c=o.getCoordinate(),f={x:n/c.getWidth(),y:a/c.getHeight()},h=A(A({},s),{x:s.x.map(function(m){return m+=f.x}),y:s.y.map(function(m){return m+=f.y})}),v=ye(u);v[this.currentElementIdx]=h,o.data(v);var d=s.name,p=this.getEdgeView(),x=p.getOptions().data;x.forEach(function(m){m.source===d&&(m.x[0]+=f.x,m.x[1]+=f.x,m.y[0]+=f.y,m.y[1]+=f.y),m.target===d&&(m.x[2]+=f.x,m.x[3]+=f.x,m.y[2]+=f.y,m.y[3]+=f.y)}),p.data(x),this.prevPoint=i,t.render(!0)}}},r.prototype.end=function(){this.isDragging=!1,this.context.isDragging=!1,this.prevPoint=null,this.currentElementIdx=null,this.getNodeView().animate(this.prevNodeAnimateCfg),this.getEdgeView().animate(this.prevEdgeAnimateCfg)},r}(Ie);Et("sankey-node-drag",ozt);Lt("sankey-node-draggable",{showEnable:[{trigger:"polygon:mouseenter",action:"cursor:pointer"},{trigger:"polygon:mouseleave",action:"cursor:default"}],start:[{trigger:"polygon:mousedown",action:"sankey-node-drag:start"}],processing:[{trigger:"plot:mousemove",action:"sankey-node-drag:translate"},{isEnable:function(e){return e.isDragging},trigger:"plot:mousemove",action:"cursor:move"}],end:[{trigger:"plot:mouseup",action:"sankey-node-drag:end"}]});(function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="sankey",t}return r.getDefaultOptions=function(){return{appendPadding:8,syncViewPadding:!0,nodeStyle:{opacity:1,fillOpacity:1,lineWidth:1},edgeStyle:{opacity:.3,lineWidth:0},edgeState:{active:{style:{opacity:.8,lineWidth:0}}},label:{formatter:function(t){var i=t.name;return i},callback:function(t){var i=t[1]===1;return{style:{fill:"#545454",textAlign:i?"end":"start"},offsetX:i?-8:8}},layout:[{type:"hide-overlap"}]},tooltip:{showTitle:!1,showMarkers:!1,shared:!1,showContent:function(t){return!I(t,[0,"data","isNode"])},formatter:function(t){var i=t.source,n=t.target,a=t.value;return{name:i+" -> "+n,value:a}}},nodeWidthRatio:.008,nodePaddingRatio:.01,animation:{appear:{animation:"wave-in"},enter:{animation:"wave-in"}}}},r.prototype.changeData=function(t){this.updateOption({data:t});var i=lU(this.options,this.chart.width,this.chart.height),n=i.nodes,a=i.edges,o=Yt(this.chart,oI),l=Yt(this.chart,lI);o.changeData(n),l.changeData(a)},r.prototype.getSchemaAdaptor=function(){return azt},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r})(Dt);var lzt={y:0,nodeWidthRatio:.05,weight:!1,nodePaddingRatio:.1,id:function(e){return e.id},source:function(e){return e.source},target:function(e){return e.target},sourceWeight:function(e){return e.value||1},targetWeight:function(e){return e.value||1},sortBy:null};function szt(e,r,t){P(e,function(i,n){i.inEdges=r.filter(function(a){return""+t.target(a)==""+n}),i.outEdges=r.filter(function(a){return""+t.source(a)==""+n}),i.edges=i.outEdges.concat(i.inEdges),i.frequency=i.edges.length,i.value=0,i.inEdges.forEach(function(a){i.value+=t.targetWeight(a)}),i.outEdges.forEach(function(a){i.value+=t.sourceWeight(a)})})}function uzt(e,r){var t={weight:function(n,a){return a.value-n.value},frequency:function(n,a){return a.frequency-n.frequency},id:function(n,a){return(""+r.id(n)).localeCompare(""+r.id(a))}},i=t[r.sortBy];!i&&pt(r.sortBy)&&(i=r.sortBy),i&&e.sort(i)}function czt(e,r){var t=e.length;if(!t)throw new TypeError("Invalid nodes: it's empty!");if(r.weight){var i=r.nodePaddingRatio;if(i<0||i>=1)throw new TypeError("Invalid nodePaddingRatio: it must be in range [0, 1)!");var n=i/(2*t),a=r.nodeWidthRatio;if(a<=0||a>=1)throw new TypeError("Invalid nodeWidthRatio: it must be in range (0, 1)!");var o=0;e.forEach(function(s){o+=s.value}),e.forEach(function(s){s.weight=s.value/o,s.width=s.weight*(1-i),s.height=a}),e.forEach(function(s,u){for(var c=0,f=u-1;f>=0;f--)c+=e[f].width+2*n;var h=s.minX=n+c,v=s.maxX=s.minX+s.width,d=s.minY=r.y-a/2,p=s.maxY=d+a;s.x=[h,v,v,h],s.y=[d,d,p,p]})}else{var l=1/t;e.forEach(function(s,u){s.x=(u+.5)*l,s.y=r.y})}return e}function fzt(e,r,t){if(t.weight){var i={};P(e,function(n,a){i[a]=n.value}),r.forEach(function(n){var a=t.source(n),o=t.target(n),l=e[a],s=e[o];if(l&&s){var u=i[a],c=t.sourceWeight(n),f=l.minX+(l.value-u)/l.value*l.width,h=f+c/l.value*l.width;i[a]-=c;var v=i[o],d=t.targetWeight(n),p=s.minX+(s.value-v)/s.value*s.width,x=p+d/s.value*s.width;i[o]-=d;var m=t.y;n.x=[f,h,p,x],n.y=[m,m,m,m],n.source=l,n.target=s}})}else r.forEach(function(n){var a=e[t.source(n)],o=e[t.target(n)];a&&o&&(n.x=[a.x,o.x],n.y=[a.y,o.y],n.source=a,n.target=o)});return r}function hzt(e){return Kt({},lzt,e)}function vzt(e,r){var t=hzt(e),i={},n=r.nodes,a=r.links;n.forEach(function(s){var u=t.id(s);i[u]=s}),szt(i,a,t),uzt(n,t);var o=czt(n,t),l=fzt(i,a,t);return{nodes:o,links:l}}var sU="x",uU="y",cU="name",fU="source",dzt={nodeStyle:{opacity:1,fillOpacity:1,lineWidth:1},edgeStyle:{opacity:.5,lineWidth:2},label:{fields:["x","name"],callback:function(e,r){var t=(e[0]+e[1])/2,i=t>.5?-4:4;return{labelEmit:!0,style:{fill:"#8c8c8c"},offsetX:i,content:r}}},tooltip:{showTitle:!1,showMarkers:!1,fields:["source","target","value","isNode"],showContent:function(e){return!I(e,[0,"data","isNode"])},formatter:function(e){var r=e.source,t=e.target,i=e.value;return{name:r+" -> "+t,value:i}}},interactions:[{type:"element-active"}],weight:!0,nodePaddingRatio:.1,nodeWidthRatio:.05};function pzt(e){var r=e.options,t=r.data,i=r.sourceField,n=r.targetField,a=r.weightField,o=r.nodePaddingRatio,l=r.nodeWidthRatio,s=r.rawFields,u=s===void 0?[]:s,c=DX(t,i,n,a),f=vzt({weight:!0,nodePaddingRatio:o,nodeWidthRatio:l},c),h=f.nodes,v=f.links,d=h.map(function(x){return A(A({},se(x,ye(["id","x","y","name"],u))),{isNode:!0})}),p=v.map(function(x){return A(A({source:x.source.name,target:x.target.name,name:x.source.name||x.target.name},se(x,ye(["x","y","value"],u))),{isNode:!1})});return A(A({},e),{ext:A(A({},e.ext),{chordData:{nodesData:d,edgesData:p}})})}function gzt(e){var r,t=e.chart;return t.scale((r={x:{sync:!0,nice:!0},y:{sync:!0,nice:!0,max:1}},r[cU]={sync:"color"},r[fU]={sync:"color"},r)),e}function yzt(e){var r=e.chart;return r.axis(!1),e}function mzt(e){var r=e.chart;return r.legend(!1),e}function xzt(e){var r=e.chart,t=e.options,i=t.tooltip;return r.tooltip(i),e}function _zt(e){var r=e.chart;return r.coordinate("polar").reflect("y"),e}function bzt(e){var r=e.chart,t=e.options,i=e.ext.chordData.nodesData,n=t.nodeStyle,a=t.label,o=t.tooltip,l=r.createView();return l.data(i),Tb({chart:l,options:{xField:sU,yField:uU,seriesField:cU,polygon:{style:n},label:a,tooltip:o}}),e}function wzt(e){var r=e.chart,t=e.options,i=e.ext.chordData.edgesData,n=t.edgeStyle,a=t.tooltip,o=r.createView();o.data(i);var l={xField:sU,yField:uU,seriesField:fU,edge:{style:n,shape:"arc"},tooltip:a};return NX({chart:o,options:l}),e}function Czt(e){var r=e.chart,t=e.options,i=t.animation;return typeof i=="boolean"?r.animate(i):r.animate(!0),P(HLt(r),function(n){n.animate(i)}),e}function Szt(e){return It(ie,pzt,_zt,gzt,yzt,mzt,xzt,wzt,bzt,Ae,Rs,Czt)(e)}(function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="chord",t}return r.getDefaultOptions=function(){return dzt},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return Szt},r})(Dt);var Azt={field:"value",as:["x","y","r"],sort:function(e,r){return r.value-e.value}};function Tzt(e,r){r=Kt({},Azt,r);var t=r.as;if(!it(t)||t.length!==3)throw new TypeError('Invalid as: it must be an array with 3 strings (e.g. [ "x", "y", "r" ])!');var i;try{i=JP(r)}catch(u){console.warn(u)}var n=function(u){return S4().size(r.size).padding(r.padding)(Nh(u).sum(function(c){return c[i]}).sort(r.sort))},a=n(e),o=t[0],l=t[1],s=t[2];return a.each(function(u){u[o]=u.x,u[l]=u.y,u[s]=u.r}),tI(a)}function hU(e){var r=e.data,t=e.hierarchyConfig,i=e.rawFields,n=i===void 0?[]:i,a=e.enableDrillDown,o=Tzt(r,A(A({},t),{field:"value",as:["x","y","r"]})),l=[];return o.forEach(function(s){for(var u,c=s.data.name,f=A({},s);f.depth>1;)c=((u=f.parent.data)===null||u===void 0?void 0:u.name)+" / "+c,f=f.parent;if(a&&s.depth>2)return null;var h=J({},s.data,A(A(A({},se(s.data,n)),{path:c}),s));h.ext=t,h[dp]={hierarchyConfig:t,rawFields:n,enableDrillDown:a},l.push(h)}),l}function vU(e,r,t){var i=BP([e,r]),n=i[0],a=i[1],o=i[2],l=i[3],s=t.width,u=t.height,c=s-(l+a),f=u-(n+o),h=Math.min(c,f),v=(c-h)/2,d=(f-h)/2,p=n+d,x=a+v,m=o+d,_=l+v,b=[p,x,m,_],w=h<0?0:h;return{finalPadding:b,finalSize:w}}var Mzt=["x","y","r","name","value","path","depth"],Ezt={colorField:"name",autoFit:!0,pointStyle:{lineWidth:0,stroke:"#fff"},legend:!1,hierarchyConfig:{size:[1,1],padding:0},label:{fields:["name"],layout:{type:"limit-in-shape"}},tooltip:{showMarkers:!1,showTitle:!1},drilldown:{enabled:!1}};function Fzt(e){var r=e.chart,t=Math.min(r.viewBBox.width,r.viewBBox.height);return J({options:{size:function(i){var n=i.r;return n*t}}},e)}function Ozt(e){var r=e.options,t=e.chart,i=t.viewBBox,n=r.padding,a=r.appendPadding,o=r.drilldown,l=a;if(o!=null&&o.enabled){var s=bb(t.appendPadding,I(o,["breadCrumb","position"]));l=BP([s,a])}var u=vU(n,l,i).finalPadding;return t.padding=u,t.appendPadding=0,e}function Pzt(e){var r=e.chart,t=e.options,i=r.padding,n=r.appendPadding,a=t.color,o=t.colorField,l=t.pointStyle,s=t.hierarchyConfig,u=t.sizeField,c=t.rawFields,f=c===void 0?[]:c,h=t.drilldown,v=hU({data:t.data,hierarchyConfig:s,enableDrillDown:h==null?void 0:h.enabled,rawFields:f});r.data(v);var d=r.viewBBox,p=vU(i,n,d).finalSize,x=function(m){var _=m.r;return _*p};return u&&(x=function(m){return m[u]*p}),An(J({},e,{options:{xField:"x",yField:"y",seriesField:o,sizeField:u,rawFields:ye(Mzt,f),point:{color:a,style:l,shape:"circle",size:x}}})),e}function Izt(e){return It(We({},{x:{min:0,max:1,minLimit:0,maxLimit:1,nice:!0},y:{min:0,max:1,minLimit:0,maxLimit:1,nice:!0}}))(e)}function Lzt(e){var r=e.chart,t=e.options,i=t.tooltip;if(i===!1)r.tooltip(!1);else{var n=i;I(i,"fields")||(n=J({},{customItems:function(a){return a.map(function(o){var l=I(r.getOptions(),"scales"),s=I(l,["name","formatter"],function(c){return c}),u=I(l,["value","formatter"],function(c){return c});return A(A({},o),{name:s(o.data.name),value:u(o.data.value)})})}},n)),r.tooltip(n)}return e}function Dzt(e){var r=e.chart;return r.axis(!1),e}function $zt(e){var r=e.drilldown,t=e.interactions,i=t===void 0?[]:t;return r!=null&&r.enabled?J({},e,{interactions:ye(i,[{type:"drill-down",cfg:{drillDownConfig:r,transformData:hU,enableDrillDown:!0}}])}):e}function kzt(e){var r=e.chart,t=e.options;return Ae({chart:r,options:$zt(t)}),e}function Rzt(e){return It(Sn("pointStyle"),Fzt,Ozt,ie,Izt,Pzt,Dzt,Og,Lzt,kzt,ce,Xe())(e)}(function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="circle-packing",t}return r.getDefaultOptions=function(){return Ezt},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return Rzt},r.prototype.triggerResize=function(){this.chart.destroyed||(this.chart.forceFit(),this.chart.clear(),this.execAdaptor(),this.chart.render(!0))},r})(Dt);(function(e){X(r,e);function r(t,i,n,a){var o=e.call(this,t,J({},a,i))||this;return o.type="g2-plot",o.defaultOptions=a,o.adaptor=n,o}return r.prototype.getDefaultOptions=function(){return this.defaultOptions},r.prototype.getSchemaAdaptor=function(){return this.adaptor},r})(Dt);var Bzt={line:VX,pie:JX,column:Eb,bar:UX,area:HX,gauge:eU,"tiny-line":l6,"tiny-column":s6,"tiny-area":o6,"ring-progress":p6,progress:v6,scatter:i6,histogram:c6,funnel:N6},Nzt={line:SDt,pie:u$t,column:UDt,bar:ZDt,area:ODt,gauge:QNt,"tiny-line":Bkt,"tiny-column":Vkt,"tiny-area":Hkt,"ring-progress":iRt,progress:tRt,scatter:skt,histogram:Qkt,funnel:aNt},Gzt={pie:{label:!1},column:{tooltip:{showMarkers:!1}},bar:{tooltip:{showMarkers:!1}}};function dU(e,r,t){var i=Nzt[e];if(!i){console.error("could not find "+e+" plot");return}var n=Bzt[e];n({chart:r,options:J({},i.getDefaultOptions(),I(Gzt,e,{}),t)})}function zzt(e){var r=e.chart,t=e.options,i=t.views,n=t.legend;return P(i,function(a){var o=a.region,l=a.data,s=a.meta,u=a.axes,c=a.coordinate,f=a.interactions,h=a.annotations,v=a.tooltip,d=a.geometries,p=r.createView({region:o});p.data(l);var x={};u&&P(u,function(m,_){x[_]=se(m,ji)}),x=J({},s,x),p.scale(x),u?P(u,function(m,_){p.axis(_,m)}):p.axis(!1),p.coordinate(c),P(d,function(m){var _=Ki({chart:p,options:m}).ext,b=m.adjust;b&&_.geometry.adjust(b)}),P(f,function(m){m.enable===!1?p.removeInteraction(m.type):p.interaction(m.type,m.cfg)}),P(h,function(m){p.annotation()[m.type](A({},m))}),typeof a.animation=="boolean"?p.animate(!1):(p.animate(!0),P(p.geometries,function(m){m.animate(a.animation)})),v&&(p.interaction("tooltip"),p.tooltip(v))}),n?P(n,function(a,o){r.legend(o,a)}):r.legend(!1),r.tooltip(t.tooltip),e}function Vzt(e){var r=e.chart,t=e.options,i=t.plots;return P(i,function(n){var a=n.type,o=n.region,l=n.options,s=l===void 0?{}:l,u=s.tooltip,c=r.createView(A({region:o},se(s,kX)));u&&c.interaction("tooltip"),dU(a,c,s)}),e}function jzt(e){return It(ce,zzt,Vzt,Ae,ce,ie,Dr)(e)}function Hzt(e,r){var t=e.getModel(),i=t.data,n;return it(i)?n=i[0][r]:n=i[r],n}function Yzt(e){var r=Gx(e);P(r,function(t){t.hasState("active")&&t.setState("active",!1),t.hasState("selected")&&t.setState("selected",!1),t.hasState("inactive")&&t.setState("inactive",!1)})}var Wzt=function(e){X(r,e);function r(){return e!==null&&e.apply(this,arguments)||this}return r.prototype.getAssociationItems=function(t,i){var n,a=this.context.event,o=i||{},l=o.linkField,s=o.dim,u=[];if(!((n=a.data)===null||n===void 0)&&n.data){var c=a.data.data;P(t,function(f){var h,v,d=l;if(s==="x"?d=f.getXScale().field:s==="y"?d=(h=f.getYScales().find(function(x){return x.field===d}))===null||h===void 0?void 0:h.field:d||(d=(v=f.getGroupScales()[0])===null||v===void 0?void 0:v.field),!!d){var p=je(Gx(f),function(x){var m=!1,_=!1,b=it(c)?I(c[0],d):I(c,d);return Hzt(x,d)===b?m=!0:_=!0,{element:x,view:f,active:m,inactive:_}});u.push.apply(u,p)}})}return u},r.prototype.showTooltip=function(t){var i=ZN(this.context.view),n=this.getAssociationItems(i,t);P(n,function(a){if(a.active){var o=a.element.shape.getCanvasBBox();a.view.showTooltip({x:o.minX+o.width/2,y:o.minY+o.height/2})}})},r.prototype.hideTooltip=function(){var t=ZN(this.context.view);P(t,function(i){i.hideTooltip()})},r.prototype.active=function(t){var i=od(this.context.view),n=this.getAssociationItems(i,t);P(n,function(a){var o=a.active,l=a.element;o&&l.setState("active",!0)})},r.prototype.selected=function(t){var i=od(this.context.view),n=this.getAssociationItems(i,t);P(n,function(a){var o=a.active,l=a.element;o&&l.setState("selected",!0)})},r.prototype.highlight=function(t){var i=od(this.context.view),n=this.getAssociationItems(i,t);P(n,function(a){var o=a.inactive,l=a.element;o&&l.setState("inactive",!0)})},r.prototype.reset=function(){var t=od(this.context.view);P(t,function(i){Yzt(i)})},r}(Ie);Et("association",Wzt);Lt("association-active",{start:[{trigger:"element:mouseenter",action:"association:active"}],end:[{trigger:"element:mouseleave",action:"association:reset"}]});Lt("association-selected",{start:[{trigger:"element:mouseenter",action:"association:selected"}],end:[{trigger:"element:mouseleave",action:"association:reset"}]});Lt("association-highlight",{start:[{trigger:"element:mouseenter",action:"association:highlight"}],end:[{trigger:"element:mouseleave",action:"association:reset"}]});Lt("association-tooltip",{start:[{trigger:"element:mousemove",action:"association:showTooltip"}],end:[{trigger:"element:mouseleave",action:"association:hideTooltip"}]});(function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="mix",t}return r.prototype.getSchemaAdaptor=function(){return jzt},r})(Dt);function Xzt(e,r){var t=r.data,i=r.coordinate,n=r.interactions,a=r.annotations,o=r.animation,l=r.tooltip,s=r.axes,u=r.meta,c=r.geometries;t&&e.data(t);var f={};s&&P(s,function(h,v){f[v]=se(h,ji)}),f=J({},u,f),e.scale(f),i&&e.coordinate(i),s===!1?e.axis(!1):P(s,function(h,v){e.axis(v,h)}),P(c,function(h){var v=Ki({chart:e,options:h}).ext,d=h.adjust;d&&v.geometry.adjust(d)}),P(n,function(h){h.enable===!1?e.removeInteraction(h.type):e.interaction(h.type,h.cfg)}),P(a,function(h){e.annotation()[h.type](A({},h))}),typeof o=="boolean"?e.animate(!1):(e.animate(!0),P(e.geometries,function(h){h.animate(o)})),l?(e.interaction("tooltip"),e.tooltip(l)):l===!1&&e.removeInteraction("tooltip")}function Uzt(e){var r=e.chart,t=e.options,i=t.type,n=t.data,a=t.fields,o=t.eachView,l=i1(t,["type","data","fields","eachView","axes","meta","tooltip","coordinate","theme","legend","interactions","annotations"]);return r.data(n),r.facet(i,A(A({},l),{fields:a,eachView:function(s,u){var c=o(s,u);if(c.geometries)Xzt(s,c);else{var f=c,h=f.options;h.tooltip&&s.interaction("tooltip"),dU(f.type,s,h)}}})),e}function qzt(e){var r=e.chart,t=e.options,i=t.axes,n=t.meta,a=t.tooltip,o=t.coordinate,l=t.theme,s=t.legend,u=t.interactions,c=t.annotations,f={};return i&&P(i,function(h,v){f[v]=se(h,ji)}),f=J({},n,f),r.scale(f),r.coordinate(o),i?P(i,function(h,v){r.axis(v,h)}):r.axis(!1),a?(r.interaction("tooltip"),r.tooltip(a)):a===!1&&r.removeInteraction("tooltip"),r.legend(s),l&&r.theme(l),P(u,function(h){h.enable===!1?r.removeInteraction(h.type):r.interaction(h.type,h.cfg)}),P(c,function(h){r.annotation()[h.type](A({},h))}),e}function Zzt(e){return It(ie,Uzt,qzt)(e)}var Qzt={title:{style:{fontSize:12,fill:"rgba(0,0,0,0.65)"}},rowTitle:{style:{fontSize:12,fill:"rgba(0,0,0,0.65)"}},columnTitle:{style:{fontSize:12,fill:"rgba(0,0,0,0.65)"}}};(function(e){X(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="area",t}return r.getDefaultOptions=function(){return Qzt},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return Zzt},r})(Dt);var EG;(function(e){e.DEV="DEV",e.BETA="BETA",e.STABLE="STABLE"})(EG||(EG={}));$X("en-US",iDt);$X("zh-CN",nDt);var Wx=globalThis&&globalThis.__assign||function(){return Wx=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Wx.apply(this,arguments)};te("polygon","boundary-polygon",{draw:function(e,r){var t=r.addGroup(),i={stroke:"#fff",lineWidth:1,fill:e.color,paht:[]},n=e.points,a=[["M",n[0].x,n[0].y],["L",n[1].x,n[1].y],["L",n[2].x,n[2].y],["L",n[3].x,n[3].y],["Z"]];if(i.path=this.parsePath(a),t.addShape("path",{attrs:i}),I(e,"data.lastWeek")){var o=[["M",n[2].x,n[2].y],["L",n[3].x,n[3].y]];t.addShape("path",{attrs:{path:this.parsePath(o),lineWidth:4,stroke:"#404040"}}),I(e,"data.lastDay")&&t.addShape("path",{attrs:{path:this.parsePath([["M",n[1].x,n[1].y],["L",n[2].x,n[2].y]]),lineWidth:4,stroke:"#404040"}})}return t}});var Kzt=[{sourceKey:"colors",targetKey:"color",notice:"colors \u662F g2Plot@1.0 \u7684\u5C5E\u6027\uFF0C\u8BF7\u4F7F\u7528 color \u5C5E\u6027\u66FF\u4EE3"},{sourceKey:"valueField",targetKey:"colorField",notice:"valueField \u662F g2@1.0\u7684\u5C5E\u6027\uFF0C\u5373\u5C06\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528colorField\u66FF\u4EE3"},{sourceKey:"radiusField",targetKey:"yField",notice:"radiusField \u662F g2@1.0\u7684\u5C5E\u6027\uFF0C\u5373\u5C06\u5E9F\u5F03\uFF0C\u8BF7\u4F7F\u7528yFeild\u66FF\u4EE3"}],Jzt=Qt(ub,"CalendarChart",function(e){var r=He(e);return $a(Kzt,r),K(I(e,"shape"))&&jt(r,"shape","boundary-polygon"),K(I(r,"xField"))&&K(I(r,"yField"))&&(jt(r,"xField","week"),jt(r,"meta.week",Wx({type:"cat"},I(r,"meta.week",{}))),jt(r,"yField","day"),jt(r,"meta.day",{type:"cat",values:["Sun.","Mon.","Tues.","Wed.","Thur.","Fri.","Sat."]}),jt(r,"reflect","y"),jt(r,"xAxis",Wx({tickLine:null,line:null,title:null,label:{offset:20,style:{fontSize:12,fill:"#bbb",textBaseline:"top"},formatter:function(t){return t=="2"?"MAY":t==="6"?"JUN":t=="10"?"JUL":t==="14"?"AUG":t=="18"?"SEP":t==="24"?"OCT":""}}},I(r,"xAxis",{})))),r}),sI={},mh={},Ib={};(function(e){var r;Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_OPTIONS=e.RANGE_VIEW_ID=e.INDICATEOR_VIEW_ID=e.DEFAULT_COLOR=e.PERCENT=e.RANGE_TYPE=e.RANGE_VALUE=void 0,e.RANGE_VALUE="range",e.RANGE_TYPE="type",e.PERCENT="percent",e.DEFAULT_COLOR="#f0f0f0",e.INDICATEOR_VIEW_ID="indicator-view",e.RANGE_VIEW_ID="range-view",e.DEFAULT_OPTIONS={percent:0,range:{ticks:[]},innerRadius:.9,radius:.95,startAngle:-7/6*Math.PI,endAngle:1/6*Math.PI,syncViewPadding:!0,axis:{line:null,label:{offset:-24,style:{textAlign:"center",textBaseline:"middle"}},subTickLine:{length:-8},tickLine:{length:-12},grid:null},indicator:{pointer:{style:{lineWidth:5,lineCap:"round"}},pin:{style:{r:9.75,lineWidth:4.5,fill:"#fff"}}},statistic:{title:!1},meta:(r={},r[e.RANGE_VALUE]={sync:"v"},r[e.PERCENT]={sync:"v",tickCount:5,tickInterval:.2},r),animation:!1}})(Ib);var al={};Object.defineProperty(al,"__esModule",{value:!0});al.getRangeData=al.getIndicatorData=al.processRangeData=void 0;var G0=Y,sd=Ib;function pU(e,r){return e.map(function(t,i){var n;return n={},n[sd.RANGE_VALUE]=t-(e[i-1]||0),n[sd.RANGE_TYPE]=""+i,n[sd.PERCENT]=r,n}).filter(function(t){return!!t[sd.RANGE_VALUE]})}al.processRangeData=pU;function tVt(e){var r;return[(r={},r[sd.PERCENT]=G0.clamp(e,0,1),r)]}al.getIndicatorData=tVt;function eVt(e,r){var t=G0.get(r,["ticks"],[]),i=G0.size(t)?t:[0,G0.clamp(e,0,1),1];return pU(i,e)}al.getRangeData=eVt;Object.defineProperty(mh,"__esModule",{value:!0});mh.adaptor=mh.statistic=void 0;var FG=V,rVt=Y,ud=Qe,iVt=Lr,nVt=mg,pp=mt,Za=Ib,OG=al;function aVt(e){var r=e.chart,t=e.options,i=t.percent,n=t.range,a=t.radius,o=t.innerRadius,l=t.startAngle,s=t.endAngle,u=t.axis,c=t.indicator,f=t.gaugeStyle,h=t.type,v=t.meter,d=n.color,p=n.width;if(c){var x=OG.getIndicatorData(i),m=r.createView({id:Za.INDICATEOR_VIEW_ID});m.data(x),m.point().position(Za.PERCENT+"*1").shape(c.shape||"gauge-indicator").customInfo({defaultColor:r.getTheme().defaultColor,indicator:c}),m.coordinate("polar",{startAngle:l,endAngle:s,radius:o*a}),m.axis(Za.PERCENT,u),m.scale(Za.PERCENT,pp.pick(u,nVt.AXIS_META_CONFIG_KEYS))}var _=OG.getRangeData(i,t.range),b=r.createView({id:Za.RANGE_VIEW_ID});b.data(_);var w=rVt.isString(d)?[d,Za.DEFAULT_COLOR]:d,S=iVt.interval({chart:b,options:{xField:"1",yField:Za.RANGE_VALUE,seriesField:Za.RANGE_TYPE,rawFields:[Za.PERCENT],isStack:!0,interval:{color:w,style:f,shape:h==="meter"?"meter-gauge":null},args:{zIndexReversed:!0},minColumnWidth:p,maxColumnWidth:p}}).ext,M=S.geometry;return M.customInfo({meter:v}),b.coordinate("polar",{innerRadius:o,radius:a,startAngle:l,endAngle:s}).transpose(),e}function oVt(e){var r;return pp.flow(ud.scale((r={range:{min:0,max:1,maxLimit:1,minLimit:0}},r[Za.PERCENT]={},r)))(e)}function gU(e,r){var t=e.chart,i=e.options,n=i.statistic,a=i.percent;if(t.getController("annotation").clear(!0),n){var o=n.content,l=void 0;o&&(l=pp.deepAssign({},{content:(a*100).toFixed(2)+"%",style:{opacity:.75,fontSize:"30px",lineHeight:1,textAlign:"center",color:"rgba(44,53,66,0.85)"}},o)),pp.renderGaugeStatistic(t,{statistic:FG.__assign(FG.__assign({},n),{content:l})},{percent:a})}return r&&t.render(!0),e}mh.statistic=gU;function lVt(e){var r=e.chart;return r.legend(!1),r.tooltip(!1),e}function sVt(e){return pp.flow(ud.theme,ud.animation,aVt,oVt,gU,ud.interaction,ud.annotation(),lVt)(e)}mh.adaptor=sVt;var PG=V,uVt=me;uVt.registerShape("point","gauge-indicator",{draw:function(e,r){var t=e.customInfo,i=t.indicator,n=t.defaultColor,a=i,o=a.pointer,l=a.pin,s=r.addGroup(),u=this.parsePoint({x:0,y:0});return o&&s.addShape("line",{name:"pointer",attrs:PG.__assign({x1:u.x,y1:u.y,x2:e.x,y2:e.y,stroke:n},o.style)}),l&&s.addShape("circle",{name:"pin",attrs:PG.__assign({x:u.x,y:u.y,stroke:n},l.style)}),s}});var oA=me,cVt=Y;oA.registerShape("interval","meter-gauge",{draw:function(e,r){var t=e.customInfo.meter,i=t===void 0?{}:t,n=i.steps,a=n===void 0?50:n,o=i.stepRatio,l=o===void 0?.5:o;a=a<1?1:a,l=cVt.clamp(l,0,1);var s=this.coordinate,u=s.startAngle,c=s.endAngle,f=0;if(l>0&&l<1){var h=c-u;f=h/a/(l/(1-l)+1-1/a)}for(var v=f/(1-l)*l,d=r.addGroup(),p=this.coordinate.getCenter(),x=this.coordinate.getRadius(),m=oA.Util.getAngle(e,this.coordinate),_=m.startAngle,b=m.endAngle,w=_;w<b;){var S=void 0,M=(w-u)%(v+f);M<v?S=w+(v-M):(w+=v+f-M,S=w+v);var F=oA.Util.getSectorPath(p.x,p.y,x,w,Math.min(S,b),x*this.coordinate.innerRadius);d.addShape("path",{name:"meter-gauge",attrs:{path:F,fill:e.color,stroke:e.color,lineWidth:.5}}),w=S+f}return d}});Object.defineProperty(sI,"__esModule",{value:!0});var yU=sI.Gauge=void 0,fVt=V,Zc=me,hVt=ae,IG=mh,lA=Ib,LG=al,vVt=function(e){fVt.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="gauge",t}return r.getDefaultOptions=function(){return lA.DEFAULT_OPTIONS},r.prototype.changeData=function(t){this.chart.emit(Zc.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_DATA,Zc.Event.fromData(this.chart,Zc.VIEW_LIFE_CIRCLE.BEFORE_CHANGE_DATA,null)),this.updateOption({percent:t});var i=this.chart.views.find(function(a){return a.id===lA.INDICATEOR_VIEW_ID});i&&i.data(LG.getIndicatorData(t));var n=this.chart.views.find(function(a){return a.id===lA.RANGE_VIEW_ID});n&&n.data(LG.getRangeData(t,this.options.range)),IG.statistic({chart:this.chart,options:this.options},!0),this.chart.emit(Zc.VIEW_LIFE_CIRCLE.AFTER_CHANGE_DATA,Zc.Event.fromData(this.chart,Zc.VIEW_LIFE_CIRCLE.AFTER_CHANGE_DATA,null))},r.prototype.getDefaultOptions=function(){return r.getDefaultOptions()},r.prototype.getSchemaAdaptor=function(){return IG.adaptor},r}(hVt.Plot);yU=sI.Gauge=vVt;var rM=globalThis&&globalThis.__assign||function(){return rM=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},rM.apply(this,arguments)},dVt=globalThis&&globalThis.__rest||function(e,r){var t={};for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&r.indexOf(i)<0&&(t[i]=e[i]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var n=0,i=Object.getOwnPropertySymbols(e);n<i.length;n++)r.indexOf(i[n])<0&&Object.prototype.propertyIsEnumerable.call(e,i[n])&&(t[i[n]]=e[i[n]]);return t},pVt=Qt(yU,"GaugeChart",function(e){var r=He(e),t=r.range,i=r.min,n=i===void 0?0:i,a=r.max,o=a===void 0?1:a,l=r.value,s=dVt(r,["range","min","max","value"]);it(t)?s.range={ticks:t.map(function(h){return(h-n)/(o-n)}),color:rs().colors10}:s.range=t||{};var u=I(s,"color");if(K(u)||(s.range.color=u),K(I(s,"indicator"))&&jt(s,"indicator",{pointer:{style:{stroke:"#D0D0D0"}},pin:{style:{stroke:"#D0D0D0"}}}),I(s,"statistic.visible")&&jt(s,"statistic.title",I(s,"statistic")),!K(n)&&!K(o)&&!K(l)){s.percent=(l-n)/(o-n);var c=I(s,"axis.label.formatter");jt(s,"axis",{label:{formatter:function(h){var v=h*(o-n)+n;return pt(c)?c(v):v}}})}Df(!(I(s,"min")||I(s,"max"))),Df(!(I(s,"rangeSize")||I(s,"rangeStyle")||"rangeBackgroundStyle"));var f=K(s.percent)?l:s.percent;return rM({data:f},s)}),uI={},Fe={},Hi={},cI={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.DualAxesGeometry=e.AxisType=void 0,function(r){r.Left="Left",r.Right="Right"}(e.AxisType||(e.AxisType={})),function(r){r.Line="line",r.Column="column"}(e.DualAxesGeometry||(e.DualAxesGeometry={}))})(cI);var fI={};(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_RIGHT_YAXIS_CONFIG=e.DEFAULT_LEFT_YAXIS_CONFIG=e.DEFAULT_YAXIS_CONFIG=e.RIGHT_AXES_VIEW=e.LEFT_AXES_VIEW=void 0;var r=V;e.LEFT_AXES_VIEW="left-axes-view",e.RIGHT_AXES_VIEW="right-axes-view",e.DEFAULT_YAXIS_CONFIG={nice:!0,label:{autoHide:!0,autoRotate:!1}},e.DEFAULT_LEFT_YAXIS_CONFIG=r.__assign(r.__assign({},e.DEFAULT_YAXIS_CONFIG),{position:"left"}),e.DEFAULT_RIGHT_YAXIS_CONFIG=r.__assign(r.__assign({},e.DEFAULT_YAXIS_CONFIG),{position:"right",grid:null})})(fI);Object.defineProperty(Hi,"__esModule",{value:!0});Hi.getYAxisWithDefault=Hi.transformObjectToArray=Hi.getGeometryOption=Hi.isColumn=Hi.isLine=void 0;var gVt=V,Dd=Y,iM=mt,xh=cI,DG=fI;function yVt(e){return Dd.get(e,"geometry")===xh.DualAxesGeometry.Line}Hi.isLine=yVt;function mU(e){return Dd.get(e,"geometry")===xh.DualAxesGeometry.Column}Hi.isColumn=mU;function mVt(e,r,t){return mU(t)?iM.deepAssign({},{geometry:xh.DualAxesGeometry.Column,label:t.label&&t.isRange?{content:function(i){var n;return(n=i[r])===null||n===void 0?void 0:n.join("-")}}:void 0},t):gVt.__assign({geometry:xh.DualAxesGeometry.Line},t)}Hi.getGeometryOption=mVt;function xVt(e,r){var t=e[0],i=e[1];if(Dd.isArray(r)){var n=r[0],a=r[1];return[n,a]}var o=Dd.get(r,t),l=Dd.get(r,i);return[o,l]}Hi.transformObjectToArray=xVt;function _Vt(e,r){return r===xh.AxisType.Left?e===!1?!1:iM.deepAssign({},DG.DEFAULT_LEFT_YAXIS_CONFIG,e):r===xh.AxisType.Right?e===!1?!1:iM.deepAssign({},DG.DEFAULT_RIGHT_YAXIS_CONFIG,e):e}Hi.getYAxisWithDefault=_Vt;var Lb={};Object.defineProperty(Lb,"__esModule",{value:!0});Lb.getViewLegendItems=void 0;var Qc=Y,$G=me,kG=mt,RG=Hi;function bVt(e){var r=e.view,t=e.geometryOption,i=e.yField,n=e.legend,a=Qc.get(n,"marker"),o=kG.findGeometry(r,RG.isLine(t)?"line":"interval");if(!t.seriesField){var l=Qc.get(r,"options.scales."+i+".alias")||i,s=o.getAttribute("color"),u=r.getTheme().defaultColor;s&&(u=$G.Util.getMappingValue(s,l,Qc.get(s,["values",0],u)));var c=(Qc.isFunction(a)?a:!Qc.isEmpty(a)&&kG.deepAssign({},{style:{stroke:u,fill:u}},a))||(RG.isLine(t)?{symbol:function(h,v,d){return[["M",h-d,v],["L",h+d,v]]},style:{lineWidth:2,r:6,stroke:u}}:{symbol:"square",style:{fill:u}});return[{value:i,name:l,marker:c,isGeometry:!0,viewId:r.id}]}var f=o.getGroupAttributes();return Qc.reduce(f,function(h,v){var d=$G.Util.getLegendItems(r,o,v,r.getTheme(),a);return h.concat(d)},[])}Lb.getViewLegendItems=bVt;var Db={};Object.defineProperty(Db,"__esModule",{value:!0});Db.drawSingleGeometry=void 0;var Nn=V,wVt=Y,BG=Lr,fu=mt,CVt=Aa,NG=Hi;function SVt(e){var r=e.options,t=e.chart,i=r.geometryOption,n=i.isStack,a=i.color,o=i.seriesField,l=i.groupField,s=i.isGroup,u=["xField","yField"];if(NG.isLine(i)){BG.line(fu.deepAssign({},e,{options:Nn.__assign(Nn.__assign(Nn.__assign({},fu.pick(r,u)),i),{line:{color:i.color,style:i.lineStyle}})})),BG.point(fu.deepAssign({},e,{options:Nn.__assign(Nn.__assign(Nn.__assign({},fu.pick(r,u)),i),{point:i.point&&Nn.__assign({color:a,shape:"circle"},i.point)})}));var c=[];s&&c.push({type:"dodge",dodgeBy:l||o,customOffset:0}),n&&c.push({type:"stack"}),c.length&&wVt.each(t.geometries,function(f){f.adjust(c)})}return NG.isColumn(i)&&CVt.adaptor(fu.deepAssign({},e,{options:Nn.__assign(Nn.__assign(Nn.__assign({},fu.pick(r,u)),i),{widthRatio:i.columnWidthRatio,interval:Nn.__assign(Nn.__assign({},fu.pick(i,["color"])),{style:i.columnStyle})})})),e}Db.drawSingleGeometry=SVt;var $b={};Object.defineProperty($b,"__esModule",{value:!0});$b.doSliderFilter=void 0;var sA=Y,AVt=mt;$b.doSliderFilter=function(e,r){var t=r[0],i=r[1],n=e.getOptions().data,a=e.getXScale(),o=sA.size(n);if(!(!a||!o)){var l=sA.valuesOfKey(n,a.field),s=l,u=sA.size(s),c=Math.floor(t*(u-1)),f=Math.floor(i*(u-1));e.filter(a.field,function(h){var v=s.indexOf(h);return v>-1?AVt.isBetween(v,c,f):!0}),e.render(!0)}};Object.defineProperty(Fe,"__esModule",{value:!0});Fe.adaptor=Fe.slider=Fe.legend=Fe.limitInPlot=Fe.animation=Fe.theme=Fe.annotation=Fe.interaction=Fe.tooltip=Fe.axis=Fe.meta=Fe.color=Fe.transformOptions=void 0;var Gv=V,Gr=Y,bn=Qe,TVt=_n,Oi=mt,qe=Ko,Du=Hi,GG=Lb,MVt=Db,zG=$b,nM=cI,ze=fI;function xU(e){var r,t=e.options,i=t.geometryOptions,n=i===void 0?[]:i,a=t.xField,o=t.yField,l=Gr.every(n,function(s){var u=s.geometry;return u===nM.DualAxesGeometry.Line||u===void 0});return Oi.deepAssign({},{options:{geometryOptions:[],meta:(r={},r[a]={type:"cat",sync:!0,range:l?[0,1]:void 0},r),tooltip:{showMarkers:l,showCrosshairs:l,shared:!0,crosshairs:{type:"x"}},interactions:l?[{type:"legend-visible-filter"}]:[{type:"legend-visible-filter"},{type:"active-region"}],legend:{position:"top-left"}}},e,{options:{yAxis:Du.transformObjectToArray(o,t.yAxis),geometryOptions:[Du.getGeometryOption(a,o[0],n[0]),Du.getGeometryOption(a,o[1],n[1])],annotations:Du.transformObjectToArray(o,t.annotations)}})}Fe.transformOptions=xU;function EVt(e){var r,t,i=e.chart,n=e.options,a=n.geometryOptions,o={line:0,column:1},l=[{type:(r=a[0])===null||r===void 0?void 0:r.geometry,id:ze.LEFT_AXES_VIEW},{type:(t=a[1])===null||t===void 0?void 0:t.geometry,id:ze.RIGHT_AXES_VIEW}];return l.sort(function(s,u){return-o[s.type]+o[u.type]}).forEach(function(s){return i.createView({id:s.id})}),e}function FVt(e){var r=e.chart,t=e.options,i=t.xField,n=t.yField,a=t.geometryOptions,o=t.data,l=t.tooltip,s=[Gv.__assign(Gv.__assign({},a[0]),{id:ze.LEFT_AXES_VIEW,data:o[0],yField:n[0]}),Gv.__assign(Gv.__assign({},a[1]),{id:ze.RIGHT_AXES_VIEW,data:o[1],yField:n[1]})];return s.forEach(function(u){var c=u.id,f=u.data,h=u.yField,v=Du.isColumn(u)&&u.isPercent,d=v?TVt.percent(f,h,i,h):f,p=qe.findViewById(r,c).data(d),x=v?Gv.__assign({formatter:function(m){return{name:m[u.seriesField]||h,value:(Number(m[h])*100).toFixed(2)+"%"}}},l):l;MVt.drawSingleGeometry({chart:p,options:{xField:i,yField:h,tooltip:x,geometryOption:u}})}),e}function _U(e){var r,t=e.chart,i=e.options,n=i.geometryOptions,a=((r=t.getTheme())===null||r===void 0?void 0:r.colors10)||[],o=0;return t.once("beforepaint",function(){Gr.each(n,function(l,s){var u=qe.findViewById(t,s===0?ze.LEFT_AXES_VIEW:ze.RIGHT_AXES_VIEW);if(!l.color){var c=u.getGroupScales(),f=Gr.get(c,[0,"values","length"],1),h=a.slice(o,o+f).concat(s===0?[]:a);u.geometries.forEach(function(v){l.seriesField?v.color(l.seriesField,h):v.color(h[0])}),o+=f}}),t.render(!0)}),e}Fe.color=_U;function bU(e){var r,t,i=e.chart,n=e.options,a=n.xAxis,o=n.yAxis,l=n.xField,s=n.yField;return bn.scale((r={},r[l]=a,r[s[0]]=o[0],r))(Oi.deepAssign({},e,{chart:qe.findViewById(i,ze.LEFT_AXES_VIEW)})),bn.scale((t={},t[l]=a,t[s[1]]=o[1],t))(Oi.deepAssign({},e,{chart:qe.findViewById(i,ze.RIGHT_AXES_VIEW)})),e}Fe.meta=bU;function wU(e){var r=e.chart,t=e.options,i=qe.findViewById(r,ze.LEFT_AXES_VIEW),n=qe.findViewById(r,ze.RIGHT_AXES_VIEW),a=t.xField,o=t.yField,l=t.xAxis,s=t.yAxis;return r.axis(a,!1),r.axis(o[0],!1),r.axis(o[1],!1),i.axis(a,l),i.axis(o[0],Du.getYAxisWithDefault(s[0],nM.AxisType.Left)),n.axis(a,!1),n.axis(o[1],Du.getYAxisWithDefault(s[1],nM.AxisType.Right)),e}Fe.axis=wU;function CU(e){var r=e.chart,t=e.options,i=t.tooltip,n=qe.findViewById(r,ze.LEFT_AXES_VIEW),a=qe.findViewById(r,ze.RIGHT_AXES_VIEW);return r.tooltip(i),n.tooltip({shared:!0}),a.tooltip({shared:!0}),e}Fe.tooltip=CU;function SU(e){var r=e.chart;return bn.interaction(Oi.deepAssign({},e,{chart:qe.findViewById(r,ze.LEFT_AXES_VIEW)})),bn.interaction(Oi.deepAssign({},e,{chart:qe.findViewById(r,ze.RIGHT_AXES_VIEW)})),e}Fe.interaction=SU;function AU(e){var r=e.chart,t=e.options,i=t.annotations,n=Gr.get(i,[0]),a=Gr.get(i,[1]);return bn.annotation(n)(Oi.deepAssign({},e,{chart:qe.findViewById(r,ze.LEFT_AXES_VIEW),options:{annotations:n}})),bn.annotation(a)(Oi.deepAssign({},e,{chart:qe.findViewById(r,ze.RIGHT_AXES_VIEW),options:{annotations:a}})),e}Fe.annotation=AU;function TU(e){var r=e.chart;return bn.theme(Oi.deepAssign({},e,{chart:qe.findViewById(r,ze.LEFT_AXES_VIEW)})),bn.theme(Oi.deepAssign({},e,{chart:qe.findViewById(r,ze.RIGHT_AXES_VIEW)})),bn.theme(e),e}Fe.theme=TU;function MU(e){var r=e.chart;return bn.animation(Oi.deepAssign({},e,{chart:qe.findViewById(r,ze.LEFT_AXES_VIEW)})),bn.animation(Oi.deepAssign({},e,{chart:qe.findViewById(r,ze.RIGHT_AXES_VIEW)})),e}Fe.animation=MU;function EU(e){var r=e.chart,t=e.options,i=t.yAxis;return bn.limitInPlot(Oi.deepAssign({},e,{chart:qe.findViewById(r,ze.LEFT_AXES_VIEW),options:{yAxis:i[0]}})),bn.limitInPlot(Oi.deepAssign({},e,{chart:qe.findViewById(r,ze.RIGHT_AXES_VIEW),options:{yAxis:i[1]}})),e}Fe.limitInPlot=EU;function FU(e){var r=e.chart,t=e.options,i=t.legend,n=t.geometryOptions,a=t.yField,o=t.data,l=qe.findViewById(r,ze.LEFT_AXES_VIEW),s=qe.findViewById(r,ze.RIGHT_AXES_VIEW);if(i===!1)r.legend(!1);else if(Gr.isObject(i)&&i.custom===!0)r.legend(i);else{var u=Gr.get(n,[0,"legend"],i),c=Gr.get(n,[1,"legend"],i);r.once("beforepaint",function(){var f=o[0].length?GG.getViewLegendItems({view:l,geometryOption:n[0],yField:a[0],legend:u}):[],h=o[1].length?GG.getViewLegendItems({view:s,geometryOption:n[1],yField:a[1],legend:c}):[];r.legend(Oi.deepAssign({},i,{custom:!0,items:f.concat(h)}))}),n[0].seriesField&&l.legend(n[0].seriesField,u),n[1].seriesField&&s.legend(n[1].seriesField,c),r.on("legend-item:click",function(f){var h=Gr.get(f,"gEvent.delegateObject",{});if(h&&h.item){var v=h.item,d=v.value,p=v.isGeometry,x=v.viewId;if(p){var m=Gr.findIndex(a,function(w){return w===d});if(m>-1){var _=Gr.get(qe.findViewById(r,x),"geometries");Gr.each(_,function(w){w.changeVisible(!h.item.unchecked)})}}else{var b=Gr.get(r.getController("legend"),"option.items",[]);Gr.each(r.views,function(w){var S=w.getGroupScales();Gr.each(S,function(M){M.values&&M.values.indexOf(d)>-1&&w.filter(M.field,function(F){var O=Gr.find(b,function(L){return L.value===F});return!O.unchecked})}),r.render(!0)})}}})}return e}Fe.legend=FU;function OU(e){var r=e.chart,t=e.options,i=t.slider,n=qe.findViewById(r,ze.LEFT_AXES_VIEW),a=qe.findViewById(r,ze.RIGHT_AXES_VIEW);return i&&(n.option("slider",i),n.on("slider:valuechanged",function(o){var l=o.event,s=l.value,u=l.originValue;Gr.isEqual(s,u)||zG.doSliderFilter(a,s)}),r.once("afterpaint",function(){if(!Gr.isBoolean(i)){var o=i.start,l=i.end;(o||l)&&zG.doSliderFilter(a,[o,l])}})),e}Fe.slider=OU;function OVt(e){return Oi.flow(xU,EVt,TU,FVt,bU,wU,EU,CU,SU,AU,MU,_U,FU,OU)(e)}Fe.adaptor=OVt;Object.defineProperty(uI,"__esModule",{value:!0});var PU=uI.DualAxes=void 0,PVt=V,IVt=ae,LVt=mt,DVt=Fe,$Vt=function(e){PVt.__extends(r,e);function r(){var t=e!==null&&e.apply(this,arguments)||this;return t.type="dual-axes",t}return r.prototype.getDefaultOptions=function(){return LVt.deepAssign({},e.prototype.getDefaultOptions.call(this),{yAxis:[],syncViewPadding:!0})},r.prototype.getSchemaAdaptor=function(){return DVt.adaptor},r}(IVt.Plot);PU=uI.DualAxes=$Vt;var kVt=Qt(PU,"DualAxesChart"),RVt=Object.freeze(Object.defineProperty({__proto__:null,LineChart:HTt,TreemapChart:hEt,StepLineChart:vEt,BarChart:ZEt,StackedBarChart:QEt,GroupedBarChart:tFt,PercentStackedBarChart:eFt,RangeBarChart:rFt,AreaChart:cFt,StackedAreaChart:fFt,PercentStackedAreaChart:hFt,ColumnChart:wFt,GroupedColumnChart:SFt,StackedColumnChart:AFt,RangeColumnChart:TFt,PercentStackedColumnChart:MFt,PieChart:oOt,DensityHeatmapChart:MOt,HeatmapChart:FOt,WordCloudChart:uPt,RoseChart:MPt,FunnelChart:gIt,StackedRoseChart:xIt,GroupedRoseChart:wIt,RadarChart:GIt,LiquidChart:h2t,HistogramChart:I2t,DonutChart:D2t,WaterfallChart:rLt,ScatterChart:SLt,BubbleChart:ALt,BulletChart:zLt,CalendarChart:Jzt,GaugeChart:pVt,DualAxesChart:kVt},Symbol.toStringTag,{value:"Module"})),Xx=globalThis&&globalThis.__assign||function(){return Xx=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Xx.apply(this,arguments)};globalThis&&globalThis.__rest;Xx(Xx({},RVt),ETt);var $d=globalThis&&globalThis.__assign||function(){return $d=Object.assign||function(e){for(var r,t=1,i=arguments.length;t<i;t++){r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},$d.apply(this,arguments)};$d($d($d({},sz),Y0t),gj.Util);export{GVt as A,NVt as C,D2t as D,VVt as L,Yxt as T,zVt as a};
|