Skip to content

Commit 4effe6d

Browse files
liunnn1994NAVINFO\liunian7965
andauthored
fix: fix icon not real center & in menu component margin-right error (#4091)
Co-authored-by: NAVINFO\liunian7965 <[email protected]>
1 parent 07b4150 commit 4effe6d

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

components/avatar/style/index.less

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,14 @@
77
.reset-component();
88

99
position: relative;
10-
display: inline-block;
10+
display: inline-flex;
1111
overflow: hidden;
1212
color: @avatar-color;
1313
white-space: nowrap;
14-
text-align: center;
1514
vertical-align: middle;
1615
background: @avatar-bg;
16+
justify-content: center;
17+
align-items: center;
1718

1819
&-image {
1920
background: transparent;
@@ -44,7 +45,6 @@
4445
.avatar-size(@size, @font-size) {
4546
width: @size;
4647
height: @size;
47-
line-height: @size;
4848
border-radius: 50%;
4949

5050
&-string {
@@ -55,5 +55,8 @@
5555

5656
&.@{avatar-prefix-cls}-icon {
5757
font-size: @font-size;
58+
.@{iconfont-css-prefix} {
59+
margin: 0;
60+
}
5861
}
5962
}

0 commit comments

Comments
 (0)