1"use strict";(globalThis.webpackChunkflabs_frontend||=[]).push([[429],{78427(t,e,i){var n=i(97730),r=/rgba?\(([\s.,0-9]+)\)/,a=/^l\s*\(\s*([\d.]+)\s*\)\s*(.*)/i,o=/^r\s*\(\s*([\d.]+)\s*,\s*([\d.]+)\s*,\s*([\d.]+)\s*\)\s*(.*)/i,s=/[\d.]+:(#[^\s]+|[^\)]+\))/gi,l=function(t,e,i,n){return t[n]+(e[n]-t[n])*i};function h(t){return"#"+g(t[0])+g(t[1])+g(t[2])}var p,u=function(t){return[parseInt(t.substr(1,2),16),parseInt(t.substr(3,2),16),parseInt(t.substr(5,2),16)]},g=function(t){var e=Math.round(t).toString(16);return 1===e.length?"0"+e:e},c=function(t){if("#"===t[0]&&7===t.length)return t;var e;p||((e=document.createElement("i")).title="Web Colour Picker",e.style.display="none",document.body.appendChild(e),p=e),p.style.color=t;var i=document.defaultView.getComputedStyle(p,"").getPropertyValue("color");return i=h(r.exec(i)[1].split(/\s*,\s*/).map(function(t){return Number(t)}))};const d={rgb2arr:u,gradient:function(t){var e=(0,n.Kg)(t)?t.split("-"):t,i=(0,n.Tj)(e,function(t){return u(-1===t.indexOf("#")?c(t):t)});return function(t){return function(t,e){var i=isNaN(Number(e))||e<0?0:e>1?1:Number(e),n=t.length-1,r=Math.floor(n*i),a=n*i-r,o=t[r],s=r===n?o:t[r+1];return h([l(o,s,a,0),l(o,s,a,1),l(o,s,a,2)])}(i,t)}},toRGB:(0,n.Bj)(c),toCSSGradient:function(t){if(/^[r,R,L,l]{1}[\s]*\(/.test(t)){var e,i=void 0;if("l"===t[0]){var r=+(l=a.exec(t))[1]+90;i=l[2],e="linear-gradient("+r+"deg, "}else if("r"===t[0]){var l;e="radial-gradient(",i=(l=o.exec(t))[4]}var h=i.match(s);return(0,n.__)(h,function(t,i){var n=t.split(":");e+=n[1]+" "+100*n[0]+"%",i!==h.length-1&&(e+=", ")}),e+=")"}return t}};i.d(e,["A",0,d])},18764(t,e,i){var n=i(37827),r=i(3768),a=i(97730),o={none:[],point:["x","y"],region:["start","end"],points:["points"],circle:["center","radius","startAngle","endAngle"]};const s=function(t){function e(e){var i=t.call(this,e)||this;return i.initCfg(),i}return(0,n.C6)(e,t),e.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}},e.prototype.clear=function(){},e.prototype.update=function(t){var e=this,i=this.get("defaultCfg")||{};(0,a.__)(t,function(t,n){var r=t;e.get(n)!==t&&((0,a.Gv)(t)&&i[n]&&(r=(0,a.VL)({},i[n],t)),e.set(n,r))}),this.updateInner(t),this.afterUpdate(t)},e.prototype.updateInner=function(t){},e.prototype.afterUpdate=function(t){(0,a.CJ)(t,"visible")&&(t.visible?this.show():this.hide()),(0,a.CJ)(t,"capture")&&this.setCapture(t.capture)},e.prototype.getLayoutBBox=function(){return this.getBBox()},e.prototype.getLocationType=function(){return this.get("locationType")},e.prototype.getOffset=function(){return{offsetX:this.get("offsetX"),offsetY:this.get("offsetY")}},e.prototype.setOffset=function(t,e){this.update({offsetX:t,offsetY:e})},e.prototype.setLocation=function(t){var e=(0,n.Cl)({},t);this.update(e)},e.prototype.getLocation=function(){var t=this,e={},i=this.get("locationType"),n=o[i];return(0,a.__)(n,function(i){e[i]=t.get(i)}),e},e.prototype.isList=function(){return!1},e.prototype.isSlider=function(){return!1},e.prototype.init=function(){},e.prototype.initCfg=function(){var t=this,e=this.get("defaultCfg");(0,a.__)(e,function(e,i){var n=t.get(i);if((0,a.Gv)(n)){var r=(0,a.VL)({},e,n);t.set(i,r)}})},e}(r.Base);i.d(e,["A",0,s])},68402(t,e,i){var n=i(37827),r=i(97730),a=i(95837),o=i(82256),s=i(63941),l=i(18764),h="update_status",p=["visible","t
1ip","delegateObject"],u=["container","group","shapesMap","isRegister","isUpdating","destroyed"],g=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,n.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,n.Cl)((0,n.Cl)({},e),{container:null,shapesMap:{},group:null,capture:!0,isRegister:!1,isUpdating:!1,isInit:!0})},e.prototype.remove=function(){this.clear(),this.get("group").remove()},e.prototype.clear=function(){this.get("group").clear(),this.set("shapesMap",{}),this.clearOffScreenCache(),this.set("isInit",!0)},e.prototype.getChildComponentById=function(t){var e=this.getElementById(t);return e&&e.get("component")},e.prototype.getElementById=function(t){return this.get("shapesMap")[t]},e.prototype.getElementByLocalId=function(t){var e=this.getElementId(t);return this.getElementById(e)},e.prototype.getElementsByName=function(t){var e=[];return(0,r.__)(this.get("shapesMap"),function(i){i.get("name")===t&&e.push(i)}),e},e.prototype.getContainer=function(){return this.get("container")},e.prototype.updateInner=function(t){this.offScreenRender(),this.get("updateAutoRender")&&this.render()},e.prototype.render=function(){var t=this.get("offScreenGroup");t||(t=this.offScreenRender());var e=this.get("group");this.updateElements(t,e),this.deleteElements(),this.applyOffset(),this.get("eventInitted")||(this.initEvent(),this.set("eventInitted",!0)),this.set("isInit",!1)},e.prototype.show=function(){this.get("group").show(),this.set("visible",!0)},e.prototype.hide=function(){this.get("group").hide(),this.set("visible",!1)},e.prototype.setCapture=function(t){this.get("group").set("capture",t),this.set("capture",t)},e.prototype.destroy=function(){this.removeEvent(),this.remove(),t.prototype.destroy.call(this)},e.prototype.getBBox=function(){return this.get("group").getCanvasBBox()},e.prototype.getLayoutBBox=function(){var t=this.get("group"),e=this.getInnerLayoutBBox(),i=t.getTotalMatrix();return i&&(e=(0,o.n4)(i,e)),e},e.prototype.on=function(t,e,i){return this.get("group").on(t,e,i),this},e.prototype.off=function(t,e){var i=this.get("group");return i&&i.off(t,e),this},e.prototype.emit=function(t,e){this.get("group").emit(t,e)},e.prototype.init=function(){t.prototype.init.call(this),this.get("group")||this.initGroup(),this.offScreenRender()},e.prototype.getInnerLayoutBBox=function(){return this.get("offScreenBBox")||this.get("group").getBBox()},e.prototype.delegateEmit=function(t,e){var i=this.get("group");e.target=i,i.emit(t,e),(0,a.E)(i,t,e)},e.prototype.createOffScreenGroup=function(){return new(this.get("group").getGroupBase())({delegateObject:this.getDelegateObject()})},e.prototype.applyOffset=function(){var t=this.get("offsetX"),e=this.get("offsetY");this.moveElementTo(this.get("group"),{x:t,y:e})},e.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()}))},e.prototype.offScreenRender=function(){this.clearOffScreenCache();var t=this.createOffScreenGroup();return this.renderInner(t),this.set("offScreenGroup",t),this.set("offScreenBBox",(0,s.MU)(t)),t},e.prototype.addGroup=function(t,e){this.appendDelegateObject(t,e);var i=t.addGroup(e);return this.get("isRegister")&&this.registerElement(i),i},e.prototype.addShape=function(t,e){this.appendDelegateObject(t,e);var i=t.addShape(e);return this.get("isRegister")&&this.registerElement(i),i},e.prototype.addComponent=function(t,e){var i=e.id,r=e.component,a=(0,n.Tt)(e,["id","component"]),o=new r((0,n.Cl)((0,n.Cl)({},a),{id:i,container:t,updateAutoRender:this.get("updateAutoRender")}));return o.init(),o.render(),this.get("isRegister")&&this.registerElement(o.get("group")),o},e.prototype.initEvent=function(){},e.prototype.removeEvent=function(){this.get("group").off()},e.prototype.getElementId=function(t){return this.get("id")+"-"+this.get("name")+"-"+t},e.prototype.registerElement=function(t){var e=t.get("id");this.get("shapesMap")[e]=t},e.prototype.unregisterElement=function(t){var e=t.get("id");delete this.get("shapesMap")[e]},e.prototype.moveElementTo=function(t,e){var i=(0,o.Jb)(e);t.attr("matrix",i)}
1,e.prototype.addAnimation=function(t,e,i){var n=e.attr("opacity");(0,r.gD)(n)&&(n=1),e.attr("opacity",0),e.animate({opacity:n},i)},e.prototype.removeAnimation=function(t,e,i){e.animate({opacity:0},i)},e.prototype.updateAnimation=function(t,e,i,n){e.animate(i,n)},e.prototype.updateElements=function(t,e){var i,n=this,a=this.get("animate"),o=this.get("animateOption"),l=t.getChildren().slice(0);(0,r.__)(l,function(t){var l=t.get("id"),g=n.getElementById(l),c=t.get("name");if(g)if(t.get("isComponent")){var d=t.get("component"),f=g.get("component"),y=(0,r.Up)(d.cfg,(0,r.iv)((0,r.HP)(d.cfg),u));f.update(y),g.set(h,"update")}else{var m=n.getReplaceAttrs(g,t);a&&o.update?n.updateAnimation(c,g,m,o.update):g.attr(m),t.isGroup()&&n.updateElements(t,g),(0,r.__)(p,function(e){g.set(e,t.get(e))}),(0,s.wi)(g,t),i=g,g.set(h,"update")}else{e.add(t);var v=e.getChildren();if(v.splice(v.length-1,1),i){var x=v.indexOf(i);v.splice(x+1,0,t)}else v.unshift(t);if(n.registerElement(t),t.set(h,"add"),t.get("isComponent"))(d=t.get("component")).set("container",e);else t.isGroup()&&n.registerNewGroup(t);if(i=t,a){var C=n.get("isInit")?o.appear:o.enter;C&&n.addAnimation(c,t,C)}}})},e.prototype.clearUpdateStatus=function(t){var e=t.getChildren();(0,r.__)(e,function(t){t.set(h,null)})},e.prototype.clearOffScreenCache=function(){var t=this.get("offScreenGroup");t&&t.destroy(),this.set("offScreenGroup",null),this.set("offScreenBBox",null)},e.prototype.getDelegateObject=function(){var t;return(t={})[this.get("name")]=this,t.component=this,t},e.prototype.appendDelegateObject=function(t,e){var i=t.get("delegateObject");e.delegateObject||(e.delegateObject={}),(0,r.jh)(e.delegateObject,i)},e.prototype.getReplaceAttrs=function(t,e){var i=t.attr(),n=e.attr();return(0,r.__)(i,function(t,e){void 0===n[e]&&(n[e]=void 0)}),n},e.prototype.registerNewGroup=function(t){var e=this,i=t.getChildren();(0,r.__)(i,function(t){e.registerElement(t),t.set(h,"add"),t.isGroup()&&e.registerNewGroup(t)})},e.prototype.deleteElements=function(){var t=this,e=this.get("shapesMap"),i=[];(0,r.__)(e,function(t,e){!t.get(h)||t.destroyed?i.push([e,t]):t.set(h,null)});var n=this.get("animate"),a=this.get("animateOption");(0,r.__)(i,function(i){var o=i[0],s=i[1];if(!s.destroyed){var l=s.get("name");if(n&&a.leave){var h=(0,r.jh)({callback:function(){t.removeElement(s)}},a.leave);t.removeAnimation(l,s,h)}else t.removeElement(s)}delete e[o]})},e.prototype.removeElement=function(t){if(t.get("isGroup")){var e=t.get("component");e&&e.destroy()}t.remove()},e}(l.A);const c=g;i.d(e,["A",0,c])},89740(t,e,i){var n=i(37827),r=i(33237),a=i(18468),o=i(97730),s=i(63941),l=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,n.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,n.Cl)((0,n.Cl)({},e),{container:null,containerTpl:"<div></div>",updateAutoRender:!0,containerClassName:"",parent:null})},e.prototype.getContainer=function(){return this.get("container")},e.prototype.show=function(){this.get("container").style.display="",this.set("visible",!0)},e.prototype.hide=function(){this.get("container").style.display="none",this.set("visible",!1)},e.prototype.setCapture=function(t){var e=t?"auto":"none";this.getContainer().style.pointerEvents=e,this.set("capture",t)},e.prototype.getBBox=function(){var t=this.getContainer(),e=parseFloat(t.style.left)||0,i=parseFloat(t.style.top)||0;return(0,s.qn)(e,i,t.clientWidth,t.clientHeight)},e.prototype.clear=function(){var t=this.get("container");(0,s.wE)(t)},e.prototype.destroy=function(){this.removeEvent(),this.removeDom(),t.prototype.destroy.call(this)},e.prototype.init=function(){t.prototype.init.call(this),this.initContainer(),this.initDom(),this.resetStyles(),this.applyStyles(),this.initEvent(),this.initCapture(),this.initVisible()},e.prototype.initCapture=function(){this.setCapture(this.get("capture"))},e.prototype.initVisible=function(){this.get("visible")?this.show():this.hide()},e.prototype.initDom=function(){},e.prototype.initContainer=function(){var t=this.get("container");if((0,o.gD)(t)){t=this.createDom();var e=this.get("parent");(0,o.Kg)(e)&&(e=document.getElementById(e),this.set("parent",e)),e.appendChild(t),this.get("containerId")&&t.setAttribute("id",this.get("containerId")),this.set("container",t)}else(0,o.Kg)(t)&&(t=document.getElementById(t),this.set("container",t));this.get("parent")||this.set("parent",t.parentNode)},e.prototype.resetStyles=function(){var t=this.get("domStyles"),e=this.get("defaultStyles");t=t?(0,o.VL)({},e,t):e,this.set("domStyles",t)},e.prototype.applyStyles=function(){var t=this.get("domStyles");if(t){var e=this.getContainer();this.applyChildrenStyles(e,t);var i=this.get("containerClassName");if(i&&(0,s.nB)(e,i)){var n=t[i];(0,a.A)(e,n)}}},e.prototype.applyChildrenStyles=function(t,e){(0,o.__)(e,function(e,i){var n=t.getElementsByClassName(i);(0,o.__)(n,function(t){(0,a.A)(t,e)})})},e.prototype.applyStyle=function(t,e){var i=this.get("domStyles");(0,a.A)(e,i[t])},e.prototype.createDom=function(){var t=this.get("containerTpl");return(0,r.A)(t)},e.prototype.initEvent=function(){},e.prototype.removeDom=function(){var t=this.get("container");t&&t.parentNode&&t.parentNode.removeChild(t)},e.prototype.removeEvent=function(){},e.prototype.updateInner=function(t){(0,o.CJ)(t,"domStyles")&&(this.resetStyles(),this.applyStyles()),this.resetPosition()},e.prototype.resetPosition=function(){},e}(i(18764).A);const h=l;i.d(e,["A",0,h])},6731(t,e,i){i.d(e,{Annotation:()=>n,Axis:()=>l,Crosshair:()=>h,Grid:()=>p,Legend:()=>u,Scrollbar:()=>oe,Slider:()=>ne,TOOLTIP_CSS_CONST:()=>le,Tooltip:()=>Zt,propagationDelegate:()=>se.E});var n={};i.r(n),i.d(n,{Arc:()=>B,DataMarker:()=>M,DataRegion:()=>P,Html:()=>J,Image:()=>w,Line:()=>x,Region:()=>A,RegionFilter:()=>R,Shape:()=>V,Text:()=>E});var r={};i.r(r),i.d(r,{ellipsisHead:()=>Q,ellipsisMiddle:()=>
1tt,ellipsisTail:()=>$,getDefault:()=>K});var a={};i.r(a),i.d(a,{equidistance:()=>ht,equidistanceWithReverseBoth:()=>pt,getDefault:()=>at,reserveBoth:()=>lt,reserveFirst:()=>ot,reserveLast:()=>st});var o={};i.r(o),i.d(o,{fixedAngle:()=>ct,getDefault:()=>gt,unfixedAngle:()=>dt});var s={};i.r(s),i.d(s,{autoEllipsis:()=>r,autoHide:()=>a,autoRotate:()=>o});var l={};i.r(l),i.d(l,{jl:()=>vt,N1:()=>yt});var h={};i.r(h),i.d(h,{Base:()=>Ct,Circle:()=>Bt,Html:()=>Tt,Line:()=>Et});var p={};i.r(p),i.d(p,{jl:()=>_t,N1:()=>Ot});var u={};i.r(u),i.d(u,{b7:()=>Gt,Wz:()=>Ut});var g=i(37827),c=i(97730),d=i(68402),f=i(65837),y=i(59724),m=i(63941),v=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,g.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{name:"annotation",type:"line",locationType:"region",start:null,end:null,style:{},text:null,defaultCfg:{style:{fill:y.A.textColor,fontSize:12,textAlign:"center",textBaseline:"bottom",fontFamily:y.A.fontFamily},text:{position:"center",autoRotate:!0,content:null,offsetX:0,offsetY:0,style:{stroke:y.A.lineColor,lineWidth:1}}}})},e.prototype.renderInner=function(t){this.renderLine(t),this.get("text")&&this.renderLabel(t)},e.prototype.renderLine=function(t){var e=this.get("start"),i=this.get("end"),n=this.get("style");this.addShape(t,{type:"line",id:this.getElementId("line"),name:"annotation-line",attrs:(0,g.Cl)({x1:e.x,y1:e.y,x2:i.x,y2:i.y},n)})},e.prototype.getLabelPoint=function(t,e,i){var n;return((n="start"===i?0:"center"===i?.5:(0,c.Kg)(i)&&-1!==i.indexOf("%")?parseInt(i,10)/100:(0,c.Et)(i)?i:1)>1||n<0)&&(n=1),{x:(0,m.mj)(t.x,e.x,n),y:(0,m.mj)(t.y,e.y,n)}},e.prototype.renderLabel=function(t){var e=this.get("text"),i=this.get("start"),n=this.get("end"),r=e.position,a=e.content,o=e.style,s=e.offsetX,l=e.offsetY,h=e.autoRotate,p=e.maxLength,u=e.autoEllipsis,g=e.ellipsisPosition,c=e.background,d=e.isVertical,y=void 0!==d&&d,m=this.getLabelPoint(i,n,r),v=m.x+s,x=m.y+l,C={id:this.getElementId("line-text"),name:"annotation-line-text",x:v,y:x,content:a,style:o,maxLength:p,autoEllipsis:u,ellipsisPosition:g,background:c,isVertical:y};if(h){var I=[n.x-i.x,n.y-i.y];C.rotate=Math.atan2(I[1],I[0])}(0,f.v)(t,C)},e}(d.A);const x=v;var C=i(82256),I=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,g.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{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:y.A.textColor,fontSize:12,textAlign:"center",textBaseline:"middle",fontFamily:y.A.fontFamily}}})},e.prototype.setLocation=function(t){this.set("x",t.x),this.set("y",t.y),this.resetLocation()},e.prototype.renderInner=function(t){var e=this.getLocation(),i=e.x,n=e.y,r=this.get("content"),a=this.get("style"),o={id:this.getElementId("text"),name:this.get("name")+"-text",x:i,y:n,content:r,style:a,maxLength:this.get("maxLength"),autoEllipsis:this.get("autoEllipsis"),isVertical:this.get("isVertical"),ellipsisPosition:this.get("ellipsisPosition"),background:this.get("background"),rotate:this.get("rotate")};(0,f.v)(t,o)},e.prototype.resetLocation=function(){var t=this.getElementByLocalId("text-group");if(t){var e=this.getLocation(),i=e.x,n=e.y,r=this.get("rotate");(0,C.T_)(t,i,n),(0,C.gB)(t,r,i,n)}},e}(d.A);const E=I;var b=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,g.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{name:"annotation",type:"arc",locationType:"circle",center:null,radius:100,startAngle:-Math.PI/2,endAngle:3*Math.PI/2,style:{stroke:"#999",lineWidth:1}})},e.prototype.renderInner=function(t){this.renderArc(t)},e.prototype.getArcPath=function(){var t=this.getLocation(),e=t.center,i=t.radius,n=t.startAngle,r=t.endAngle,a=(0,m.JJ)(e,i,n),o=(0,m.JJ)(e,i,r),s=r-n>Math.PI?1:0,l=[["M",a.x,a.y]];if(r-n===2*Math.PI){var h=(0,m.JJ)(e,i,n+Math.PI);l.push(["A",i,i,0,s,1,h.x,h.y]),l.push(["A",i,i,0,s,1,o.x,o.y])}else l.push(["A",i,i,0,s,1,o.x,o.y]);return l},e.prototype.renderArc=function(t){var e=this.getArcPath(),i=this.get("style");this.addShape(t,{type:"path",id:this.getElementId("arc"),name:"annotation-arc",attrs:(0,g.Cl)({path:e},i)})},e}(d.A);const B=b;var L=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,g.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{name:"annotation",type:"region",locationType:"region",start:null,end:null,
1style:{},defaultCfg:{style:{lineWidth:0,fill:y.A.regionColor,opacity:.4}}})},e.prototype.renderInner=function(t){this.renderRegion(t)},e.prototype.renderRegion=function(t){var e=this.get("start"),i=this.get("end"),n=this.get("style"),r=(0,m.$4)({start:e,end:i});this.addShape(t,{type:"rect",id:this.getElementId("region"),name:"annotation-region",attrs:(0,g.Cl)({x:r.x,y:r.y,width:r.width,height:r.height},n)})},e}(d.A);const A=L;var k=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,g.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{name:"annotation",type:"image",locationType:"region",start:null,end:null,src:null,style:{}})},e.prototype.renderInner=function(t){this.renderImage(t)},e.prototype.getImageAttrs=function(){var t=this.get("start"),e=this.get("end"),i=this.get("style"),n=(0,m.$4)({start:t,end:e}),r=this.get("src");return(0,g.Cl)({x:n.x,y:n.y,img:r,width:n.width,height:n.height},i)},e.prototype.renderImage=function(t){this.addShape(t,{type:"image",id:this.getElementId("image"),name:"annotation-image",attrs:this.getImageAttrs()})},e}(d.A);const w=k;var S=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,g.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{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:y.A.lineColor,lineWidth:1}},text:{content:"",display:!0,style:{fill:y.A.textColor,opacity:.65,fontSize:12,textAlign:"start",fontFamily:y.A.fontFamily}}}})},e.prototype.renderInner=function(t){(0,c.Jt)(this.get("line"),"display")&&this.renderLine(t),(0,c.Jt)(this.get("text"),"display")&&this.renderText(t),(0,c.Jt)(this.get("point"),"display")&&this.renderPoint(t),this.get("autoAdjust")&&this.autoAdjust(t)},e.prototype.applyOffset=function(){this.moveElementTo(this.get("group"),{x:this.get("x")+this.get("offsetX"),y:this.get("y")+this.get("offsetY")})},e.prototype.renderPoint=function(t){var e=this.getShapeAttrs().point;this.addShape(t,{type:"circle",id:this.getElementId("point"),name:"annotation-point",attrs:e})},e.prototype.renderLine=function(t){var e=this.getShapeAttrs().line;this.addShape(t,{type:"path",id:this.getElementId("line"),name:"annotation-line",attrs:e})},e.prototype.renderText=function(t){var e=this.getShapeAttrs().text,i=e.x,n=e.y,r=e.text,a=(0,g.Tt)(e,["x","y","text"]),o=this.get("text"),s=o.background,l=o.maxLength,h=o.autoEllipsis,p=o.isVertival,u=o.ellipsisPosition,c={x:i,y:n,id:this.getElementId("text"),name:"annotation-text",content:r,style:a,background:s,maxLength:l,autoEllipsis:h,isVertival:p,ellipsisPosition:u};(0,f.v)(t,c)},e.prototype.autoAdjust=function(t){var e=this.get("direction"),i=this.get("x"),n=this.get("y"),r=(0,c.Jt)(this.get("line"),"length",0),a=this.get("coordinateBBox"),o=t.getBBox(),s=o.minX,l=o.maxX,h=o.minY,p=o.maxY,u=t.findById(this.getElementId("text-group")),g=t.findById(this.getElementId("text")),d=t.findById(this.getElementId("line"));if(a&&u){var f=u.attr("x"),y=u.attr("y"),m=g.getCanvasBBox(),v=m.width,x=m.height,I=0,E=0;if(i+s<=a.minX)if("leftward"===e)I=1;else{var b=a.minX-(i+s);f=u.attr("x")+b}else if(i+l>=a.maxX)if("rightward"===e)I=-1;else{b=i+l-a.maxX;f=u.attr("x")-b}if(I&&(d&&d.attr("path",[["M",0,0],["L",r*I,0]]),f=(r+2+v)*I),n+h<=a.minY)if("upward"===e)E=1;else{b=a.minY-(n+h);y=u.attr("y")+b}else if(n+p>=a.maxY)if("downward"===e)E=-1;else{b=n+p-a.maxY;y=u.attr("y")-b}E&&(d&&d.attr("path",[["M",0,0],["L",0,r*E]]),y=(r+2+x)*E),f===u.attr("x")&&y===u.attr("y")||(0,C.T_)(u,f,y)}},e.prototype.getShapeAttrs=function(){var t=(0,c.Jt)(this.get("line"),"display"),e=(0,c.Jt)(this.get("point"),"style",{}),i=(0,c.Jt)(this.get("line"),"style",{}),n=(0,c.Jt)(this.get("text"),"style",{}),r=this.get("direction"),a=t?(0,c.Jt)(this.get("line"),"length",0):0,o=0,s=0,l="top",h="start";switch(r){case"upward":s=-1,l="bottom";break;case"downward":s=1,l="top";break;case"leftward":o=-1,h="end";break;case"rightward":o=1,h="start"}return{point:(0,g.Cl)({x:0,y:0},e),line:(0,g.Cl)({path:[["M",0,0],["L",a*o,a*s]]},i),text:(0,g.Cl)({x:(a+2)*o,y:(a+2)*s,text:(0,c.Jt)(this.get("text"),"content",""),textBaseline:l,textAlign:h},n)}},e}(d.A);const M=S;var T=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,g.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{name:"annotation",type:"dataRegion",locationType:"points",points:[],lineLength:0,region:{},text:{}
1,defaultCfg:{region:{style:{lineWidth:0,fill:y.A.regionColor,opacity:.4}},text:{content:"",style:{textAlign:"center",textBaseline:"bottom",fontSize:12,fill:y.A.textColor,fontFamily:y.A.fontFamily}}}})},e.prototype.renderInner=function(t){var e=(0,c.Jt)(this.get("region"),"style",{}),i=((0,c.Jt)(this.get("text"),"style",{}),this.get("lineLength")||0),n=this.get("points");if(n.length){var r=(0,m.K4)(n),a=[];a.push(["M",n[0].x,r.minY-i]),n.forEach(function(t){a.push(["L",t.x,t.y])}),a.push(["L",n[n.length-1].x,n[n.length-1].y-i]),this.addShape(t,{type:"path",id:this.getElementId("region"),name:"annotation-region",attrs:(0,g.Cl)({path:a},e)});var o=(0,g.Cl)({id:this.getElementId("text"),name:"annotation-text",x:(r.minX+r.maxX)/2,y:r.minY-i},this.get("text"));(0,f.v)(t,o)}},e}(d.A);const P=T;var D=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,g.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{name:"annotation",type:"regionFilter",locationType:"region",start:null,end:null,color:null,shape:[]})},e.prototype.renderInner=function(t){var e=this,i=this.get("start"),n=this.get("end"),r=this.addGroup(t,{id:this.getElementId("region-filter"),capture:!1});(0,c.__)(this.get("shapes"),function(t,i){var n=t.get("type"),a=(0,c.o8)(t.attr());e.adjustShapeAttrs(a),e.addShape(r,{id:e.getElementId("shape-"+n+"-"+i),capture:!1,type:n,attrs:a})});var a=(0,m.$4)({start:i,end:n});r.setClip({type:"rect",attrs:{x:a.minX,y:a.minY,width:a.width,height:a.height}})},e.prototype.adjustShapeAttrs=function(t){var e=this.get("color");t.fill&&(t.fill=t.fillStyle=e),t.stroke=t.strokeStyle=e},e}(d.A);const R=D;var _=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,g.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{name:"annotation",type:"shape",draw:c.lQ})},e.prototype.renderInner=function(t){var e=this.get("render");(0,c.Tn)(e)&&e(t)},e}(d.A);const V=_;var O=i(33237),H=i(40536),z=i(65486),F=i(18468),X=i(89740),Y=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,g.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{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})},e.prototype.render=function(){var t=this.getContainer(),e=this.get("html");(0,m.wE)(t);var i=(0,c.Tn)(e)?e(t):e;if((0,c.vq)(i))t.appendChild(i);else if((0,c.Kg)(i)||(0,c.Et)(i)){var n=(0,O.A)(""+i);n&&t.appendChild(n)}this.resetPosition()},e.prototype.resetPosition=function(){var t=this.getContainer(),e=this.getLocation(),i=e.x,n=e.y,r=this.get("alignX"),a=this.get("alignY"),o=this.get("offsetX"),s=this.get("offsetY"),l=(0,H.A)(t),h=(0,z.A)(t),p={x:i,y:n};"middle"===r?p.x-=Math.round(l/2):"right"===r&&(p.x-=Math.round(l)),"middle"===a?p.y-=Math.round(h/2):"bottom"===a&&(p.y-=Math.round(h)),o&&(p.x+=o),s&&(p.y+=s),(0,F.A)(t,{position:"absolute",left:p.x+"px",top:p.y+"px",zIndex:this.get("zIndex")})},e}(X.A);const J=Y;var j=i(93784),W=i(13628),G=i(40360),N=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,g.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{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:y.A.lineColor}},tickLine:{style:{lineWidth:1,stroke:y.A.lineColor},alignTick:!0,length:5,displayWithLabel:!0},subTickLine:{style:{lineWidth:1,stroke:y.A.lineColor},count:4,length:2},label:{autoRotate:!0,autoHide:!1,autoEllipsis:!1,style:{fontSize:12,fill:y.A.textColor,fontFamily:y.A.fontFamily,fontWeight:"normal"},offset:10,offsetX:0,offsetY:0},title:{autoRotate:!0,spacing:5,position:"center",style:{fontSize:12,fill:y.A.textColor,textBaseline:"middle",fontFamily:y.A.fontFamily,textAlign:"center"},iconStyle:{fill:y.A.descriptionIconFill,stroke:y.A.descriptionIconStroke},description:""},tickStates:{active:{labelStyle:{fontWeight:500},tickLineStyle:{lineWidth:2}},inactive:{labelStyle:{fill:y.A.uncheckedColor}}},optimize:{enable:!0,threshold:400}},theme:{}})},e.prototype.renderInner=function(t){this.get("line")&&this.drawLine(t),this.drawTicks(t),this.get("title")&&this.drawTitle(t)},e.prototype.isList=function(){return!0},e.prototype.getItems=function(){return this.get("ticks")},e.prototype.setItems=function(t){this.update({ticks:t})},e.prototype.updateItem=function(t,e){(0,c.jh)(t,e),this.clear(),this.render()},e.prototype.clearItems=function(){var t=this.getElementByLocalId("label-group");t&&t.clear()}
1,e.prototype.setItemState=function(t,e,i){t[e]=i,this.updateTickStates(t)},e.prototype.hasState=function(t,e){return!!t[e]},e.prototype.getItemStates=function(t){var e=this.get("tickStates"),i=[];return(0,c.__)(e,function(e,n){t[n]&&i.push(n)}),i},e.prototype.clearItemsState=function(t){var e=this,i=this.getItemsByState(t);(0,c.__)(i,function(i){e.setItemState(i,t,!1)})},e.prototype.getItemsByState=function(t){var e=this,i=this.getItems();return(0,c.pb)(i,function(i){return e.hasState(i,t)})},e.prototype.getSidePoint=function(t,e){var i=this.getSideVector(e,t);return{x:t.x+i[0],y:t.y+i[1]}},e.prototype.getTextAnchor=function(t){var e;return(0,c.YX)(t[0],0)?e="center":t[0]>0?e="start":t[0]<0&&(e="end"),e},e.prototype.getTextBaseline=function(t){var e;return(0,c.YX)(t[1],0)?e="middle":t[1]>0?e="top":t[1]<0&&(e="bottom"),e},e.prototype.processOverlap=function(t){},e.prototype.drawLine=function(t){var e=this.getLinePath(),i=this.get("line");this.addShape(t,{type:"path",id:this.getElementId("line"),name:"axis-line",attrs:(0,c.jh)({path:e},i.style)})},e.prototype.getTickLineItems=function(t){var e=this,i=[],n=this.get("tickLine"),r=n.alignTick,a=n.length,o=1;return t.length>=2&&(o=t[1].value-t[0].value),(0,c.__)(t,function(t){var n=t.point;r||(n=e.getTickPoint(t.value-o/2));var s=e.getSidePoint(n,a);i.push({startPoint:n,tickValue:t.value,endPoint:s,tickId:t.id,id:"tickline-"+t.id})}),i},e.prototype.getSubTickLineItems=function(t){var e=[],i=this.get("subTickLine"),n=i.count,r=t.length;if(r>=2)for(var a=0;a<r-1;a++)for(var o=t[a],s=t[a+1],l=0;l<n;l++){var h=(l+1)/(n+1),p=(1-h)*o.tickValue+h*s.tickValue,u=this.getTickPoint(p),g=this.getSidePoint(u,i.length);e.push({startPoint:u,endPoint:g,tickValue:p,id:"sub-"+o.id+"-"+l})}return e},e.prototype.getTickLineAttrs=function(t,e,i,n){var r=this.get(e).style,a={points:[t.startPoint,t.endPoint]},o=(0,c.Jt)(this.get("theme"),["tickLine","style"],{});r=(0,c.Tn)(r)?(0,c.jh)({},o,r(a,i,n)):r;var s=t.startPoint,l=t.endPoint;return(0,g.Cl)({x1:s.x,y1:s.y,x2:l.x,y2:l.y},r)},e.prototype.drawTick=function(t,e,i,n,r){this.addShape(e,{type:"line",id:this.getElementId(t.id),name:"axis-"+i,attrs:this.getTickLineAttrs(t,i,n,r)})},e.prototype.drawTickLines=function(t){var e=this,i=this.get("ticks"),n=this.get("subTickLine"),r=this.getTickLineItems(i),a=this.addGroup(t,{name:"axis-tickline-group",id:this.getElementId("tickline-group")}),o=this.get("tickLine");if((0,c.__)(r,function(i,n){if(o.displayWithLabel){var s=e.getElementId("label-"+i.tickId);t.findById(s)&&e.drawTick(i,a,"tickLine",n,r)}else e.drawTick(i,a,"tickLine",n,r)}),n){var s=this.getSubTickLineItems(r);(0,c.__)(s,function(t,i){e.drawTick(t,a,"subTickLine",i,s)})}},e.prototype.processTicks=function(){var t=this,e=this.get("ticks");(0,c.__)(e,function(e){e.point=t.getTickPoint(e.value),(0,c.gD)(e.id)&&(e.id=e.name)})},e.prototype.drawTicks=function(t){var e=this;this.optimizeTicks(),this.processTicks(),this.get("label")&&this.drawLabels(t),this.get("tickLine")&&this.drawTickLines(t);var i=this.get("ticks");(0,c.__)(i,function(i){e.applyTickStates(i,t)})},e.prototype.optimizeTicks=function(){var t=this.get("optimize"),e=this.get("ticks");if(t&&t.enable&&t.threshold>0){var i=(0,c.Ej)(e);if(i>t.threshold){var n=Math.ceil(i/t.threshold),r=e.filter(function(t,e){return e%n===0});this.set("ticks",r),this.set("originalTicks",e)}}},e.prototype.getLabelAttrs=function(t,e,i){var n=this.get("label"),r=n.offset,a=n.offsetX,o=n.offsetY,s=n.rotate,l=n.formatter,h=this.getSidePoint(t.point,r),p=this.getSideVector(r,h),u=l?l(t.name,t,e):t.name,g=n.style;g=(0,c.Tn)(g)?(0,c.Jt)(this.get("theme"),["label","style"],{}):g;var d=(0,c.jh)({x:h.x+a,y:h.y+o,text:u,textAlign:this.getTextAnchor(p),textBaseline:this.getTextBaseline(p)},g);return s&&(d.matrix=(0,C.cw)(h,s)),d},e.prototype.drawLabels=function(t){var e=this,i=this.get("ticks"),n=this.addGroup(t,{name:"axis-label-group",id:this.getElementId("label-group")});(0,c.__)(i,function(t,r){e.addShape(n,{type:"text",name:"axis-label",id:e.getElementId("label-"+t.id),attrs:e.getLabelAttrs(t,r,i),delegateObject:{tick:t,item:t,
1index:r}})}),this.processOverlap(n);var r=n.getChildren(),a=(0,c.Jt)(this.get("theme"),["label","style"],{}),o=this.get("label"),s=o.style,l=o.formatter;if((0,c.Tn)(s)){var h=r.map(function(t){return(0,c.Jt)(t.get("delegateObject"),"tick")});(0,c.__)(r,function(t,e){var i=t.get("delegateObject").tick,n=l?l(i.name,i,e):i.name,r=(0,c.jh)({},a,s(n,e,h));t.attr(r)})}},e.prototype.getTitleAttrs=function(){var t=this.get("title"),e=t.style,i=t.position,n=t.offset,r=t.spacing,a=void 0===r?0:r,o=t.autoRotate,s=e.fontSize,l=.5;"start"===i?l=0:"end"===i&&(l=1);var h=this.getTickPoint(l),p=this.getSidePoint(h,n||a+s/2),u=(0,c.jh)({x:p.x,y:p.y,text:t.text},e),g=t.rotate,d=g;if((0,c.gD)(g)&&o){var f=this.getAxisVector(h);d=W.LL(f,[1,0],!0)}if(d){var y=(0,C.cw)(p,d);u.matrix=y}return u},e.prototype.drawTitle=function(t){var e,i=this.getTitleAttrs(),n=this.addShape(t,{type:"text",id:this.getElementId("title"),name:"axis-title",attrs:i});(null===(e=this.get("title"))||void 0===e?void 0:e.description)&&this.drawDescriptionIcon(t,n,i.matrix)},e.prototype.drawDescriptionIcon=function(t,e,i){var n=this.addGroup(t,{name:"axis-description",id:this.getElementById("description")}),r=e.getBBox(),a=r.maxX,o=r.maxY,s=r.height,l=this.get("title").iconStyle,h=s/2,p=h/6,u=a+4,c=o-s/2,d=[u+h,c-h],f=d[0],y=d[1],m=[f+h,y+h],v=m[0],x=m[1],C=[f,x+h],I=C[0],E=C[1],b=[u,y+h],B=b[0],L=b[1],A=[u+h,c-s/4],k=A[0],w=A[1],S=[k,w+p],M=S[0],T=S[1],P=[M,T+p],D=P[0],R=P[1],_=[D,R+3*h/4],V=_[0],O=_[1];this.addShape(n,{type:"path",id:this.getElementId("title-description-icon"),name:"axis-title-description-icon",attrs:(0,g.Cl)({path:[["M",f,y],["A",h,h,0,0,1,v,x],["A",h,h,0,0,1,I,E],["A",h,h,0,0,1,B,L],["A",h,h,0,0,1,f,y],["M",k,w],["L",M,T],["M",D,R],["L",V,O]],lineWidth:p,matrix:i},l)}),this.addShape(n,{type:"rect",id:this.getElementId("title-description-rect"),name:"axis-title-description-rect",attrs:{x:u,y:c-s/2,width:s,height:s,stroke:"#000",fill:"#000",opacity:0,matrix:i,cursor:"pointer"}})},e.prototype.applyTickStates=function(t,e){if(this.getItemStates(t).length){var i=this.get("tickStates"),n=this.getElementId("label-"+t.id),r=e.findById(n);if(r){var a=(0,G.u)(t,"label",i);a&&r.attr(a)}var o=this.getElementId("tickline-"+t.id),s=e.findById(o);if(s){var l=(0,G.u)(t,"tickLine",i);l&&s.attr(l)}}},e.prototype.updateTickStates=function(t){var e=this.getItemStates(t),i=this.get("tickStates"),n=this.get("label"),r=this.getElementByLocalId("label-"+t.id),a=this.get("tickLine"),o=this.getElementByLocalId("tickline-"+t.id);if(e.length){if(r){var s=(0,G.u)(t,"label",i);s&&r.attr(s)}if(o){var l=(0,G.u)(t,"tickLine",i);l&&o.attr(l)}}else r&&r.attr(n.style),o&&o.attr(a.style)},e}(d.A);const U=N;var Z=i(23105);function q(t,e,i,n){var r=e.getChildren(),a=!1;return(0,c.__)(r,function(e){var r=(0,Z.A9)(t,e,i,n);a=a||r}),a}function K(){return $}function Q(t,e,i){return q(t,e,i,"head")}function $(t,e,i){return q(t,e,i,"tail")}function tt(t,e,i){return q(t,e,i,"middle")}function et(t){var e=function(t){var e=t.attr("matrix");return e&&1!==e[0]}(t)?(0,C.St)(t.attr("matrix")):0;return e%360}function it(t,e,i,n){var r=!1,a=et(e),o=t?Math.abs(i.attr("y")-e.attr("y")):Math.abs(i.attr("x")-e.attr("x")),s=(t?i.attr("y")>e.attr("y"):i.attr("x")>e.attr("x"))?e.getBBox():i.getBBox();if(t){var l=Math.abs(Math.cos(a));r=(0,m.Zh)(l,0,Math.PI/180)?s.width+n>o:s.height/l+n>o}else{l=Math.abs(Math.sin(a));r=(0,m.Zh)(l,0,Math.PI/180)?s.width+n>o:s.height/l+n>o}return r}function nt(t,e,i,n){var r=(null==n?void 0:n.minGap)||0,a=e.getChildren().slice().filter(function(t){return t.get("visible")});if(!a.length)return!1;var o=!1;i&&a.reverse();for(var s=a.length,l=a[0],h=1;h<s;h++){var p=a[h];p.getBBox();it(t,l,p,r)?(p.hide(),o=!0):l=p}return o}function rt(t,e,i){var n=(null==i?void 0:i.minGap)||0,r=e.getChildren().slice();if(r.length<2)return!1;var a=!1,o=r[0],s=o.getBBox(),l=r[1],h=r.length,p=et(o),u=t?Math.abs(l.attr("y")-o.attr("y")):Math.abs(l.attr("x")-o.attr("x")),g=0;if(t){var c=Math.abs(Math.cos(p));if((0,m.Zh)(c,0,Math.PI/180))g=((0,Z.Zm)(r)+n)/u;else g=(s.height/c+n)/u}else{c=Math.abs(Math.sin(p));
1if((0,m.Zh)(c,0,Math.PI/180))g=((0,Z.Zm)(r)+n)/u;else g=(s.height/c+n)/u}if(g>1){g=Math.ceil(g);for(var d=0;d<h;d++)d%g!==0&&(r[d].hide(),a=!0)}return a}function at(){return ht}function ot(t,e,i,n){return nt(t,e,!1,n)}function st(t,e,i,n){return nt(t,e,!0,n)}function lt(t,e,i,n){var r=(null==n?void 0:n.minGap)||0,a=e.getChildren().slice();if(a.length<=2)return!1;for(var o=!1,s=a.length,l=a[0],h=a[s-1],p=l,u=1;u<s-1;u++){var g=a[u];g.getBBox();it(t,p,g,r)?(g.hide(),o=!0):p=g}return it(t,p,h,r)&&(p.hide(),o=!0),o}function ht(t,e,i,n){var r=rt(t,e,n);return nt(t,e,!1)&&(r=!0),r}function pt(t,e,i,n){var r=e.getChildren().slice(),a=rt(t,e,n);if(r.length>2){var o=r[0],s=r[r.length-1];o.get("visible")||(o.show(),nt(t,e,!1,n)&&(a=!0)),s.get("visible")||(s.show(),nt(t,e,!0,n)&&(a=!0))}return a}function ut(t,e,i,n){var r=e.getChildren();if(!r.length)return!1;if(!t&&r.length<2)return!1;var a=(0,Z.Zm)(r),o=!1;t?o=!!i&&a>i:o=a>Math.abs(r[1].attr("x")-r[0].attr("x"));o&&function(t,e){(0,c.__)(t,function(t){var i=t.attr("x"),n=t.attr("y"),r=(0,C.cw)({x:i,y:n},e);t.attr("matrix",r)})}(r,n(i,a));return o}function gt(){return ct}function ct(t,e,i,n){return ut(t,e,i,function(){return(0,c.Et)(n)?n:t?y.A.verticalAxisRotate:y.A.horizontalAxisRotate})}function dt(t,e,i){return ut(t,e,i,function(e,i){if(!e)return t?y.A.verticalAxisRotate:y.A.horizontalAxisRotate;if(t)return-Math.acos(e/i);var n=0;return(e>i||(n=Math.asin(e/i))>Math.PI/4)&&(n=Math.PI/4),n})}var ft=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,g.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{type:"line",locationType:"region",start:null,end:null})},e.prototype.getLinePath=function(){var t=this.get("start"),e=this.get("end"),i=[];return i.push(["M",t.x,t.y]),i.push(["L",e.x,e.y]),i},e.prototype.getInnerLayoutBBox=function(){var e=this.get("start"),i=this.get("end"),n=t.prototype.getInnerLayoutBBox.call(this),r=Math.min(e.x,i.x,n.x),a=Math.min(e.y,i.y,n.y),o=Math.max(e.x,i.x,n.maxX),s=Math.max(e.y,i.y,n.maxY);return{x:r,y:a,minX:r,minY:a,maxX:o,maxY:s,width:o-r,height:s-a}},e.prototype.isVertical=function(){var t=this.get("start"),e=this.get("end");return(0,c.YX)(t.x,e.x)},e.prototype.isHorizontal=function(){var t=this.get("start"),e=this.get("end");return(0,c.YX)(t.y,e.y)},e.prototype.getTickPoint=function(t){var e=this.get("start"),i=this.get("end"),n=i.x-e.x,r=i.y-e.y;return{x:e.x+n*t,y:e.y+r*t}},e.prototype.getSideVector=function(t){var e=this.getAxisVector(),i=j.S8([0,0],e),n=this.get("verticalFactor"),r=[i[1],-1*i[0]];return j.hs([0,0],r,t*n)},e.prototype.getAxisVector=function(){var t=this.get("start"),e=this.get("end");return[e.x-t.x,e.y-t.y]},e.prototype.processOverlap=function(t){var e=this,i=this.isVertical(),n=this.isHorizontal();if(i||n){var r=this.get("label"),a=this.get("title"),o=this.get("verticalLimitLength"),s=r.offset,l=o,h=0,p=0;a&&(h=a.style.fontSize,p=a.spacing),l&&(l=l-s-p-h);var u=this.get("overlapOrder");if((0,c.__)(u,function(i){r[i]&&e.canProcessOverlap(i)&&e.autoProcessOverlap(i,r[i],t,l)}),a&&(0,c.gD)(a.offset)){var g=t.getCanvasBBox(),d=i?g.width:g.height;a.offset=s+d+p+h/2}}},e.prototype.canProcessOverlap=function(t){var e=this.get("label");return"autoRotate"!==t||(0,c.gD)(e.rotate)},e.prototype.autoProcessOverlap=function(t,e,i,n){var r=this,a=this.isVertical(),o=!1,l=s[t];if(!0===e){this.get("label");o=l.getDefault()(a,i,n)}else if((0,c.Tn)(e))o=e(a,i,n);else if((0,c.Gv)(e)){var h=e;l[h.type]&&(o=l[h.type](a,i,n,h.cfg))}else l[e]&&(o=l[e](a,i,n));if("autoRotate"===t){if(o){var p=i.getChildren(),u=this.get("verticalFactor");(0,c.__)(p,function(t){if("center"===t.attr("textAlign")){var e=u>0?"end":"start";t.attr("textAlign",e)}})}}else if("autoHide"===t){var g=i.getChildren().slice(0);(0,c.__)(g,function(t){t.get("visible")||(r.get("isRegister")&&r.unregisterElement(t),t.remove())})}},e}(U);const yt=ft;var mt=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,g.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{type:"circle",locationType:"circle",center:null,radius:null,
1startAngle:-Math.PI/2,endAngle:3*Math.PI/2})},e.prototype.getLinePath=function(){var t=this.get("center"),e=t.x,i=t.y,n=this.get("radius"),r=n,a=this.get("startAngle"),o=this.get("endAngle"),s=[];if(Math.abs(o-a)===2*Math.PI)s=[["M",e,i-r],["A",n,r,0,1,1,e,i+r],["A",n,r,0,1,1,e,i-r],["Z"]];else{var l=this.getCirclePoint(a),h=this.getCirclePoint(o),p=Math.abs(o-a)>Math.PI?1:0,u=a>o?0:1;s=[["M",e,i],["L",l.x,l.y],["A",n,r,0,p,u,h.x,h.y],["L",e,i]]}return s},e.prototype.getTickPoint=function(t){var e=this.get("startAngle"),i=e+(this.get("endAngle")-e)*t;return this.getCirclePoint(i)},e.prototype.getSideVector=function(t,e){var i=this.get("center"),n=[e.x-i.x,e.y-i.y],r=this.get("verticalFactor"),a=j.Bw(n);return j.hs(n,n,r*t/a),n},e.prototype.getAxisVector=function(t){var e=this.get("center"),i=[t.x-e.x,t.y-e.y];return[i[1],-1*i[0]]},e.prototype.getCirclePoint=function(t,e){var i=this.get("center");return e=e||this.get("radius"),{x:i.x+Math.cos(t)*e,y:i.y+Math.sin(t)*e}},e.prototype.canProcessOverlap=function(t){var e=this.get("label");return"autoRotate"!==t||(0,c.gD)(e.rotate)},e.prototype.processOverlap=function(t){var e=this,i=this.get("label"),n=this.get("title"),r=this.get("verticalLimitLength"),a=i.offset,o=r,s=0,l=0;n&&(s=n.style.fontSize,l=n.spacing),o&&(o=o-a-l-s);var h=this.get("overlapOrder");if((0,c.__)(h,function(n){i[n]&&e.canProcessOverlap(n)&&e.autoProcessOverlap(n,i[n],t,o)}),n&&(0,c.gD)(n.offset)){var p=t.getCanvasBBox().height;n.offset=a+p+l+s/2}},e.prototype.autoProcessOverlap=function(t,e,i,n){var r=this,a=!1,o=s[t];if(n>0)if(!0===e)a=o.getDefault()(!1,i,n);else if((0,c.Tn)(e))a=e(!1,i,n);else if((0,c.Gv)(e)){var l=e;o[l.type]&&(a=o[l.type](!1,i,n,l.cfg))}else o[e]&&(a=o[e](!1,i,n));if("autoRotate"===t){if(a){var h=i.getChildren(),p=this.get("verticalFactor");(0,c.__)(h,function(t){if("center"===t.attr("textAlign")){var e=p>0?"end":"start";t.attr("textAlign",e)}})}}else if("autoHide"===t){var u=i.getChildren().slice(0);(0,c.__)(u,function(t){t.get("visible")||(r.get("isRegister")&&r.unregisterElement(t),t.remove())})}},e}(U);const vt=mt;var xt=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,g.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{name:"crosshair",type:"base",line:{},text:null,textBackground:{},capture:!1,defaultCfg:{line:{style:{lineWidth:1,stroke:y.A.lineColor}},text:{position:"start",offset:10,autoRotate:!1,content:null,style:{fill:y.A.textColor,textAlign:"center",textBaseline:"middle",fontFamily:y.A.fontFamily}},textBackground:{padding:5,style:{stroke:y.A.lineColor}}}})},e.prototype.renderInner=function(t){this.get("line")&&this.renderLine(t),this.get("text")&&(this.renderText(t),this.renderBackground(t))},e.prototype.renderText=function(t){var e=this.get("text"),i=e.style,n=e.autoRotate,r=e.content;if(!(0,c.gD)(r)){var a=this.getTextPoint(),o=null;if(n){var s=this.getRotateAngle();o=(0,C.cw)(a,s)}this.addShape(t,{type:"text",name:"crosshair-text",id:this.getElementId("text"),attrs:(0,g.Cl)((0,g.Cl)((0,g.Cl)({},a),{text:r,matrix:o}),i)})}},e.prototype.renderLine=function(t){var e=this.getLinePath(),i=this.get("line").style;this.addShape(t,{type:"path",name:"crosshair-line",id:this.getElementId("line"),attrs:(0,g.Cl)({path:e},i)})},e.prototype.renderBackground=function(t){var e=this.getElementId("text"),i=t.findById(e),n=this.get("textBackground");if(n&&i){var r=i.getBBox(),a=(0,m.FZ)(n.padding),o=n.style;this.addShape(t,{type:"rect",name:"crosshair-text-background",id:this.getElementId("text-background"),attrs:(0,g.Cl)({x:r.x-a[3],y:r.y-a[0],width:r.width+a[1]+a[3],height:r.height+a[
10]+a[2],matrix:i.attr("matrix")},o)}).toBack()}},e}(d.A);const Ct=xt;var It=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,g.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{type:"line",locationType:"region",start:null,end:null})},e.prototype.getRotateAngle=function(){var t=this.getLocation(),e=t.start,i=t.end,n=this.get("text").position,r=Math.atan2(i.y-e.y,i.x-e.x);return"start"===n?r-Math.PI/2:r+Math.PI/2},e.prototype.getTextPoint=function(){var t=this.getLocation(),e=t.start,i=t.end,n=this.get("text"),r=n.position,a=n.offset;return(0,m.E2)(e,i,r,a)},e.prototype.getLinePath=function(){var t=this.getLocation(),e=t.start,i=t.end;return[["M",e.x,e.y],["L",i.x,i.y]]},e}(Ct);const Et=It;var bt=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,g.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{type:"circle",locationType:"circle",center:null,radius:100,startAngle:-Math.PI/2,endAngle:3*Math.PI/2})},e.prototype.getRotateAngle=function(){var t=this.getLocation(),e=t.startAngle,i=t.endAngle;return"start"===this.get("text").position?e+Math.PI/2:i-Math.PI/2},e.prototype.getTextPoint=function(){var t=this.get("text"),e=t.position,i=t.offset,n=this.getLocation(),r=n.center,a=n.radius,o=n.startAngle,s=n.endAngle,l="start"===e?o:s,h=this.getRotateAngle()-Math.PI,p=(0,m.JJ)(r,a,l),u=Math.cos(h)*i,g=Math.sin(h)*i;return{x:p.x+u,y:p.y+g}},e.prototype.getLinePath=function(){var t=this.getLocation(),e=t.center,i=t.radius,n=t.startAngle,r=t.endAngle,a=null;if(r-n===2*Math.PI){var o=e.x,s=e.y;a=[["M",o,s-i],["A",i,i,0,1,1,o,s+i],["A",i,i,0,1,1,o,s-i],["Z"]]}else{var l=(0,m.JJ)(e,i,n),h=(0,m.JJ)(e,i,r),p=Math.abs(r-n)>Math.PI?1:0,u=n>r?0:1;a=[["M",l.x,l.y],["A",i,i,0,p,u,h.x,h.y]]}return a},e}(Ct);const Bt=bt;var Lt,At="g2-crosshair",kt=At+"-line",wt=At+"-text";const St=((Lt={})[""+At]={position:"relative"},Lt[""+kt]={position:"absolute",backgroundColor:"rgba(0, 0, 0, 0.25)"},Lt[""+wt]={position:"absolute",color:y.A.textColor,fontFamily:y.A.fontFamily},Lt);var Mt=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,g.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{name:"crosshair",type:"html",locationType:"region",start:{x:0,y:0},end:{x:0,y:0},capture:!1,text:null,containerTpl:'<div class="'+At+'"></div>',crosshairTpl:'<div class="'+kt+'"></div>',textTpl:'<span class="'+wt+'">{content}</span>',domStyles:null,containerClassName:At,defaultStyles:St,defaultCfg:{text:{position:"start",content:null,align:"center",offset:10}}})},e.prototype.render=function(){this.resetText(),this.resetPosition()},e.prototype.initCrossHair=function(){var t=this.getContainer(),e=this.get("crosshairTpl"),i=(0,O.A)(e);t.appendChild(i),this.applyStyle(kt,i),this.set("crosshairEl",i)},e.prototype.getTextPoint=function(){var t=this.getLocation(),e=t.start,i=t.end,n=this.get("text"),r=n.position,a=n.offset;return(0,m.E2)(e,i,r,a)},e.prototype.resetText=function(){var t=this.get("text"),e=this.get("textEl");if(t){var i=t.content;if(!e){var n=this.getContainer(),r=(0,c.V2)(this.get("textTpl"),t);e=(0,O.A)(r),n.appendChild(e),this.applyStyle(wt,e),this.set("textEl",e)}e.innerHTML=i}else e&&e.remove()},e.prototype.isVertical=function(t,e){return t.x===e.x},e.prototype.resetPosition=function(){var t=this.get("crosshairEl");t||(this.initCrossHair(),t=this.get("crosshairEl"));var e=this.get("start"),i=this.get("end"),n=Math.min(e.x,i.x),r=Math.min(e.y,i.y);this.isVertical(e,i)?(0,F.A)(t,{width:"1px",height:(0,m.cl)(Math.abs(i.y-e.y))}):(0,F.A)(t,{height:"1px",width:(0,m.cl)(Math.abs(i.x-e.x))}),(0,F.A)(t,{top:(0,m.cl)(r),left:(0,m.cl)(n)}),this.alignText()},e.prototype.alignText=function(){var t=this.get("textEl");if(t){var e=this.get("text").align,i=t.clientWidth,n=this.getTextPoint();switch(e){case"center":n.x=n.x-i/2;break;case"right":n.x=n.x-i}(0,F.A)(t,{top:(0,m.cl)(n.y),left:(0,m.cl)(n.x)})}},e.prototype.updateInner=function(e){(0,c.CJ)(e,"text")&&this.resetText(),t.prototype.updateInner.call(this,e)},e}(X.A);const Tt=Mt;var Pt=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,g.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{name:"grid",line:{},alternateColor:null,capture:!1,items:[],closed:!1,defaultCfg:{line:{type:"line",style:{lineWidth:1,stroke:y.A.lineColor}}}})},e.prototype.getLineType=function(){return(this.get("line")||this.get("defaultCfg").line).type}
1,e.prototype.renderInner=function(t){this.drawGrid(t)},e.prototype.getAlternatePath=function(t,e){var i=this.getGridPath(t),n=e.slice(0).reverse(),r=this.getGridPath(n,!0);return this.get("closed")?i=i.concat(r):(r[0][0]="L",(i=i.concat(r)).push(["Z"])),i},e.prototype.getPathStyle=function(){return this.get("line").style},e.prototype.drawGrid=function(t){var e=this,i=this.get("line"),n=this.get("items"),r=this.get("alternateColor"),a=null;(0,c.__)(n,function(o,s){var l=o.id||s;if(i){var h=e.getPathStyle();h=(0,c.Tn)(h)?h(o,s,n):h;var p=e.getElementId("line-"+l),u=e.getGridPath(o.points);e.addShape(t,{type:"path",name:"grid-line",id:p,attrs:(0,c.jh)({path:u},h)})}if(r&&s>0){var g=e.getElementId("region-"+l),d=s%2==0;if((0,c.Kg)(r))d&&e.drawAlternateRegion(g,t,a.points,o.points,r);else{var f=d?r[1]:r[0];e.drawAlternateRegion(g,t,a.points,o.points,f)}}a=o})},e.prototype.drawAlternateRegion=function(t,e,i,n,r){var a=this.getAlternatePath(i,n);this.addShape(e,{type:"path",id:t,name:"grid-region",attrs:{path:a,fill:r}})},e}(d.A);const Dt=Pt;var Rt=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,g.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{type:"circle",center:null,closed:!0})},e.prototype.getGridPath=function(t,e){var i,n,r,a,o,s,l=this.getLineType(),h=this.get("closed"),p=[];if(t.length)if("circle"===l){var u=this.get("center"),g=t[0],d=(i=u.x,n=u.y,r=g.x,a=g.y,o=r-i,s=a-n,Math.sqrt(o*o+s*s)),f=e?0:1;h?(p.push(["M",u.x,u.y-d]),p.push(["A",d,d,0,0,f,u.x,u.y+d]),p.push(["A",d,d,0,0,f,u.x,u.y-d]),p.push(["Z"])):(0,c.__)(t,function(t,e){0===e?p.push(["M",t.x,t.y]):p.push(["A",d,d,0,0,f,t.x,t.y])})}else(0,c.__)(t,function(t,e){0===e?p.push(["M",t.x,t.y]):p.push(["L",t.x,t.y])}),h&&p.push(["Z"]);return p},e}(Dt);const _t=Rt;var Vt=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,g.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{type:"line"})},e.prototype.getGridPath=function(t){var e=[];return(0,c.__)(t,function(t,i){0===i?e.push(["M",t.x,t.y]):e.push(["L",t.x,t.y])}),e},e}(Dt);const Ot=Vt;var Ht=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,g.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{name:"legend",layout:"horizontal",locationType:"point",x:0,y:0,offsetX:0,offsetY:0,title:null,background:null})},e.prototype.getLayoutBBox=function(){var e=t.prototype.getLayoutBBox.call(this),i=this.get("maxWidth"),n=this.get("maxHeight"),r=e.width,a=e.height;return i&&(r=Math.min(r,i)),n&&(a=Math.min(a,n)),(0,m.qn)(e.minX,e.minY,r,a)},e.prototype.setLocation=function(t){this.set("x",t.x),this.set("y",t.y),this.resetLocation()},e.prototype.resetLocation=function(){var t=this.get("x"),e=this.get("y"),i=this.get("offsetX"),n=this.get("offsetY");this.moveElementTo(this.get("group"),{x:t+i,y:e+n})},e.prototype.applyOffset=function(){this.resetLocation()},e.prototype.getDrawPoint=function(){return this.get("currentPoint")},e.prototype.setDrawPoint=function(t){return this.set("currentPoint",t)},e.prototype.renderInner=function(t){this.resetDraw(),this.get("title")&&this.drawTitle(t),this.drawLegendContent(t),this.get("background")&&this.drawBackground(t)},e.prototype.drawBackground=function(t){var e=this.get("background"),i=t.getBBox(),n=(0,m.FZ)(e.padding),r=(0,g.Cl)({x:0,y:0,width:i.width+n[1]+n[3],height:i.height+n[0]+n[2]},e.style);this.addShape(t,{type:"rect",id:this.getElementId("background"),name:"legend-background",attrs:r}).toBack()},e.prototype.drawTitle=function(t){var e=this.get("currentPoint"),i=this.get("title"),n=i.spacing,r=i.style,a=i.text,o=this.addShape(t,{type:"text",id:this.getElementId("title"),name:"legend-title",attrs:(0,g.Cl)({text:a,x:e.x,y:e.y},r)}).getBBox();this.set("currentPoint",{x:e.x,y:o.maxY+n})},e.prototype.resetDraw=function(){var t=this.get("background"),e={x:0,y:0};if(t){var i=(0,m.FZ)(t.padding);e.x=i[3],e.y=i[0]}this.set("currentPoint",e)},e}(d.A);
1const zt=Ht;var Ft={marker:{style:{inactiveFill:"#000",inactiveOpacity:.45,fill:"#000",opacity:1,size:12}},text:{style:{fill:"#ccc",fontSize:12}}},Xt={fill:y.A.textColor,fontSize:12,textAlign:"start",textBaseline:"middle",fontFamily:y.A.fontFamily,fontWeight:"normal",lineHeight:12},Yt="navigation-arrow-right",Jt="navigation-arrow-left",jt={right:90*Math.PI/180,left:270*Math.PI/180,up:0,down:180*Math.PI/180},Wt=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.currentPageIndex=1,e.totalPagesCnt=1,e.pageWidth=0,e.pageHeight=0,e.startX=0,e.startY=0,e.onNavigationBack=function(){var t=e.getElementByLocalId("item-group");if(e.currentPageIndex>1){e.currentPageIndex-=1,e.updateNavigation();var i=e.getCurrentNavigationMatrix();e.get("animate")?t.animate({matrix:i},100):t.attr({matrix:i})}},e.onNavigationAfter=function(){var t=e.getElementByLocalId("item-group");if(e.currentPageIndex<e.totalPagesCnt){e.currentPageIndex+=1,e.updateNavigation();var i=e.getCurrentNavigationMatrix();e.get("animate")?t.animate({matrix:i},100):t.attr({matrix:i})}},e}return(0,g.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{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:{}
1,itemBackground:{},pageNavigator:{},defaultCfg:{title:{spacing:5,style:{fill:y.A.textColor,fontSize:12,textAlign:"start",textBaseline:"top"}},background:{padding:5,style:{stroke:y.A.lineColor}},itemBackground:{style:{opacity:0,fill:"#fff"}},pageNavigator:Ft,itemName:{spacing:16,style:Xt},marker:{spacing:8,style:{r:6,symbol:"circle"}},itemValue:{alignRight:!1,formatter:null,style:Xt,spacing:6},itemStates:{active:{nameStyle:{opacity:.8}},unchecked:{nameStyle:{fill:y.A.uncheckedColor},markerStyle:{fill:y.A.uncheckedColor,stroke:y.A.uncheckedColor}},inactive:{nameStyle:{fill:y.A.uncheckedColor},markerStyle:{opacity:.2}}}}})},e.prototype.isList=function(){return!0},e.prototype.getItems=function(){return this.get("items")},e.prototype.setItems=function(t){this.update({items:t})},e.prototype.updateItem=function(t,e){(0,c.jh)(t,e),this.clear(),this.render()},e.prototype.clearItems=function(){var t=this.getElementByLocalId("item-group");t&&t.clear()},e.prototype.setItemState=function(t,e,i){t[e]=i;var n=this.getElementByLocalId("item-"+t.id);if(n){var r=this.getItems().indexOf(t),a=this.createOffScreenGroup(),o=this.drawItem(t,r,this.getItemHeight(),a);this.updateElements(o,n),this.clearUpdateStatus(n)}},e.prototype.hasState=function(t,e){return!!t[e]},e.prototype.getItemStates=function(t){var e=this.get("itemStates"),i=[];return(0,c.__)(e,function(e,n){t[n]&&i.push(n)}),i},e.prototype.clearItemsState=function(t){var e=this,i=this.getItemsByState(t);(0,c.__)(i,function(i){e.setItemState(i,t,!1)})},e.prototype.getItemsByState=function(t){var e=this,i=this.getItems();return(0,c.pb)(i,function(i){return e.hasState(i,t)})},e.prototype.drawLegendContent=function(t){this.processItems(),this.drawItems(t)},e.prototype.processItems=function(){var t=this.get("items");(0,c.__)(t,function(t){t.id||(t.id=t.name)})},e.prototype.drawItems=function(t){var e=this,i=this.addGroup(t,{id:this.getElementId("item-container-group"),name:"legend-item-container-group"}),n=this.addGroup(i,{id:this.getElementId("item-group"),name:"legend-item-group"}),r=this.getItemHeight(),a=this.get("itemWidth"),o=this.get("itemSpacing"),s=this.get("itemMarginBottom"),l=this.get("currentPoint"),h=l.x,p=l.y,u=this.get("layout"),g=this.get("items"),d=!1,f=0,y=this.get("maxWidth"),m=this.get("maxHeight");(0,c.__)(g,function(t,i){var g=e.drawItem(t,i,r,n),c=g.getBBox(),v=a||c.width;v>f&&(f=v),"horizontal"===u?(y&&y<l.x+v-h&&(d=!0,l.x=h,l.y+=r+s),e.moveElementTo(g,l),l.x+=v+o):(m&&m<l.y+r+s-p&&(d=!0,l.x+=f+o,l.y=p,f=0),e.moveElementTo(g,l),l.y+=r+s)}),d&&this.get("flipPage")&&(this.pageHeight=0,this.pageWidth=0,this.totalPagesCnt=1,this.startX=h,this.startY=p,this.adjustNavigation(t,n))},e.prototype.getItemHeight=function(){var t=this.get("itemHeight");if(!t){var e=(this.get("itemName")||{}).style;if((0,c.Tn)(e)){var i=this.getItems();i.forEach(function(n,r){var a=(0,g.Cl)((0,g.Cl)({},Xt),e(n,r,i)).fontSize;t<a&&(t=a)})}else e&&(t=e.fontSize)}return t},e.prototype.drawMarker=function(t,e,i,n){var r=(0,g.Cl)((0,g.Cl)((0,g.Cl)({x:0,y:n/2},e.style),{symbol:(0,c.Jt)(i.marker,"symbol","circle")}),(0,c.Jt)(i.marker,"style",{})),a=this.addShape(t,{type:"marker",id:this.getElementId("item-"+i.id+"-marker"),name:"legend-item-marker",attrs:r}),o=a.getBBox();a.attr("x",o.width/2);var s=a.attr(),l=s.stroke,h=s.fill;return l&&a.set("isStroke",!0),h&&a.set("isFill",!0),a},e.prototype.drawItemText=function(t,e,i,n,r,a,o){var s=i.formatter,l=i.style,h=(0,g.Cl)((0,g.Cl)({x:a,y:r/2,text:s?s(n[e],n,o):n[e]},Xt),(0,c.Tn)(l)?l(n,o,this.getItems()):l);return this.addShape(t,{type:"text",id:this.getElementId("item-"+n.id+"-"+e),name:"legend-item-"+e,attrs:h})},e.prototype.drawRadio=function(t,e,i,n,r){var a,o,s=e.style||{},l=null!==(a=s.r)&&void 0!==a?a:n/2,h=3.6*l/8,p=[r+l,n/2-l],u=p[0],c=p[1],d=[u+l,c+l],f=d[0],y=d[1],m=[u,y+l],v=m[0],x=m[1],C=[r,c+l],I=C[0],E=C[1],b=i.showRadio,B=(0,g.Cl)((0,g.Cl)({path:[["M",u,c],["A",l,l,0,0,1,f,y],["L",f-h,y],["L",f,y],["A",l,l,0,0,1,v,x],["L",v,x-h],["L",v,x],["A",l,l,0,0,1,I,E],["L",I+h,E],["L",I,E],["A",l,l,0,0,1,u,c],["L",u,c+h]],stroke:"#000000",fill:"#ffffff"},s),{opacity:b?null!==(o=null==s?void 0:s.opacity)&&void 0!==o?o:.45:0}),L=this.addShape(t,{type:"path",id:this.getElementId("item-"+i.id+"-radio"),name:"legend-item-radio",attrs:B});return L.set("tip",e.tip),L}
1,e.prototype.drawItem=function(t,e,i,n){var r="item-"+t.id,a=this.addGroup(n,{name:"legend-item-container",id:this.getElementId("item-container-"+r),delegateObject:{item:t,index:e}}),o=this.addGroup(a,{name:"legend-item",id:this.getElementId(r),delegateObject:{item:t,index:e}}),s=this.get("marker"),l=this.get("itemName"),h=this.get("itemValue"),p=this.get("itemBackground"),u=this.get("radio"),d=this.getLimitItemWidth(),f=0;if(s){var y=this.drawMarker(o,s,t,i),m=s.spacing,v=(0,c.Jt)(t,["marker","spacing"]);(0,c.Et)(v)&&(m=v),f=y.getBBox().maxX+m}if(l){var x=this.drawItemText(o,"name",l,t,i,f,e);d&&(0,Z.A9)(!0,x,(0,c.qE)(d-f,0,d)),f=x.getBBox().maxX+l.spacing}if(h){var C=this.drawItemText(o,"value",h,t,i,f,e);d&&(h.alignRight?(C.attr({textAlign:"right",x:d}),(0,Z.A9)(!0,C,(0,c.qE)(d-f,0,d),"head")):(0,Z.A9)(!0,C,(0,c.qE)(d-f,0,d))),f=C.getBBox().maxX+h.spacing}if(u&&this.drawRadio(o,u,t,i,f),p){var I=o.getBBox();this.addShape(o,{type:"rect",name:"legend-item-background",id:this.getElementId(r+"-background"),attrs:(0,g.Cl)({x:0,y:0,width:I.width,height:i},p.style)}).toBack()}return this.applyItemStates(t,o),o},e.prototype.adjustNavigation=function(t,e){var i=this,n=this.startX,r=this.startY,a=this.get("layout"),o=e.findAll(function(t){return"legend-item"===t.get("name")}),s=this.get("maxWidth"),l=this.get("maxHeight"),h=this.get("itemWidth"),p=this.get("itemSpacing"),u=this.getItemHeight(),g=(0,c.VL)({},Ft,this.get("pageNavigator")),d=this.drawNavigation(t,a,"00/00",g),f=d.getBBox(),y={x:n,y:r},m=1,v=0,x=0,C=0,I=this.get("itemMarginBottom");if("horizontal"===a){var E=this.get("maxRow")||1,b=u+(1===E?0:I),B=s-p-f.width-f.minX;this.pageHeight=b*E,this.pageWidth=B,(0,c.__)(o,function(t){var e=t.getBBox(),r=h||e.width;(v&&v<y.x+r+p||function(t,e){var i=t.getBBox(),n=h||i.width;return e.x+n+p+f.width>s}(t,y))&&(1===m&&(v=y.x+p,i.moveElementTo(d,{x:B,y:y.y+u/2-f.height/2-f.minY})),m+=1,y.x=n,y.y+=b),i.moveElementTo(t,y),t.getParent().setClip({type:"rect",attrs:{x:y.x,y:y.y,width:r+p,height:u}}),y.x+=r+p})}else{(0,c.__)(o,function(t){var e=t.getBBox();e.width>x&&(x=e.width)}),C=x,x+=p,s&&(x=Math.min(s,x),C=Math.min(s,C)),this.pageWidth=x,this.pageHeight=l-Math.max(f.height,u+I);var L=Math.floor(this.pageHeight/(u+I));(0,c.__)(o,function(t,e){0!==e&&e%L===0&&(m+=1,y.x+=x,y.y=r),i.moveElementTo(t,y),t.getParent().setClip({type:"rect",attrs:{x:y.x,y:y.y,width:x,height:u}}),y.y+=u+I}),this.totalPagesCnt=m,this.moveElementTo(d,{x:n+C/2-f.width/2-f.minX,y:l-f.height-f.minY})}this.pageHeight&&this.pageWidth&&e.getParent().setClip({type:"rect",attrs:{x:this.startX,y:this.startY,width:this.pageWidth,height:this.pageHeight}}),"horizontal"===a&&this.get("maxRow")?this.totalPagesCnt=Math.ceil(m/this.get("maxRow")):this.totalPagesCnt=m,this.currentPageIndex>this.totalPagesCnt&&(this.currentPageIndex=1),this.updateNavigation(d),e.attr("matrix",this.getCurrentNavigationMatrix())},e.prototype.drawNavigation=function(t,e,i,n){var r={x:0,y:0},a=this.addGroup(t,{id:this.getElementId("navigation-group"),name:"legend-navigation"}),o=(0,c.Jt)(n.marker,"style",{}),s=o.size,l=void 0===s?12:s,h=(0,g.Tt)(o,["size"]),p=this.drawArrow(a,r,Jt,"horizontal"===e?"up":"left",l,h);p.on("click",this.onNavigationBack);var u=p.getBBox();r.x+=u.width+2;var d=this.addShape(a,{type:"text",id:this.getElementId("navigation-text"),name:"navigation-text",attrs:(0,g.Cl)({x:r.x,y:r.y+l/2,text:i,textBaseline:"middle"},(0,c.Jt)(n.text,"style"))}).getBBox();return r.x+=d.width+2,this.drawArrow(a,r,Yt,"horizontal"===e?"down":"right",l,h).on("click",this.onNavigationAfter),a},e.prototype.updateNavigation=function(t){var e=(0,c.VL)({},Ft,this.get("pageNavigator")).marker.style,i=e.fill,n=e.opacity,r=e.inactiveFill,a=e.inactiveOpacity,o=this.currentPageIndex+"/"+this.totalPagesCnt,s=t?t.getChildren()[1]:this.getElementByLocalId("navigation-text"),l=t?t.findById(this.getElementId(Jt)):this.getElementByLocalId(Jt),h=t?t.findById(this.getElementId(Yt)):this.getElementByLocalId(Yt);s.attr("text",o),l.attr("opacity",1===this.currentPageIndex?a:n),l.attr("fill",1===this.currentPageIndex?r:i),l.attr("cursor",1===this.currentPageIndex?"not-allowed":"pointer"),h.attr("opacity",this.currentPageIndex===this.totalPagesCnt?a:n),h.attr("fill",this.currentPageIndex===this.totalPagesCnt?r:i),h.attr("cursor",this.currentPageIndex===this.totalPagesCnt?"not-allowed":"pointer");var p=l.getBBox().maxX+2;s.attr("x",p),p+=s.getBBox().width+2,this.updateArrowPath(h,{x:p,y:0})}
1,e.prototype.drawArrow=function(t,e,i,n,r,a){var o=e.x,s=e.y,l=this.addShape(t,{type:"path",id:this.getElementId(i),name:i,attrs:(0,g.Cl)({size:r,direction:n,path:[["M",o+r/2,s],["L",o,s+r],["L",o+r,s+r],["Z"]],cursor:"pointer"},a)});return l.attr("matrix",(0,C.cw)({x:o+r/2,y:s+r/2},jt[n])),l},e.prototype.updateArrowPath=function(t,e){var i=e.x,n=e.y,r=t.attr(),a=r.size,o=r.direction,s=(0,C.cw)({x:i+a/2,y:n+a/2},jt[o]);t.attr("path",[["M",i+a/2,n],["L",i,n+a],["L",i+a,n+a],["Z"]]),t.attr("matrix",s)},e.prototype.getCurrentNavigationMatrix=function(){var t=this,e=t.currentPageIndex,i=t.pageWidth,n=t.pageHeight,r="horizontal"===this.get("layout")?{x:0,y:n*(1-e)}:{x:i*(1-e),y:0};return(0,C.Jb)(r)},e.prototype.applyItemStates=function(t,e){if(this.getItemStates(t).length>0){var i=e.getChildren(),n=this.get("itemStates");(0,c.__)(i,function(e){var i=e.get("name").split("-")[2],r=(0,G.u)(t,i,n);r&&(e.attr(r),"marker"!==i||e.get("isStroke")&&e.get("isFill")||(e.get("isStroke")&&e.attr("fill",null),e.get("isFill")&&e.attr("stroke",null)))})}},e.prototype.getLimitItemWidth=function(){var t=this.get("itemWidth"),e=this.get("maxItemWidth");return e?t&&(e=t<=e?t:e):t&&(e=t),e},e}(zt);const Gt=Wt;var Nt=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,g.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{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:y.A.textColor,textBaseline:"middle",fontFamily:y.A.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:y.A.textColor,fontSize:12,textAlign:"start",textBaseline:"top"}}}})},e.prototype.isSlider=function(){return!0},e.prototype.getValue=function(){return this.getCurrentValue()},e.prototype.getRange=function(){return{min:this.get("min"),max:this.get("max")}},e.prototype.setRange=function(t,e){this.update({min:t,max:e})},e.prototype.setValue=function(t){var e=this.getValue();this.set("value",t);var i=this.get("group");this.resetTrackClip(),this.get("slidable")&&this.resetHandlers(i),this.delegateEmit("valuechanged",{originValue:e,value:t})},e.prototype.initEvent=function(){var t=this.get("group");this.bindSliderEvent(t),this.bindRailEvent(t),this.bindTrackEvent(t)},e.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)},e.prototype.bindSliderEvent=function(t){this.bindHandlersEvent(t)},e.prototype.bindHandlersEvent=function(t){var e=this;t.on("legend-handler-min:drag",function(t){var i=e.getValueByCanvasPoint(t.x,t.y),n=e.getCurrentValue()[1];n<i&&(n=i),e.setValue([i,n])}),t.on("legend-handler-max:drag",function(t){var i=e.getValueByCanvasPoint(t.x,t.y),n=e.getCurrentValue()[0];n>i&&(n=i),e.setValue([n,i])})},e.prototype.bindRailEvent=function(t){},e.prototype.bindTrackEvent=function(t){var e=this,i=null;t.on("legend-track:dragstart",function(t){i={x:t.x,y:t.y}}),t.on("legend-track:drag",function(t){if(i){var n=e.getValueByCanvasPoint(i.x,i.y),r=e.getValueByCanvasPoint(t.x,t.y),a=e.getCurrentValue(),o=a[1]-a[0],s=e.getRange(),l=r-n;l<0?a[0]+l>s.min?e.setValue([a[0]+l,a[1]+l]):e.setValue([s.min,s.min+o]):l>0&&(l>0&&a[1]+l<s.max?e.setValue([a[0]+l,a[1]+l]):e.setValue([s.max-o,s.max])),i={x:t.x,y:t.y}}}),t.on("legend-track:dragend",function(t){i=null})},e.prototype.drawLabels=function(t){this.drawLabel("min",t),this.drawLabel("max",t)},e.prototype.drawLabel=function(t,e){var i=this.get("label"),n=i.style,r=i.align,a=i.formatter,o=this.get(t),s=this.getLabelAlignAttrs(t,r),l="label-"+t;this.addShape(e,{type:"text",id:this.getElementId(l),name:"legend-label-"+t,attrs:(0,g.Cl)((0,g.Cl)({x:0,y:0,text:(0,c.Tn)(a)?a(o):o},n),s)})},e.prototype.getLabelAlignAttrs=function(t,e){var i="center",n="middle";return this.isVertical()?(i="start",n="rail"!==e?"min"===t?"top":"bottom":"top"):"rail"!==e?(n="top",i="min"===t?"start":"end"):(i="start",n="middle"),{textAlign:i,textBaseline:n}
vendor: 4,265 bytes, line 1
1},e.prototype.getRailPath=function(t,e,i,n){var r=this.get("rail"),a=r.size,o=r.defaultLength,s=r.type,l=this.isVertical(),h=i,p=n;h||(h=l?a:o),p||(p=l?o:a);var u=[];return"color"===s?(u.push(["M",t,e]),u.push(["L",t+h,e]),u.push(["L",t+h,e+p]),u.push(["L",t,e+p]),u.push(["Z"])):(u.push(["M",t+h,e]),u.push(["L",t+h,e+p]),u.push(["L",t,e+p]),u.push(["Z"])),u},e.prototype.drawRail=function(t){var e=this.get("rail").style;this.addShape(t,{type:"path",id:this.getElementId("rail"),name:"legend-rail",attrs:(0,g.Cl)({path:this.getRailPath(0,0)},e)})},e.prototype.getTrackColor=function(t){var e,i=t.length;if(!i)return null;if(1===i)return t[0];e=this.isVertical()?"l(90)":"l(0)";for(var n=0;n<i;n++){e+=" "+n/(i-1)+":"+t[n]}return e},e.prototype.getTrackPath=function(t){var e=this.getRailShape(t).attr("path");return(0,c.o8)(e)},e.prototype.getClipTrackAttrs=function(t){var e,i,n,r,a=this.getCurrentValue(),o=a[0],s=a[1],l=this.getRailBBox(t),h=this.getPointByValue(o,t),p=this.getPointByValue(s,t);return this.isVertical()?(e=l.minX,i=h.y,n=l.width,r=p.y-h.y):(e=h.x,i=l.minY,n=p.x-h.x,r=l.height),{x:e,y:i,width:n,height:r}},e.prototype.getTrackAttrs=function(t){var e=this.get("track"),i=this.get("colors"),n=this.getTrackPath(t);return(0,c.jh)({path:n,fill:this.getTrackColor(i)},e.style)},e.prototype.resetTrackClip=function(t){var e=t||this.get("group"),i=this.getElementId("track"),n=e.findById(i),r=n.getClip(),a=this.getClipTrackAttrs(t);r?r.attr(a):n.setClip({type:"rect",attrs:a})},e.prototype.resetTrack=function(t){var e=this.getElementId("track"),i=t.findById(e),n=this.getTrackAttrs(t);i?i.attr(n):this.addShape(t,{type:"path",id:e,draggable:this.get("slidable"),name:"legend-track",attrs:n})},e.prototype.getPointByValue=function(t,e){var i=this.getRange(),n=i.min,r=(t-n)/(i.max-n),a=this.getRailBBox(e),o={x:0,y:0};return this.isVertical()?(o.x=a.minX+a.width/2,o.y=(0,m.mj)(a.minY,a.maxY,r)):(o.x=(0,m.mj)(a.minX,a.maxX,r),o.y=a.minY+a.height/2),o},e.prototype.getRailShape=function(t){return(t||this.get("group")).findById(this.getElementId("rail"))},e.prototype.getRailBBox=function(t){return this.getRailShape(t).getBBox()},e.prototype.getRailCanvasBBox=function(){return this.get("group").findById(this.getElementId("rail")).getCanvasBBox()},e.prototype.isVertical=function(){return"vertical"===this.get("layout")},e.prototype.getValueByCanvasPoint=function(t,e){var i,n=this.getRange(),r=n.min,a=n.max,o=this.getRailCanvasBBox(),s=this.isVertical(),l=this.get("step");i=s?(e-o.minY)/o.height:(t-o.minX)/o.width;var h=(0,m.mj)(r,a,i);l&&(h=r+Math.round((h-r)/l)*l);return h>a&&(h=a),h<r&&(h=r),h},e.prototype.getCurrentValue=function(){var t=this.get("value");if(!t){var e=this.get("values");return e?[Math.max(Math.min.apply(Math,(0,g.aN)(e,[this.get("max")])),this.get("min")),Math.min(Math.max.apply(Math,(0,g.aN)(e,[this.get("min")])),this.get("max"))]:[this.get("min"),this.get("max")]}return t},e.prototype.resetHandlers=function(t){var e=this.getCurrentValue(),i=e[0],n=e[1];this.resetHandler(t,"min",i),this.resetHandler(t,"max",n)},e.prototype.getHandlerPath=function(t,e){var i=this.isVertical(),n=[],r=t.size,a=e.x,o=e.y,s=1.4*r,l=r/2,h=r/6;if(i){var p=a+.4*s;n.push(["M",a,o]),n.push(["L",p,o+l]),n.push(["L",a+s,o+l]),n.push(["L",a+s,o-l]),n.push(["L",p,o-l]),n.push(["Z"]),n.push(["M",p,o+h]),n.push(["L",a+s-2,o+h]),n.push(["M",p,o-h]),n.push(["L",a+s-2,o-h])}else{var u=o+.4*s;n.push(["M",a,o]),n.push(["L",a-l,u]),n.push(["L",a-l,o+s]),n.push(["L",a+l,o+s]),n.push(["L",a+l,u]),n.push(["Z"]),n.push(["M",a-h,u]),n.push(["L",a-h,o+s-2]),n.push(["M",a+h,u]),n.push(["L",a+h,o+s-2])}return n},e.prototype.resetHandler=function(t,e,i){var n=this.getPointByValue(i,t),r=this.get("handler"),a=this.getHandlerPath(r,n),o=this.getElementId("handler-"+e),s=t.findById(o),l=this.isVertical();s?s.attr("path",a):this.addShape(t,{type:"path",name:"legend-handler-"+e,draggable:!0,id:o,attrs:(0,g.Cl)((0,g.Cl)({path:a},r.style),{cursor:l?"ns-resize":"ew-resize"})})},e.prototype.fixedElements=function(t){var e=t.findById(this.getElementId("rail")),i=t.findById(this.getElementId("label-min")),n=t.findById(this.getElementId("label-max")),r=this.getDrawPoint();this.isVertical()?this.fixedVertail(i,n,e,r):this.fixedHorizontal(i,n,e,r)}
1,e.prototype.fitRailLength=function(t,e,i,n){var r=this.isVertical()?"height":"width",a=this.get("label"),o=a.align,s=a.spacing,l=this.get("max"+(0,c.Zb)(r));if(l){var h=("rail"===o?i[r]+t[r]+e[r]+2*s:i[r])-l;h>0&&this.changeRailLength(n,r,i[r]-h)}},e.prototype.changeRailLength=function(t,e,i){var n,r=t.getBBox();n="height"===e?this.getRailPath(r.x,r.y,r.width,i):this.getRailPath(r.x,r.y,i,r.height),t.attr("path",n)},e.prototype.changeRailPosition=function(t,e,i){var n=t.getBBox(),r=this.getRailPath(e,i,n.width,n.height);t.attr("path",r)},e.prototype.fixedHorizontal=function(t,e,i,n){var r=this.get("label"),a=r.align,o=r.spacing,s=i.getBBox(),l=t.getBBox(),h=e.getBBox(),p=s.height;this.fitRailLength(l,h,s,i),s=i.getBBox(),"rail"===a?(t.attr({x:n.x,y:n.y+p/2}),this.changeRailPosition(i,n.x+l.width+o,n.y),e.attr({x:n.x+l.width+s.width+2*o,y:n.y+p/2})):"top"===a?(t.attr({x:n.x,y:n.y}),e.attr({x:n.x+s.width,y:n.y}),this.changeRailPosition(i,n.x,n.y+l.height+o)):(this.changeRailPosition(i,n.x,n.y),t.attr({x:n.x,y:n.y+s.height+o}),e.attr({x:n.x+s.width,y:n.y+s.height+o}))},e.prototype.fixedVertail=function(t,e,i,n){var r=this.get("label"),a=r.align,o=r.spacing,s=i.getBBox(),l=t.getBBox(),h=e.getBBox();if(this.fitRailLength(l,h,s,i),s=i.getBBox(),"rail"===a)t.attr({x:n.x,y:n.y}),this.changeRailPosition(i,n.x,n.y+l.height+o),e.attr({x:n.x,y:n.y+l.height+s.height+2*o});else if("right"===a)t.attr({x:n.x+s.width+o,y:n.y}),this.changeRailPosition(i,n.x,n.y),e.attr({x:n.x+s.width+o,y:n.y+s.height});else{var p=Math.max(l.width,h.width);t.attr({x:n.x,y:n.y}),this.changeRailPosition(i,n.x+p+o,n.y),e.attr({x:n.x,y:n.y+s.height})}},e}(zt);const Ut=Nt;var Zt=i(33467),qt=(i(18764),i(24432)),Kt={fill:"#F7F7F7",stroke:"#BFBFBF",radius:2,opacity:1,cursor:"ew-resize",highLightFill:"#FFF"},Qt=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,g.C6)(e,t),e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{name:"handler",x:0,y:0,width:10,height:24,style:Kt})},e.prototype.renderInner=function(t){var e=this.cfg,i=e.width,n=e.height,r=e.style,a=r.fill,o=r.stroke,s=r.radius,l=r.opacity,h=r.cursor;this.addShape(t,{type:"rect",id:this.getElementId("background"),attrs:{x:0,y:0,width:i,height:n,fill:a,stroke:o,radius:s,opacity:l,cursor:h}});var p=1/3*i,u=2/3*i,g=1/4*n,c=3/4*n;this.addShape(t,{id:this.getElementId("line-left"),type:"line",attrs:{x1:p,y1:g,x2:p,y2:c,stroke:o,cursor:h}}),this.addShape(t,{id:this.getElementId("line-right"),type:"line",attrs:{x1:u,y1:g,x2:u,y2:c,stroke:o,cursor:h}})},e.prototype.applyOffset=function(){this.moveElementTo(this.get("group"),{x:this.get("x"),y:this.get("y")})},e.prototype.initEvent=function(){this.bindEvents()},e.prototype.bindEvents=function(){var t=this;this.get("group").on("mouseenter",function(){var e=t.get("style").highLightFill;t.getElementByLocalId("background").attr("fill",e),t.draw()}),this.get("group").on("mouseleave",function(){var e=t.get("style").fill;t.getElementByLocalId("background").attr("fill",e),t.draw()})},e.prototype.draw=function(){var t=this.get("container").get("canvas");t&&t.draw()},e}(d.A);var $t={fill:"#416180",opacity:.05},te={fill:"#5B8FF9",opacity:.15,cursor:"move"},ee={width:10,height:24},ie={textBaseline:"middle",fill:"#000",opacity:.45},ne=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.onMouseDown=function(t){return function(i){e.currentTarget=t;var n=i.originalEvent;n.stopPropagation(),n.preventDefault(),e.prevX=(0,c.Jt)(n,"touches.0.pageX",n.pageX),e.prevY=(0,c.Jt)(n,"touches.0.pageY",n.pageY);var r=e.getContainerDOM();r.addEventListener("mousemove",e.onMouseMove),r.addEventListener("mouseup",e.onMouseUp),r.addEventListener("mouseleave",e.onMouseUp),r.addEventListener("touchmove",e.onMouseMove),r.addEventListener("touchend",e.onMouseUp),r.addEventListener("touchcancel",e.onMouseUp)}},e.onMouseMove=function(t){var i=e.cfg.width,n=[e.get("start"),e.get("end")];t.stopPropagation(),t.preventDefault();var r=(0,c.Jt)(t,"touches.0.pageX",t.pageX),a=(0,c.Jt)(t,"touches.0.pageY",t.pageY),o=r-e.prevX,s=e.adjustOffsetRange(o/i);e.updateStartEnd(s),e.updateUI(e.getElementByLocalId("foreground"),e.getElementByLocalId("minText"),e.getElementByLocalId("maxText")),e.prevX=r,e.prevY=a,e.draw(),e.emit("sliderchange",[e.get("start"),e.get("end")].sort()),e.delegateEmit("valuechanged",{originValue:n,value:[e.get("start"),e.get("end")]})},e.onMouseUp=function(){e.currentTarget&&(e.currentTarget=void 0);var t=e.getContainerDOM();t&&(t.removeEventListener("mousemove",e.onMouseMove),t.removeEventListener("mouseup",e.onMouseUp),t.removeEventListener("mouseleave",e.onMouseUp),t.removeEventListener("touchmove",e.onMouseMove),t.removeEventListener("touchend",e.onMouseUp),t.removeEventListener("touchcancel",e.onMouseUp))},e}return(0,g.C6)(e,t),e.prototype.setRange=function(t,e){this.set("minLimit",t),this.set("maxLimit",e);var i=this.get("start"),n=this.get("end"),r=(0,c.qE)(i,t,e),a=(0,c.qE)(n,t,e);
1this.get("isInit")||i===r&&n===a||this.setValue([r,a])},e.prototype.getRange=function(){return{min:this.get("minLimit")||0,max:this.get("maxLimit")||1}},e.prototype.setValue=function(t){var e=this.getRange();if((0,c.cy)(t)&&2===t.length){var i=[this.get("start"),this.get("end")];this.update({start:(0,c.qE)(t[0],e.min,e.max),end:(0,c.qE)(t[1],e.min,e.max)}),this.get("updateAutoRender")||this.render(),this.delegateEmit("valuechanged",{originValue:i,value:t})}},e.prototype.getValue=function(){return[this.get("start"),this.get("end")]},e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{name:"slider",x:0,y:0,width:100,height:16,backgroundStyle:{},foregroundStyle:{},handlerStyle:{},textStyle:{},defaultCfg:{backgroundStyle:$t,foregroundStyle:te,handlerStyle:ee,textStyle:ie}})},e.prototype.update=function(e){var i=e.start,n=e.end,r=(0,g.Cl)({},e);(0,c.gD)(i)||(r.start=(0,c.qE)(i,0,1)),(0,c.gD)(n)||(r.end=(0,c.qE)(n,0,1)),t.prototype.update.call(this,r),this.minHandler=this.getChildComponentById(this.getElementId("minHandler")),this.maxHandler=this.getChildComponentById(this.getElementId("maxHandler")),this.trend=this.getChildComponentById(this.getElementId("trend"))},e.prototype.init=function(){this.set("start",(0,c.qE)(this.get("start"),0,1)),this.set("end",(0,c.qE)(this.get("end"),0,1)),t.prototype.init.call(this)},e.prototype.render=function(){t.prototype.render.call(this),this.updateUI(this.getElementByLocalId("foreground"),this.getElementByLocalId("minText"),this.getElementByLocalId("maxText"))},e.prototype.renderInner=function(t){var e=this.cfg,i=(e.start,e.end,e.width),n=e.height,r=e.trendCfg,a=void 0===r?{}:r,o=e.minText,s=e.maxText,l=e.backgroundStyle,h=void 0===l?{}:l,p=e.foregroundStyle,u=void 0===p?{}:p,d=e.textStyle,f=void 0===d?{}:d,y=(0,c.VL)({},Kt,this.cfg.handlerStyle);(0,c.Ej)((0,c.Jt)(a,"data"))&&(this.trend=this.addComponent(t,(0,g.Cl)({component:qt.c,id:this.getElementId("trend"),x:0,y:0,width:i,height:n},a))),this.addShape(t,{id:this.getElementId("background"),type:"rect",attrs:(0,g.Cl)({x:0,y:0,width:i,height:n},h)});this.addShape(t,{id:this.getElementId("minText"),type:"text",attrs:(0,g.Cl)({y:n/2,textAlign:"right",text:o,silent:!1},f)}),this.addShape(t,{id:this.getElementId("maxText"),type:"text",attrs:(0,g.Cl)({y:n/2,textAlign:"left",text:s,silent:!1},f)}),this.addShape(t,{id:this.getElementId("foreground"),name:"foreground",type:"rect",attrs:(0,g.Cl)({y:0,height:n},u)});var m=(0,c.Jt)(y,"width",10),v=(0,c.Jt)(y,"height",24);this.minHandler=this.addComponent(t,{component:Qt,id:this.getElementId("minHandler"),name:"handler-min",x:0,y:(n-v)/2,width:m,height:v,cursor:"ew-resize",style:y}),this.maxHandler=this.addComponent(t,{component:Qt,id:this.getElementId("maxHandler"),name:"handler-max",x:0,y:(n-v)/2,width:m,height:v,cursor:"ew-resize",style:y})},e.prototype.applyOffset=function(){this.moveElementTo(this.get("group"),{x:this.get("x"),y:this.get("y")})},e.prototype.initEvent=function(){this.bindEvents()},e.prototype.updateUI=function(t,e,i){var n=this.cfg,r=n.start,a=n.end,o=n.width,s=n.minText,l=n.maxText,h=n.handlerStyle,p=n.height,u=r*o,g=a*o;this.trend&&(this.trend.update({width:o,height:p}),this.get("updateAutoRender")||this.trend.render()),t.attr("x",u),t.attr("width",g-u);var d=(0,c.Jt)(h,"width",10);e.attr("text",s),i.attr("text",l);var f=this._dodgeText([u,g],e,i),y=f[0],m=f[1];this.minHandler&&(this.minHandler.update({x:u-d/2}),this.get("updateAutoRender")||this.minHandler.render()),(0,c.__)(y,function(t,i){return e.attr(i,t)}),this.maxHandler&&(this.maxHandler.update({x:g-d/2}),this.get("updateAutoRender")||this.maxHandler.render()),(0,c.__)(m,function(t,e){return i.attr(e,t)})},e.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 e=t.findById(this.getElementId("foreground"));e.on("mousedown",this.onMouseDown("foreground")),e.on("touchstart",this.onMouseDown("foreground"))},e.prototype.adjustOffsetRange=function(t){var e=this.cfg,i=e.start,n=e.end;switch(this.currentTarget){case"minHandler":var r=0-i,a=1-i;return Math.min(a,Math.max(r,t));case"maxHandler":r=0-n,a=1-n;return Math.min(a,Math.max(r,t));case"foreground":r=0-i,a=1-n;return Math.min(a,Math.max(r,t))}},e.prototype.updateStartEnd=function(t){var e=this.cfg,i=e.start,n=e.end;switch(this.currentTarget){case"minHandler":i+=t;break;case"maxHandler":n+=t;break;case"foreground":i+=t,n+=t}this.set("start",i),this.set("end",n)}
vendor: 5,379 bytes, line 1
1,e.prototype._dodgeText=function(t,e,i){var n,r,a=this.cfg,o=a.handlerStyle,s=a.width,l=(0,c.Jt)(o,"width",10),h=t[0],p=t[1],u=!1;h>p&&(h=(n=[p,h])[0],p=n[1],e=(r=[i,e])[0],i=r[1],u=!0);var g=e.getBBox(),d=i.getBBox(),f=g.width>h-2?{x:h+l/2+2,textAlign:"left"}:{x:h-l/2-2,textAlign:"right"},y=d.width>s-p-2?{x:p-l/2-2,textAlign:"right"}:{x:p+l/2+2,textAlign:"left"};return u?[y,f]:[f,y]},e.prototype.draw=function(){var t=this.get("container"),e=t&&t.get("canvas");e&&e.draw()},e.prototype.getContainerDOM=function(){var t=this.get("container"),e=t&&t.get("canvas");return e&&e.get("container")},e}(d.A);var re=i(77693),ae={default:{trackColor:"rgba(0,0,0,0)",thumbColor:"rgba(0,0,0,0.15)",size:8,lineCap:"round"},hover:{thumbColor:"rgba(0,0,0,0.2)"}},oe=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.clearEvents=c.lQ,e.onStartEvent=function(t){return function(i){e.isMobile=t,i.originalEvent.preventDefault();var n=t?(0,c.Jt)(i.originalEvent,"touches.0.clientX"):i.clientX,r=t?(0,c.Jt)(i.originalEvent,"touches.0.clientY"):i.clientY;e.startPos=e.cfg.isHorizontal?n:r,e.bindLaterEvent()}},e.bindLaterEvent=function(){var t=e.getContainerDOM(),i=[];i=e.isMobile?[(0,re.A)(t,"touchmove",e.onMouseMove),(0,re.A)(t,"touchend",e.onMouseUp),(0,re.A)(t,"touchcancel",e.onMouseUp)]:[(0,re.A)(t,"mousemove",e.onMouseMove),(0,re.A)(t,"mouseup",e.onMouseUp),(0,re.A)(t,"mouseleave",e.onMouseUp)],e.clearEvents=function(){i.forEach(function(t){t.remove()})}},e.onMouseMove=function(t){var i=e.cfg,n=i.isHorizontal,r=i.thumbOffset;t.preventDefault();var a=e.isMobile?(0,c.Jt)(t,"touches.0.clientX"):t.clientX,o=e.isMobile?(0,c.Jt)(t,"touches.0.clientY"):t.clientY,s=n?a:o,l=s-e.startPos;e.startPos=s,e.updateThumbOffset(r+l)},e.onMouseUp=function(t){t.preventDefault(),e.clearEvents()},e.onTrackClick=function(t){var i=e.cfg,n=i.isHorizontal,r=i.x,a=i.y,o=i.thumbLen,s=e.getContainerDOM().getBoundingClientRect(),l=t.clientX,h=t.clientY,p=n?l-s.left-r-o/2:h-s.top-a-o/2,u=e.validateRange(p);e.updateThumbOffset(u)},e.onThumbMouseOver=function(){var t=e.cfg.theme.hover.thumbColor;e.getElementByLocalId("thumb").attr("stroke",t),e.draw()},e.onThumbMouseOut=function(){var t=e.cfg.theme.default.thumbColor;e.getElementByLocalId("thumb").attr("stroke",t),e.draw()},e}return(0,g.C6)(e,t),e.prototype.setRange=function(t,e){this.set("minLimit",t),this.set("maxLimit",e);var i=this.getValue(),n=(0,c.qE)(i,t,e);i===n||this.get("isInit")||this.setValue(n)},e.prototype.getRange=function(){return{min:this.get("minLimit")||0,max:this.get("maxLimit")||1}},e.prototype.setValue=function(t){var e=this.getRange(),i=this.getValue();this.update({thumbOffset:(this.get("trackLen")-this.get("thumbLen"))*(0,c.qE)(t,e.min,e.max)}),this.delegateEmit("valuechange",{originalValue:i,value:this.getValue()})},e.prototype.getValue=function(){return(0,c.qE)(this.get("thumbOffset")/(this.get("trackLen")-this.get("thumbLen")),0,1)},e.prototype.getDefaultCfg=function(){var e=t.prototype.getDefaultCfg.call(this);return(0,g.Cl)((0,g.Cl)({},e),{name:"scrollbar",isHorizontal:!0,minThumbLen:20,thumbOffset:0,theme:ae})},e.prototype.renderInner=function(t){this.renderTrackShape(t),this.renderThumbShape(t)},e.prototype.applyOffset=function(){this.moveElementTo(this.get("group"),{x:this.get("x"),y:this.get("y")})},e.prototype.initEvent=function(){this.bindEvents()},e.prototype.renderTrackShape=function(t){var e=this.cfg,i=e.trackLen,n=e.theme,r=void 0===n?{default:{}}:n,a=(0,c.VL)({},ae,r).default,o=a.lineCap,s=a.trackColor,l=a.size,h=(0,c.Jt)(this.cfg,"size",l),p=this.get("isHorizontal")?{x1:0+h/2,y1:h/2,x2:i-h/2,y2:h/2,lineWidth:h,stroke:s,lineCap:o}:{x1:h/2,y1:0+h/2,x2:h/2,y2:i-h/2,lineWidth:h,stroke:s,lineCap:o};return this.addShape(t,{id:this.getElementId("track"),name:"track",type:"line",attrs:p})},e.prototype.renderThumbShape=function(t){var e=this.cfg,i=e.thumbOffset,n=e.thumbLen,r=e.theme,a=(0,c.VL)({},ae,r).default,o=a.size,s=a.lineCap,l=a.thumbColor,h=(0,c.Jt)(this.cfg,"size",o),p=this.get("isHorizontal")?{x1:i+h/2,y1:h/2,x2:i+n-h/2,y2:h/2,lineWidth:h,stroke:l,lineCap:s,cursor:"default"}:{x1:h/2,y1:i+h/2,x2:h/2,y2:i+n-h/2,lineWidth:h,stroke:l,lineCap:s,cursor:"default"};return this.addShape(t,{id:this.getElementId("thumb"),name:"thumb",type:"line",attrs:p})},e.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),t.findById(this.getElementId("track")).on("click",this.onTrackClick);var e=t.findById(this.getElementId("thumb"));e.on("mouseover",this.onThumbMouseOver),e.on("mouseout",this.onThumbMouseOut)},e.prototype.getContainerDOM=function(){var t=this.get("container"),e=t&&t.get("canvas");return e&&e.get("container")},e.prototype.validateRange=function(t){var e=this.cfg,i=e.thumbLen,n=e.trackLen,r=t;return t+i>n?r=n-i:t+i<i&&(r=0),r},e.prototype.draw=function(){var t=this.get("container"),e=t&&t.get("canvas");e&&e.draw()},e.prototype.updateThumbOffset=function(t){var e=this.cfg,i=e.thumbOffset,n=e.isHorizontal,r=e.thumbLen,a=e.size,o=this.validateRange(t);if(o!==i){var s=this.getElementByLocalId("thumb");n?s.attr({x1:o+a/2,x2:o+r-a/2}):s.attr({y1:o+a/2,y2:o+r-a/2}),this.emitOffsetChange(o)}},e.prototype.emitOffsetChange=function(t){var e=this.cfg,i=e.thumbOffset,n=e.trackLen,r=e.thumbLen;
1this.cfg.thumbOffset=t,this.emit("scrollchange",{thumbOffset:t,ratio:(0,c.qE)(t/(n-r),0,1)}),this.delegateEmit("valuechange",{originalValue:i,value:t})},e}(d.A),se=i(95837),le=i(91169)}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.