Skip to content

Commit

Permalink
Charts: Add options support for X and Y axis (#41109)
Browse files Browse the repository at this point in the history
* allow passing in axis options

* changelog

* passing through the class names

* add options

* move defaults to component to make them available when options is passed
  • Loading branch information
kangzj committed Jan 17, 2025
1 parent 5459b75 commit a032966
Showing 1 changed file with 12 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,18 @@ const Template: StoryFn< typeof LineChart > = args => <LineChart { ...args } />;
export const Default: StoryObj< typeof LineChart > = Template.bind( {} );
Default.args = {
data: sampleData,
showLegend: false,
legendOrientation: 'horizontal',
options: {
axis: {
x: {
orientation: 'bottom',
},
y: {
orientation: 'left',
},
},
},
};

// Story with single data series
Expand Down

0 comments on commit a032966

Please sign in to comment.