mirror of
https://github.com/twbs/bootstrap.git
synced 2025-08-09 15:16:51 +02:00
Some .navbar .dropdown-menu optimisation (#22776)
This commit is contained in:
@@ -251,21 +251,6 @@ const Dropdown = (($) => {
|
|||||||
return $(this._element).closest('.navbar').length > 0
|
return $(this._element).closest('.navbar').length > 0
|
||||||
}
|
}
|
||||||
|
|
||||||
_navbarPositioning() {
|
|
||||||
const $parentNavbar = $(this._element).closest('.navbar')
|
|
||||||
if ($(this._menu).hasClass(ClassName.MENURIGHT)) {
|
|
||||||
if (!$parentNavbar.hasClass('navbar-expand')) {
|
|
||||||
return {
|
|
||||||
position: 'static',
|
|
||||||
transform: '',
|
|
||||||
float: 'none'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return {}
|
|
||||||
}
|
|
||||||
|
|
||||||
_getPopperConfig() {
|
_getPopperConfig() {
|
||||||
const popperConfig = {
|
const popperConfig = {
|
||||||
placement : this._getPlacement(),
|
placement : this._getPlacement(),
|
||||||
|
@@ -141,13 +141,6 @@
|
|||||||
|
|
||||||
&#{$infix} {
|
&#{$infix} {
|
||||||
@include media-breakpoint-down($breakpoint) {
|
@include media-breakpoint-down($breakpoint) {
|
||||||
.navbar-nav {
|
|
||||||
.dropdown-menu {
|
|
||||||
position: static;
|
|
||||||
float: none;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
> .container,
|
> .container,
|
||||||
> .container-fluid {
|
> .container-fluid {
|
||||||
padding-right: 0;
|
padding-right: 0;
|
||||||
@@ -172,11 +165,6 @@
|
|||||||
left: auto; // Reset the default from `.dropdown-menu`
|
left: auto; // Reset the default from `.dropdown-menu`
|
||||||
}
|
}
|
||||||
|
|
||||||
.dropdown-menu-left {
|
|
||||||
right: auto;
|
|
||||||
left: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.nav-link {
|
.nav-link {
|
||||||
padding-right: .5rem;
|
padding-right: .5rem;
|
||||||
padding-left: .5rem;
|
padding-left: .5rem;
|
||||||
|
Reference in New Issue
Block a user