Fixed resolution bug when switching to higher resolution
This commit is contained in:
@@ -96,6 +96,8 @@ export default class ClimateChart {
|
|||||||
const pixelsPerPoint = chartWidth / points;
|
const pixelsPerPoint = chartWidth / points;
|
||||||
if (pixelsPerPoint < MIN_PIXELS_PER_POINT) {
|
if (pixelsPerPoint < MIN_PIXELS_PER_POINT) {
|
||||||
this.resolution = Math.ceil(MIN_PIXELS_PER_POINT / pixelsPerPoint);
|
this.resolution = Math.ceil(MIN_PIXELS_PER_POINT / pixelsPerPoint);
|
||||||
|
} else {
|
||||||
|
this.resolution = 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user