/
_selection-controls.sass
119 lines (98 loc) 路 2.36 KB
/
_selection-controls.sass
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
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
@import '../styles.sass'
.v-input--selection-controls
margin-top: $input-top-spacing
padding-top: 4px
> .v-input__append-outer,
> .v-input__prepend-outer
margin-top: 0
margin-bottom: 0
&:not(.v-input--hide-details)
> .v-input__slot
margin-bottom: 12px
.v-input__slot,
.v-radio
cursor: pointer
> .v-label
align-items: center
display: inline-flex
flex: 1 1 auto
// TODO: Resolve in v3, all selection controls need separate sass files
height: auto
&__input
color: inherit
display: inline-flex
flex: 0 0 auto
height: 24px
position: relative
transition: $primary-transition
transition-property: transform
width: 24px
user-select: none
.v-icon
width: 100%
+ltr()
margin-right: 8px
+rtl()
margin-left: 8px
input[role="checkbox"],
input[role="radio"],
input[role="switch"]
position: absolute
opacity: 0
width: 100%
height: 100%
cursor: pointer
user-select: none
// Sibling selector to avoid targeting v-radio-group's label
& + .v-label
cursor: pointer
user-select: none
&__ripple
border-radius: 50%
cursor: pointer
height: 34px
position: absolute
transition: inherit
width: 34px
left: -12px
top: calc(50% - 24px)
margin: 7px
&:before
border-radius: inherit
bottom: 0
content: ''
position: absolute
opacity: .2
left: 0
right: 0
top: 0
transform-origin: center center
transform: scale(0.2)
transition: inherit
> .v-ripple__container
transform: scale(1.2)
&.v-input--dense
.v-input--selection-controls__ripple
width: 28px
height: 28px
left: -9px
&:not(.v-input--switch)
.v-input--selection-controls__ripple
top: calc(50% - 21px)
&.v-input
flex: 0 1 auto
&.v-input--is-focused,
.v-radio--is-focused
.v-input--selection-controls__ripple:before
background: currentColor
transform: scale(1.2)
&.v-input--is-disabled:not(.v-input--indeterminate)
.v-icon
color: inherit
&.v-input--is-disabled:not(.v-input--is-readonly)
pointer-events: none
.v-input--selection-controls__input:hover
.v-input--selection-controls__ripple:before
background: currentColor
transform: scale(1.2)
transition: none