Skip to content

Commit

Permalink
docs: update to use story decorator
Browse files Browse the repository at this point in the history
Co-authored-by: Radek Podrazky <[email protected]>
  • Loading branch information
julesbarr and ajkl2533 committed Oct 3, 2023
1 parent 8f6a4a2 commit 8b471fa
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 12 deletions.
Binary file not shown.
31 changes: 19 additions & 12 deletions src/components/Datatable/DatatableTests.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -299,15 +299,22 @@ WithAllColumnsHidden.args = {
},
};

export const WithPersistedState = () => (
<Stack gap="md">
<Text>
An id must be provided to the Datatable in order to persists the table
configuration.
</Text>
{DatatableTemplate({
...MinimalConfig.args,
id: 'persisted_state',
})}
</Stack>
);
export const WithPersistedState = DatatableTemplate.bind({});
WithPersistedState.args = {
...MinimalConfig.args,
id: 'persisted_state',
};
WithPersistedState.parameters = {
screenshot: { skip: true },
};
WithPersistedState.decorators = [
(storyFn) => (
<Stack gap="md">
<Text>
An id must be provided to the Datatable in order to persists the table
configuration.
</Text>
{storyFn()}
</Stack>
),
];

0 comments on commit 8b471fa

Please sign in to comment.