Skip to content

Commit 789ed19

Browse files
authored
Multiselect do not interfere with interactive elements (joomla#43574)
1 parent 69a6529 commit 789ed19

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

build/media_source/system/js/multiselect.es6.js

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -46,10 +46,8 @@ class JMultiSelect {
4646

4747
// Handle click on a row
4848
onRowClick({ target, shiftKey }) {
49-
// Do not interfere with links, buttons, inputs
50-
if (target.tagName && (target.tagName === 'A' || target.tagName === 'BUTTON'
51-
|| target.tagName === 'SELECT' || target.tagName === 'TEXTAREA'
52-
|| (target.tagName === 'INPUT' && !target.matches(this.boxSelector)))) {
49+
// Do not interfere with links, buttons, inputs and other interactive elements
50+
if (target.closest('a, button, input, select, textarea, details, dialog, audio, video')) {
5351
return;
5452
}
5553

0 commit comments

Comments
 (0)