@canvasjs/stockcharts 1.7.41 → 1.7.42
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +1 -1
- package/README.md +6 -5
- package/canvasjs.stock.min.js +36 -37
- package/package.json +4 -3
package/LICENSE
CHANGED
package/README.md
CHANGED
|
@@ -19,7 +19,7 @@ CanvasJS StockCharts provides you with a powerful [JavaScript StockChart](https:
|
|
|
19
19
|
|
|
20
20
|
<br/>
|
|
21
21
|
|
|
22
|
-
## Links
|
|
22
|
+
## Important Links
|
|
23
23
|
- [Official Website](https://canvasjs.com/)
|
|
24
24
|
- [JavaScript StockCharts Demo](https://canvasjs.com/javascript-stockcharts/)
|
|
25
25
|
- [Download CanvasJS](https://canvasjs.com/download-html5-charting-graphing-library/)
|
|
@@ -120,10 +120,11 @@ stockChart.render();
|
|
|
120
120
|
|
|
121
121
|
<br/>
|
|
122
122
|
|
|
123
|
-
###
|
|
124
|
-
* [
|
|
125
|
-
* [
|
|
126
|
-
* [
|
|
123
|
+
### Related StockChart Packages
|
|
124
|
+
* [React StockCharts](https://www.npmjs.com/package/@canvasjs/react-stockcharts)
|
|
125
|
+
* [Angular StockCharts](https://www.npmjs.com/package/@canvasjs/angular-stockcharts)
|
|
126
|
+
* [Vue StockCharts](https://www.npmjs.com/package/@canvasjs/vue-stockcharts)
|
|
127
|
+
* [jQuery StockCharts](https://www.npmjs.com/package/@canvasjs/jquery-stockcharts)
|
|
127
128
|
|
|
128
129
|
<br/>
|
|
129
130
|
|
package/canvasjs.stock.min.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
CanvasJS StockChart - v1.7.
|
|
2
|
+
CanvasJS StockChart - v1.7.42 GA - https://canvasjs.com/
|
|
3
3
|
Copyright 2024 fenopix
|
|
4
4
|
|
|
5
5
|
--------------------- License Information --------------------
|
|
@@ -892,46 +892,45 @@ l.size=Math.max(1.5*l.size<<0,10),l.borderColor=l.borderColor||"#FFFFFF",l.borde
|
|
|
892
892
|
"white",l.borderColor="white",g.globalAlpha=0.3,z.drawMarkers([l]),g.globalAlpha=1):"column"===b.type||"stackedColumn"===b.type||"stackedColumn100"===b.type||"bar"===b.type||"rangeBar"===b.type||"stackedBar"===b.type||"stackedBar100"===b.type||"rangeColumn"===b.type||"waterfall"===b.type?ca(g,e.x1,e.y1,e.x2,e.y2,"white",0,null,!1,!1,!1,!1,0.3):"pie"===b.type||"doughnut"===b.type?d(g,e.center,e.radius,"white",b.type,e.startAngle,e.endAngle,0.3,e.percentInnerRadius):"funnel"===b.type||"pyramid"===b.type?
|
|
893
893
|
y(g,e.funnelSection,0.3,"white"):"candlestick"===b.type?(g.globalAlpha=1,g.strokeStyle=e.color,g.lineWidth=2*e.borderThickness,b=0===g.lineWidth%2?0:0.5,g.beginPath(),g.moveTo(e.x3-b,Math.min(e.y2,e.y3)),g.lineTo(e.x3-b,Math.min(e.y1,e.y4)),g.stroke(),g.beginPath(),g.moveTo(e.x3-b,Math.max(e.y1,e.y4)),g.lineTo(e.x3-b,Math.max(e.y2,e.y3)),g.stroke(),ca(g,e.x1,Math.min(e.y1,e.y4),e.x2,Math.max(e.y1,e.y4),"transparent",2*e.borderThickness,e.color,!1,!1,!1,!1),g.globalAlpha=1):"ohlc"===b.type?(g.globalAlpha=
|
|
894
894
|
1,g.strokeStyle=e.color,g.lineWidth=2*e.borderThickness,b=0===g.lineWidth%2?0:0.5,g.beginPath(),g.moveTo(e.x3-b,e.y2),g.lineTo(e.x3-b,e.y3),g.stroke(),g.beginPath(),g.moveTo(e.x3,e.y1),g.lineTo(e.x1,e.y1),g.stroke(),g.beginPath(),g.moveTo(e.x3,e.y4),g.lineTo(e.x2,e.y4),g.stroke(),g.globalAlpha=1):"boxAndWhisker"===b.type?(g.save(),g.globalAlpha=1,g.strokeStyle=e.stemColor,g.lineWidth=2*e.stemThickness,0<e.stemThickness&&(g.beginPath(),g.moveTo(e.x3,e.y2+e.borderThickness/2),g.lineTo(e.x3,e.y1+e.whiskerThickness/
|
|
895
|
-
2),g.stroke(),g.beginPath(),g.moveTo(e.x3,e.y4-e.whiskerThickness/2),g.lineTo(e.x3,e.y3-e.borderThickness/2),g.stroke()),g.beginPath(),ca(g,e.x1
|
|
896
|
-
e.whiskerLength/2),e.
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
"
|
|
902
|
-
|
|
903
|
-
"
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
this.
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
this.
|
|
918
|
-
0
|
|
919
|
-
c=
|
|
920
|
-
|
|
921
|
-
l
|
|
922
|
-
qa.prototype.
|
|
923
|
-
a
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
(c.target.style.cursor=f.cursor):(c.target.style.cursor=this.chart.panEnabled?"itemmouseout"!==e.mouseout||f.dockInsidePlotArea?"move":this.chart._defaultCursor:this.chart._defaultCursor,delete a.eventParameter,delete a.eventContext);"click"===d&&("dataPoint"===a.objectType&&this.chart.pieDoughnutClickHandler)&&this.chart.pieDoughnutClickHandler.call(this.chart.data[a.dataSeriesIndex],b);"click"===d&&("dataPoint"===a.objectType&&this.chart.funnelPyramidClickHandler)&&this.chart.funnelPyramidClickHandler.call(this.chart.data[a.dataSeriesIndex],
|
|
895
|
+
2),g.stroke(),g.beginPath(),g.moveTo(e.x3,e.y4-e.whiskerThickness/2),g.lineTo(e.x3,e.y3-e.borderThickness/2),g.stroke()),g.beginPath(),ca(g,e.x1,Math.max(e.y2,e.y3),e.x2,Math.min(e.y2,e.y3),"transparent",2*e.borderThickness,e.color,!1,!1,!1,!1),g.globalAlpha=1,g.strokeStyle=e.whiskerColor,g.lineWidth=2*e.whiskerThickness,0<e.whiskerThickness&&(g.beginPath(),g.moveTo(Math.floor(e.x3-e.whiskerLength/2),e.y4),g.lineTo(Math.ceil(e.x3+e.whiskerLength/2),e.y4),g.stroke(),g.beginPath(),g.moveTo(Math.floor(e.x3-
|
|
896
|
+
e.whiskerLength/2),e.y1),g.lineTo(Math.ceil(e.x3+e.whiskerLength/2),e.y1),g.stroke()),g.globalAlpha=1,g.strokeStyle=e.lineColor,g.lineWidth=2*e.lineThickness,0<e.lineThickness&&(g.beginPath(),g.moveTo(e.x1,e.y5),g.lineTo(e.x2,e.y5),g.stroke()),g.restore(),g.globalAlpha=1):"error"===b.type&&Q(g,e.x1,e.y1,e.x2,e.y2,"white",e.whiskerProperties,e.stemProperties,e.isXYSwapped,0.3))}}g.restore();g.globalAlpha=1;g.beginPath()};qa.prototype.getToolTipInnerHTML=function(a){a=a.entries;var d=null,c=null,b=
|
|
897
|
+
null,e=0,l="";this.isToolTipDefinedInData=!0;for(var f=0;f<a.length;f++)if(a[f].dataSeries.toolTipContent||a[f].dataPoint.toolTipContent){this.isToolTipDefinedInData=!1;break}if(this.isToolTipDefinedInData&&(this.content&&"function"===typeof this.content||this.contentFormatter))a={chart:this.chart,toolTip:this.options,entries:a},d=this.contentFormatter?this.contentFormatter(a):this.content(a);else if(this.shared&&"none"!==this.chart.plotInfo.axisPlacement){for(var k=null,t="",f=0;f<a.length;f++){c=
|
|
898
|
+
a[f].dataSeries;b=a[f].dataPoint;e=a[f].index;l="";if(0===f&&this.isToolTipDefinedInData&&!this.content){this.chart.axisX&&0<this.chart.axisX.length?t+="undefined"!==typeof this.chart.axisX[0].labels[b.x]?this.chart.axisX[0].labels[b.x]:"{x}":this.chart.axisX2&&0<this.chart.axisX2.length&&(t+="undefined"!==typeof this.chart.axisX2[0].labels[b.x]?this.chart.axisX2[0].labels[b.x]:"{x}");t+="</br>";if(!c.visible)continue;t=this.chart.replaceKeywordsWithValue(t,b,c,e)}null===b.toolTipContent||"undefined"===
|
|
899
|
+
typeof b.toolTipContent&&null===c.options.toolTipContent||("line"===c.type||"stepLine"===c.type||"spline"===c.type||"area"===c.type||"stepArea"===c.type||"splineArea"===c.type||"column"===c.type||"bar"===c.type||"scatter"===c.type||"stackedColumn"===c.type||"stackedColumn100"===c.type||"stackedBar"===c.type||"stackedBar100"===c.type||"stackedArea"===c.type||"stackedArea100"===c.type||"waterfall"===c.type?(this.chart.axisX&&1<this.chart.axisX.length&&(l+=k!=c.axisXIndex?c.axisX.title?c.axisX.title+
|
|
900
|
+
"<br/>":"X:{axisXIndex}<br/>":""),l+=b.toolTipContent?b.toolTipContent:c.toolTipContent?c.toolTipContent:this.content&&"function"!==typeof this.content?this.content:"<span data-color='\""+(this.options.fontColor?"":"'{color}'")+"\"'>{name}:</span> {y}",k=c.axisXIndex):"bubble"===c.type?(this.chart.axisX&&1<this.chart.axisX.length&&(l+=k!=c.axisXIndex?c.axisX.title?c.axisX.title+"<br/>":"X:{axisXIndex}<br/>":""),l+=b.toolTipContent?b.toolTipContent:c.toolTipContent?c.toolTipContent:this.content&&
|
|
901
|
+
"function"!==typeof this.content?this.content:"<span data-color='\""+(this.options.fontColor?"":"'{color}'")+"\"'>{name}:</span> {y}, {z}"):"rangeColumn"===c.type||"rangeBar"===c.type||"rangeArea"===c.type||"rangeSplineArea"===c.type||"error"===c.type?(this.chart.axisX&&1<this.chart.axisX.length&&(l+=k!=c.axisXIndex?c.axisX.title?c.axisX.title+"<br/>":"X:{axisXIndex}<br/>":""),l+=b.toolTipContent?b.toolTipContent:c.toolTipContent?c.toolTipContent:this.content&&"function"!==
|
|
902
|
+
typeof this.content?this.content:"<span data-color='\""+(this.options.fontColor?"":"'{color}'")+"\"'>{name}:</span> {y[0]}, {y[1]}"):"candlestick"===c.type||"ohlc"===c.type?(this.chart.axisX&&1<this.chart.axisX.length&&(l+=k!=c.axisXIndex?c.axisX.title?c.axisX.title+"<br/>":"X:{axisXIndex}<br/>":""),l+=b.toolTipContent?b.toolTipContent:c.toolTipContent?c.toolTipContent:this.content&&"function"!==typeof this.content?this.content:"<span data-color='\""+(this.options.fontColor?"":"'{color}'")+
|
|
903
|
+
"\"'>{name}:</span><br/>Open: {y[0]}<br/>High: {y[1]}<br/>Low: {y[2]}<br/>Close: {y[3]}"):"boxAndWhisker"===c.type&&(this.chart.axisX&&1<this.chart.axisX.length&&(l+=k!=c.axisXIndex?c.axisX.title?c.axisX.title+"<br/>":"X:{axisXIndex}<br/>":""),l+=b.toolTipContent?b.toolTipContent:c.toolTipContent?c.toolTipContent:this.content&&"function"!==typeof this.content?this.content:"<span data-color='\""+(this.options.fontColor?"":"'{color}'")+"\"'>{name}:</span><br/>Minimum: {y[0]}<br/>Q1: {y[1]}<br/>Q2: {y[4]}<br/>Q3: {y[2]}<br/>Maximum: {y[3]}"),
|
|
904
|
+
null===d&&(d=""),c.visible&&(!0===this.reversed?(d=this.chart.replaceKeywordsWithValue(l,b,c,e)+d,f<a.length-1&&(d="</br>"+d)):(d+=this.chart.replaceKeywordsWithValue(l,b,c,e),f<a.length-1&&(d+="</br>"))))}null!==d&&(d=t+d)}else{c=a[0].dataSeries;b=a[0].dataPoint;e=a[0].index;if(null===b.toolTipContent||"undefined"===typeof b.toolTipContent&&null===c.options.toolTipContent)return null;"line"===c.type||"stepLine"===c.type||"spline"===c.type||"area"===c.type||"stepArea"===c.type||"splineArea"===c.type||
|
|
905
|
+
"column"===c.type||"bar"===c.type||"scatter"===c.type||"stackedColumn"===c.type||"stackedColumn100"===c.type||"stackedBar"===c.type||"stackedBar100"===c.type||"stackedArea"===c.type||"stackedArea100"===c.type||"waterfall"===c.type?l=b.toolTipContent?b.toolTipContent:c.toolTipContent?c.toolTipContent:this.content&&"function"!==typeof this.content?this.content:"<span data-color='\""+(this.options.fontColor?"":"'{color}'")+"\"'>"+(b.label?"{label}":"{x}")+":</span> {y}":"bubble"===c.type?
|
|
906
|
+
l=b.toolTipContent?b.toolTipContent:c.toolTipContent?c.toolTipContent:this.content&&"function"!==typeof this.content?this.content:"<span data-color='\""+(this.options.fontColor?"":"'{color}'")+"\"'>"+(b.label?"{label}":"{x}")+":</span> {y}, {z}":"pie"===c.type||"doughnut"===c.type||"funnel"===c.type||"pyramid"===c.type?l=b.toolTipContent?b.toolTipContent:c.toolTipContent?c.toolTipContent:this.content&&"function"!==typeof this.content?this.content:"<span data-color='\""+(this.options.fontColor?
|
|
907
|
+
"":"'{color}'")+"\"'>"+(b.name?"{name}:</span> ":b.label?"{label}:</span> ":"</span>")+"{y}":"rangeColumn"===c.type||"rangeBar"===c.type||"rangeArea"===c.type||"rangeSplineArea"===c.type||"error"===c.type?l=b.toolTipContent?b.toolTipContent:c.toolTipContent?c.toolTipContent:this.content&&"function"!==typeof this.content?this.content:"<span data-color='\""+(this.options.fontColor?"":"'{color}'")+"\"'>"+(b.label?"{label}":"{x}")+" :</span> {y[0]}, {y[1]}":"candlestick"===
|
|
908
|
+
c.type||"ohlc"===c.type?l=b.toolTipContent?b.toolTipContent:c.toolTipContent?c.toolTipContent:this.content&&"function"!==typeof this.content?this.content:"<span data-color='\""+(this.options.fontColor?"":"'{color}'")+"\"'>"+(b.label?"{label}":"{x}")+"</span><br/>Open: {y[0]}<br/>High: {y[1]}<br/>Low: {y[2]}<br/>Close: {y[3]}":"boxAndWhisker"===c.type&&(l=b.toolTipContent?b.toolTipContent:c.toolTipContent?c.toolTipContent:this.content&&
|
|
909
|
+
"function"!==typeof this.content?this.content:"<span data-color='\""+(this.options.fontColor?"":"'{color}'")+"\"'>"+(b.label?"{label}":"{x}")+"</span><br/>Minimum: {y[0]}<br/>Q1: {y[1]}<br/>Q2: {y[4]}<br/>Q3: {y[2]}<br/>Maximum: {y[3]}");null===d&&(d="");d+=this.chart.replaceKeywordsWithValue(l,
|
|
910
|
+
b,c,e)}return d};qa.prototype.enableAnimation=function(){if(!this.container.style.WebkitTransition){var a=this.getContainerTransition(this.containerTransitionDuration);this.container.style.WebkitTransition=a;this.container.style.MsTransition=a;this.container.style.transition=a;this.container.style.MozTransition=this.mozContainerTransition}};qa.prototype.disableAnimation=function(){this.container.style.WebkitTransition&&(this.container.style.WebkitTransition="",this.container.style.MozTransition="",
|
|
911
|
+
this.container.style.MsTransition="",this.container.style.transition="")};qa.prototype.hide=function(a){this.container&&(this.container.style.display="none",this.currentSeriesIndex=-1,this._prevY=this._prevX=NaN,("undefined"===typeof a||a)&&this.chart.resetOverlayedCanvas())};qa.prototype.show=function(a,d,c){this._updateToolTip(a,d,"undefined"===typeof c?!1:c)};qa.prototype.showAtIndex=function(a,d){};qa.prototype.showAtX=function(a,d){if(!this.enabled)return!1;this.chart.clearedOverlayedCanvas=
|
|
912
|
+
null;var c,b,e,l=[];e=!1;d=!f(d)&&0<=d&&d<this.chart.data.length?d:0;if(this.shared)for(var k=0;k<this.chart.data.length;k++)c=this.chart.data[k],(b=c.getDataPointAtX(a,!1))&&(b.dataPoint&&!f(b.dataPoint.y)&&c.visible)&&(b.dataSeries=c,l.push(b));else c=this.chart.data[d],(b=c.getDataPointAtX(a,!1))&&(b.dataPoint&&!f(b.dataPoint.y)&&c.visible)&&(b.dataSeries=c,l.push(b));if(0<l.length){for(k=0;k<l.length;k++)if(b=l[k],(this.shared||0<=b.dataSeries.type.indexOf("100"))&&b.dataPoint.x>=b.dataSeries.axisX.viewportMinimum&&
|
|
913
|
+
b.dataPoint.x<=b.dataSeries.axisX.viewportMaximum){e=!1;break}else if(b.dataPoint.x<b.dataSeries.axisX.viewportMinimum||b.dataPoint.x>b.dataSeries.axisX.viewportMaximum||b.dataPoint.y<b.dataSeries.axisY.viewportMinimum||b.dataPoint.y>b.dataSeries.axisY.viewportMaximum)e=!0;else{e=!1;break}if(e)return this.hide(),!1;this.highlightObjects(l);this._entries=l;k="";k=this.getToolTipInnerHTML({entries:l});if(null!==k){this.contentDiv.innerHTML=k;if(this.isToolTipDefinedInData&&f(this.options.content)&&
|
|
914
|
+
f(this.options.contentFormatter))for(b=this.contentDiv.getElementsByTagName("span"),k=0;k<b.length;k++)b[k]&&(b[k].style.color=b[k].getAttribute("data-color"));k=!1;"none"===this.container.style.display&&(k=!0,this.container.style.display="block");try{this.contentDiv.style.background=this.backgroundColor?this.backgroundColor:s?"rgba(255,255,255,.9)":"rgb(255,255,255)",this.borderColor="waterfall"===l[0].dataSeries.type?this.contentDiv.style.borderRightColor=this.contentDiv.style.borderLeftColor=this.contentDiv.style.borderColor=
|
|
915
|
+
this.options.borderColor?this.options.borderColor:l[0].dataPoint.color?l[0].dataPoint.color:0<l[0].dataPoint.y?l[0].dataSeries.risingColor:l[0].dataSeries.fallingColor:"error"===l[0].dataSeries.type?this.contentDiv.style.borderRightColor=this.contentDiv.style.borderLeftColor=this.contentDiv.style.borderColor=this.options.borderColor?this.options.borderColor:l[0].dataSeries.color?l[0].dataSeries.color:l[0].dataSeries._colorSet[c.index%l[0].dataSeries._colorSet.length]:this.contentDiv.style.borderRightColor=
|
|
916
|
+
this.contentDiv.style.borderLeftColor=this.contentDiv.style.borderColor=this.options.borderColor?this.options.borderColor:l[0].dataPoint.color?l[0].dataPoint.color:l[0].dataSeries.color?l[0].dataSeries.color:l[0].dataSeries._colorSet[l[0].index%l[0].dataSeries._colorSet.length],this.contentDiv.style.borderWidth=this.borderThickness||0===this.borderThickness?this.borderThickness+"px":"2px",this.contentDiv.style.borderRadius=this.cornerRadius||0===this.cornerRadius?this.cornerRadius+"px":"5px",this.container.style.borderRadius=
|
|
917
|
+
this.contentDiv.style.borderRadius,this.contentDiv.style.fontSize=this.fontSize||0===this.fontSize?this.fontSize+"px":"14px",this.contentDiv.style.color=this.fontColor?this.fontColor:"#000000",this.contentDiv.style.fontFamily=this.fontFamily?this.fontFamily:"Calibri, Arial, Georgia, serif;",this.contentDiv.style.fontWeight=this.fontWeight?this.fontWeight:"normal",this.contentDiv.style.fontStyle=this.fontStyle?this.fontStyle:s?"italic":"normal"}catch(t){}"pie"===l[0].dataSeries.type||"doughnut"===
|
|
918
|
+
l[0].dataSeries.type||"funnel"===l[0].dataSeries.type||"pyramid"===l[0].dataSeries.type?c=mouseX-10-this.container.clientWidth:(c="bar"===l[0].dataSeries.type||"rangeBar"===l[0].dataSeries.type||"stackedBar"===l[0].dataSeries.type||"stackedBar100"===l[0].dataSeries.type?l[0].dataSeries.axisY.convertValueToPixel(l[0].dataPoint.y)-this.container.clientWidth<<0:l[0].dataSeries.axisX.convertValueToPixel(l[0].dataPoint.x)-this.container.clientWidth<<0,c-=10);0>c&&(c+=this.container.clientWidth+20);c+this.container.clientWidth>
|
|
919
|
+
Math.max(this.chart.container.clientWidth,this.chart.width)&&(c=Math.max(0,Math.max(this.chart.container.clientWidth,this.chart.width)-this.container.clientWidth));l=1!==l.length||this.shared||"line"!==l[0].dataSeries.type&&"stepLine"!==l[0].dataSeries.type&&"spline"!==l[0].dataSeries.type&&"area"!==l[0].dataSeries.type&&"stepArea"!==l[0].dataSeries.type&&"splineArea"!==l[0].dataSeries.type?"bar"===l[0].dataSeries.type||"rangeBar"===l[0].dataSeries.type||"stackedBar"===l[0].dataSeries.type||"stackedBar100"===
|
|
920
|
+
l[0].dataSeries.type?l[0].dataSeries.axisX.convertValueToPixel(l[0].dataPoint.x):l[0].dataSeries.axisY.convertValueToPixel(l[0].dataPoint.y):l[0].dataSeries.axisY.convertValueToPixel(l[0].dataPoint.y);l=-l+10;0<l+this.container.clientHeight+5&&(l-=l+this.container.clientHeight+5-0);this.fixMozTransitionDelay(c,l);!this.animationEnabled||k?this.disableAnimation():(this.enableAnimation(),this.container.style.MozTransition=this.mozContainerTransition);this.container.style.left=c+"px";this.container.style.bottom=
|
|
921
|
+
l+"px"}else return this.hide(!1),!1}else return this.hide(),!1;return!0};qa.prototype.fixMozTransitionDelay=function(a,d){if(20<this.chart._eventManager.lastObjectId)this.mozContainerTransition=this.getContainerTransition(0);else{var c=parseFloat(this.container.style.left),c=isNaN(c)?0:c,b=parseFloat(this.container.style.bottom),b=isNaN(b)?0:b;10<Math.sqrt(Math.pow(c-a,2)+Math.pow(b-d,2))?this.mozContainerTransition=this.getContainerTransition(0.1):this.mozContainerTransition=this.getContainerTransition(0)}};
|
|
922
|
+
qa.prototype.getContainerTransition=function(a){return"left "+a+"s ease-out 0s, bottom "+a+"s ease-out 0s"};ha.prototype.reset=function(){this.lastObjectId=0;this.objectMap=[];this.rectangularRegionEventSubscriptions=[];this.previousDataPointEventObject=null;this.eventObjects=[];s&&(this.ghostCtx.clearRect(0,0,this.chart.width,this.chart.height),this.ghostCtx.beginPath())};ha.prototype.getNewObjectTrackingId=function(){return++this.lastObjectId};ha.prototype.mouseEventHandler=function(a){if("mousemove"===
|
|
923
|
+
a.type||"click"===a.type){var d=[],c=Ba(a),b=null;if((b=this.chart.getObjectAtXY(c.x,c.y,!1))&&"undefined"!==typeof this.objectMap[b])if(b=this.objectMap[b],"dataPoint"===b.objectType){var e=this.chart.data[b.dataSeriesIndex],f=e.dataPoints[b.dataPointIndex],k=b.dataPointIndex;b.eventParameter={x:c.x,y:c.y,dataPoint:f,dataSeries:e.options,dataPointIndex:k,dataSeriesIndex:e.index,chart:this.chart};b.eventContext={context:f,userContext:f,mouseover:"mouseover",mousemove:"mousemove",mouseout:"mouseout",
|
|
924
|
+
click:"click"};d.push(b);b=this.objectMap[e.id];b.eventParameter={x:c.x,y:c.y,dataPoint:f,dataSeries:e.options,dataPointIndex:k,dataSeriesIndex:e.index,chart:this.chart};b.eventContext={context:e,userContext:e.options,mouseover:"mouseover",mousemove:"mousemove",mouseout:"mouseout",click:"click"};d.push(this.objectMap[e.id])}else"legendItem"===b.objectType&&(e=this.chart.data[b.dataSeriesIndex],f=null!==b.dataPointIndex?e.dataPoints[b.dataPointIndex]:null,b.eventParameter={x:c.x,y:c.y,dataSeries:e.options,
|
|
925
|
+
dataPoint:f,dataPointIndex:b.dataPointIndex,dataSeriesIndex:b.dataSeriesIndex,chart:this.chart},b.eventContext={context:this.chart.legend,userContext:this.chart.legend.options,mouseover:"itemmouseover",mousemove:"itemmousemove",mouseout:"itemmouseout",click:"itemclick"},d.push(b));e=[];for(c=0;c<this.mouseoveredObjectMaps.length;c++){f=!0;for(b=0;b<d.length;b++)if(d[b].id===this.mouseoveredObjectMaps[c].id){f=!1;break}f?this.fireEvent(this.mouseoveredObjectMaps[c],"mouseout",a):e.push(this.mouseoveredObjectMaps[c])}this.mouseoveredObjectMaps=
|
|
926
|
+
e;for(c=0;c<d.length;c++){e=!1;for(b=0;b<this.mouseoveredObjectMaps.length;b++)if(d[c].id===this.mouseoveredObjectMaps[b].id){e=!0;break}e||(this.fireEvent(d[c],"mouseover",a),this.mouseoveredObjectMaps.push(d[c]));"click"===a.type?this.fireEvent(d[c],"click",a):"mousemove"===a.type&&this.fireEvent(d[c],"mousemove",a)}}};ha.prototype.fireEvent=function(a,d,c){if(a&&d){var b=a.eventParameter,e=a.eventContext,f=a.eventContext.userContext;f&&(e&&f[e[d]])&&f[e[d]].call(f,b);"mouseout"!==d?f.cursor&&f.cursor!==
|
|
927
|
+
c.target.style.cursor&&(c.target.style.cursor=f.cursor):(c.target.style.cursor=this.chart.panEnabled?"itemmouseout"!==e.mouseout||f.dockInsidePlotArea?"move":this.chart._defaultCursor:this.chart._defaultCursor,delete a.eventParameter,delete a.eventContext);"click"===d&&("dataPoint"===a.objectType&&this.chart.pieDoughnutClickHandler)&&this.chart.pieDoughnutClickHandler.call(this.chart.data[a.dataSeriesIndex],b);"click"===d&&("dataPoint"===a.objectType&&this.chart.funnelPyramidClickHandler)&&this.chart.funnelPyramidClickHandler.call(this.chart.data[a.dataSeriesIndex],
|
|
929
928
|
b)}};ja.prototype.animate=function(a,d,c,b,e){var f=this;this.chart.isAnimating=!0;e=e||t.easing.linear;c&&this.animations.push({startTime:(new Date).getTime()+(a?a:0),duration:d,animationCallback:c,onComplete:b});for(a=[];0<this.animations.length;)if(d=this.animations.shift(),c=(new Date).getTime(),b=0,d.startTime<=c&&(b=e(Math.min(c-d.startTime,d.duration),0,1,d.duration),b=Math.min(b,1),isNaN(b)||!isFinite(b))&&(b=1),1>b&&a.push(d),d.animationCallback(b),1<=b&&d.onComplete)d.onComplete();this.animations=
|
|
930
929
|
a;0<this.animations.length?this.animationRequestId=this.chart.requestAnimFrame.call(window,function(){f.animate.call(f)}):this.chart.isAnimating=!1};ja.prototype.cancelAllAnimations=function(){this.animations=[];this.animationRequestId&&this.chart.cancelRequestAnimFrame.call(window,this.animationRequestId);this.animationRequestId=null;this.chart.isAnimating=!1};var t={yScaleAnimation:function(a,d){if(0!==a){var c=d.dest,b=d.source.canvas,e=d.animationBase;c.drawImage(b,0,0,b.width,b.height,0,e-e*
|
|
931
930
|
a,c.canvas.width/ia,a*c.canvas.height/ia)}},xScaleAnimation:function(a,d){if(0!==a){var c=d.dest,b=d.source.canvas,e=d.animationBase;c.drawImage(b,0,0,b.width,b.height,e-e*a,0,a*c.canvas.width/ia,c.canvas.height/ia)}},xClipAnimation:function(a,d){if(0!==a){var c=d.dest,b=d.source.canvas;c.save();0<a&&c.drawImage(b,0,0,b.width*a,b.height,0,0,b.width*a/ia,b.height/ia);c.restore()}},fadeInAnimation:function(a,d){if(0!==a){var c=d.dest,b=d.source.canvas;c.save();c.globalAlpha=a;c.drawImage(b,0,0,b.width,
|
|
932
931
|
b.height,0,0,c.canvas.width/ia,c.canvas.height/ia);c.restore()}},easing:{linear:function(a,d,c,b){return c*a/b+d},easeOutQuad:function(a,d,c,b){return-c*(a/=b)*(a-2)+d},easeOutQuart:function(a,d,c,b){return-c*((a=a/b-1)*a*a*a-1)+d},easeInQuad:function(a,d,c,b){return c*(a/=b)*a+d},easeInQuart:function(a,d,c,b){return c*(a/=b)*a*a*a+d}}},z={drawMarker:function(a,d,c,b,e,f,k,t){if(c){var m=1;c.fillStyle=f?f:"#000000";c.strokeStyle=k?k:"#000000";c.lineWidth=t?t:0;c.setLineDash&&c.setLineDash(X("solid",
|
|
933
932
|
t));"circle"===b?(c.moveTo(a,d),c.beginPath(),c.arc(a,d,e/2,0,2*Math.PI,!1),f&&c.fill(),t&&(k?c.stroke():(m=c.globalAlpha,c.globalAlpha=0.15,c.strokeStyle="black",c.stroke(),c.globalAlpha=m))):"square"===b?(c.beginPath(),c.rect(a-e/2,d-e/2,e,e),f&&c.fill(),t&&(k?c.stroke():(m=c.globalAlpha,c.globalAlpha=0.15,c.strokeStyle="black",c.stroke(),c.globalAlpha=m))):"triangle"===b?(c.beginPath(),c.moveTo(a-e/2,d+e/2),c.lineTo(a+e/2,d+e/2),c.lineTo(a,d-e/2),c.closePath(),f&&c.fill(),t&&(k?c.stroke():(m=c.globalAlpha,
|
|
934
|
-
c.globalAlpha=0.15,c.strokeStyle="black",c.stroke(),c.globalAlpha=m)),c.beginPath()):"cross"===b&&(c.strokeStyle=f,c.lineWidth=e/4,c.beginPath(),c.moveTo(a-e/2,d-e/2),c.lineTo(a+e/2,d+e/2),c.stroke(),c.moveTo(a+e/2,d-e/2),c.lineTo(a-e/2,d+e/2),c.stroke())}},drawMarkers:function(a){for(var d=0;d<a.length;d++){var c=a[d];z.drawMarker(c.x,c.y,c.ctx,c.type,c.size,c.color,c.borderColor,c.borderThickness)}}};return m}();Ka.version="v3.7.
|
|
933
|
+
c.globalAlpha=0.15,c.strokeStyle="black",c.stroke(),c.globalAlpha=m)),c.beginPath()):"cross"===b&&(c.strokeStyle=f,c.lineWidth=e/4,c.beginPath(),c.moveTo(a-e/2,d-e/2),c.lineTo(a+e/2,d+e/2),c.stroke(),c.moveTo(a+e/2,d-e/2),c.lineTo(a-e/2,d+e/2),c.stroke())}},drawMarkers:function(a){for(var d=0;d<a.length;d++){var c=a[d];z.drawMarker(c.x,c.y,c.ctx,c.type,c.size,c.color,c.borderColor,c.borderThickness)}}};return m}();Ka.version="v3.7.42 GA";window.CanvasJS&&(Ka&&!window.CanvasJS.Chart)&&(window.CanvasJS.Chart=
|
|
935
934
|
Ka);ha.StockChart={width:500,height:600,backgroundColor:"white",theme:"light1",animationEnabled:!1,animationDuration:1200,culture:"en",creditHref:"",creditText:"CanvasJS",exportEnabled:!1,exportFileName:"StockChart",colorSet:"colorSet1",rangeChanging:null,rangeChanged:null,publicProperties:{title:"readWrite",subtitles:"readWrite",toolbar:"readWrite",navigator:"readWrite",rangeSelector:"readWrite",charts:"readWrite",options:"readWrite",bounds:"readOnly",container:"readOnly",selectedColorSet:"readOnly"}};
|
|
936
935
|
ha.Navigator={enabled:!0,width:500,height:70,verticalAlign:"bottom",horizontalAlign:"center",dynamicUpdate:!0,backgroundColor:"#fff",animationEnabled:!1,animationDuration:1200,theme:"light1",publicProperties:{slider:"readWrite",backgroundColor:"readWrite",animationEnabled:"readWrite",animationDuration:"readWrite",theme:"readWrite",axisX:"readWrite",axisY:"readWrite",axisX2:"readWrite",axisY2:"readWrite",data:"readWrite",options:"readWrite",bounds:"readOnly"}};ha.RangeSelector={enabled:!0,width:500,
|
|
937
936
|
height:35,label:"Range",verticalAlign:"top",horizontalAlign:"center",selectedRangeButtonIndex:null,publicProperties:{options:"readWrite",buttons:"readWrite",inputFields:"readWrite",buttonStyle:"readWrite",bounds:"readOnly"}};ha.RangeButton={range:null,rangeType:null,label:null,style:"position: inline; margin: 5px 0;text-align:center;cursor: pointer;",backgroundColorDisabled:"#ddd",publicProperties:{options:"readWrite",bounds:"readOnly"}};ha.ButtonStyle={backgroundColor:"#fff",backgroundColorOnHover:"#2196f3",
|
|
@@ -1117,7 +1116,7 @@ k[d]:this.label};N.prototype.render=function(){this.textBlock.render(!0)};ga(T,b
|
|
|
1117
1116
|
this.style.fontFamily,this.elements[d].style.fontWeight=this.style.fontWeight,this.elements[d].style.lineHeight=1,isNaN(this.style.padding)?(this.elements[d].style.paddingTop=this.style.padding.top+"px",this.elements[d].style.paddingRight=this.style.padding.right+"px",this.elements[d].style.paddingBottom=this.style.padding.bottom+"px",this.elements[d].style.paddingLeft=this.style.padding.left+"px"):this.elements[d].style.padding=this.style.padding+"px",this.elements[d].style.mozAppearance=this.elements[d].style.webkitAppearance=
|
|
1118
1117
|
this.elements[d].style.appearance="none",this.elements[d].style.webkitBorderRadius=0,this.elements[d].style.mozBorderRadius=0,this.elements[d].style.borderRadius=0,this.elements[d].style.boxSizing="content-box";this.parent=this.rangeSelector=this.stockChart.rangeSelector}};ga(X,ba);X.prototype._updateOptions=function(){this.updateOption("backgroundColor");this.updateOption("backgroundColorOnHover");this.updateOption("backgroundColorOnSelect");this.updateOption("borderColor");this.updateOption("borderThickness");
|
|
1119
1118
|
this.updateOption("labelFontColor");this.updateOption("labelFontColorOnHover");this.updateOption("labelFontSize");this.updateOption("labelFontStyle");this.updateOption("labelFontFamily");this.updateOption("labelFontWeight");this.updateOption("width");this.updateOption("maxWidth");this.updateOption("padding");this.updateOption("spacing");this.updateOption("cursor")};ga(Y,ba);Y.prototype._updateOptions=function(){this.updateOption("backgroundColor");this.updateOption("borderColor");this.updateOption("borderThickness");
|
|
1120
|
-
this.updateOption("borderColorOnFocus");this.updateOption("fontColor");this.updateOption("fontSize");this.updateOption("fontStyle");this.updateOption("fontFamily");this.updateOption("fontWeight");this.updateOption("width");this.updateOption("maxWidth");this.updateOption("padding");this.updateOption("spacing");this.updateOption("cursor")};return H}();T.version="v1.7.
|
|
1119
|
+
this.updateOption("borderColorOnFocus");this.updateOption("fontColor");this.updateOption("fontSize");this.updateOption("fontStyle");this.updateOption("fontFamily");this.updateOption("fontWeight");this.updateOption("width");this.updateOption("maxWidth");this.updateOption("padding");this.updateOption("spacing");this.updateOption("cursor")};return H}();T.version="v1.7.42 GA";window.CanvasJS&&(T&&(!window.CanvasJS.StockChart&&window.CanvasJS.Chart)&&(window.CanvasJS.StockChart=T),T&&!window.CanvasJS.Chart&&
|
|
1121
1120
|
(window.CanvasJS.Chart=Ka,window.CanvasJS.StockChart=T))})();
|
|
1122
1121
|
|
|
1123
1122
|
/*
|
package/package.json
CHANGED
|
@@ -1,16 +1,17 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@canvasjs/stockcharts",
|
|
3
|
-
"version": "1.7.
|
|
3
|
+
"version": "1.7.42",
|
|
4
4
|
"description": "CanvasJS JavaScript StockCharts - Official",
|
|
5
5
|
"main": "canvasjs.stock.min.js",
|
|
6
6
|
"keywords": [
|
|
7
7
|
"javascript",
|
|
8
|
-
"
|
|
8
|
+
"stockcharts",
|
|
9
9
|
"financial chart",
|
|
10
|
-
"javascript
|
|
10
|
+
"javascript stockcharts",
|
|
11
11
|
"javascript stockchart library",
|
|
12
12
|
"html5 stockcharts",
|
|
13
13
|
"js stockcharts",
|
|
14
|
+
"stock chart",
|
|
14
15
|
"high performance stock charts",
|
|
15
16
|
"canvasjs"
|
|
16
17
|
],
|