aboutsummaryrefslogtreecommitdiffstats
path: root/src/components/organisms/layout/comments-list.stories.tsx
diff options
context:
space:
mode:
authorArmand Philippot <git@armandphilippot.com>2022-05-15 17:45:41 +0200
committerArmand Philippot <git@armandphilippot.com>2022-05-15 19:06:42 +0200
commitc95cce04393080a52a54191cff7be8fec68af4b0 (patch)
tree1022bc574c8fc8e657be922b26c1cf16cbfd9071 /src/components/organisms/layout/comments-list.stories.tsx
parent235fe67d770f83131c9ec10b99012319440db690 (diff)
chore: add Article pages
Diffstat (limited to 'src/components/organisms/layout/comments-list.stories.tsx')
-rw-r--r--src/components/organisms/layout/comments-list.stories.tsx30
1 files changed, 20 insertions, 10 deletions
diff --git a/src/components/organisms/layout/comments-list.stories.tsx b/src/components/organisms/layout/comments-list.stories.tsx
index 9edf368..4d95205 100644
--- a/src/components/organisms/layout/comments-list.stories.tsx
+++ b/src/components/organisms/layout/comments-list.stories.tsx
@@ -1,13 +1,19 @@
import { ComponentMeta, ComponentStory } from '@storybook/react';
-import { IntlProvider } from 'react-intl';
import CommentsListComponent, { Comment } from './comments-list';
+const saveComment = async () => {
+ /** Do nothing. */
+};
+
/**
* CommentsList - Storybook Meta
*/
export default {
title: 'Organisms/Layout/CommentsList',
component: CommentsListComponent,
+ args: {
+ saveComment,
+ },
argTypes: {
comments: {
control: {
@@ -30,6 +36,19 @@ export default {
required: true,
},
},
+ Notice: {
+ control: {
+ type: null,
+ },
+ description: 'A component to display a success or error message.',
+ table: {
+ category: 'Options',
+ },
+ type: {
+ name: 'function',
+ required: false,
+ },
+ },
saveComment: {
control: {
type: null,
@@ -44,13 +63,6 @@ export default {
},
},
},
- decorators: [
- (Story) => (
- <IntlProvider locale="en">
- <Story />
- </IntlProvider>
- ),
- ],
} as ComponentMeta<typeof CommentsListComponent>;
const Template: ComponentStory<typeof CommentsListComponent> = (args) => (
@@ -130,7 +142,6 @@ export const WithoutChildComments = Template.bind({});
WithoutChildComments.args = {
comments,
depth: 0,
- saveComment: () => null,
};
/**
@@ -140,5 +151,4 @@ export const WithChildComments = Template.bind({});
WithChildComments.args = {
comments,
depth: 1,
- saveComment: () => null,
};