summaryrefslogtreecommitdiff
path: root/lib/flat-ttrss/dijit/form/Checkbox.styl
blob: 556afaf68773ec4b9ce156576fd020f20ea21723 (plain)
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
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
/* CheckBox
 * 
 * Styling CheckBox mainly includes:
 * 
 * 1. Containers
 * 		.dijitCheckBox
 * 
 * 2. CheckBox within ToggleButton
 * 		.dijitCheckBoxIcon
 * 
 * 3. States - Checked, Hover, Disabled.
 *		.dijitCheckBoxChecked
 * 		.dijitCheckBoxHover
 * 		.dijitCheckBoxCheckedHover
 * 		.dijitCheckBoxDisabled
 *		.dijitCheckBoxCheckedDisabled
 */


@import 'dijit_form_variables';

.{$theme-name} {
		
	.dijitCheckBox {
		background-color: $checkbox-background-color;
		border: 1px solid $checkbox-border-color;
		width: $checkbox-width;
		height: $checkbox-height;
		line-height: 1;
		padding: $checkbox-padding;
		border-radius: $checkbox-border-radius;
		text-align: center;
		position: relative;
		overflow: visible;
		transition: all 0.1s linear;
		input {
			position: absolute;
			top: 0;
		}
	}

	/* Icon */

	.dijitCheckBoxIcon,
	.dijitCheckBoxChecked,
	.dijitCheckBoxCheckedDisabled {
		&:before {
			_icon-core-style();
			content: $checkbox-icon;
			color: $checkbox-checked-icon-color;
		}
	}

	/* This is the checkbox icon within a widget, e.g. toggle button */
	
	.dijitCheckBoxIcon {
		padding: $checkbox-icon-padding;

		&:before {
			color: $checkbox-icon-checked-icon-color;
		}
	}
	
	// checkbox icon within alternative buttons
	if($button-alternative-colors && length($button-alternative-colors) > 0) {
		for class in $button-alternative-colors {
			.{class} {
				.dijitCheckBoxIcon {
					&:before {
						color: $checkbox-checked-icon-color;
					}
				}
			}
		}
	}

	/* checked */

	.dijitCheckBoxChecked {
		background-color: $checkbox-checked-background-color;
		border-color: $checkbox-checked-border-color;
	}

	/* hovered */
	/* over unchecked */

	.dijitCheckBoxHover {
		background-color: $checkbox-hover-unchecked-background-color;
		border: $checkbox-hover-unchecked-border-color;
	}

	/* over checked */

	.dijitCheckBoxCheckedHover {
		background-color: $checkbox-hover-checked-background-color;
		border: $checkbox-hover-checked-border-color;
	}

	/* disabled */

	.dijitCheckBoxDisabled {
		color: $checkbox-disabled-color;
		background-color: $checkbox-disabled-background-color;
		border-color: $checkbox-disabled-border-color;
	}
	
	.dijitCheckBoxCheckedDisabled {
		color: $checkbox-checked-disabled-color;
		background-color: $checkbox-checked-disabled-background-color;
		border-color: $checkbox-checked-disabled-border-color;
	}
	
	/* Checkbox within a menu item */
	
	.dijitCheckedMenuItem .dijitCheckedMenuItemIcon {
		background-color: $checkbox-background-color;
		border: 1px solid $checkbox-border-color;
		width: $checkbox-width;
		height: $checkbox-height;
		line-height: 1;
		padding: $checkbox-padding;
		border-radius: $checkbox-border-radius;
		text-align: center;
		position: relative;
		overflow: visible;
		transition: all 0.1s linear;
	}
		
	.dijitCheckedMenuItemChecked .dijitCheckedMenuItemIcon {
		&:before {
			_icon-core-style();
			content: $checkbox-icon;
			color: $theme-base;
		}
	}
	
}