philomena/assets/css/common/_dropdown.scss
David Joseph Guzsik 8d47f56917
Build assets using Webpack (#150)
* Build assets using webpack

* Change webpack bundling method, add path aliases, restore deploy script

* Remove babel dependencies

* Add buble rollup plugin and always attach promise polyfill to window

* Fix object formatting for buble rollup plugin config

* Remove reference to setImmediate from promise polyfill
2020-06-28 14:53:19 -04:00

33 lines
623 B
SCSS

.dropdown {
position: relative;
display: inline-block;
}
.dropdown .dropdown__content {
position: absolute;
display: none;
/* align at top left (e.g., tag margins) */
top: 100%;
left: 0;
}
.dropdown__content.dropdown__content-right {
left: inherit;
right: 0;
}
/* Our child should be a block element */
.dropdown .dropdown__content > *:not(.hidden) {
display: block;
white-space: nowrap;
}
.dropdown:hover .dropdown__content {
/* show it */
display: block;
/* dropdowns should be at least as big as the button */
min-width: 100%;
/* and shouldn't sit below content */
z-index: 999;
}