New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Deleting selections from multi-select using backspace causes browser back in IE11 #3168
Comments
I was able to reproduce the issue locally in IE, will do more testing later. |
Thank you Kevin! |
Still having the problem in IE9 and rc2 |
Solved modifying the following code: this.$selection.on('keydown', '.select2-search--inline', function (evt) {
evt.stopPropagation();
self.trigger('keypress', evt);
self._keyUpPrevented = evt.isDefaultPrevented();
var key = evt.which;
if (key === KEYS.BACKSPACE && self.$search.val() === '') {
var $previousChoice = self.$searchContainer.prev('.select2-selection__choice');
if ($previousChoice.length > 0) {
var item = $previousChoice.data('data');
self.searchRemoveChoice(item);
self.$search.val("").blur().focus();
evt.preventDefault();
}
}
}); |
This is fixed on master but is not yet in a release. |
Hi Kevin, when will this fix be available in the release? |
This should have been included in the 4.0.0 release that went out about two weeks ago. Can you confirm if you are still having issues with it? |
Hi Kevin, I have not yet taken the latest release. I will get it, and revert incase of issues. |
I am experiencing this issue in IE 11 when using As a side note, the fix in |
Do you want to create a pair of jsfiddles (one with the full, one with the regular build) and a step by step set of instructions for how you are testing? I'm not sure what would be included in the full builds that would be affecting this. |
I can't seem to reproduce the difference between Both jsfiddles use the latest version of library from the
|
any updates on this issue? |
Using select2 with multiple tags in my project, the following code helped:
|
Hi guys Im using select2 in an Angular 2 template. We use the backspace key to delete the tags of the input. We found this solution:
` That work great on Chrome. But on IE the second time I hit the backspace key the browser just go back. Im using this version: "select2": "4.0.3" Do you know any workaround or how to fix this? |
Have you tried pulling the
|
@alexweissman Thanks for you answer. It uses select2 and I get the code of the library from npm. I think it get from master branch. Thanks! |
It looks like the wrapper pulls the last release (not Also, have you confirmed that this is still an issue even without using the wrapper? |
It is still not working in IE11....... |
It would seem that this is still a problem, even in |
#3394 claims to resolve this problem. |
Discussion continues here -> #3394 |
This is still broken with version 4.0.7 and |
Deleting the tag using backspace causes browser back. This occurs in IE 11 but not in Chrome 41.0.
Jsfiddle: http://jsfiddle.net/6XvqX/822/
The text was updated successfully, but these errors were encountered: