Scrollable tables in settings pages (#4857)

* Scrollable tables in settings pages

* Add space before curly brace
signup-info-prompt
Lynx Kotoura 2017-09-09 09:26:58 +09:00 committed by Eugen Rochko
parent baa8b82179
commit 3c45d3963a
15 changed files with 262 additions and 249 deletions

View File

@ -190,11 +190,15 @@
.filters { .filters {
display: flex; display: flex;
margin-bottom: 20px; flex-wrap: wrap;
.filter-subset { .filter-subset {
flex: 0 0 auto; flex: 0 0 auto;
margin-right: 40px; margin: 0 40px 10px 0;
&:last-child {
margin-bottom: 20px;
}
ul { ul {
margin-top: 5px; margin-top: 5px;

View File

@ -3,7 +3,6 @@
max-width: 100%; max-width: 100%;
border-spacing: 0; border-spacing: 0;
border-collapse: collapse; border-collapse: collapse;
margin-bottom: 20px;
th, th,
td { td {
@ -43,17 +42,15 @@
font-weight: 500; font-weight: 500;
} }
&.inline-table { &.inline-table > tbody > tr:nth-child(odd) > td,
td, &.inline-table > tbody > tr:nth-child(odd) > th {
th {
padding: 8px 2px;
}
& > tbody > tr:nth-child(odd) > td,
& > tbody > tr:nth-child(odd) > th {
background: transparent; background: transparent;
} }
} }
.table-wrapper {
overflow: auto;
margin-bottom: 20px;
} }
samp { samp {

View File

@ -1,4 +1,5 @@
%table.table .table-wrapper
%table.table
%tbody %tbody
%tr %tr
%td= t('admin.accounts.show.created_reports') %td= t('admin.accounts.show.created_reports')

View File

@ -50,7 +50,8 @@
%button= t('admin.accounts.search') %button= t('admin.accounts.search')
= link_to t('admin.accounts.reset'), admin_accounts_path, class: 'button negative' = link_to t('admin.accounts.reset'), admin_accounts_path, class: 'button negative'
%table.table .table-wrapper
%table.table
%thead %thead
%tr %tr
%th= t('admin.accounts.username') %th= t('admin.accounts.username')

View File

@ -1,7 +1,8 @@
- content_for :page_title do - content_for :page_title do
= @account.acct = @account.acct
%table.table .table-wrapper
%table.table
%tbody %tbody
%tr %tr
%th= t('admin.accounts.username') %th= t('admin.accounts.username')
@ -81,7 +82,6 @@
%th= t('.targeted_reports') %th= t('.targeted_reports')
%td= link_to pluralize(@account.targeted_reports.count, t('.report')), admin_reports_path(target_account_id: @account.id) %td= link_to pluralize(@account.targeted_reports.count, t('.report')), admin_reports_path(target_account_id: @account.id)
%div{ style: 'float: right' } %div{ style: 'float: right' }
- if @account.local? - if @account.local?
= link_to t('admin.accounts.reset_password'), admin_account_reset_path(@account.id), method: :create, class: 'button' = link_to t('admin.accounts.reset_password'), admin_account_reset_path(@account.id), method: :create, class: 'button'

View File

@ -1,7 +1,8 @@
- content_for :page_title do - content_for :page_title do
= t('admin.domain_blocks.title') = t('admin.domain_blocks.title')
%table.table .table-wrapper
%table.table
%thead %thead
%tr %tr
%th= t('admin.domain_blocks.domain') %th= t('admin.domain_blocks.domain')

View File

@ -1,7 +1,8 @@
- content_for :page_title do - content_for :page_title do
= t('admin.instances.title') = t('admin.instances.title')
%table.table .table-wrapper
%table.table
%thead %thead
%tr %tr
%th= t('admin.instances.domain_name') %th= t('admin.instances.domain_name')

View File

@ -10,6 +10,7 @@
= form_tag do = form_tag do
.table-wrapper
%table.table %table.table
%thead %thead
%tr %tr

View File

@ -1,7 +1,8 @@
- content_for :page_title do - content_for :page_title do
= t('admin.subscriptions.title') = t('admin.subscriptions.title')
%table.table .table-wrapper
%table.table
%thead %thead
%tr %tr
%th= t('admin.subscriptions.topic') %th= t('admin.subscriptions.topic')

View File

@ -1,7 +1,8 @@
%h6= t 'sessions.title' %h6= t 'sessions.title'
%p.muted-hint= t 'sessions.explanation' %p.muted-hint= t 'sessions.explanation'
%table.table.inline-table .table-wrapper
%table.table.inline-table
%thead %thead
%tr %tr
%th= t 'sessions.browser' %th= t 'sessions.browser'

View File

@ -1,7 +1,8 @@
- content_for :page_title do - content_for :page_title do
= t('doorkeeper.authorized_applications.index.title') = t('doorkeeper.authorized_applications.index.title')
%table.table .table-wrapper
%table.table
%thead %thead
%tr %tr
%th= t('doorkeeper.authorized_applications.index.application') %th= t('doorkeeper.authorized_applications.index.application')

View File

@ -1,7 +1,8 @@
- content_for :page_title do - content_for :page_title do
= t('doorkeeper.applications.index.title') = t('doorkeeper.applications.index.title')
%table.table .table-wrapper
%table.table
%thead %thead
%tr %tr
%th= t('doorkeeper.applications.index.application') %th= t('doorkeeper.applications.index.application')

View File

@ -3,7 +3,8 @@
%p.hint= t('applications.warning') %p.hint= t('applications.warning')
%table.table .table-wrapper
%table.table
%tbody %tbody
%tr %tr
%th= t('doorkeeper.applications.show.application_id') %th= t('doorkeeper.applications.show.application_id')

View File

@ -1,7 +1,8 @@
- content_for :page_title do - content_for :page_title do
= t('settings.export') = t('settings.export')
%table.table .table-wrapper
%table.table
%tbody %tbody
%tr %tr
%th= t('exports.storage') %th= t('exports.storage')

View File

@ -12,6 +12,7 @@
%p= t('followers.explanation_html') %p= t('followers.explanation_html')
%p= t('followers.true_privacy_html') %p= t('followers.true_privacy_html')
.table-wrapper
%table.table %table.table
%thead %thead
%tr %tr