ngx-line-chart
Advanced tools
Comparing version 0.0.1-beta.3 to 0.0.1-beta.4
@@ -101,3 +101,3 @@ import { CommonModule } from '@angular/common'; | ||
LineChartComponent.prototype.applyDefaultStyle = function () { | ||
this.style = deepmerge(this.style, LineChartComponent.DEFAULT_STYLE); | ||
this.style = deepmerge(this.style || {}, LineChartComponent.DEFAULT_STYLE); | ||
}; | ||
@@ -190,3 +190,7 @@ return LineChartComponent; | ||
} | ||
return (value - min) / (minAndMax.max - min); | ||
var /** @type {?} */ divider = minAndMax.max - min; | ||
if (divider === 0) { | ||
return 0; | ||
} | ||
return (value - min) / divider; | ||
}; | ||
@@ -193,0 +197,0 @@ /** |
@@ -105,3 +105,3 @@ (function (global, factory) { | ||
LineChartComponent.prototype.applyDefaultStyle = function () { | ||
this.style = deepmerge(this.style, LineChartComponent.DEFAULT_STYLE); | ||
this.style = deepmerge(this.style || {}, LineChartComponent.DEFAULT_STYLE); | ||
}; | ||
@@ -194,3 +194,7 @@ return LineChartComponent; | ||
} | ||
return (value - min) / (minAndMax.max - min); | ||
var /** @type {?} */ divider = minAndMax.max - min; | ||
if (divider === 0) { | ||
return 0; | ||
} | ||
return (value - min) / divider; | ||
}; | ||
@@ -197,0 +201,0 @@ /** |
{ | ||
"name": "ngx-line-chart", | ||
"version": "0.0.1-beta.3", | ||
"version": "0.0.1-beta.4", | ||
"repository": { | ||
@@ -5,0 +5,0 @@ "type": "git", |
@@ -33,3 +33,3 @@ # ngx-line-chart | ||
// Import your library | ||
// Import the module | ||
import { NgxLineChartModule } from 'ngx-line-chart'; | ||
@@ -43,2 +43,3 @@ | ||
BrowserModule, | ||
// Add module here | ||
NgxLineChartModule | ||
@@ -45,0 +46,0 @@ ], |
45986
768
113