.table { position: relative; z-index: $zindex-dropdown; border-radius: $border-radius; border-collapse: separate; border-spacing: 0px; @include themify($themes) { color: themed("text-primary"); border: 1px solid themed("gray-30"); } &.b-table > thead > tr { & > [aria-sort="ascending"] { background-image: url("~@/assets/images/_sila/sort-ascending.svg"); background-size: 17px; } & > [aria-sort="descending"], [aria-sort="none"] { background-image: url("~@/assets/images/_sila/sort-descending.svg"); background-size: 14px; } } thead { th { border: none; &:first-child { border-radius: $border-radius 0 0 0; } &:last-child { border-radius: 0 $border-radius 0 0; } } } tbody { tr { border: none; &:first-child { border-radius: 0 0 0 $border-radius; } &:last-child { border-radius: 0 0 $border-radius 0; } &.b-table-details:hover { background-color: transparent; } } } td { vertical-align: middle; font-size: 0.875rem; @include themify($themes) { border-top: 1px solid themed("gray-30") !important; } // Table action buttons .btn-link { width: 40px; height: 40px; padding: 5px !important; display: inline-flex; justify-content: center; align-items: center; } } // thead-light added for specificity .thead-light th { vertical-align: middle; text-transform: uppercase; @include themify($themes) { color: themed("text-primary"); background-color: themed("gray-10"); } &:focus { outline: none; } & > div { font-size: 0.875rem !important; } } .custom-switch { width: 100%; } .status-icon svg { width: 1rem; height: auto; } .b-table-has-details { td { border-bottom: none; } .table-row-expand svg { transform: rotate(180deg); } } .b-table-details { background-color: inherit; @include themify($themes) { border-top: 1px solid themed("gray-30"); } td { padding-left: $table-cell-padding; padding-right: $table-cell-padding; } dl { margin: 0; } dt { font-size: 0.75rem !important; float: left; clear: left; margin-right: $spacer / 2; } dd { font-size: 0.75rem !important; line-height: 1.5; } } .table-row-expand { width: 50px; .btn { padding: 0; width: 40px; } svg { fill: theme-color("dark"); } } .b-table-sort-icon-left { background-position: left calc(1.1rem / 2) center !important; padding-left: calc(1.2rem + 0.65em) !important; &:focus { outline: none; box-shadow: inset 0 0 0 2px theme-color("primary") !important; } &:hover { @include themify($themes) { background-color: themed("gray-5-hover"); } } } .custom-radio, .custom-checkbox { margin-left: 10px; .custom-control-label::before, .custom-control-label::after { margin-top: 0px; } } } .table-hover tbody tr:hover { @include themify($themes) { color: themed("text-primary"); background-color: themed("gray-5"); } } .b-table-sticky-header td { border-top: none; } .table-responsive, .table-responsive-md { margin-top: 0.5rem; } [class*="table-responsive-"] { @include media-breakpoint-up(lg) { overflow: auto; width: calc(100vw - 347px); .table { border-radius: $border-radius; @include themify($themes) { border-right: 1px solid themed("gray-30"); } } .table-accessory, .table-full { border-right: none; border-radius: 0px; } } @include media-breakpoint-down(lg) { @include media-breakpoint-up(md) { overflow: auto; .table { border-radius: $border-radius; @include themify($themes) { border-right: 1px solid themed("gray-30"); } } .table-accessory, .table-full { border-right: none; border-radius: 0px; } } } } // style for table contained in components #page-network { [class*="table-responsive-"] { @include media-breakpoint-up(lg) { width: calc(100vw - 390px); } } } // Table stacked style for small screen only @include media-breakpoint-down(xs) { .b-table-stacked-sm { @include themify($themes) { border: 1px solid themed("gray-10"); } tr { &:not(:first-child) > td[aria-colindex="1"] { padding-top: 0.625rem; } &:not(.b-table-empty-row) { position: relative; // Restrict background color to get zebra striping for the row &::before, &::after { position: absolute; top: 0; height: 100%; z-index: -1; } &:before { content: ""; background-color: gray("200"); width: 40%; border-right: 1px solid gray("300"); } &:after { content: ""; right: 0; width: 60%; } &:nth-child(even)::after { background-color: gray("100"); // Zebra striping for the row } } td { border: 0; padding: 0.75rem; text-align: left !important; &:last-of-type { border-right: 0; } } } } .table.b-table.b-table-stacked-sm > tbody > tr > [data-label] { &::before { text-align: left; padding-left: $spacer / 2; } > div { padding-left: 1rem; } } } .table-accessory { border: none !important; thead th { @include themify($themes) { border-bottom: 1px solid themed("gray-30"); } background-color: transparent !important; padding: 5px 0; } tbody tr td { border: none !important; padding: 2px; } td { white-space: nowrap; font-size: 0.745rem; @include themify($themes) { color: themed("text-tretiatry"); } } .thead-light th > div { font-size: 0.755rem !important; white-space: nowrap; text-overflow: ellipsis; overflow: hidden; width: 90%; } @include media-breakpoint-down(md) { overflow-y: auto; width: 100vw; } } .item-color { display: inline-block; width: 8px; height: 8px; border-radius: 2px; }