Icard/angular-clarity-master(work.../node_modules/highcharts/modules/gantt.js

9 lines
107 KiB
JavaScript
Raw Normal View History

2024-07-16 14:55:36 +00:00
!/**
* Highcharts Gantt JS v11.4.1 (2024-04-04)
*
* Gantt series
*
* (c) 2016-2024 Lars A. V. Cabrera
*
* License: www.highcharts.com/license
*/function(t){"object"==typeof module&&module.exports?(t.default=t,module.exports=t):"function"==typeof define&&define.amd?define("highcharts/modules/gantt",["highcharts"],function(e){return t(e),t.Highcharts=e,t}):t("undefined"!=typeof Highcharts?Highcharts:void 0)}(function(t){"use strict";var e=t?t._modules:{};function i(t,e,i,s){t.hasOwnProperty(e)||(t[e]=s.apply(null,i),"function"==typeof CustomEvent&&window.dispatchEvent(new CustomEvent("HighchartsModuleLoaded",{detail:{path:e,module:t[e]}})))}i(e,"Extensions/ArrowSymbols.js",[],function(){function t(t,e,i,s){return[["M",t,e+s/2],["L",t+i,e],["L",t,e+s/2],["L",t+i,e+s]]}function e(e,i,s,o){return t(e,i,s/2,o)}function i(t,e,i,s){return[["M",t+i,e],["L",t,e+s/2],["L",t+i,e+s],["Z"]]}function s(t,e,s,o){return i(t,e,s/2,o)}return{compose:function(o){let r=o.prototype.symbols;r.arrow=t,r["arrow-filled"]=i,r["arrow-filled-half"]=s,r["arrow-half"]=e,r["triangle-left"]=i,r["triangle-left-half"]=s}}}),i(e,"Gantt/Connection.js",[e["Core/Globals.js"],e["Core/Utilities.js"]],function(t,e){let{defined:i,error:s,merge:o,objectEach:r}=e,n=t.deg2rad,a=Math.max,l=Math.min;return class{constructor(t,e,i){this.init(t,e,i)}init(t,e,i){this.fromPoint=t,this.toPoint=e,this.options=i,this.chart=t.series.chart,this.pathfinder=this.chart.pathfinder}renderPath(t,e){let i=this.chart,s=i.styledMode,o=this.pathfinder,r={},n=this.graphics&&this.graphics.path;o.group||(o.group=i.renderer.g().addClass("highcharts-pathfinder-group").attr({zIndex:-1}).add(i.seriesGroup)),o.group.translate(i.plotLeft,i.plotTop),n&&n.renderer||(n=i.renderer.path().add(o.group),s||n.attr({opacity:0})),n.attr(e),r.d=t,s||(r.opacity=1),n.animate(r),this.graphics=this.graphics||{},this.graphics.path=n}addMarker(t,e,i){let s,o,r,a,l,h,d,c;let p=this.fromPoint.series.chart,u=p.pathfinder,g=p.renderer,x="start"===t?this.fromPoint:this.toPoint,f=x.getPathfinderAnchorPoint(e);e.enabled&&((c="start"===t?i[1]:i[i.length-2])&&"M"===c[0]||"L"===c[0])&&(d={x:c[1],y:c[2]},o=x.getRadiansToVector(d,f),s=x.getMarkerVector(o,e.radius,f),r=-o/n,e.width&&e.height?(l=e.width,h=e.height):l=h=2*e.radius,this.graphics=this.graphics||{},a={x:s.x-l/2,y:s.y-h/2,width:l,height:h,rotation:r,rotationOriginX:s.x,rotationOriginY:s.y},this.graphics[t]?this.graphics[t].animate(a):(this.graphics[t]=g.symbol(e.symbol).addClass("highcharts-point-connecting-path-"+t+"-marker highcharts-color-"+this.fromPoint.colorIndex).attr(a).add(u.group),g.styledMode||this.graphics[t].attr({fill:e.color||this.fromPoint.color,stroke:e.lineColor,"stroke-width":e.lineWidth,opacity:0}).animate({opacity:1},x.series.options.animation)))}getPath(t){let e=this.pathfinder,i=this.chart,r=e.algorithms[t.type],n=e.chartObstacles;return"function"!=typeof r?(s('"'+t.type+'" is not a Pathfinder algorithm.'),{path:[],obstacles:[]}):(r.requiresObstacles&&!n&&(n=e.chartObstacles=e.getChartObstacles(t),i.options.connectors.algorithmMargin=t.algorithmMargin,e.chartObstacleMetrics=e.getObstacleMetrics(n)),r(this.fromPoint.getPathfinderAnchorPoint(t.startMarker),this.toPoint.getPathfinderAnchorPoint(t.endMarker),o({chartObstacles:n,lineObstacles:e.lineObstacles||[],obstacleMetrics:e.chartObstacleMetrics,hardBounds:{xMin:0,xMax:i.plotWidth,yMin:0,yMax:i.plotHeight},obstacleOptions:{margin:t.algorithmMargin},startDirectionX:e.getAlgorithmStartDirection(t.startMarker)},t)))}render(){let t=this.fromPoint,e=t.series,s=e.chart,r=s.pathfinder,n={},h=o(s.options.connectors,e.options.connectors,t.options.connectors,this.options);!s.styledMode&&(n.stroke=h.lineColor||t.color,n["stroke-width"]=h.lineWidth,h.dashStyle&&(n.dashstyle=h.dashStyle)),n.class="highcharts-point-connecting-path highcharts-color-"+t.colorIndex,i((h=o(n,h)).marker.radius)||(h.marker.radius=l(a(Math.ceil((h.algorithmMargin||8)/2)-1,1),5));let d=this.getPath(h),c=d.path;d.obstacles&&(r.lineObstacles=r.lineObstacles||[],r.lineObstacles=r.lineObstacles.concat(d.obstacles)),this.renderPath(c,n),this.addMarker("start",o(h.marker,h.startMarker),c),this.addMarker("end",o(h.marker,h.endMarker),c)}destroy(){this.graphics&&(r(this.grap