table.fixed { table-layout: fixed; } table:not([id]) > thead .sort-asc, table:not([id]) > thead .sort-desc { display: none; } table .order-up, table .order-down { cursor: pointer; } table thead input[type=radio] { padding: 0; margin: 0; display: none; } table thead i.fa { color: #888; } table input[type=radio]:checked + i { color: var(--button-colored-background); } table input[type=checkbox]:checked + label i { color: var(--button-colored-background); } table .sort-asc, table .sort-desc, table .filter { padding: 0 2px 0 2px; cursor: pointer; } @for $i from 1 through 10 { .fixed-#{$i} td:nth-child(#{$i}) { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; } } table.default.sticky { position: relative; thead { th, td { background: var(--table-head-background); position: sticky; top: 0; z-index: 2; } } } table.default { border-radius: 4px; width: 100%; max-width: 100%; font-size: 0.9em; box-sizing: border-box; overflow-x: auto; tbody { :not(.tag) > .fa { color: var(--button-colored-background); } } caption { font-size: 1.5rem; font-weight: 400; border-bottom: 1px solid var(--box-border); background: var(--table-caption-background); padding: .5rem; border-top-left-radius: 4px; border-top-right-radius: 4px; text-align: left; i { font-size: .8rem; } height: 3rem; } td { padding: 5px 10px 5px 10px; white-space: nowrap; } tbody { tr { height: 3rem; &:nth-of-type(2n) td { background: var(--table-row-background); } &:nth-of-type(2n+1) td { background: var(--table-row-background-alt); } &:hover td, &:focus td { background: var(--table-row-background-hover); } td, th { border-bottom: 1px solid var(--box-border); } &:last-child td, &:last-child th { border: none; } &:focus, &:hover { outline: none; transform: scale(1); box-shadow: 0 0 5px rgba(90, 71, 114, 0.3); } } th { background: var(--table-head-background); } } thead { background: var(--table-head-background); tr { height: 3rem; } td { border-bottom: 1px solid var(--box-border); } input[type=radio] { display: none; &:checked + label { color: var(--box-highlight);; } } } .empty { text-align: center; color: #d8d8d8; } tfoot { border: none; label { float: left; } select { width: auto; float: right; margin: 0; min-width: 0px; } td { text-align: center; padding-top: 10px; } } } table.list { th { text-align: left; padding: 2px 0 2px 0; } td { padding: 2px 5px 2px 5px; } } @media screen and (max-width: 600px) { table.table { display: table; table-layout: fixed; width: 100%; border: 0; thead { display: none; } tbody { tr { height: auto; display: block; margin-bottom: .625em; td:last-child { border-bottom: 1px solid var(--box-border); } &:last-child td { border-bottom: none; &:last-child { border-bottom: 1px solid var(--box-border); } } } td { border-left: 1px solid var(--box-border); border-right: 1px solid var(--box-border); display: block; font-size: .8rem; text-align: right; position: relative; height: 2rem; line-height: 2rem; text-overflow: ellipsis; overflow: hidden; max-width: 100%; &:before { content: attr(data-label); float: left; margin-right: 10px; font-weight: bold; } } } tfoot { // if not hidden colspan will cause problems and reduce width based on cospan value // 1/cospan_val display: none; } } } .nobreak { white-space: nowrap; }