mirror of
https://github.com/twbs/bootstrap.git
synced 2025-08-10 23:54:08 +02:00
Dropdown - Disable applyStyle modifier instead of removing inline style applied by Popper.js
This commit is contained in:
@@ -265,14 +265,10 @@ const Dropdown = (($) => {
|
||||
}
|
||||
}
|
||||
|
||||
// Disable Popper.js for Dropdown in Navbar
|
||||
if (this._inNavbar) {
|
||||
popperConfig.modifiers.AfterApplyStyle = {
|
||||
enabled: true,
|
||||
order: 901, // ApplyStyle order + 1
|
||||
fn: () => {
|
||||
// reset Popper styles
|
||||
$(this._menu).attr('style', '')
|
||||
}
|
||||
popperConfig.modifiers.applyStyle = {
|
||||
enabled: !this._inNavbar
|
||||
}
|
||||
}
|
||||
return popperConfig
|
||||
|
Reference in New Issue
Block a user