blob: 5b47e64955e2b5a371ebb677c69b075f20192824 (
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
|
@import './config.scss';
$toggle-size: 14px;
$toggle-width: 40px;
$toggle-button-size: 22px;
.franz-form {
.franz-form__toggle-wrapper {
display: flex;
flex-direction: row;
.franz-form__label {
margin-left: 20px;
}
.franz-form__toggle {
width: $toggle-width;
height: $toggle-size;
position: relative;
background: $theme-gray-lighter;
border-radius: $theme-border-radius;
.franz-form__toggle-button {
position: absolute;
left: 0;
top: -($toggle-button-size - $toggle-size) / 2;
width: $toggle-button-size;
height: $toggle-button-size;
background: $theme-gray-light;
border-radius: 100%;
transition: all 0.5s;
box-shadow: 0 1px 4px rgba(0,0,0,0.3);
}
&.is-active {
.franz-form__toggle-button {
left: $toggle-width - $toggle-button-size;
background: $theme-brand-primary;
}
}
input {
display: none;
}
}
}
}
|