diff --git a/chartist/chartist-tests.ts b/chartist/chartist-tests.ts index f4ec32f2a..22b10e8b0 100644 --- a/chartist/chartist-tests.ts +++ b/chartist/chartist-tests.ts @@ -242,6 +242,26 @@ new Chartist.Line('.ct-chart', { } }); +new Chartist.Line('.ct-chart', { + labels: [1, 2, 3, 4, 5, 6, 7, 8], + series: [ + [5, 9, 7, 8, 5, 3, 5, 4] + ] +}, { + ticks: [0, 4], + low: 0, + showArea: true, + axisX: { + showGrid: false + }, + axisY: { + showLabel: true, + showGrid: false, + ticks: [1, 4], + type: Chartist.FixedScaleAxis + } + }); + var chart2 = new Chartist.Line('.ct-chart', { labels: [1, 2, 3, 4, 5], series: [ diff --git a/chartist/chartist.d.ts b/chartist/chartist.d.ts index 8d63696f6..a38aa4ce7 100644 --- a/chartist/chartist.d.ts +++ b/chartist/chartist.d.ts @@ -305,13 +305,13 @@ declare module Chartist { } interface IChartistStepAxis extends ILineChartAxis { - type: IStepAxisStatic; + type?: IStepAxisStatic; ticks?: Array | Array; stretch?: boolean; } interface IChartistFixedScaleAxis extends ILineChartAxis { - type: IFixedScaleAxisStatic; + type?: IFixedScaleAxisStatic; high?: number; low?: number; divisor?: number; @@ -324,7 +324,7 @@ declare module Chartist { scaleMinSpace?: number; onlyInteger?: boolean; referenceValue?: number; - type: IAutoScaleAxisStatic; + type?: IAutoScaleAxisStatic; } interface ILineChartClasses {