-
Notifications
You must be signed in to change notification settings - Fork 83
/
Copy pathchart-donut.less
73 lines (61 loc) · 1.5 KB
/
chart-donut.less
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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
.ffe-chart-donut {
display: grid;
width: fit-content;
grid-template-columns: auto;
grid-template-rows: auto;
place-items: center;
position: relative;
text-align: left;
&--first {
stroke: var(--ffe-color-default-brand-primary-subtle);
}
&--last {
stroke: var(--ffe-color-foreground-emphasis);
}
&__circle,
&__description {
grid-column: 1 e('/') 1;
grid-row: 1 e('/') 1;
}
&__circle {
width: 12.5rem;
aspect-ratio: 1;
}
&__description {
z-index: 1;
}
&__name {
color: var(--ffe-color-foreground-emphasis);
text-align: center;
}
&__fractions {
display: grid;
grid-template-columns: auto 1px auto;
grid-template-rows: auto auto;
grid-column-gap: var(--ffe-spacing-xs);
&::after {
grid-column: 2 e('/') 3;
grid-row: 1 e('/') 2;
display: flex;
// Using subtle border color for the separator
background: var(--ffe-color-border-primary-subtle);
height: 1lh;
content: '';
}
}
&__fraction {
display: grid;
place-items: center;
}
.ffe-chart-donut__amount {
color: var(--ffe-color-foreground-default);
}
&__fraction:first-of-type {
grid-column: 1 e('/') 2;
grid-row: 1 e('/') 3;
}
&__fraction:last-of-type {
grid-column: 3 e('/') 4;
grid-row: 1 e('/') 3;
}
}