mirror of
https://github.com/discourse/discourse.git
synced 2024-11-25 07:51:36 +08:00
6c91f795d0
* DEV: Remove the margin from widget-dropdown Generic components should not have a margin. Those should be styled in the place where they are used. * DEV: Remove margin from the dropdown body It triggered a warning in popper and was effectively a no-op as popper positions dropdowns on its own using `position: fixed` and `top/right/bottom/left` properties.
54 lines
879 B
SCSS
54 lines
879 B
SCSS
.widget-dropdown {
|
|
display: inline-flex;
|
|
box-sizing: border-box;
|
|
|
|
&.closed {
|
|
.widget-dropdown-body {
|
|
display: none;
|
|
}
|
|
}
|
|
|
|
.widget-dropdown-body {
|
|
display: flex;
|
|
flex-direction: column;
|
|
padding: 0.25em;
|
|
background: $secondary;
|
|
z-index: z("dropdown");
|
|
border: 1px solid $primary-low;
|
|
max-height: 250px;
|
|
overflow-y: auto;
|
|
overflow-x: hidden;
|
|
}
|
|
|
|
.widget-dropdown-item {
|
|
cursor: pointer;
|
|
padding: 0.25em;
|
|
display: flex;
|
|
flex: 1;
|
|
align-items: center;
|
|
|
|
.d-icon {
|
|
color: $primary-medium;
|
|
margin-right: 0.25em;
|
|
}
|
|
|
|
&.separator {
|
|
padding: 0;
|
|
background: $primary-low;
|
|
margin: 0.25em 0;
|
|
|
|
&:hover {
|
|
background: $primary-low;
|
|
}
|
|
}
|
|
|
|
&:hover {
|
|
background: $tertiary-low;
|
|
}
|
|
}
|
|
|
|
.widget-dropdown-header {
|
|
cursor: pointer;
|
|
}
|
|
}
|