Commit 4b165332 authored by Heinrich Fenkart's avatar Heinrich Fenkart
Browse files

Merge pull request #14925 from twbs/button-focus-use-regexp

Use RegExp for button plugin's focus shim
parents 33e78ed9 5178d8b8
Showing with 1 addition and 1 deletion
+1 -1
......@@ -110,7 +110,7 @@
e.preventDefault()
})
.on('focus.bs.button.data-api blur.bs.button.data-api', '[data-toggle^="button"]', function (e) {
$(e.target).closest('.btn').toggleClass('focus', e.type == 'focus')
$(e.target).closest('.btn').toggleClass('focus', /^focus(in)?$/.test(e.type))
})
}(jQuery);
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment