()
| 129 | } |
| 130 | |
| 131 | handleTickRangeOptions() { |
| 132 | const {minDefined, maxDefined} = this.getUserBounds(); |
| 133 | let min = this.min; |
| 134 | let max = this.max; |
| 135 | |
| 136 | const setMin = v => (min = minDefined ? min : v); |
| 137 | const setMax = v => (max = maxDefined ? max : v); |
| 138 | |
| 139 | if (min === max) { |
| 140 | if (min <= 0) { // includes null |
| 141 | setMin(1); |
| 142 | setMax(10); |
| 143 | } else { |
| 144 | setMin(changeExponent(min, -1)); |
| 145 | setMax(changeExponent(max, +1)); |
| 146 | } |
| 147 | } |
| 148 | if (min <= 0) { |
| 149 | setMin(changeExponent(max, -1)); |
| 150 | } |
| 151 | if (max <= 0) { |
| 152 | |
| 153 | setMax(changeExponent(min, +1)); |
| 154 | } |
| 155 | |
| 156 | this.min = min; |
| 157 | this.max = max; |
| 158 | } |
| 159 | |
| 160 | buildTicks() { |
| 161 | const opts = this.options; |
no test coverage detected