From 5b56e174b1b6a9cb3a359e7b5931c6809322af1c Mon Sep 17 00:00:00 2001 From: Stanislav Romanov Date: Thu, 18 Aug 2022 12:39:01 +0300 Subject: [PATCH] Add table styles --- app/assets/styles.css | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) diff --git a/app/assets/styles.css b/app/assets/styles.css index b5c61c9..d4305ec 100644 --- a/app/assets/styles.css +++ b/app/assets/styles.css @@ -1,3 +1,42 @@ @tailwind base; @tailwind components; @tailwind utilities; + +.royal-table { + @apply table-auto border text-left mb-4; + + thead { + @apply bg-light; + + tr { + @apply border-b; + + th { + @apply px-4 py-4 text-dark font-normal whitespace-nowrap; + + &[type="button"] { + @apply cursor-pointer select-none; + } + + svg { + width: 1em; + height: 1em; + bottom: .1em; + position: relative; + } + } + } + } + + tbody { + tr { + &:nth-child(even) { + @apply bg-light; + } + + td { + @apply px-4 py-2 text-text; + } + } + } +}