-
Notifications
You must be signed in to change notification settings - Fork 347
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Michiel Bijl
committed
Feb 22, 2017
1 parent
4781f28
commit 7d71a01
Showing
2 changed files
with
96 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,92 @@ | ||
/* Contains the accordion elements */ | ||
.accordion { | ||
border: 1px solid hsl(0, 0%, 82%); | ||
border-radius: .3em; | ||
box-shadow: 0 1px 2px hsl(0, 0%, 82%); | ||
} | ||
|
||
.accordion > * + * { | ||
border-top: 1px solid hsl(0, 0%, 82%); | ||
} | ||
|
||
/* Heading containing accordion button */ | ||
.accordion dt[role="heading"] { | ||
|
||
} | ||
|
||
.accordion dt[role="heading"]:first-of-type > [role="button"] { | ||
border-radius: .3em .3em 0 0; | ||
} | ||
|
||
.accordion dt[role="heading"]:last-of-type > [role="button"] { | ||
border-radius: 0 0 .3em .3em; | ||
} | ||
|
||
.accordion dt[role="heading"]:last-of-type > [role="button"][aria-expanded="true"] { | ||
border-radius: 0; | ||
} | ||
|
||
/* Accordion button */ | ||
.accordion dt > [role="button"] { | ||
display: block; | ||
position: relative; | ||
margin: 0; | ||
padding: 1em 1.5em; | ||
border-bottom: 0; | ||
color: hsl(0, 0%, 13%); | ||
font-weight: normal; | ||
} | ||
|
||
.accordion dt > [role="button"]:hover, | ||
.accordion dt > [role="button"]:focus { | ||
margin: inherit; | ||
background: hsl(0, 0%, 93%); | ||
} | ||
|
||
/* Accordion button icon */ | ||
.accordion dt > [role="button"] .icon { | ||
position: absolute; | ||
top: 50%; | ||
right: 1.5em; | ||
transform: translateY(-60%) rotate(45deg); | ||
width: 8px; | ||
height: 8px; | ||
border: solid hsl(0, 0%, 62%); | ||
border-width: 0 2px 2px 0; | ||
} | ||
|
||
.accordion dt > [role="button"][aria-expanded="true"] .icon { | ||
transform: translateY(-50%) rotate(-135deg); | ||
} | ||
|
||
.accordion dt > [role="button"]:hover .icon, | ||
.accordion dt > [role="button"]:focus .icon { | ||
border-color: hsl(0, 0%, 13%); | ||
} | ||
|
||
/* Accordion panel */ | ||
.accordion dd[role="region"] { | ||
margin: 0; | ||
padding: 1em 1.5em; | ||
/*border: solid hsl(0, 0%, 82%); | ||
border-width: 0 1px;*/ | ||
} | ||
|
||
.accordion dd[role="region"].hidden { | ||
display: none; | ||
} | ||
|
||
/* Basic stuff */ | ||
fieldset { | ||
border: 0; | ||
margin: 0; | ||
padding: 0; | ||
} | ||
|
||
input[type="text"] { | ||
display: block; | ||
padding: .3em .5em; | ||
border: 1px solid hsl(0, 0%, 62%); | ||
border-radius: .3em; | ||
font-size: inherit; | ||
} |