|
|
|
@ -938,7 +938,7 @@ abstract class ChartwerkPod<T extends TimeSerie, O extends Options> {
|
|
|
|
|
this.series |
|
|
|
|
.filter(serie => serie.visible !== false && this.filterSerieByYAxisOrientation(serie, yAxisOrientation.LEFT)) |
|
|
|
|
.map( |
|
|
|
|
serie => minBy<number[]>(serie.datapoints, dp => dp[0])[0] |
|
|
|
|
serie => minBy<number[]>(serie.datapoints, dp => dp[1])[1] |
|
|
|
|
) |
|
|
|
|
); |
|
|
|
|
return minValue; |
|
|
|
@ -956,7 +956,7 @@ abstract class ChartwerkPod<T extends TimeSerie, O extends Options> {
|
|
|
|
|
this.series |
|
|
|
|
.filter(serie => serie.visible !== false && this.filterSerieByYAxisOrientation(serie, yAxisOrientation.LEFT)) |
|
|
|
|
.map( |
|
|
|
|
serie => maxBy<number[]>(serie.datapoints, dp => dp[0])[0] |
|
|
|
|
serie => maxBy<number[]>(serie.datapoints, dp => dp[1])[1] |
|
|
|
|
) |
|
|
|
|
); |
|
|
|
|
return maxValue; |
|
|
|
@ -974,7 +974,7 @@ abstract class ChartwerkPod<T extends TimeSerie, O extends Options> {
|
|
|
|
|
this.series |
|
|
|
|
.filter(serie => serie.visible !== false && this.filterSerieByYAxisOrientation(serie, yAxisOrientation.RIGHT)) |
|
|
|
|
.map( |
|
|
|
|
serie => minBy<number[]>(serie.datapoints, dp => dp[0])[0] |
|
|
|
|
serie => minBy<number[]>(serie.datapoints, dp => dp[1])[1] |
|
|
|
|
) |
|
|
|
|
); |
|
|
|
|
return minValue; |
|
|
|
@ -991,7 +991,7 @@ abstract class ChartwerkPod<T extends TimeSerie, O extends Options> {
|
|
|
|
|
this.series |
|
|
|
|
.filter(serie => serie.visible !== false && this.filterSerieByYAxisOrientation(serie, yAxisOrientation.RIGHT)) |
|
|
|
|
.map( |
|
|
|
|
serie => maxBy<number[]>(serie.datapoints, dp => dp[0])[0] |
|
|
|
|
serie => maxBy<number[]>(serie.datapoints, dp => dp[1])[1] |
|
|
|
|
) |
|
|
|
|
); |
|
|
|
|
return maxValue; |
|
|
|
@ -1009,7 +1009,7 @@ abstract class ChartwerkPod<T extends TimeSerie, O extends Options> {
|
|
|
|
|
this.series |
|
|
|
|
.filter(serie => serie.visible !== false) |
|
|
|
|
.map( |
|
|
|
|
serie => minBy<number[]>(serie.datapoints, dp => dp[1])[1] |
|
|
|
|
serie => minBy<number[]>(serie.datapoints, dp => dp[0])[0] |
|
|
|
|
) |
|
|
|
|
); |
|
|
|
|
return minValue; |
|
|
|
@ -1026,7 +1026,7 @@ abstract class ChartwerkPod<T extends TimeSerie, O extends Options> {
|
|
|
|
|
this.series |
|
|
|
|
.filter(serie => serie.visible !== false) |
|
|
|
|
.map( |
|
|
|
|
serie => maxBy<number[]>(serie.datapoints, dp => dp[1])[1] |
|
|
|
|
serie => maxBy<number[]>(serie.datapoints, dp => dp[0])[0] |
|
|
|
|
) |
|
|
|
|
); |
|
|
|
|
return maxValue; |
|
|
|
@ -1058,8 +1058,8 @@ abstract class ChartwerkPod<T extends TimeSerie, O extends Options> {
|
|
|
|
|
if(this.series.length === 0) { |
|
|
|
|
return undefined; |
|
|
|
|
} |
|
|
|
|
const startTimestamp = first(this.series[0].datapoints)[1]; |
|
|
|
|
const endTimestamp = last(this.series[0].datapoints)[1]; |
|
|
|
|
const startTimestamp = first(this.series[0].datapoints)[0]; |
|
|
|
|
const endTimestamp = last(this.series[0].datapoints)[0]; |
|
|
|
|
return (endTimestamp - startTimestamp) / 1000; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
@ -1095,7 +1095,7 @@ abstract class ChartwerkPod<T extends TimeSerie, O extends Options> {
|
|
|
|
|
|
|
|
|
|
get timeInterval(): number { |
|
|
|
|
if(this.series !== undefined && this.series.length > 0 && this.series[0].datapoints.length > 1) { |
|
|
|
|
const interval = this.series[0].datapoints[1][1] - this.series[0].datapoints[0][1]; |
|
|
|
|
const interval = this.series[0].datapoints[1][0] - this.series[0].datapoints[0][0]; |
|
|
|
|
return interval; |
|
|
|
|
} |
|
|
|
|
if(this.options.timeInterval !== undefined && this.options.timeInterval.count !== undefined) { |
|
|
|
|