From 698e4381c29e9f82ad0212612d7c4ed252c956c0 Mon Sep 17 00:00:00 2001 From: Sebastian Kippe Date: Mon, 1 Feb 2021 18:53:48 +0100 Subject: [PATCH] Improve table styles * Nicer table headers * Hide invitation IDs on small screens --- app/assets/stylesheets/layout.scss | 28 +++++++++++++++++++++++----- app/views/invitations/index.html.erb | 4 ++-- 2 files changed, 25 insertions(+), 7 deletions(-) diff --git a/app/assets/stylesheets/layout.scss b/app/assets/stylesheets/layout.scss index ac82e4b..cf4267b 100644 --- a/app/assets/stylesheets/layout.scss +++ b/app/assets/stylesheets/layout.scss @@ -118,11 +118,6 @@ main { } } - th, td { - line-height: 1.5rem; - padding-right: 1rem; - } - section { padding-bottom: 3rem; margin-bottom: 3rem; @@ -132,6 +127,29 @@ main { } } + table { + width: 100%; + + th, td { + line-height: 1.5rem; + padding-right: 1rem; + + &.hide-small { + @include media-max(small) { + display: none; + } + } + } + + th { + color: $text-color-discreet; + font-weight: normal; + text-transform: uppercase; + font-size: 0.85rem; + padding-bottom: 0.5rem; + } + } + .actions { margin-top: 2rem; } diff --git a/app/views/invitations/index.html.erb b/app/views/invitations/index.html.erb index a35d313..1c5996f 100644 --- a/app/views/invitations/index.html.erb +++ b/app/views/invitations/index.html.erb @@ -29,7 +29,7 @@ - + @@ -37,7 +37,7 @@ <% @invitations_used.each do |invitation| %> - +
URLID Accepted Invited user
<%= invitation_url(invitation.token) %><%= invitation.token %> <%= invitation.used_at.strftime("%Y-%m-%d") %> <%= User.find(invitation.invited_user_id).address %>