style: 合并username样式

This commit is contained in:
Argo Zhang 2019-08-18 11:15:35 +08:00
parent 789be04c42
commit 6f34d76a9f
No known key found for this signature in database
GPG Key ID: 152E398953DDF19F
2 changed files with 17 additions and 12 deletions

View File

@ -96,7 +96,7 @@
<div class="d-flex flex-fill align-items-center">
<img src="@Url.Content(Model.Icon)">
<div class="flex-fill">
<div class="font-weight-bold flex-fill">@Model.DisplayName</div>
<div class="username text-truncate">@Model.DisplayName</div>
<div>登录名:@Model.UserName</div>
</div>
</div>

View File

@ -36,17 +36,22 @@
top: 64px;
}
.username {
margin-left: 0.625rem;
font-size: 1rem;
font-weight: 500;
vertical-align: middle;
max-width: 120px;
}
.userinfo img {
border-radius: 4px;
width: 40px;
height: 40px;
margin-right: 0.625rem;
}
.userinfo .username {
font-size: 1rem;
max-width: 110px;
font-weight: 500;
}
.userinfo .dropdown-toggle, .userinfo .dropdown-toggle:hover, .userinfo.show .dropdown-toggle, .nav [data-toggle="dropdown"], .nav [data-toggle="dropdown"]:hover {
@ -72,10 +77,17 @@
.userinfo .dropdown-item img {
width: 60px;
margin-right: 1rem;
height: 60px;
}
.userinfo .dropdown-item .username {
max-width: 180px;
}
.userinfo .dropdown-item .username + div {
margin-left: 0.625rem;
}
.userinfo .dropdown-item a {
padding: 0.25rem 0.625rem;
}
@ -136,12 +148,6 @@ aside {
left: 4px;
}
aside .nav-header .username {
font-size: 1rem;
max-width: 120px;
vertical-align: middle;
}
aside .nav-link span {
display: inline-block;
white-space: nowrap;
@ -282,7 +288,6 @@ body {
aside .nav-header span, .sidebar-open aside:hover .nav-header span {
color: #eee;
margin-left: 0.625rem;
}
aside .sub .nav-link, .userinfo .dropdown-item, aside .sidebar .sub .nav-item {