summaryrefslogtreecommitdiffstats
path: root/src/.old/objects/_status-indicator.scss
blob: d8ea9ef9cb69a8729e89665514bf15e39fa92526 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
@use 'iro-sass/src/index' as iro;
@use '../functions' as fn;

@include iro.props-namespace('status-indicator') {
    @include iro.props-store((
        --dims: (
            --size: fn.global-dim(--size --125),
        ),
    ), 'dims');

    @include iro.props-store((
        --colors: (
            --default: fn.global-color(--obj-lo),
            --primary: fn.global-color(--fg),
            --green:   fn.global-color(--green --solid --bg-hi),
            --yellow:  fn.global-color(--yellow --solid --bg-hi),
            --red:     fn.global-color(--red --solid --bg-hi),
        ),
    ), 'colors');

    @include iro.bem-object(iro.props-namespace()) {
        display:          inline-block;
        width:            fn.dim(--size);
        height:           fn.dim(--size);
        border-radius:    10em;
        background-color: fn.color(--default);
        vertical-align:   middle;

        @each $color in 'primary' 'green' 'yellow' 'red' {
            @include iro.bem-is($color) {
                background-color: fn.color(--#{$color});
            }
        }
    }
}