about summary refs log tree commit diff
path: root/config
diff options
context:
space:
mode:
Diffstat (limited to 'config')
-rw-r--r--config/application.rb2
-rw-r--r--config/locales/en.yml18
-rw-r--r--config/locales/simple_form.en.yml1
-rw-r--r--config/routes.rb21
4 files changed, 31 insertions, 11 deletions
diff --git a/config/application.rb b/config/application.rb
index 091f9c535..79ace8521 100644
--- a/config/application.rb
+++ b/config/application.rb
@@ -45,7 +45,7 @@ module Mastodon
     config.browserify_rails.commandline_options = '--transform [ babelify --presets [ es2015 react ] ] --extension=".jsx"'
 
     config.to_prepare do
-      Doorkeeper::AuthorizationsController.layout 'auth'
+      Doorkeeper::AuthorizationsController.layout 'public'
     end
 
     config.action_dispatch.default_headers = {
diff --git a/config/locales/en.yml b/config/locales/en.yml
index 4cf958517..e166fc717 100644
--- a/config/locales/en.yml
+++ b/config/locales/en.yml
@@ -14,6 +14,7 @@ en:
     people_followed_by: People whom %{name} follows
     people_who_follow: People who follow %{name}
     posts: Posts
+    remote_follow: Remote follow
     unfollow: Unfollow
   application_mailer:
     signature: Mastodon notifications from %{instance}
@@ -26,6 +27,11 @@ en:
     resend_confirmation: Resend confirmation instructions
     reset_password: Reset password
     set_new_password: Set new password
+  authorize_follow:
+    error: Unfortunately, there was an error looking up the remote account
+    follow: Follow
+    prompt_html: 'You (<strong>%{self}</strong>) have requested to follow:'
+    title: Follow %{acct}
   datetime:
     distance_in_words:
       about_x_hours: "%{count}h"
@@ -40,10 +46,6 @@ en:
       x_minutes: "%{count}m"
       x_months: "%{count}mo"
       x_seconds: "%{count}s"
-  follow_requests:
-    authorize: Authorize
-    reject: Reject
-    title: Follow requests
   generic:
     changes_saved_msg: Changes successfully saved!
     powered_by: powered by %{link}
@@ -58,6 +60,9 @@ en:
     follow:
       body: "%{name} is now following you!"
       subject: "%{name} is now following you"
+    follow_request:
+      body: "%{name} has requested to follow you"
+      subject: 'Pending follower: %{name}'
     mention:
       body: 'You were mentioned by %{name} in:'
       subject: You were mentioned by %{name}
@@ -67,6 +72,11 @@ en:
   pagination:
     next: Next
     prev: Prev
+  remote_follow:
+    acct: Enter your username@domain you want to follow from
+    missing_resource: Could not find the required redirect URL for your account
+    proceed: Proceed to follow
+    prompt: 'You are going to follow:'
   settings:
     edit_profile: Edit profile
     preferences: Preferences
diff --git a/config/locales/simple_form.en.yml b/config/locales/simple_form.en.yml
index 12b717877..578208700 100644
--- a/config/locales/simple_form.en.yml
+++ b/config/locales/simple_form.en.yml
@@ -25,6 +25,7 @@ en:
       notification_emails:
         favourite: Send e-mail when someone favourites your status
         follow: Send e-mail when someone follows you
+        follow_request: Send e-mail when someone requests to follow you
         mention: Send e-mail when someone mentions you
         reblog: Send e-mail when someone reblogs your status
     'no': 'No'
diff --git a/config/routes.rb b/config/routes.rb
index e8c8f619d..18c239c48 100644
--- a/config/routes.rb
+++ b/config/routes.rb
@@ -31,6 +31,9 @@ Rails.application.routes.draw do
       end
     end
 
+    get :remote_follow,  to: 'remote_follow#new'
+    post :remote_follow, to: 'remote_follow#create'
+
     member do
       get :followers
       get :following
@@ -48,12 +51,9 @@ Rails.application.routes.draw do
   resources :media, only: [:show]
   resources :tags,  only: [:show]
 
-  resources :follow_requests do
-    member do
-      post :authorize
-      post :reject
-    end
-  end
+  # Remote follow
+  get  :authorize_follow, to: 'authorize_follow#new'
+  post :authorize_follow, to: 'authorize_follow#create'
 
   namespace :admin do
     resources :pubsubhubbub, only: [:index]
@@ -103,8 +103,17 @@ Rails.application.routes.draw do
       resources :follows,  only: [:create]
       resources :media,    only: [:create]
       resources :apps,     only: [:create]
+      resources :blocks,   only: [:index]
+
+      resources :follow_requests, only: [:index] do
+        member do
+          post :authorize
+          post :reject
+        end
+      end
 
       resources :notifications, only: [:index]
+      resources :favourites,    only: [:index]
 
       resources :accounts, only: [:show] do
         collection do