20 lines
1.0 KiB
Plaintext
20 lines
1.0 KiB
Plaintext
<% cache notification do %>
|
|
<%= notification_tag notification do %>
|
|
<div class="avatar txt-x-small flex-item-no-shrink">
|
|
<%= avatar_image_tag notification.creator %>
|
|
</div>
|
|
|
|
<div class="flex flex-column min-width flex-item-grow">
|
|
<strong class="overflow-ellipsis notification__title txt-small txt-tight-lines"><%= notification_title(notification) %></strong>
|
|
<div class="overflow-ellipsis txt-small txt-tight-lines">
|
|
<% if notification.event.action == "commented" %>
|
|
<%= "#{strip_tags(notification.event.comment.body_html).blank? ? "#{notification.event.creator.name} replied" : "#{notification.event.creator.name}:" } #{strip_tags(notification.event.comment.body_html).truncate(200)}" %>
|
|
<% else %>
|
|
<%= notification_body(notification) %>
|
|
<% end %>
|
|
</div>
|
|
<div class="tray__item-meta overflow-ellipsis translucent"><%= notification.card.collection.name %> · <%= local_datetime_tag(notification.created_at, style: :ago) %></div>
|
|
</div>
|
|
<% end %>
|
|
<% end %>
|