Mercurial > libervia-templates
diff sat_templates/templates/bulma/components/avatar.html @ 403:65c53ec5e777
Bulma: complete redesign:
This is a WIP full redesign of the whole web UI. Only chat is usable at the moment, many
things are broken.
The design uses the new Bulma v1+, has a look closer to industry standards, paves the way
for a dark theme, and should be easy to use.
It's a basis for coming features such as UI/UX for threads.
rel 457
author | Goffi <goffi@goffi.org> |
---|---|
date | Fri, 11 Apr 2025 21:32:05 +0200 |
parents | 6ae380307ddc |
children | 5016fb0ff62f |
line wrap: on
line diff
--- a/sat_templates/templates/bulma/components/avatar.html Sat Oct 26 22:53:26 2024 +0200 +++ b/sat_templates/templates/bulma/components/avatar.html Fri Apr 11 21:32:05 2025 +0200 @@ -1,13 +1,13 @@ -{% macro avatar(jid, class="is-48x48") %} +{% macro avatar(jid, class="") %} {%- if identities is defined -%} {% set identity = identities.get(jid) %} {%- if identity and identity.avatar.filename %} - <div class="is-avatar image {{class}}"> + <div class="avatar image {{class}}"> <img src="/cache/common/{{identity.avatar.filename}}"> </div> {% else %} {% set nick = identity.nicknames[0] if identity.nicknames else jid %} - <span class="is-avatar image {{class}} is-flex has-items-centered has-text-weight-bold is-size-3 {{class}}">{{nick|first|upper}}</span> + <span class="avatar {{class}} is-flex is-align-items-center is-justify-content-center has-text-weight-bold is-family-code {{class}}">{{nick|initials}}</span> {%- endif -%} {%- endif -%} {% endmacro %}