Mercurial > libervia-templates
diff sat_templates/templates/default/blog/item.html @ 247:40fccd3b7cf0
updated code to handle blog items following data structure change in backend/Libervia
author | Goffi <goffi@goffi.org> |
---|---|
date | Thu, 16 Jul 2020 09:08:32 +0200 |
parents | aa37750c2617 |
children | c5de5514a251 |
line wrap: on
line diff
--- a/sat_templates/templates/default/blog/item.html Fri Jun 19 17:57:13 2020 +0200 +++ b/sat_templates/templates/default/blog/item.html Thu Jul 16 09:08:32 2020 +0200 @@ -28,7 +28,7 @@ <div class="blog__title"> {% block blog_title scoped %} - {% set title = item.title_xhtml or item.title or '' %} + {% set title = item.title_xhtml|safe or item.title or '' %} {% if item_http_uri %} <a href="{{item_http_uri}}">{{title}}</a> {% else %} @@ -42,7 +42,7 @@ {% if avatar is defined %} {{ avatar.avatar(item.author_jid, "avatar--float-left") }} {% endif %} - <span class="blog__author">{{identities[item.author_jid].nicknames[0] if identities[item.author_jid].nicknames else item.author}}</span> + <span class="blog__author">{{identities[item.author_jid].nicknames[0] if identities[item.author_jid].nicknames else item.author)}}</span> {% else %} <span class="blog__author">{{item.author}}</span> {% endif %} @@ -72,7 +72,7 @@ <div class="box__content{{' box__content--plaintext' if not item.content_xhtml}}"> {% block content %} - {{- item.content_xhtml or item.content|urlize or '' -}} + {{- item.content_xhtml|safe or item.content|urlize or '' -}} {% endblock content %} </div>