Skip to content

Commit b724948

Browse files
author
Nikolai Lopin
committed
docs: migrate Tag docs to csf3
1 parent 7ef196a commit b724948

File tree

3 files changed

+46
-48
lines changed

3 files changed

+46
-48
lines changed

src/components/Tag/docs/Tag.stories.mdx

Lines changed: 0 additions & 48 deletions
This file was deleted.
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
import { Meta, StoryObj } from '@storybook/react';
2+
import { Tag } from '../Tag';
3+
4+
const meta: Meta = {
5+
title: 'Components/Tag',
6+
component: Tag,
7+
argTypes: {
8+
children: {
9+
description: 'Content of the tag'
10+
}
11+
},
12+
args: {
13+
children: 'Taxi'
14+
}
15+
};
16+
17+
export default meta;
18+
19+
type Story = StoryObj<typeof Tag>;
20+
21+
export const Default: Story = {};
22+
23+
export const NotDismissible: Story = {
24+
args: {
25+
dismissible: false
26+
}
27+
};
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
import { Primary, Stories, ArgTypes, Meta } from '@storybook/blocks';
2+
import { StyledSystemLinks } from '../../../docs/StyledSystemLinks';
3+
import * as TagStories from './Tag.stories';
4+
5+
<Meta of={TagStories} />
6+
7+
# Tag
8+
9+
The Tag component is used to categorize items. The text inside the Tag should be kept as short as possible. Multi-labels
10+
should be avoided as well.
11+
12+
<Primary />
13+
14+
## Properties
15+
16+
<ArgTypes of={TagStories} />
17+
<StyledSystemLinks component="Tag" supportedProps={['margin']} />
18+
19+
<Stories includePrimary={false} />

0 commit comments

Comments
 (0)