-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdivider.scss
47 lines (40 loc) · 868 Bytes
/
divider.scss
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
@import "common/var";
@import "mixins/mixins";
@include b(divider) {
background-color: $--border-color-base;
position: relative;
@include m(horizontal) {
display: block;
height: 1px;
width: 100%;
margin: 24px 0;
}
@include m(vertical) {
display: inline-block;
width: 1px;
height: 1em;
margin: 0 8px;
vertical-align: middle;
position: relative;
}
@include e(text) {
position: absolute;
background-color: $--color-white;
padding: 0 20px;
font-weight: 500;
color: $--color-text-primary;
font-size: 14px;
@include when(left) {
left: 20px;
transform: translateY(-50%);
}
@include when(center) {
left: 50%;
transform: translateX(-50%) translateY(-50%);
}
@include when(right) {
right: 20px;
transform: translateY(-50%);
}
}
}