Skip to content

Commit

Permalink
feat(badge): support to set border
Browse files Browse the repository at this point in the history
  • Loading branch information
binbin authored and binbin committed Sep 11, 2023
1 parent c640f5d commit b355149
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/varlet-ui/src/badge/badge.less
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
--badge-success-color: var(--color-success);
--badge-warning-color: var(--color-warning);
--badge-info-color: var(--color-info);
--badge-content-border: none;
}

.var-badge {
Expand All @@ -16,12 +17,12 @@

&__content {
color: #fff;
border-radius: 100px;
font-size: 12px;
padding: 2px 6px;
vertical-align: middle;
text-align: center;
display: inline-block;
border: var(--badge-content-border);
}

&__icon[var-badge-cover] {
Expand Down
1 change: 1 addition & 0 deletions packages/varlet-ui/src/badge/docs/en-US.md
Original file line number Diff line number Diff line change
Expand Up @@ -174,3 +174,4 @@ Here are the CSS variables used by the component, Styles can be customized using
| `--badge-success-color` | `var(--color-success)`|
| `--badge-warning-color` | `var(--color-warning)`|
| `--badge-info-color` | `var(--color-info)`|
| `--badge-content-border`| `none` |
1 change: 1 addition & 0 deletions packages/varlet-ui/src/badge/docs/zh-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -176,3 +176,4 @@ function handleChange() {
| `--badge-success-color` | `var(--color-success)`|
| `--badge-warning-color` | `var(--color-warning)`|
| `--badge-info-color` | `var(--color-info)`|
| `--badge-content-border`| `none` |

0 comments on commit b355149

Please sign in to comment.