Deprecate Pleroma.Web.base_url/0
[akkoma] / lib / pleroma / web / templates / feed / feed / _activity.rss.eex
1 <item>
2 <activity:object-type>http://activitystrea.ms/schema/1.0/note</activity:object-type>
3 <activity:verb>http://activitystrea.ms/schema/1.0/post</activity:verb>
4 <guid><%= @data["id"] %></guid>
5 <title><%= activity_title(@data, Keyword.get(@feed_config, :post_title, %{})) %></title>
6 <description><%= activity_content(@data) %></description>
7 <pubDate><%= @activity.data["published"] %></pubDate>
8 <updated><%= @activity.data["published"] %></updated>
9 <ostatus:conversation ref="<%= activity_context(@activity) %>">
10 <%= activity_context(@activity) %>
11 </ostatus:conversation>
12
13 <%= if @data["summary"] do %>
14 <description><%= escape(@data["summary"]) %></description>
15 <% end %>
16
17 <%= if @activity.local do %>
18 <link><%= @data["id"] %></link>
19 <% else %>
20 <link><%= @data["external_url"] %></link>
21 <% end %>
22
23 <link rel="ostatus:conversation"><%= activity_context(@activity) %></link>
24
25 <%= for tag <- @data["tag"] || [] do %>
26 <category term="<%= tag %>"></category>
27 <% end %>
28
29 <%= for attachment <- @data["attachment"] || [] do %>
30 <link type="<%= attachment_type(attachment) %>"><%= attachment_href(attachment) %></link>
31 <% end %>
32
33 <%= if @data["inReplyTo"] do %>
34 <thr:in-reply-to ref='<%= @data["inReplyTo"] %>' href='<%= get_href(@data["inReplyTo"]) %>'/>
35 <% end %>
36
37 <%= for id <- @activity.recipients do %>
38 <%= if id == Pleroma.Constants.as_public() do %>
39 <link rel="mentioned" ostatus:object-type="http://activitystrea.ms/schema/1.0/collection">http://activityschema.org/collection/public</link>
40 <% else %>
41 <%= unless Regex.match?(~r/^#{Pleroma.Web.Endpoint.url()}.+followers$/, id) do %>
42 <link rel="mentioned" ostatus:object-type="http://activitystrea.ms/schema/1.0/person"><%= id %></link>
43 <% end %>
44 <% end %>
45 <% end %>
46
47 <%= for {emoji, file} <- @data["emoji"] || %{} do %>
48 <link name="<%= emoji %>" rel="emoji"><%= file %></link>
49 <% end %>
50 </item>