Skip to content

Commit f5013b2

Browse files
committed
Update docs
1 parent f500d94 commit f5013b2

File tree

3 files changed

+31
-1
lines changed

3 files changed

+31
-1
lines changed

src/assets/badge-types.png

187 KB
Loading

src/content/docs/components/badge.mdx

Lines changed: 28 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,30 @@
22
title: Badge
33
---
44

5+
import { Image } from "astro:assets";
56
import Demo from "@components/Demo.astro";
67
import PageSwitcher from "@components/PageSwitcher.astro";
78
import Imports from "@components/examples/badge/Imports.astro";
9+
import badgeTypes from "@assets/badge-types.png";
810

911
<Imports />
1012
<PageSwitcher />
1113

12-
## Basic example
14+
## Explanation of badge styles
15+
16+
The following badge styles have been implemented based on the VSCode UI:
17+
18+
1. Default style
19+
2. Activity bar counter
20+
3. Counter
21+
4. Tab bar counter
22+
23+
<Image
24+
src={badgeTypes}
25+
alt="Visual explanation of various badge styles"
26+
/>
27+
28+
## Default style
1329

1430
<Demo>
1531
<vscode-badge>308 Settings Found</vscode-badge>
@@ -41,3 +57,14 @@ import Imports from "@components/examples/badge/Imports.astro";
4157
```
4258
</Fragment>
4359
</Demo>
60+
61+
## Tab bar counter
62+
63+
<Demo>
64+
<vscode-badge variant="activity-bar-counter">42</vscode-badge>
65+
<Fragment slot="html">
66+
```html
67+
<vscode-badge variant="tab-bar-counter">42</vscode-badge>
68+
```
69+
</Fragment>
70+
</Demo>

tsconfig.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@
1010
"@data/*": [
1111
"src/data/*"
1212
],
13+
"@assets/*": [
14+
"src/assets/*"
15+
],
1316
}
1417
}
1518
}

0 commit comments

Comments
 (0)