Skip to content

Commit

Permalink
fix(core): add missing properties to AxisOptions interface (#1432)
Browse files Browse the repository at this point in the history
* fix(core): add missing properties to `ComboChartAxisOptions`

Fixes #1413

* chore: apply correct formatting
  • Loading branch information
metonym committed Sep 19, 2022
1 parent 67bfc79 commit f88f310
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
12 changes: 12 additions & 0 deletions packages/core/src/interfaces/axis-scales.ts
Expand Up @@ -126,6 +126,18 @@ export interface AxisOptions extends BasedAxisOptions {
percentage?: boolean;
}

export interface ComboChartAxisOptions extends AxisOptions {
/**
* should be set to `true` for the
* left axis to be the primary axis
*/
main?: boolean;
/**
* used to map data on the secondary axis
*/
correspondingDatasets?: Array<string>;
}

export interface BinnedAxisOptions {
/**
* should be set to `true` on the domain
Expand Down
2 changes: 2 additions & 0 deletions packages/core/src/interfaces/charts.ts
Expand Up @@ -20,6 +20,7 @@ import { BarOptions, StackedBarOptions, ToolbarOptions } from './components';
import {
AxisOptions,
BinnedAxisOptions,
ComboChartAxisOptions,
TimeScaleOptions,
} from './axis-scales';

Expand Down Expand Up @@ -451,6 +452,7 @@ export interface RadarChartOptions extends BaseChartOptions {
* options specific to combo charts
*/
export interface ComboChartOptions extends AxisChartOptions {
axes?: AxesOptions<ComboChartAxisOptions>;
comboChartTypes: Array<{
type: ChartTypes | any;
options?: object;
Expand Down

0 comments on commit f88f310

Please sign in to comment.