forked from ryanseddon/bootleg
-
Notifications
You must be signed in to change notification settings - Fork 0
/
bootleg-collapse.css
60 lines (54 loc) · 1.34 KB
/
bootleg-collapse.css
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
/*
* Bootleg.css
* https://github.com/ryanseddon/bootleg
*
* WTFPL - http://sam.zoy.org/wtfpl/
*/
.accordion-group {
position: relative;
}
.accordion-toggle {
margin: 0;
color: #0088CC;
}
.accordion-toggle:hover,
label[for="collapseAll"]:hover + .accordion-heading .accordion-toggle {
color: #005580;
text-decoration: underline;
}
#collapse .accordion input ~ .collapse {
max-height: 0;
height: auto;
-webkit-transition: max-height 0.2s ease 0s;
-moz-transition: max-height 0.2s ease 0s;
-ms-transition: max-height 0.2s ease 0s;
-o-transition: max-height 0.2s ease 0s;
transition: max-height 0.2s ease 0s;
}
#collapse .accordion input:checked ~ .collapse {
max-height: 500px;
-webkit-transition-duration: 0.7s;
-moz-transition-duration: 0.7s;
-ms-transition-duration: 0.7s;
-o-transition-duration: 0.7s;
transition-duration: 0.7s;
}
#collapse .accordion input:checked ~ .collapse > div {
max-height: 500px;
overflow: auto;
}
#collapse .accordion input:checked + .accordion-dismiss {
position: absolute;
top: 0;
right: 0;
left: 0;
min-height: 36px;
}
#collapseAll:checked ~ .accordion-group label[for="collapseAll"],
#collapse .accordion input + label[for="collapseAll"] {
display: none;
}
#collapse .accordion input:checked + label[for="collapseAll"] {
display: block;
cursor: pointer
}