Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HACK: We be formatting #1684

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft

Conversation

envex
Copy link
Collaborator

@envex envex commented Jun 26, 2024

},
];

function formatData(data) {
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Format the data back to what polaris-viz expects.

@@ -8,8 +8,63 @@ import {DEFAULT_DATA, Template} from './data';

export const Default: Story<BarChartProps> = Template.bind({});

const data = [
{
name: 'Monday',
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Easier to reason about data structure where the top level name would be the primary dimension/group and then the series.data array are the bars.

@philschoefer
Copy link
Contributor

I only see the changes in the story file. Did you not need to do updates in the BarChart itself?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants