c6c9e0d5fc
- Restyle system events so they don't look like comments and aren't attributed to the system user - Ensure the event creator is included in the description so it's clear who did it. - Walk back system comment replacement. Yes, it potentially avoids embarassing people when they change their mind, it's also losing data. If two intentional assigments happen in proximity, we've been only showing the latest one,.
40 lines
1.9 KiB
Plaintext
40 lines
1.9 KiB
Plaintext
<% cache comment do %>
|
|
<%= turbo_frame_tag comment do %>
|
|
<div class="comment flex align-start full-width <%= "comment--system" if comment.creator.system? %>" data-creator-id="<%= comment.creator_id %>" data-created-by-current-user-target="creation">
|
|
<figure class="comment__avatar flex-item-no-shrink" aria-hidden="true">
|
|
<%= avatar_tag comment.creator, hidden_for_screen_reader: true %>
|
|
</figure>
|
|
|
|
<div class="comment__content flex flex-column flex-item-grow full-width">
|
|
<div class="comment__author flex align-center gap-half">
|
|
<strong>
|
|
<%= link_to comment.creator.name, comment.creator, class: "txt-ink btn btn--plain fill-transparent", data: { turbo_frame: "_top" } %>
|
|
</strong>
|
|
|
|
<%= link_to comment, class: "txt-undecorated txt-ink translucent txt-normal txt-capitalize flex-item-justify-start" do %>
|
|
<%= local_datetime_tag comment.created_at, style: :agoorweekday %>,
|
|
<%= local_datetime_tag comment.created_at, style: :time %>
|
|
<% end %>
|
|
|
|
<%= link_to edit_card_comment_path(comment.card, comment),
|
|
class: "comment__edit btn btn--circle borderless fill-transparent translucent" do %>
|
|
<%= icon_tag "menu-dots-horizontal" %> <span class="for-screen-reader">Edit this comment</span>
|
|
<% end %>
|
|
|
|
<%= render "cards/comments/reactions/quick_reaction", comment: comment do %>
|
|
<button class="comment__reaction btn btn--circle borderless fill-transparent" data-action="click->dialog#open:stop">
|
|
<%= icon_tag "menu-dots-horizontal" %>
|
|
</button>
|
|
<% end %>
|
|
</div>
|
|
|
|
<div class="comment__body markdown-content txt-align-start">
|
|
<%= sanitize comment.body_html %>
|
|
</div>
|
|
|
|
<%= render "cards/comments/reactions/reactions", comment: comment %>
|
|
</div>
|
|
</div>
|
|
<% end %>
|
|
<% end %>
|