From 134eaa4d584b5441af5f0ce7c49a8001030cf972 Mon Sep 17 00:00:00 2001 From: Eragon Date: Tue, 3 Dec 2019 23:13:22 +0100 Subject: [PATCH] Ajout du style et d'un peut d'affichage pour les topics MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit J'ai fait mon possible pour que ça rende bien et que le css ne soit pas trop moche. Il faudra peut-être modifier légèrement l'afichage du profil, ce dernier est pas assez bien en place à mon goût. --- app/static/css/table.css | 10 ++++++++++ app/templates/forum/topic.html | 18 ++++++++++++++---- app/templates/widgets/editor.html | 2 +- 3 files changed, 25 insertions(+), 5 deletions(-) diff --git a/app/static/css/table.css b/app/static/css/table.css index 4445169..a8c479a 100644 --- a/app/static/css/table.css +++ b/app/static/css/table.css @@ -61,3 +61,13 @@ table.topiclist th > td:last-child, table.topiclist tr > td:last-child { width: 20%; text-align: center; } + + +/* Thread table */ + +table.thread { + width: 100%; +} +table.thread td.member { + width: 20%; +} diff --git a/app/templates/forum/topic.html b/app/templates/forum/topic.html index 1afe3b4..78a9f27 100644 --- a/app/templates/forum/topic.html +++ b/app/templates/forum/topic.html @@ -1,23 +1,33 @@ {% extends "base/base.html" %} {% import "widgets/editor.html" as widget_editor %} +{% import "widgets/member.html" as widget_member %} {% block title %} -Forum de Planète Casio »

{{ t.forum.name }}

+Forum de Planète Casio » {{ t.forum.name }} »

{{ t.title }}

{% endblock %} {% block content %}

{{ t.title }}

+ + + +
{{ widget_member.profile(t.author ) }}{{ t.thread.top_comment.text }}
+
-
{{ t.thread.top_comment.text }}
- + {% for i, c in enumerate(t.thread.comments) %} + {% if c != t.thread.top_comment %} -
{{ c.text }}
+ + + {% endfor %} +
{{ widget_member.profile(c.author ) }}{{ c.text }} {% elif i != 0 %}
Ce message est le top comment
{% endif %} +

Commenter le sujet

diff --git a/app/templates/widgets/editor.html b/app/templates/widgets/editor.html index 087865a..f51c3ae 100644 --- a/app/templates/widgets/editor.html +++ b/app/templates/widgets/editor.html @@ -1,7 +1,7 @@ {% macro text_editor(field, label=True) %}
{{ field.label if label }} -
Widgets. Lots of widgets :3
+
Widgets. Lots of widgets :3 For lightscript
{{ field() }} {% for error in field.errors %} {{ error }}