Raj Magesh (Talk | contribs) |
|||
Line 255: | Line 255: | ||
.dropdown:hover .dropdown-content { | .dropdown:hover .dropdown-content { | ||
display: block; | display: block; | ||
+ | } | ||
+ | |||
+ | /* Style the buttons that are used to open and close the accordion panel */ | ||
+ | button.accordion { | ||
+ | background-color: #eee; | ||
+ | color: #444; | ||
+ | cursor: pointer; | ||
+ | padding: 18px; | ||
+ | width: 100%; | ||
+ | text-align: left; | ||
+ | border: none; | ||
+ | outline: none; | ||
+ | transition: 0.4s; | ||
+ | } | ||
+ | |||
+ | /* Add a background color to the button if it is clicked on (add the .active class with JS), and when you move the mouse over it (hover) */ | ||
+ | button.accordion.active, button.accordion:hover { | ||
+ | background-color: #ccc; | ||
+ | } | ||
+ | |||
+ | /* Style the accordion panel. Note: hidden by default */ | ||
+ | div.accopanel { | ||
+ | padding: 0 18px; | ||
+ | background-color: white; | ||
+ | display: none; | ||
} | } | ||
Revision as of 16:08, 31 October 2017