From 213176c3c33088794ec2557fe54b10481ed603ed Mon Sep 17 00:00:00 2001 From: scarlett Date: Mon, 10 Dec 2018 23:15:01 +0000 Subject: [PATCH 1/2] Add new frontend options to server-side config. --- config/config.exs | 5 ++++- lib/pleroma/web/twitter_api/controllers/util_controller.ex | 5 ++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/config/config.exs b/config/config.exs index 8d2fdd40d..1401b0a3d 100644 --- a/config/config.exs +++ b/config/config.exs @@ -126,7 +126,10 @@ formatting_options_enabled: false, collapse_message_with_subject: false, hide_post_stats: false, - hide_user_stats: false + hide_user_stats: false, + scope_copy: true, + subject_line_behavior: "email", + always_show_subject_input: true config :pleroma, :activitypub, accept_blocks: true, diff --git a/lib/pleroma/web/twitter_api/controllers/util_controller.ex b/lib/pleroma/web/twitter_api/controllers/util_controller.ex index 0ed519ea6..b1e4c77e8 100644 --- a/lib/pleroma/web/twitter_api/controllers/util_controller.ex +++ b/lib/pleroma/web/twitter_api/controllers/util_controller.ex @@ -183,7 +183,10 @@ def config(conn, _params) do formattingOptionsEnabled: Keyword.get(instance_fe, :formatting_options_enabled), collapseMessageWithSubject: Keyword.get(instance_fe, :collapse_message_with_subject), hidePostStats: Keyword.get(instance_fe, :hide_post_stats), - hideUserStats: Keyword.get(instance_fe, :hide_user_stats) + hideUserStats: Keyword.get(instance_fe, :hide_user_stats), + scopeCopy: Keyword.get(instance_fe, :scope_copy), + subjectLineBehavior: Keyword.get(instance_fe, :subject_line_behavior), + alwaysShowSubjectInput: Keyword.get(instance_fe, :always_show_subject_input) } managed_config = Keyword.get(instance, :managed_config) From e1cbb183276eb44ae620da5018cb1f6134cadfd4 Mon Sep 17 00:00:00 2001 From: scarlett Date: Mon, 10 Dec 2018 23:23:10 +0000 Subject: [PATCH 2/2] Document the new frontend options. --- config/config.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/config/config.md b/config/config.md index 5b30ddc27..dbbfa9194 100644 --- a/config/config.md +++ b/config/config.md @@ -57,6 +57,12 @@ This filter replaces the filename (not the path) of an upload. For complete obfu * `allowed_post_formats`: MIME-type list of formats allowed to be posted (transformed into HTML) * `finmoji_enabled`: Whenether to enable the finmojis in the custom emojis. * `mrf_transparency`: Make the content of your Message Rewrite Facility settings public (via nodeinfo). +* `scope_copy`: Copy the scope (private/unlisted/public) in replies to posts by default. +* `subject_line_behavior`: Allows changing the default behaviour of subject lines in replies. Valid values: + * "email": Copy and preprend re:, as in email. + * "masto": Copy verbatim, as in Mastodon. + * "noop": Don't copy the subject. +* `always_show_subject_input`: When set to false, auto-hide the subject field when it's empty. ## :fe This section is used to configure Pleroma-FE, unless ``:managed_config`` in ``:instance`` is set to false.