Skip to content

Commit

Permalink
Phantom-oriented fix for input.is(‘:focus’) always returning false an…
Browse files Browse the repository at this point in the history
…d causing an infinite loop

Addresses ariya/phantomjs#10427
  • Loading branch information
markdicksonjr committed Sep 29, 2017
1 parent 2669ad8 commit 22d7687
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion addon/components/paper-chips.js
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ export default Component.extend({

this.set('focusedElement', 'input');

if (!this.get('content').length && !input.is(':focus')) {
if (!this.get('content').length && !input.is(':focus') && input[0] !== document.activeElement) {
input.focus();
} else {
this.set('activeChip', -1);
Expand Down

0 comments on commit 22d7687

Please sign in to comment.