0
0
mirror of https://github.com/twbs/bootstrap.git synced 2024-12-01 13:24:25 +01:00

dropdown: Move constant

This commit is contained in:
XhmikosR 2021-11-09 15:43:02 +02:00
parent a8887ea8a8
commit 7d3bc44bb0

View File

@ -359,10 +359,6 @@ class Dropdown extends BaseComponent {
continue
}
const relatedTarget = {
relatedTarget: context._element
}
const composedPath = event.composedPath()
const isMenuTarget = composedPath.includes(context._menu)
if (
@ -378,6 +374,8 @@ class Dropdown extends BaseComponent {
continue
}
const relatedTarget = { relatedTarget: context._element }
if (event.type === 'click') {
relatedTarget.clickEvent = event
}