about summary refs log tree commit diff
path: root/app/views
diff options
context:
space:
mode:
Diffstat (limited to 'app/views')
-rw-r--r--app/views/accounts/show.atom.ruby3
-rw-r--r--app/views/admin/pubsubhubbub/index.html.haml20
-rw-r--r--app/views/api/v1/statuses/_show.rabl2
-rw-r--r--app/views/settings/preferences/show.html.haml4
-rw-r--r--app/views/stream_entries/show.html.haml3
5 files changed, 31 insertions, 1 deletions
diff --git a/app/views/accounts/show.atom.ruby b/app/views/accounts/show.atom.ruby
index d7b2201d4..558c777f0 100644
--- a/app/views/accounts/show.atom.ruby
+++ b/app/views/accounts/show.atom.ruby
@@ -1,3 +1,5 @@
+# frozen_string_literal: true
+
 Nokogiri::XML::Builder.new do |xml|
   feed(xml) do
     simple_id  xml, account_url(@account, format: 'atom')
@@ -12,6 +14,7 @@ Nokogiri::XML::Builder.new do |xml|
 
     link_alternate xml, TagManager.instance.url_for(@account)
     link_self      xml, account_url(@account, format: 'atom')
+    link_hub       xml, api_push_url
     link_hub       xml, Rails.configuration.x.hub_url
     link_salmon    xml, api_salmon_url(@account.id)
 
diff --git a/app/views/admin/pubsubhubbub/index.html.haml b/app/views/admin/pubsubhubbub/index.html.haml
new file mode 100644
index 000000000..bb897eb89
--- /dev/null
+++ b/app/views/admin/pubsubhubbub/index.html.haml
@@ -0,0 +1,20 @@
+%table.table
+  %thead
+    %tr
+      %th Topic
+      %th Callback URL
+      %th Confirmed
+      %th Expires in
+  %tbody
+    - @subscriptions.each do |subscription|
+      %tr
+        %td
+          %samp= subscription.account.acct
+        %td
+          %samp= subscription.callback_url
+        %td
+          - if subscription.confirmed?
+            %i.fa.fa-check
+        %td= distance_of_time_in_words(Time.now, subscription.expires_at)
+
+= will_paginate @subscriptions, pagination_options
diff --git a/app/views/api/v1/statuses/_show.rabl b/app/views/api/v1/statuses/_show.rabl
index 90457eca9..579c47b26 100644
--- a/app/views/api/v1/statuses/_show.rabl
+++ b/app/views/api/v1/statuses/_show.rabl
@@ -1,4 +1,4 @@
-attributes :id, :created_at, :in_reply_to_id
+attributes :id, :created_at, :in_reply_to_id, :sensitive
 
 node(:uri)              { |status| TagManager.instance.uri_for(status) }
 node(:content)          { |status| Formatter.instance.format(status) }
diff --git a/app/views/settings/preferences/show.html.haml b/app/views/settings/preferences/show.html.haml
index 693702ff7..db5b9fb48 100644
--- a/app/views/settings/preferences/show.html.haml
+++ b/app/views/settings/preferences/show.html.haml
@@ -12,6 +12,10 @@
     = ff.input :favourite, as: :boolean, wrapper: :with_label
     = ff.input :mention, as: :boolean, wrapper: :with_label
 
+  = f.simple_fields_for :interactions, current_user.settings(:interactions) do |ff|
+    = ff.input :must_be_follower, as: :boolean, wrapper: :with_label
+    = ff.input :must_be_following, as: :boolean, wrapper: :with_label
+
   .actions
     = f.button :button, t('generic.save_changes'), type: :submit
 
diff --git a/app/views/stream_entries/show.html.haml b/app/views/stream_entries/show.html.haml
index b16258679..2c6de32d9 100644
--- a/app/views/stream_entries/show.html.haml
+++ b/app/views/stream_entries/show.html.haml
@@ -1,5 +1,8 @@
 - content_for :header_tags do
   %link{ rel: 'alternate', type: 'application/atom+xml', href: account_stream_entry_url(@account, @stream_entry, format: 'atom') }/
+  %meta{ name: 'og:site_name', content: 'Mastodon' }/
+  %meta{ name: 'og:type', content: 'article' }/
+  %meta{ name: 'og:article:author', content: @account.username }/
 
 .activity-stream.activity-stream-headless
   = render partial: @type, locals: { @type.to_sym => @stream_entry.activity, include_threads: true }