UX: Include the flagged person's username on the flagged post

This commit is contained in:
Robin Ward 2017-11-09 13:18:33 -05:00
parent 6e2853da53
commit 3093074398
3 changed files with 14 additions and 0 deletions

View File

@ -20,6 +20,10 @@
</div>
<div class="flagged-post-contents">
<div class='flagged-post-user-details'>
<a class='username' href={{user.path}} data-user-card={{flaggedPost.user.username}}>{{format-username flaggedPost.user.username}}</a>
</div>
<div class='flagged-post-excerpt'>
{{#unless hideTitle}}
<h3>

View File

@ -42,6 +42,14 @@
width: 100%;
word-wrap: break-word;
.flagged-post-user-details {
.username {
font-weight: bold;
color: $primary;
}
margin-bottom: 0.5em;
}
.d-icon {
display: inline-block;
}
@ -202,3 +210,4 @@
padding-right: 0.25em;
}
}

View File

@ -8,6 +8,7 @@ QUnit.test("flagged posts", assert => {
assert.equal(find('.flagged-post .flag-user').length, 1, 'shows who flagged it');
assert.equal(find('.flagged-post-response').length, 2);
assert.equal(find('.flagged-post-response:eq(0) img.avatar').length, 1);
assert.equal(find('.flagged-post-user-details .username').length, 1, 'shows the flagged username');
});
});