Put “Add new domain block” button on /admin/instances in header (#13934)

This commit is contained in:
Mélanie Chauvel 2020-06-03 20:19:14 +02:00 committed by GitHub
parent 175fd5b8ba
commit 77619b1654
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,6 +1,12 @@
- content_for :page_title do - content_for :page_title do
= t('admin.instances.title') = t('admin.instances.title')
- content_for :heading_actions do
- if whitelist_mode?
= link_to t('admin.domain_allows.add_new'), new_admin_domain_allow_path, class: 'button'
- else
= link_to t('admin.domain_blocks.add_new'), new_admin_domain_block_path, class: 'button'
.filters .filters
.filter-subset .filter-subset
%strong= t('admin.instances.moderation.title') %strong= t('admin.instances.moderation.title')
@ -10,12 +16,6 @@
- unless whitelist_mode? - unless whitelist_mode?
%li= filter_link_to t('admin.instances.moderation.limited'), limited: '1' %li= filter_link_to t('admin.instances.moderation.limited'), limited: '1'
%div.special-action-button
- if whitelist_mode?
= link_to t('admin.domain_allows.add_new'), new_admin_domain_allow_path, class: 'button'
- else
= link_to t('admin.domain_blocks.add_new'), new_admin_domain_block_path, class: 'button'
- unless whitelist_mode? - unless whitelist_mode?
= form_tag admin_instances_url, method: 'GET', class: 'simple_form' do = form_tag admin_instances_url, method: 'GET', class: 'simple_form' do
.fields-group .fields-group