Browse Source

Fix conflict

pull/535/head
Masayuki Tanaka 11 years ago
parent
commit
fd2cbf8d57
  1. 6
      c3.js
  2. 8
      c3.min.js
  3. 6
      src/domain.js

6
c3.js

@ -1239,6 +1239,12 @@
if (yTargets.length === 0) { // use current domain if target of axisId is none
return axisId === 'y2' ? $$.y2.domain() : $$.y.domain();
}
if (isNaN(yDomainMin)) { // set minimum to zero when not number
yDomainMin = 0;
}
if (isNaN(yDomainMax)) { // set maximum to have same value as yDomainMin
yDomainMax = yDomainMin;
}
if (yDomainMin === yDomainMax) {
yDomainMin < 0 ? yDomainMax = 0 : yDomainMin = 0;
}

8
c3.min.js vendored

File diff suppressed because one or more lines are too long

6
src/domain.js

@ -76,6 +76,12 @@ c3_chart_internal_fn.getYDomain = function (targets, axisId) {
if (yTargets.length === 0) { // use current domain if target of axisId is none
return axisId === 'y2' ? $$.y2.domain() : $$.y.domain();
}
if (isNaN(yDomainMin)) { // set minimum to zero when not number
yDomainMin = 0;
}
if (isNaN(yDomainMax)) { // set maximum to have same value as yDomainMin
yDomainMax = yDomainMin;
}
if (yDomainMin === yDomainMax) {
yDomainMin < 0 ? yDomainMax = 0 : yDomainMin = 0;
}

Loading…
Cancel
Save