From d804d09fd41d120262f30bdb87cc7603bb89d5c4 Mon Sep 17 00:00:00 2001 From: Anton Khorev Date: Tue, 1 Jul 2025 03:42:42 +0300 Subject: [PATCH] Reserve space for two-digit comment count in changeset line --- app/assets/stylesheets/common.scss | 4 ++++ app/views/changesets/_changeset_line.html.erb | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/app/assets/stylesheets/common.scss b/app/assets/stylesheets/common.scss index 69933a809..978a88f37 100644 --- a/app/assets/stylesheets/common.scss +++ b/app/assets/stylesheets/common.scss @@ -620,6 +620,10 @@ tr.turn { } } +#sidebar .changeset_line .changeset_num_comments { + min-width: 2.5em; +} + /* Rules for the browse sidebar */ #sidebar_content { diff --git a/app/views/changesets/_changeset_line.html.erb b/app/views/changesets/_changeset_line.html.erb index ebfb90aab..e7beeb72b 100644 --- a/app/views/changesets/_changeset_line.html.erb +++ b/app/views/changesets/_changeset_line.html.erb @@ -1,4 +1,4 @@ -
+
<%= yield %> @@ -14,7 +14,7 @@ <% end %> <% if num_comments %> - <%= tag.span :class => ["d-flex align-items-baseline gap-1", { "opacity-50" => num_comments.zero? }], + <%= tag.span :class => ["changeset_num_comments d-flex align-items-baseline gap-1 justify-content-end", { "opacity-50" => num_comments.zero? }], :title => t(".comments", :count => num_comments) do %> <%= num_comments %> -- 2.39.5