Mercurial > libervia-templates
annotate sat_templates/templates/bulma/chat/message.html @ 312:6411615771b6
bulma (base): menu can now be fixed on top with `menu_fixed_top` bool variable
author | Goffi <goffi@goffi.org> |
---|---|
date | Fri, 19 Mar 2021 15:51:26 +0100 |
parents | f5f428a50c10 |
children | b2b859a62e70 |
rev | line source |
---|---|
230 | 1 {% import 'components/avatar.html' as avatar with context %} |
2 | |
3 <div id="{{msg.id}}" class="media is-chat-message msg_{{msg.type}} {{'own_msg' if msg.from_ == own_jid.full()}}"> | |
4 {%- if msg.type != C.MESS_TYPE_INFO %} | |
5 {%- set author = identities[msg.from_].nicknames[0] | default(msg.from_) -%} | |
6 <figure class="media-left"> | |
7 {{ avatar.avatar(msg.from_, "is-32x32") }} | |
8 </figure> | |
9 {% endif -%} | |
10 <div class="media-content"> | |
11 <div class="content"> | |
12 {%- if msg.type != C.MESS_TYPE_INFO %} | |
13 <nav class="level is-mobile is-marginless is-size-7"> | |
14 <div class="level-left has-text-weight-bold"> | |
15 <div class="level-item"> | |
16 <span class="author">{{author}}</span> | |
17 </div> | |
18 </div> | |
19 <div class="level-right is-italic"> | |
20 <div class="level-item"> | |
21 <span class="date">{{msg.timestamp|date_fmt('auto_day')}}</span> | |
22 </div> | |
23 </div> | |
24 </nav> | |
25 {% endif -%} | |
235
f5f428a50c10
chat, ticket: use `pre-wrap` instead of `pre` for whitespaces
Goffi <goffi@goffi.org>
parents:
230
diff
changeset
|
26 <p class="msg_body has-whitespace-pre-wrap"> |
230 | 27 {{- msg.html or (msg.text|urlize(nofollow=true, target="_blank")) -}} |
28 </p> | |
29 </div> | |
30 </div> | |
31 </div> |