|
0
|
1 |
.yui-checkbox { |
|
|
2 |
|
|
|
3 |
display: -moz-inline-stack; /* Gecko < 1.9, since it doesn't support "inline-block" */ |
|
|
4 |
display: inline-block; /* IE, Opera and Webkit, and Gecko 1.9 */ |
|
|
5 |
width: 10px; |
|
|
6 |
height: 10px; |
|
|
7 |
border: inset 2px #999; |
|
|
8 |
background-color: #fff; /* Need to set a background color or IE won't get mouse events * |
|
|
9 |
|
|
|
10 |
/* |
|
|
11 |
Necessary for IE 6 (Quirks and Standards Mode) and IE 7 (Quirks Mode), since |
|
|
12 |
they don't support use of negative margins without relative positioning. |
|
|
13 |
*/ |
|
|
14 |
|
|
|
15 |
_position: relative; |
|
|
16 |
} |
|
|
17 |
|
|
|
18 |
.yui-checkbox span { |
|
|
19 |
|
|
|
20 |
display: block; |
|
|
21 |
height: 14px; |
|
|
22 |
width: 12px; |
|
|
23 |
overflow: hidden; |
|
|
24 |
|
|
|
25 |
/* Position the checkmark for Gecko, Opera and Webkit and IE 7 (Strict Mode). */ |
|
|
26 |
margin: -5px 0 0 1px; |
|
|
27 |
|
|
|
28 |
|
|
|
29 |
/* Position the checkmark for IE 6 (Strict and Quirks Mode) and IE 7 (Quirks Mode).*/ |
|
|
30 |
_margin: 0; |
|
|
31 |
_position: absolute; |
|
|
32 |
_top: -5px; |
|
|
33 |
_left: 1px; |
|
|
34 |
|
|
|
35 |
} |
|
|
36 |
|
|
|
37 |
/* For Gecko < 1.9: Positions the checkbox on the same line as its corresponding label. */ |
|
|
38 |
.yui-checkbox span:after { |
|
|
39 |
|
|
|
40 |
content: "."; |
|
|
41 |
visibility: hidden; |
|
|
42 |
line-height: 2; |
|
|
43 |
|
|
|
44 |
} |
|
|
45 |
|
|
|
46 |
/* |
|
|
47 |
Hide the actual checkbox offscreen so that it is out of view, but still accessible via |
|
|
48 |
the keyboard. |
|
|
49 |
*/ |
|
|
50 |
.yui-checkbox input { |
|
|
51 |
|
|
|
52 |
position: absolute; |
|
|
53 |
left: -10000px; |
|
|
54 |
|
|
|
55 |
} |
|
|
56 |
|
|
|
57 |
.yui-checkbox-focus { |
|
|
58 |
|
|
|
59 |
border-color: #39f; |
|
|
60 |
background-color: #9cf; |
|
|
61 |
|
|
|
62 |
} |
|
|
63 |
|
|
|
64 |
.yui-checkbox-active { |
|
|
65 |
|
|
|
66 |
background-color: #ccc; |
|
|
67 |
|
|
|
68 |
} |
|
|
69 |
|
|
|
70 |
.yui-checkbox-checked span { |
|
|
71 |
|
|
|
72 |
/* Draw a custom checkmark for the checked state using a background image. */ |
|
|
73 |
background: url(checkmark.png) no-repeat; |
|
|
74 |
|
|
|
75 |
} |