Skip to content

Commit b1f46e4

Browse files
committed
chore(ui): add hover bg for link item in breadcrumb
1 parent cdee125 commit b1f46e4

File tree

2 files changed

+9
-3
lines changed

2 files changed

+9
-3
lines changed

packages/ui/src/components/breadcrumb/demos/1.Basic.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ export default function Demo() {
2828
Home
2929
</div>
3030
),
31+
link: true,
3132
},
3233
{
3334
id: 1,

packages/ui/src/styles/components/breadcrumb.scss

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,22 +2,27 @@
22
@include e(list) {
33
display: flex;
44
flex-wrap: wrap;
5-
gap: 4px 8px;
5+
gap: 4px 2px;
66
align-items: center;
77
padding: 0;
8-
margin: 0;
8+
margin: 0 -6px;
99
list-style: none;
1010
}
1111

1212
@include e(item) {
13+
padding: 0 6px;
14+
line-height: 1.5;
1315
color: var(--#{$rd-prefix}text-color-sub);
16+
border-radius: var(--#{$rd-prefix}border-radius);
1417

1518
@include m(link) {
1619
cursor: pointer;
17-
transition: color var(--#{$rd-prefix}animation-duration-base) linear;
20+
transition: color var(--#{$rd-prefix}animation-duration-base) linear,
21+
background-color var(--#{$rd-prefix}animation-duration-base) linear;
1822

1923
&:hover {
2024
color: var(--#{$rd-prefix}text-color);
25+
background-color: var(--#{$rd-prefix}background-color-gray);
2126
}
2227
}
2328

0 commit comments

Comments
 (0)