2021-12-23 02:42:22 +00:00
|
|
|
@use "sass:math";
|
2015-11-19 06:05:57 +00:00
|
|
|
// =============================================================================
|
|
|
|
// Indicator light
|
|
|
|
// =============================================================================
|
|
|
|
|
|
|
|
|
|
|
|
// =============================================================================
|
|
|
|
// Indicator light
|
|
|
|
// =============================================================================
|
2017-08-25 22:04:10 +00:00
|
|
|
$c-indicator-size: 0.625em;
|
|
|
|
$c-indicator-margin: 0.25rem;
|
2015-11-19 06:05:57 +00:00
|
|
|
|
|
|
|
.c-indicator {
|
|
|
|
display: inline-block;
|
|
|
|
border-radius: 50rem;
|
|
|
|
width: $c-indicator-size;
|
|
|
|
height: $c-indicator-size;
|
2017-08-25 22:04:10 +00:00
|
|
|
margin-top: -0.125rem;
|
2015-11-19 06:05:57 +00:00
|
|
|
margin-right: $c-indicator-margin;
|
|
|
|
font-size: 1rem;
|
|
|
|
vertical-align: middle;
|
|
|
|
}
|
|
|
|
|
|
|
|
// =============================================================================
|
|
|
|
// States
|
|
|
|
// =============================================================================
|
|
|
|
.is-absent .c-indicator {
|
|
|
|
background: $color-state-absent;
|
|
|
|
}
|
|
|
|
|
|
|
|
.is-live .c-indicator {
|
|
|
|
background: $color-state-live;
|
|
|
|
}
|
|
|
|
|
|
|
|
.is-draft .c-indicator {
|
|
|
|
background: $color-state-draft;
|
|
|
|
}
|
|
|
|
|
|
|
|
// This is hipster. But it works.
|
|
|
|
.is-live\+draft .c-indicator {
|
|
|
|
background: $color-state-draft;
|
|
|
|
position: relative;
|
|
|
|
|
|
|
|
&:before {
|
|
|
|
content: '';
|
2021-12-23 02:42:22 +00:00
|
|
|
width: math.div($c-indicator-size, 2);
|
2015-11-19 06:05:57 +00:00
|
|
|
height: $c-indicator-size;
|
|
|
|
position: absolute;
|
|
|
|
top: 0;
|
|
|
|
left: 0;
|
|
|
|
border-bottom-left-radius: 50rem;
|
|
|
|
border-top-left-radius: 50rem;
|
|
|
|
background: $color-state-live;
|
|
|
|
transform: rotate(45deg);
|
|
|
|
transform-origin: 100% 50%;
|
|
|
|
}
|
|
|
|
}
|