summaryrefslogtreecommitdiffstats
path: root/assets/css/components/_post-list.scss
blob: 6ddc9b7200a436ed6a0ddb6a1b277e27a871a4f0 (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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
@include namespace('post-list') {
    @include store((
        --colors: (
            --cat: (
                --fg: prop(--colors --fg-lo, $global: true),
            ),
            --post: (
                --idle-fg:    prop(--colors --fg-lo, $global: true),
                --visited-fg: prop(--colors --fg, $global: true),
            ),
            --meta: (
                --fg: prop(--colors --fg-hi, $global: true),
            )
        )
    ));

    @include component(namespace()) {
        @include element('category-header') {
            color: prop(--colors --cat --fg);

            @include next-element('post') {
                margin-top: $line-height * .5rem;
            }
        }

        @include element('post') {
            color: prop(--colors --post --idle-fg);

            &:visited {
                color: prop(--colors --post --visited-fg);
            }

            @include next-twin-element {
                margin-top: .6rem;
            }
        }

        @include element('post-title') {
            //font-size:   1 / 16 * 17em;
            font-weight: normal;
        }

        @include element('post-date') {
            flex:       0 0 auto;
            transition: color .2s;
            color:      prop(--colors --meta --fg);
            font-size:  1 / 16 * 14em;
        }
    }
}