Skip to content

Commit

Permalink
Change results mouseup to click event to avoid accidental selection a…
Browse files Browse the repository at this point in the history
…fter clear (select2#6187)
  • Loading branch information
Brainshaker95 committed Oct 7, 2022
1 parent 011fadd commit 84c866c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/js/select2/results.js
Expand Up @@ -328,7 +328,7 @@ define([
return;
}

$highlighted.trigger('mouseup');
$highlighted.trigger('click');
});

container.on('results:select', function () {
Expand Down Expand Up @@ -448,7 +448,7 @@ define([
});
}

this.$results.on('mouseup', '.select2-results__option--selectable',
this.$results.on('click', '.select2-results__option--selectable',
function (evt) {
var $this = $(this);

Expand Down

0 comments on commit 84c866c

Please sign in to comment.