@esfaenza/es-charts 11.2.26 → 11.2.29
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/bundles/esfaenza-es-charts.umd.js +49 -25
- package/bundles/esfaenza-es-charts.umd.js.map +1 -1
- package/bundles/esfaenza-es-charts.umd.min.js +1 -1
- package/bundles/esfaenza-es-charts.umd.min.js.map +1 -1
- package/esfaenza-es-charts.metadata.json +1 -1
- package/esm2015/lib/models/data/LineChartData.js +1 -1
- package/esm2015/lib/models/data/base/Limit.js +3 -2
- package/esm2015/lib/services/LineChartService.js +47 -25
- package/fesm2015/esfaenza-es-charts.js +48 -25
- package/fesm2015/esfaenza-es-charts.js.map +1 -1
- package/lib/models/data/LineChartData.d.ts +2 -2
- package/lib/models/data/base/Limit.d.ts +2 -1
- package/package.json +1 -1
|
@@ -600,13 +600,15 @@
|
|
|
600
600
|
*/
|
|
601
601
|
var Limit = /** @class */ (function () {
|
|
602
602
|
/** @ignore */
|
|
603
|
-
function Limit(upper, upperlabel, uppercolor, lower, lowerlabel, lowercolor) {
|
|
603
|
+
function Limit(upper, upperlabel, uppercolor, lower, lowerlabel, lowercolor, fillColor) {
|
|
604
|
+
if (fillColor === void 0) { fillColor = ""; }
|
|
604
605
|
this.upper = upper;
|
|
605
606
|
this.upperlabel = upperlabel;
|
|
606
607
|
this.uppercolor = uppercolor;
|
|
607
608
|
this.lower = lower;
|
|
608
609
|
this.lowerlabel = lowerlabel;
|
|
609
610
|
this.lowercolor = lowercolor;
|
|
611
|
+
this.fillColor = fillColor;
|
|
610
612
|
}
|
|
611
613
|
return Limit;
|
|
612
614
|
}());
|
|
@@ -1593,30 +1595,52 @@
|
|
|
1593
1595
|
yAxis.min = settings.Min;
|
|
1594
1596
|
if (settings.Max)
|
|
1595
1597
|
yAxis.max = settings.Max;
|
|
1596
|
-
|
|
1597
|
-
|
|
1598
|
-
|
|
1599
|
-
|
|
1600
|
-
|
|
1601
|
-
|
|
1602
|
-
|
|
1603
|
-
|
|
1604
|
-
|
|
1605
|
-
|
|
1606
|
-
|
|
1607
|
-
|
|
1608
|
-
|
|
1609
|
-
|
|
1610
|
-
|
|
1611
|
-
|
|
1612
|
-
|
|
1613
|
-
|
|
1614
|
-
|
|
1615
|
-
|
|
1616
|
-
|
|
1617
|
-
|
|
1618
|
-
|
|
1619
|
-
|
|
1598
|
+
var limitNullOrUndef = dataConverted.limit == null || dataConverted.limit == undefined;
|
|
1599
|
+
var limits = limitNullOrUndef ? [] : !dataConverted.limit.length ? [dataConverted.limit] : dataConverted.limit;
|
|
1600
|
+
if (limits.length > 0) {
|
|
1601
|
+
for (var i = 0; i < limits.length; i++) {
|
|
1602
|
+
var limit = limits[i];
|
|
1603
|
+
if (limit.upper != null && limit.upper != undefined && limit.lower != null && limit.lower != undefined) {
|
|
1604
|
+
var range = yAxis.axisRanges.create();
|
|
1605
|
+
range.value = limit.lower;
|
|
1606
|
+
range.endValue = limit.upper;
|
|
1607
|
+
if (limit.fillColor) {
|
|
1608
|
+
range.contents.stroke = am4core__namespace.color(limit.fillColor);
|
|
1609
|
+
range.contents.fill = range.contents.stroke;
|
|
1610
|
+
}
|
|
1611
|
+
range.label.inside = true;
|
|
1612
|
+
range.label.text = limit.upperlabel;
|
|
1613
|
+
range.label.fill = range.grid.stroke;
|
|
1614
|
+
range.label.verticalCenter = "bottom";
|
|
1615
|
+
range.label.stroke = am4core__namespace.color(limit.uppercolor || "#F92200");
|
|
1616
|
+
range.grid.stroke = am4core__namespace.color(limit.uppercolor || "#F92200");
|
|
1617
|
+
range.grid.strokeWidth = 2;
|
|
1618
|
+
range.grid.strokeOpacity = 1;
|
|
1619
|
+
}
|
|
1620
|
+
else if ((limit.lower == null || limit.lower == undefined) && limit.upper != null && limit.upper != undefined) {
|
|
1621
|
+
var range = yAxis.axisRanges.create();
|
|
1622
|
+
range.value = limit.upper;
|
|
1623
|
+
range.label.inside = true;
|
|
1624
|
+
range.label.text = limit.upperlabel;
|
|
1625
|
+
range.label.fill = range.grid.stroke;
|
|
1626
|
+
range.label.verticalCenter = "bottom";
|
|
1627
|
+
range.label.stroke = am4core__namespace.color(limit.uppercolor || "#F92200");
|
|
1628
|
+
range.grid.stroke = am4core__namespace.color(limit.uppercolor || "#F92200");
|
|
1629
|
+
range.grid.strokeWidth = 2;
|
|
1630
|
+
range.grid.strokeOpacity = 1;
|
|
1631
|
+
}
|
|
1632
|
+
else if ((limit.upper == null || limit.upper == undefined) && limit.lower != null && limit.lower != undefined) {
|
|
1633
|
+
var range = yAxis.axisRanges.create();
|
|
1634
|
+
range.value = limit.lower;
|
|
1635
|
+
range.label.inside = true;
|
|
1636
|
+
range.label.text = limit.lowerlabel;
|
|
1637
|
+
range.label.fill = range.grid.stroke;
|
|
1638
|
+
range.label.verticalCenter = "bottom";
|
|
1639
|
+
range.label.stroke = am4core__namespace.color(limit.lowercolor || "#F92200");
|
|
1640
|
+
range.grid.stroke = am4core__namespace.color(limit.lowercolor || "#F92200");
|
|
1641
|
+
range.grid.strokeWidth = 2;
|
|
1642
|
+
range.grid.strokeOpacity = 1;
|
|
1643
|
+
}
|
|
1620
1644
|
}
|
|
1621
1645
|
}
|
|
1622
1646
|
this.dateAxis = ChartInstanceCasted.xAxes.push(new am4charts__namespace.DateAxis());
|