storybook/docs/snippets/angular/mdx-canvas-multiple-stories.mdx.mdx
2021-12-05 01:49:50 +08:00

39 lines
659 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>
```