Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dropdown — Apply positioning only when Popper is not used #33482

Merged
merged 1 commit into from
Apr 17, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 7 additions & 13 deletions scss/_dropdown.scss
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
// The dropdown menu
.dropdown-menu {
position: absolute;
top: 100%;
z-index: $zindex-dropdown;
display: none; // none by default, but block on "open" of the menu
min-width: $dropdown-min-width;
Expand All @@ -33,6 +32,7 @@
@include box-shadow($dropdown-box-shadow);

&[data-bs-popper] {
top: 100%;
left: 0;
margin-top: $dropdown-spacer;
}
Expand Down Expand Up @@ -83,15 +83,12 @@
}

.dropend {
.dropdown-menu {
.dropdown-menu[data-bs-popper] {
top: 0;
right: auto;
left: 100%;

&[data-bs-popper] {
margin-top: 0;
margin-left: $dropdown-spacer;
}
margin-top: 0;
margin-left: $dropdown-spacer;
}

.dropdown-toggle {
Expand All @@ -103,15 +100,12 @@
}

.dropstart {
.dropdown-menu {
.dropdown-menu[data-bs-popper] {
top: 0;
right: 100%;
left: auto;

&[data-bs-popper] {
margin-top: 0;
margin-right: $dropdown-spacer;
}
margin-top: 0;
margin-right: $dropdown-spacer;
}

.dropdown-toggle {
Expand Down