~cytrogen/masto-fe

163b004bb19343f02a6d901d0f5723aae82df57f — Claire 2 years ago e90649b
Change admin e-mail notification settins to be their own settings group (#26596)

2 files changed, 10 insertions(+), 4 deletions(-)

M app/views/settings/preferences/notifications/show.html.haml
M config/locales/en.yml
M app/views/settings/preferences/notifications/show.html.haml => app/views/settings/preferences/notifications/show.html.haml +9 -4
@@ 18,14 18,19 @@
      = ff.input :'notification_emails.reblog', wrapper: :with_label, label: I18n.t('simple_form.labels.notification_emails.reblog')
      = ff.input :'notification_emails.favourite', wrapper: :with_label, label: I18n.t('simple_form.labels.notification_emails.favourite')
      = ff.input :'notification_emails.mention', wrapper: :with_label, label: I18n.t('simple_form.labels.notification_emails.mention')
      = ff.input :'notification_emails.report', wrapper: :with_label, label: I18n.t('simple_form.labels.notification_emails.report') if current_user.can?(:manage_reports)
      = ff.input :'notification_emails.appeal', as: :boolean, wrapper: :with_label, label: I18n.t('simple_form.labels.notification_emails.appeal') if current_user.can?(:manage_appeals)
      = ff.input :'notification_emails.pending_account', wrapper: :with_label, label: I18n.t('simple_form.labels.notification_emails.pending_account') if current_user.can?(:manage_users)
      = ff.input :'notification_emails.trends', wrapper: :with_label, label: I18n.t('simple_form.labels.notification_emails.trending_tag') if current_user.can?(:manage_taxonomies)

    .fields-group
      = ff.input :always_send_emails, wrapper: :with_label, label: I18n.t('simple_form.labels.defaults.setting_always_send_emails'), hint: I18n.t('simple_form.hints.defaults.setting_always_send_emails')

    - if current_user.can?(:manage_reports, :manage_appeals, :manage_users, :manage_taxonomies)
      %h4= t 'notifications.administration_emails'

      .fields-group
        = ff.input :'notification_emails.report', wrapper: :with_label, label: I18n.t('simple_form.labels.notification_emails.report') if current_user.can?(:manage_reports)
        = ff.input :'notification_emails.appeal', as: :boolean, wrapper: :with_label, label: I18n.t('simple_form.labels.notification_emails.appeal') if current_user.can?(:manage_appeals)
        = ff.input :'notification_emails.pending_account', wrapper: :with_label, label: I18n.t('simple_form.labels.notification_emails.pending_account') if current_user.can?(:manage_users)
        = ff.input :'notification_emails.trends', wrapper: :with_label, label: I18n.t('simple_form.labels.notification_emails.trending_tag') if current_user.can?(:manage_taxonomies)

  %h4= t 'notifications.other_settings'

  .fields-group

M config/locales/en.yml => config/locales/en.yml +1 -0
@@ 1446,6 1446,7 @@ en:
    update:
      subject: "%{name} edited a post"
  notifications:
    administration_emails: Admin e-mail notifications
    email_events: Events for e-mail notifications
    email_events_hint: 'Select events that you want to receive notifications for:'
    other_settings: Other notifications settings