clacks/lib/clacks_web/templates/frontend/_action_status.html.eex

40 lines
1.4 KiB
Elixir

<% past_tense =
case @action do
:like -> "Liked"
:announce -> "Announced"
end
%>
<div class="<%= assigns[:class] || "status" %>">
<div class="status-meta">
<p class="status-announcer">
<%= past_tense %> by <a href="<%= local_actor_link(@action_actor) %>"><%= @action_actor.data["preferredUsername"] %></a>
</p>
<p class="status-meta-right">
<time datetime="<%= @action_activity.data["published"] %>"><%= display_timestamp(@action_activity.data["published"]) %></time>
</p>
</div>
<div class="status-meta">
<h2 class="status-author-nickname">
<a href="<%= local_actor_link(@original_actor) %>">
<%= @original_actor.data["preferredUsername"] %>
</a>
</h2>
<h3 class="status-author-username">
<a href="<%= @original_actor.ap_id %>">
<%= display_username(@original_actor) %>
</a>
</h3>
<p class="status-meta-right">
<time datetime="<%= @original_note["published"] %>"><%= display_timestamp(@original_note["published"]) %></time>
<a href="<%= @original_note["url"] || @original_note["id"] %>" class="status-permalink">Permalink</a>
</p>
</div>
<div class="status-content">
<%= raw(@original_note["content"]) %>
</div>
<div class="status-actions">
<a href="<%= Routes.frontend_path(@conn, :reply, @original_activity.id) %>">Reply</a>
</div>
</div>