2014-03-10 07:18:48 +01:00
|
|
|
// Tables
|
|
|
|
|
2014-12-02 23:02:35 +01:00
|
|
|
@mixin table-row-variant($state, $background) {
|
2014-03-10 07:18:48 +01:00
|
|
|
// Exact selectors below required to override `.table-striped` and prevent
|
|
|
|
// inheritance to nested tables.
|
2015-03-31 03:08:01 +02:00
|
|
|
.table-#{$state} {
|
|
|
|
&,
|
|
|
|
> th,
|
|
|
|
> td {
|
2014-12-02 23:02:35 +01:00
|
|
|
background-color: $background;
|
2014-03-10 07:18:48 +01:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
// Hover states for `.table-hover`
|
|
|
|
// Note: this is not available for cells or rows within `thead` or `tfoot`.
|
2015-03-31 03:08:01 +02:00
|
|
|
.table-hover {
|
2015-01-01 10:05:01 +01:00
|
|
|
$hover-background: darken($background, 5%);
|
|
|
|
|
2015-03-31 03:08:01 +02:00
|
|
|
.table-#{$state} {
|
2015-01-01 10:05:01 +01:00
|
|
|
@include hover {
|
|
|
|
background-color: $hover-background;
|
2015-03-31 03:08:01 +02:00
|
|
|
|
2015-01-01 10:05:01 +01:00
|
|
|
> td,
|
|
|
|
> th {
|
|
|
|
background-color: $hover-background;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2014-03-10 07:18:48 +01:00
|
|
|
}
|
|
|
|
}
|