better display of scheduled statuses

This commit is contained in:
Nicolas Constant 2019-09-06 01:34:55 -04:00
parent 8299137b56
commit 21f32b91b0
No known key found for this signature in database
GPG Key ID: 1E9F677FB01A5688
2 changed files with 27 additions and 11 deletions

View File

@ -1,19 +1,23 @@
<div class="scheduled-status">
<div class="scheduled-status__avatar">
<div>
{{ status.scheduled_at | date: 'MMM d, y, h:mm:ss a' }}
</div>
<div class="scheduled-status__avatar">
<img class="scheduled-status__avatar--image" src="{{avatar}}" />
</div>
<div class="scheduled-status__content">
<div>
{{ status.params.spoiler_text }}
<div class="scheduled-status__content--text scheduled-status__content--spoiler"
*ngIf="status.params.spoiler_text">
spoiler text: {{ status.params.spoiler_text }}
</div>
<div>
<div class="scheduled-status__content--text">
{{ status.params.text }}
</div>
<div>
{{ status.scheduled_at }}
</div>
</div>
</div>

View File

@ -1,16 +1,28 @@
.scheduled-status {
padding: 5px 5px 0 5px;
outline: 1px solid greenyellow;
$avatar-size: 40px;
.scheduled-status {
padding: 0 5px 10px 5px;
&__avatar {
float: left;
&--image {
width: 40px;
width: $avatar-size;
}
}
&__content {
&--text {
width: calc(100% - #{$avatar-size});
margin-left: $avatar-size;
padding: 0 5px;
min-height: 40px;
}
&--spoiler {
color: gray;
min-height: 0px;
}
}
}