Skip to content

Commit

Permalink
Updated tslint to us global rules. Fixed resulting linting errors
Browse files Browse the repository at this point in the history
  • Loading branch information
shaunburdick committed Dec 23, 2016
1 parent debed89 commit 1d3cfe3
Show file tree
Hide file tree
Showing 61 changed files with 632 additions and 571 deletions.
15 changes: 10 additions & 5 deletions demo/app.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -547,7 +547,9 @@ import './demo.scss';
<select
[ngModel]="curveType"
(ngModelChange)="setInterpolationType($event)">
<option *ngFor="let interpolationType of interpolationTypes" [value]="interpolationType">{{interpolationType}}</option>
<option *ngFor="let interpolationType of interpolationTypes" [value]="interpolationType">
{{interpolationType}}
</option>
</select>
</div>
Expand Down Expand Up @@ -611,7 +613,7 @@ import './demo.scss';
})
export class AppComponent implements OnInit {

theme = "dark";
theme = 'dark';
chartType = 'bar-vertical';
chartGroups: any[];
chart: any;
Expand Down Expand Up @@ -642,7 +644,10 @@ export class AppComponent implements OnInit {
// line interpolation
curveType: string = 'Linear';
curve = d3.shape.curveLinear;
interpolationTypes = ['Basis', 'Bundle', 'Cardinal', 'Catmull Rom', 'Linear', 'Monotone X', 'Monotone Y', 'Natural', 'Step', 'Step After', 'Step Before'];
interpolationTypes = [
'Basis', 'Bundle', 'Cardinal', 'Catmull Rom', 'Linear', 'Monotone X',
'Monotone Y', 'Natural', 'Step', 'Step After', 'Step Before'
];

colorSets: any;
colorScheme: any;
Expand Down Expand Up @@ -744,10 +749,10 @@ export class AppComponent implements OnInit {
let multiEntry = {
name: country,
series: [{
name: "2010",
name: '2010',
value: Math.floor(1000000 + Math.random() * 20000000)
}, {
name: "2011",
name: '2011',
value: Math.floor(1000000 + Math.random() * 20000000)
}]
};
Expand Down
4 changes: 2 additions & 2 deletions demo/app.module.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import { NgModule } from "@angular/core";
import { NgModule } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';
import { FormsModule } from '@angular/forms';

import { AppComponent } from './app.component';
import { NgxChartsModule } from "../src";
import { NgxChartsModule } from '../src';

@NgModule({
imports: [NgxChartsModule, BrowserModule, FormsModule],
Expand Down
124 changes: 85 additions & 39 deletions demo/chartTypes.ts
Original file line number Diff line number Diff line change
@@ -1,144 +1,190 @@
let chartGroups = [
{
name: "Bar Charts",
name: 'Bar Charts',
charts: [
{
name: "Vertical Bar Chart",
name: 'Vertical Bar Chart',
selector: 'bar-vertical',
inputFormat: 'singleSeries',
options: ['colorScheme', 'schemeType', 'showXAxis', 'showYAxis', 'gradient', 'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel', 'yAxisLabel', 'showGridLines']
options: [
'colorScheme', 'schemeType', 'showXAxis', 'showYAxis', 'gradient',
'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel', 'yAxisLabel', 'showGridLines'
]
},
{
name: "Horizontal Bar Chart",
name: 'Horizontal Bar Chart',
selector: 'bar-horizontal',
inputFormat: 'singleSeries',
options: ['colorScheme', 'schemeType', 'showXAxis', 'showYAxis', 'gradient', 'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel', 'yAxisLabel', 'showGridLines']
options: [
'colorScheme', 'schemeType', 'showXAxis', 'showYAxis', 'gradient',
'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel', 'yAxisLabel', 'showGridLines'
]
},
{
name: "Grouped Vertical Bar Chart",
name: 'Grouped Vertical Bar Chart',
selector: 'bar-vertical-2d',
inputFormat: 'multiSeries',
options: ['colorScheme', 'schemeType', 'showXAxis', 'showYAxis', 'gradient', 'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel', 'yAxisLabel', 'showGridLines']
options: [
'colorScheme', 'schemeType', 'showXAxis', 'showYAxis', 'gradient',
'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel', 'yAxisLabel', 'showGridLines'
]
},
{
name: "Grouped Horizontal Bar Chart",
name: 'Grouped Horizontal Bar Chart',
selector: 'bar-horizontal-2d',
inputFormat: 'multiSeries',
options: ['colorScheme', 'schemeType', 'showXAxis', 'showYAxis', 'gradient', 'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel', 'yAxisLabel', 'showGridLines']
options: [
'colorScheme', 'schemeType', 'showXAxis', 'showYAxis', 'gradient',
'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel', 'yAxisLabel', 'showGridLines'
]
},
{
name: "Stacked Vertical Bar Chart",
name: 'Stacked Vertical Bar Chart',
selector: 'bar-vertical-stacked',
inputFormat: 'multiSeries',
options: ['colorScheme', 'schemeType', 'showXAxis', 'showYAxis', 'gradient', 'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel', 'yAxisLabel', 'showGridLines']
options: [
'colorScheme', 'schemeType', 'showXAxis', 'showYAxis', 'gradient',
'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel', 'yAxisLabel', 'showGridLines'
]
},
{
name: "Stacked Horizontal Bar Chart",
name: 'Stacked Horizontal Bar Chart',
selector: 'bar-horizontal-stacked',
inputFormat: 'multiSeries',
options: ['colorScheme', 'schemeType', 'showXAxis', 'showYAxis', 'gradient', 'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel', 'yAxisLabel', 'showGridLines']
options: [
'colorScheme', 'schemeType', 'showXAxis', 'showYAxis', 'gradient',
'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel', 'yAxisLabel', 'showGridLines'
]
},
{
name: "Normalized Vertical Bar Chart",
name: 'Normalized Vertical Bar Chart',
selector: 'bar-vertical-normalized',
inputFormat: 'multiSeries',
options: ['colorScheme', 'schemeType', 'showXAxis', 'showYAxis', 'gradient', 'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel', 'yAxisLabel', 'showGridLines']
options: [
'colorScheme', 'schemeType', 'showXAxis', 'showYAxis', 'gradient',
'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel', 'yAxisLabel', 'showGridLines'
]
},
{
name: "Normalized Horizontal Bar Chart",
name: 'Normalized Horizontal Bar Chart',
selector: 'bar-horizontal-normalized',
inputFormat: 'multiSeries',
options: ['colorScheme', 'schemeType', 'showXAxis', 'showYAxis', 'gradient', 'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel', 'yAxisLabel', 'showGridLines']
options: [
'colorScheme', 'schemeType', 'showXAxis', 'showYAxis', 'gradient',
'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel', 'yAxisLabel', 'showGridLines'
]
}
]
},
{
name: "Pie Charts",
name: 'Pie Charts',
charts: [
{
name: "Pie Chart",
name: 'Pie Chart',
selector: 'pie-chart',
inputFormat: 'singleSeries',
options: ['colorScheme', 'gradient', 'showLegend', 'doughnut', 'explodeSlices', 'showLabels']
},
{
name: "Advanced Pie Chart",
name: 'Advanced Pie Chart',
selector: 'advanced-pie-chart',
inputFormat: 'singleSeries',
options: ['colorScheme', 'gradient', 'showLegend', 'doughnut', 'showLabels']
},
{
name: "Pie Grid",
name: 'Pie Grid',
selector: 'pie-grid',
inputFormat: 'singleSeries',
options: ['colorScheme']
}
]
},
{
name: "Line/Area Charts",
name: 'Line/Area Charts',
charts: [
{
name: "Line Chart",
name: 'Line Chart',
selector: 'line-chart',
inputFormat: 'multiSeries',
options: ['colorScheme', 'schemeType', 'showXAxis', 'showYAxis', 'gradient', 'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel', 'yAxisLabel', 'autoScale', 'timeline', 'showGridLines', 'curve']
options: [
'colorScheme', 'schemeType', 'showXAxis', 'showYAxis', 'gradient',
'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel',
'yAxisLabel', 'autoScale', 'timeline', 'showGridLines', 'curve'
]
},
{
name: "Area Chart",
name: 'Area Chart',
selector: 'area-chart',
inputFormat: 'multiSeries',
options: ['colorScheme', 'schemeType', 'showXAxis', 'showYAxis', 'gradient', 'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel', 'yAxisLabel', 'autoScale', 'timeline', 'showGridLines', 'curve']
options: [
'colorScheme', 'schemeType', 'showXAxis', 'showYAxis', 'gradient',
'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel',
'yAxisLabel', 'autoScale', 'timeline', 'showGridLines', 'curve'
]
},
{
name: "Stacked Area Chart",
name: 'Stacked Area Chart',
selector: 'area-chart-stacked',
inputFormat: 'multiSeries',
options: ['colorScheme', 'schemeType', 'showXAxis', 'showYAxis', 'gradient', 'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel', 'yAxisLabel', 'autoScale', 'timeline', 'showGridLines', 'curve']
options: [
'colorScheme', 'schemeType', 'showXAxis', 'showYAxis', 'gradient',
'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel',
'yAxisLabel', 'autoScale', 'timeline', 'showGridLines', 'curve'
]
},
{
name: "Normalized Area Chart",
name: 'Normalized Area Chart',
selector: 'area-chart-normalized',
inputFormat: 'multiSeries',
options: ['colorScheme', 'schemeType', 'showXAxis', 'showYAxis', 'gradient', 'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel', 'yAxisLabel', 'autoScale', 'timeline', 'showGridLines', 'curve']
options: [
'colorScheme', 'schemeType', 'showXAxis', 'showYAxis', 'gradient',
'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel',
'yAxisLabel', 'autoScale', 'timeline', 'showGridLines', 'curve'
]
},
]
},
{
name: "Other Charts",
name: 'Other Charts',
charts: [
{
name: "Force Directed Graph",
name: 'Force Directed Graph',
selector: 'force-directed-graph',
inputFormat: 'graph',
options: ['colorScheme', 'showLegend']
},
{
name: "Heat Map",
name: 'Heat Map',
selector: 'heat-map',
inputFormat: 'multiSeries',
options: ['colorScheme', 'showXAxis', 'showYAxis', 'gradient', 'showLegend', 'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel', 'yAxisLabel']
options: [
'colorScheme', 'showXAxis', 'showYAxis', 'gradient', 'showLegend',
'showXAxisLabel', 'xAxisLabel', 'showYAxisLabel', 'yAxisLabel'
]
},
{
name: "Tree Map",
name: 'Tree Map',
selector: 'tree-map',
inputFormat: 'singleSeries',
options: ['colorScheme']
},
{
name: "Number Cards",
name: 'Number Cards',
selector: 'number-card',
inputFormat: 'singleSeries',
options: ['colorScheme']
},
{
name: "Gauge",
name: 'Gauge',
selector: 'gauge',
inputFormat: 'singleSeries',
options: ['colorScheme', 'min', 'max', 'largeSegments', 'smallSegments', 'units', 'angleSpan', 'startAngle', 'showAxis']
options: [
'colorScheme', 'min', 'max', 'largeSegments', 'smallSegments', 'units',
'angleSpan', 'startAngle', 'showAxis'
]
},
{
name: "Linear Gauge",
name: 'Linear Gauge',
selector: 'linear-gauge',
inputFormat: 'single',
options: ['colorScheme', 'value', 'previousValue', 'min', 'max', 'units']
Expand Down
Loading

0 comments on commit 1d3cfe3

Please sign in to comment.