Commit 7e240195 authored by JC Brand's avatar JC Brand

Fixes #1288

Add CSS classes to differentiate between incoming and outgoing messages
parent ecff1fd9
...@@ -12,6 +12,7 @@ ...@@ -12,6 +12,7 @@
- #1188 Feature request: drag and drop file to HTTP Upload - #1188 Feature request: drag and drop file to HTTP Upload
- #1268 Switch from SASS variables to CSS custom properties - #1268 Switch from SASS variables to CSS custom properties
- #1278 Replace the default avatar with a SVG version - #1278 Replace the default avatar with a SVG version
- #1288 Add CSS classes to differentiate between incoming and outgoing messages
- #1305 added value 'all' for 'show_desktop_notifications' to notifiy even if converse.js is open - #1305 added value 'all' for 'show_desktop_notifications' to notifiy even if converse.js is open
- #1306 added option `notification_delay` - #1306 added option `notification_delay`
- #1312 Error `unrecognized expression` in Safari - #1312 Error `unrecognized expression` in Safari
......
...@@ -102627,25 +102627,27 @@ __e(o.isodate) + ...@@ -102627,25 +102627,27 @@ __e(o.isodate) +
__e(o.pretty_time) + __e(o.pretty_time) +
'</time>'; '</time>';
} ; } ;
__p += '\n <span class="chat-msg__author">'; __p += '\n <span class="chat-msg__author chat-msg__' +
__e(o.sender) +
'">';
if (o.is_me_message) { ; if (o.is_me_message) { ;
__p += '**'; __p += '**';
}; ; }; ;
__p += __p +=
__e(o.username) + __e(o.username) +
'</span>\n '; '</span>\n ';
if (!o.is_me_message) { ;
__p += '\n ';
o.roles.forEach(function (role) { ; o.roles.forEach(function (role) { ;
__p += ' <span class="badge badge-secondary">' + __p += ' <span class="badge badge-secondary">' +
__e(role) + __e(role) +
'</span> '; '</span> ';
}); ; }); ;
__p += '\n '; __p += '\n <time timestamp="' +
if (!o.is_me_message) { ;
__p += '<time timestamp="' +
__e(o.isodate) + __e(o.isodate) +
'" class="chat-msg__time">' + '" class="chat-msg__time">' +
__e(o.pretty_time) + __e(o.pretty_time) +
'</time>'; '</time>\n ';
} ; } ;
__p += '\n '; __p += '\n ';
if (o.is_encrypted) { ; if (o.is_encrypted) { ;
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
<div class="chat-msg__content {[ if (o.is_me_message) { ]}chat-msg__content--action{[ } ]}"> <div class="chat-msg__content {[ if (o.is_me_message) { ]}chat-msg__content--action{[ } ]}">
<span class="chat-msg__heading"> <span class="chat-msg__heading">
{[ if (o.is_me_message) { ]}<time timestamp="{{{o.isodate}}}" class="chat-msg__time">{{{o.pretty_time}}}</time>{[ } ]} {[ if (o.is_me_message) { ]}<time timestamp="{{{o.isodate}}}" class="chat-msg__time">{{{o.pretty_time}}}</time>{[ } ]}
<span class="chat-msg__author">{[ if (o.is_me_message) { ]}**{[ }; ]}{{{o.username}}}</span> <span class="chat-msg__author chat-msg__{{{o.sender}}}">{[ if (o.is_me_message) { ]}**{[ }; ]}{{{o.username}}}</span>
{[ if (!o.is_me_message) { ]} {[ if (!o.is_me_message) { ]}
{[o.roles.forEach(function (role) { ]} <span class="badge badge-secondary">{{{role}}}</span> {[ }); ]} {[o.roles.forEach(function (role) { ]} <span class="badge badge-secondary">{{{role}}}</span> {[ }); ]}
<time timestamp="{{{o.isodate}}}" class="chat-msg__time">{{{o.pretty_time}}}</time> <time timestamp="{{{o.isodate}}}" class="chat-msg__time">{{{o.pretty_time}}}</time>
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment