44 lines
1.5 KiB
Elixir
44 lines
1.5 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">
|
|
<%= unless is_nil(@conn.assigns[:user]) do %>
|
|
<%= render_status_content(@original_activity) %>
|
|
<% else %>
|
|
<%= raw(@original_note["content"]) %>
|
|
<% end %>
|
|
</div>
|
|
<div class="status-actions">
|
|
<a href="<%= Routes.frontend_path(@conn, :reply, @original_activity.id) %>">Reply</a>
|
|
</div>
|
|
</div>
|