Fix time placeholder showing on mobile format for condensed messages

As an extra, make sure time placeholder cannot be selected anymore, and do not do an extra call to `tz` helper when time is not relevant/displayed.

I tried to entirely remove `time`/`from` blocks, but because of flexbox layout, that broke message alignment...
This commit is contained in:
Jérémie Astori 2017-08-22 20:18:34 -04:00
parent fcd9782eb7
commit 51bd46b871
No known key found for this signature in database
GPG Key ID: B9A4F245CD67BDE8
2 changed files with 11 additions and 6 deletions

View File

@ -837,6 +837,10 @@ kbd {
display: none; display: none;
} }
#chat .condensed .time {
visibility: hidden;
}
#windows .header .topic, #windows .header .topic,
.messages .msg, .messages .msg,
.sidebar { .sidebar {
@ -2043,6 +2047,11 @@ part/quit messages where we don't load previews (adds a blank line otherwise) */
padding: 0; padding: 0;
} }
#chat .condensed .time,
#chat .condensed .from {
display: none;
}
#chat .date-marker, #chat .date-marker,
#chat .unread-marker { #chat .unread-marker {
margin: 0; margin: 0;
@ -2181,7 +2190,3 @@ part/quit messages where we don't load previews (adds a blank line otherwise) */
#chat table.channel-list .topic { #chat table.channel-list .topic {
white-space: pre-wrap; white-space: pre-wrap;
} }
.hide-text {
color: transparent !important;
}

View File

@ -1,5 +1,5 @@
<div class="msg {{type}} closed" data-time="{{time}}"> <div class="msg condensed closed" data-time="{{time}}">
<span class="time hide-text">{{tz time}}</span> <span class="time">{{tz time}}</span>
<span class="from"></span> <span class="from"></span>
<span class="content"> <span class="content">
<span class="condensed-text"></span> <span class="condensed-text"></span>