From 9d95d548e8be3d7c4428d3b350836fcb1a40de24 Mon Sep 17 00:00:00 2001 From: Anton Khorev Date: Tue, 8 Aug 2023 18:29:05 +0300 Subject: [PATCH 1/1] Update diary comments styling --- app/assets/stylesheets/common.scss | 11 ----------- app/views/diary_entries/_diary_comment.html.erb | 4 ++-- app/views/diary_entries/show.html.erb | 2 +- 3 files changed, 3 insertions(+), 14 deletions(-) diff --git a/app/assets/stylesheets/common.scss b/app/assets/stylesheets/common.scss index abee14c39..7b3bfde36 100644 --- a/app/assets/stylesheets/common.scss +++ b/app/assets/stylesheets/common.scss @@ -1060,23 +1060,12 @@ tr.turn:hover { } .diary-comment { border-top: 1px dashed $grey; - padding-top: $lineheight/2; - padding-bottom: $lineheight/2; &:first-child { - margin-top: $lineheight/2; - padding-top: $lineheight; border-top: 1px solid $grey; } - &.deleted { - background-color: #fee; - } p { margin-bottom: $lineheight/2; } - .comment-heading { - margin-bottom: 0; - margin-top: 0; - } } } diff --git a/app/views/diary_entries/_diary_comment.html.erb b/app/views/diary_entries/_diary_comment.html.erb index 403d30742..238f4d43c 100644 --- a/app/views/diary_entries/_diary_comment.html.erb +++ b/app/views/diary_entries/_diary_comment.html.erb @@ -1,9 +1,9 @@ -
"> +
">
<%= user_thumbnail diary_comment.user %>
-

<%= t(".comment_from_html", :link_user => (link_to diary_comment.user.display_name, user_path(diary_comment.user)), :comment_created_at => link_to(l(diary_comment.created_at, :format => :friendly), :anchor => "comment#{diary_comment.id}")) %> +

<%= t(".comment_from_html", :link_user => (link_to diary_comment.user.display_name, user_path(diary_comment.user)), :comment_created_at => link_to(l(diary_comment.created_at, :format => :friendly), :anchor => "comment#{diary_comment.id}")) %> <% if current_user and diary_comment.user.id != current_user.id %> | <%= report_link(t(".report"), diary_comment) %> <% end %> diff --git a/app/views/diary_entries/show.html.erb b/app/views/diary_entries/show.html.erb index 879207495..ab45a24b6 100644 --- a/app/views/diary_entries/show.html.erb +++ b/app/views/diary_entries/show.html.erb @@ -13,7 +13,7 @@ <%= render @entry %> -

+
<%= render :partial => "diary_comment", :collection => @comments %>
-- 2.39.5