storybook/docs/snippets/angular/mdx-canvas-multiple-stories.mdx.mdx
2021-11-04 18:03:37 +00:00

41 lines
664 B
Plaintext

```md
<!-- Badge.stories.mdx --->
import { Canvas, Meta, Story } from '@storybook/addon-docs';
import { Badge } from './badge.component';
<Meta title="Badge" component={Badge} />
export const Template = (args) => ({ props: args });
<Canvas>
<Story
name="warning"
args={{
status: 'warning',
label: 'Warning',
}}>
{Template.bind({})}
</Story>
<Story
name="neutral"
args={{
status: 'neutral',
label: 'Neutral',
}}>
{Template.bind({})}
</Story>
<Story
name="error"
args={{
status: 'error',
label: 'Error',
}}>
{Template.bind({})}
</Story>
</Canvas>
```