@@ -1,6 +1,61 @@ | |||||
# cache | |||||
node_modules | |||||
# Logs | |||||
logs | |||||
*.log | |||||
npm-debug.log* | |||||
yarn-debug.log* | |||||
yarn-error.log* | |||||
# misc | |||||
.DS_Store | |||||
yarn.lock | |||||
# Runtime data | |||||
pids | |||||
*.pid | |||||
*.seed | |||||
*.pid.lock | |||||
# Directory for instrumented libs generated by jscoverage/JSCover | |||||
lib-cov | |||||
# Coverage directory used by tools like istanbul | |||||
coverage | |||||
# nyc test coverage | |||||
.nyc_output | |||||
# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files) | |||||
.grunt | |||||
# Bower dependency directory (https://bower.io/) | |||||
bower_components | |||||
# node-waf configuration | |||||
.lock-wscript | |||||
# Compiled binary addons (https://nodejs.org/api/addons.html) | |||||
build/Release | |||||
# Dependency directories | |||||
node_modules/ | |||||
jspm_packages/ | |||||
# Typescript v1 declaration files | |||||
typings/ | |||||
# Optional npm cache directory | |||||
.npm | |||||
# Optional eslint cache | |||||
.eslintcache | |||||
# Optional REPL history | |||||
.node_repl_history | |||||
# Output of 'npm pack' | |||||
*.tgz | |||||
# Yarn Integrity file | |||||
.yarn-integrity | |||||
# dotenv environment variables file | |||||
.env | |||||
# next.js build output | |||||
.next |
@@ -230,6 +230,10 @@ const DEFAULT_CHAR_WIDTH = 7; | |||||
const ANGLE_RATIO = Math.PI / 180; | const ANGLE_RATIO = Math.PI / 180; | ||||
const FULL_ANGLE = 360; | const FULL_ANGLE = 360; | ||||
/** | |||||
* Returns the value of a number upto 2 decimal places. | |||||
* @param {Number} d Any number | |||||
*/ | |||||
function floatTwo(d) { | function floatTwo(d) { | ||||
return parseFloat(d.toFixed(2)); | return parseFloat(d.toFixed(2)); | ||||
} | } | ||||
@@ -3256,6 +3260,7 @@ class AxisChart extends BaseChart { | |||||
// removeDataPoint(index = 0) {} | // removeDataPoint(index = 0) {} | ||||
} | } | ||||
// import MultiAxisChart from './charts/MultiAxisChart'; | |||||
const chartTypes = { | const chartTypes = { | ||||
// multiaxis: MultiAxisChart, | // multiaxis: MultiAxisChart, | ||||
percentage: PercentageChart, | percentage: PercentageChart, | ||||
@@ -3289,4 +3294,4 @@ class Chart { | |||||
} | } | ||||
} | } | ||||
export default Chart; | |||||
export { Chart, PercentageChart, PieChart, Heatmap, AxisChart }; |
@@ -1,4 +1,4 @@ | |||||
import Chart from './chart'; | |||||
import { Chart } from './chart'; | |||||
const ALL_CHART_TYPES = ['line', 'scatter', 'bar', 'percentage', 'heatmap', 'pie']; | const ALL_CHART_TYPES = ['line', 'scatter', 'bar', 'percentage', 'heatmap', 'pie']; | ||||