Skip to content

Commit e7e7820

Browse files
authored
Merge pull request #1195 from dannyvankooten/develop
Bugfix: only calculate high low from stacked values if stackMode is accumulate
2 parents de6345e + 6288745 commit e7e7820

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/scripts/charts/bar.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@
140140
var seriesGroup = this.svg.elem('g');
141141
var labelGroup = this.svg.elem('g').addClass(options.classNames.labelGroup);
142142

143-
if(options.stackBars && data.normalized.series.length !== 0) {
143+
if(options.stackBars && (options.stackMode === 'accumulate' || !options.stackMode) && data.normalized.series.length !== 0) {
144144

145145
// If stacked bars we need to calculate the high low from stacked values from each series
146146
var serialSums = Chartist.serialMap(data.normalized.series, function serialSums() {

0 commit comments

Comments
 (0)