1
1
@import ' ../core/theming/theming' ;
2
2
@import ' ../core/style/elevation' ;
3
- @import ' ../core/style/variables ' ;
3
+ @import ' ../core/style/checkbox-common ' ;
4
4
@import ' ../core/ripple/ripple' ;
5
5
6
-
7
- // The width/height of the checkbox element.
8
- $md-checkbox-size : $md-toggle-size !default ;
9
- // The width of the line used to draw the checkmark / mixedmark.
10
- $md-checkbox-mark-stroke-size : 2 / 15 * $md-checkbox-size !default ;
11
- // The width of the checkbox border shown when the checkbox is unchecked.
12
- $md-checkbox-border-width : 2px ;
13
- // The base duration used for the majority of transitions for the checkbox.
14
- $md-checkbox-transition-duration : 90ms ;
15
- // The amount of spacing between the checkbox and its label.
16
- $md-checkbox-item-spacing : $md-toggle-padding ;
17
-
18
6
// Manual calculation done on SVG
19
7
$_md-checkbox-mark-path-length : 22.910259 ;
20
8
$_md-checkbox-indeterminate-checked-easing-function : cubic-bezier (0.14 , 0 , 0 , 1 );
21
9
22
10
// The ripple size of the checkbox
23
- $md-checkbox-ripple-size : 15px ;
11
+ $_md-checkbox-ripple-size : 15px ;
12
+
13
+ // The amount of spacing between the checkbox and its label.
14
+ $_md-checkbox-item-spacing : $md-toggle-padding ;
15
+
16
+ // The width of the line used to draw the checkmark / mixedmark.
17
+ $_md-checkbox-mark-stroke-size : 2 / 15 * $md-checkbox-size !default ;
18
+
24
19
25
20
// Fades in the background of the checkbox when it goes from unchecked -> {checked,indeterminate}.
26
21
@keyframes md-checkbox-fade-in-background {
@@ -213,7 +208,7 @@ md-checkbox {
213
208
height : $md-checkbox-size ;
214
209
line-height : 0 ;
215
210
margin : auto ;
216
- margin-right : $md -checkbox-item-spacing ;
211
+ margin-right : $_md -checkbox-item-spacing ;
217
212
order : 0 ;
218
213
position : relative ;
219
214
vertical-align : middle ;
@@ -223,7 +218,7 @@ md-checkbox {
223
218
224
219
[dir = ' rtl' ] & {
225
220
margin : {
226
- left : $md -checkbox-item-spacing ;
221
+ left : $_md -checkbox-item-spacing ;
227
222
right : auto ;
228
223
}
229
224
}
@@ -264,14 +259,14 @@ md-checkbox {
264
259
stroke : {
265
260
dashoffset : $_md-checkbox-mark-path-length ;
266
261
dasharray : $_md-checkbox-mark-path-length ;
267
- width : $md -checkbox-mark-stroke-size ;
262
+ width : $_md -checkbox-mark-stroke-size ;
268
263
}
269
264
}
270
265
271
266
.md-checkbox-mixedmark {
272
267
@extend %md-checkbox-mark ;
273
268
274
- height : floor ($md -checkbox-mark-stroke-size );
269
+ height : floor ($_md -checkbox-mark-stroke-size );
275
270
opacity : 0 ;
276
271
transform : scaleX (0 ) rotate (0deg );
277
272
}
@@ -280,14 +275,14 @@ md-checkbox {
280
275
.md-checkbox-inner-container {
281
276
order : 1 ;
282
277
margin : {
283
- left : $md -checkbox-item-spacing ;
278
+ left : $_md -checkbox-item-spacing ;
284
279
right : auto ;
285
280
}
286
281
287
282
[dir = ' rtl' ] & {
288
283
margin : {
289
284
left : auto ;
290
- right : $md -checkbox-item-spacing ;
285
+ right : $_md -checkbox-item-spacing ;
291
286
}
292
287
}
293
288
}
@@ -419,10 +414,10 @@ md-checkbox {
419
414
420
415
.md-checkbox-ripple {
421
416
position : absolute ;
422
- left : - $md -checkbox-ripple-size ;
423
- top : - $md -checkbox-ripple-size ;
424
- right : - $md -checkbox-ripple-size ;
425
- bottom : - $md -checkbox-ripple-size ;
417
+ left : - $_md -checkbox-ripple-size ;
418
+ top : - $_md -checkbox-ripple-size ;
419
+ right : - $_md -checkbox-ripple-size ;
420
+ bottom : - $_md -checkbox-ripple-size ;
426
421
border-radius : 50% ;
427
422
z-index : 1 ;
428
423
pointer-events : none ;
0 commit comments