1
0
mirror of https://github.com/twbs/bootstrap.git synced 2025-09-26 21:39:08 +02:00

Dropdown without jQuery

This commit is contained in:
Johann-S
2017-09-26 09:09:40 +02:00
committed by XhmikosR
parent 330a29734f
commit 90261b484c
6 changed files with 226 additions and 183 deletions

View File

@@ -334,7 +334,7 @@ const EventHandler = (() => {
let defaultPrevented = false
if (inNamespace && typeof $ !== 'undefined') {
jQueryEvent = new $.Event(event, args)
jQueryEvent = $.Event(event, args)
$(element).trigger(jQueryEvent)
bubbles = !jQueryEvent.isPropagationStopped()
@@ -342,8 +342,7 @@ const EventHandler = (() => {
defaultPrevented = jQueryEvent.isDefaultPrevented()
}
let evt = null
let evt = null
if (isNative) {
evt = document.createEvent('HTMLEvents')
evt.initEvent(typeEvent, bubbles, true)