UX: don't clip staff shield in user cards (#7398)

This commit is contained in:
Joe 2019-04-19 01:53:23 -07:00 committed by GitHub
parent 7e3628d11f
commit b150a57383
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 41 additions and 28 deletions

View File

@ -18,16 +18,16 @@
{{plugin-outlet name="user-card-avatar-flair" args=(hash user=user) tagName='div'}} {{plugin-outlet name="user-card-avatar-flair" args=(hash user=user) tagName='div'}}
</div> </div>
<div class="names"> <div class="names">
<span>
<h1 class="{{staff}} {{newUser}} {{if nameFirst "full-name" "username"}}"> <h1 class="{{staff}} {{newUser}} {{if nameFirst "full-name" "username"}}">
{{#if user.profile_hidden}} {{#if user.profile_hidden}}
<span> <span class="name-username-wrapper">
{{if nameFirst user.name (format-username username)}} {{if nameFirst user.name (format-username username)}}
{{user-status user currentUser=currentUser}}
</span> </span>
{{else}} {{else}}
<a href="{{user.path}}" {{action "showUser" user}} class='user-profile-link'> <a href="{{user.path}}" {{action "showUser" user}} class='user-profile-link'>
<span class="name-username-wrapper">
{{if nameFirst user.name (format-username username)}} {{if nameFirst user.name (format-username username)}}
</span>
{{user-status user currentUser=currentUser}} {{user-status user currentUser=currentUser}}
</a> </a>
{{/if}} {{/if}}
@ -47,7 +47,6 @@
<h2 class="staged">{{i18n 'user.staged'}}</h2> <h2 class="staged">{{i18n 'user.staged'}}</h2>
{{/if}} {{/if}}
{{plugin-outlet name="user-card-post-names" args=(hash user=user) tagName='div'}} {{plugin-outlet name="user-card-post-names" args=(hash user=user) tagName='div'}}
</span>
</div> </div>
<ul class="usercard-controls"> <ul class="usercard-controls">
{{#if user.can_send_private_message_to_user}} {{#if user.can_send_private_message_to_user}}

View File

@ -43,6 +43,20 @@ $avatar_margin: -50px; // negative margin makes avatars extend above cards
.first-row { .first-row {
.names { .names {
padding-left: 1.25em; padding-left: 1.25em;
.user-profile-link {
display: flex;
align-items: center;
}
.d-icon {
margin: 0 0.25em;
}
.name-username-wrapper {
margin-right: 0;
flex: 0 1 auto;
}
span { span {
display: block; display: block;
} }