Files
fizzy/app/views/comments/_body.html.erb
T

26 lines
1.3 KiB
Plaintext

<% cache comment do %>
<%= turbo_frame_tag dom_id(comment) do %>
<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, user_path(comment.creator), class: "txt-ink btn btn--plain fill-transparent", data: { turbo_frame: "_top" } %>
</strong>
<%= link_to bucket_bubble_path(comment.bubble.bucket, comment.bubble, anchor: "comment_#{comment.id}"), class: "txt-undecorated txt-uppercase" do %>
<%= local_datetime_tag comment.created_at, style: :shortdate, class: "txt-ink translucent" %>
<% end %>
<%= link_to edit_bucket_bubble_comment_path(comment.bubble.bucket, comment.bubble, comment),
class: "comment__edit btn btn--plain txt-xx-small fill-transparent translucent flex-item-justify-end" do %>
<%= image_tag "menu-dots-horizontal.svg", class: "colorize--black" %>
<span class="for-screen-reader">Edit this comment</span>
<% end %>
</div>
<div class="comment__body txt-align-start">
<%= sanitize comment.body_html %>
</div>
<%= render "comments/reactions/reactions", comment: comment %>
</div>
<% end %>
<% end %>