This commit: - Refactors centered text blocks currently used for placeholders for empty tables and puts styles for it in separate class - .centered-text, simply aliasing text-align: center. Which is furtherly used in this commit. - Improves applications settings page to use heading actions, moving "New application" button there, and displaying placeholder "You have no applications" in place of empty table. - Improves custom emoji settings page to use heading action for "Upload" button, making it more easily accessible without need to scroll through all of the emojis. - Improves email domain blocks settings page, moving "Add new" to the heading actions and using placeholder "No e-mail domains currently blacklisted" instead of showing empty table.
24 lines
836 B
Text
24 lines
836 B
Text
- content_for :page_title do
|
|
= t('filters.index.title')
|
|
|
|
- content_for :heading_actions do
|
|
= link_to t('filters.new.title'), new_filter_path, class: 'button'
|
|
|
|
- if @filters.count == 0
|
|
%div.muted-hint.center-text= t 'filters.index.empty'
|
|
- else
|
|
.table-wrapper
|
|
%table.table
|
|
%thead
|
|
%tr
|
|
%th= t('simple_form.labels.defaults.phrase')
|
|
%th= t('simple_form.labels.defaults.context')
|
|
%th
|
|
%tbody
|
|
- @filters.each do |filter|
|
|
%tr
|
|
%td= filter.phrase
|
|
%td= filter.context.map { |context| I18n.t("filters.contexts.#{context}") }.join(', ')
|
|
%td
|
|
= table_link_to 'pencil', t('filters.edit.title'), edit_filter_path(filter)
|
|
= table_link_to 'times', t('filters.index.delete'), filter_path(filter), method: :delete
|