From 447372d7f6f65569c2215f6a87d9546f849939e6 Mon Sep 17 00:00:00 2001 From: Eliseu Amaro Date: Fri, 17 Sep 2021 01:36:07 +0100 Subject: [PATCH] [CSS] Note actions re-alignment to previous position. Simplified visuals. --- public/assets/css/base.css | 16 +++++++------- templates/note/view.html.twig | 39 ++++++++++++++++++----------------- 2 files changed, 27 insertions(+), 28 deletions(-) diff --git a/public/assets/css/base.css b/public/assets/css/base.css index fb7d7adbbc..ee7c3f5864 100644 --- a/public/assets/css/base.css +++ b/public/assets/css/base.css @@ -281,10 +281,11 @@ hr { display: flex; background-color: var(--translucent); border-radius: var(--unit-size); + border: solid 2px var(--bg2); } .note-wrapper { width: 100%; - height: available; + height: inherit; } .note-sidebar { @@ -317,13 +318,12 @@ hr { align-items: center; max-height: 3rem; - border: solid 2px var(--bg2); border-bottom: unset; border-radius: var(--unit-size) var(--unit-size) 0 0; - background-color: var(--translucent); + background: linear-gradient(to left, var(--translucent), transparent); font-size: var(--medium-size); - padding: 5px 10px 5px 10px; + padding: 5px 10px 5px 0; } .note-author { @@ -345,10 +345,10 @@ hr { background-repeat: no-repeat !important; - width: var(--main-size) !important; - height: var(--main-size) !important; + width: var(--medium-size) !important; + height: var(--medium-size) !important; - margin-top: var(--unit-size); + margin-left: var(--unit-size); text-indent: -9999em; } @@ -386,8 +386,6 @@ hr { } .note-content { - border: solid 2px var(--bg2); - border-top: unset; border-radius: 0 0 var(--unit-size) var(--unit-size); height: max-content; diff --git a/templates/note/view.html.twig b/templates/note/view.html.twig index f0acde2bd4..0171aef8f3 100644 --- a/templates/note/view.html.twig +++ b/templates/note/view.html.twig @@ -3,25 +3,6 @@
@@ -33,6 +14,26 @@ {{ nickname }} + {% if app.user %} +
+ {% if have_user %} + {% for current_action in get_note_actions(note) %} + {{ form_start(current_action) }} + {% if current_action.submit_favourite is defined %} + {{ form_widget(current_action.submit_favourite) }} + {% endif %} + {% if current_action.submit_repeat is defined %} + {{ form_widget(current_action.submit_repeat) }} + {% endif %} + {% if current_action.reply is defined %} + {{ form_widget(current_action.reply) }} + {% endif %} + {{ form_end(current_action) }} + {% endfor %} + {% endif %} +
+ {% endif %} + {% set reply_to = note.getReplyToNickname() %} {% if reply_to is not null and not skip_reply_to is defined %} {% trans with {'%name%': reply_to} %} in reply to %name% {% endtrans %}