FIX: ember click event not reliably working on fx (#6256)
This commit is contained in:
parent
d77dccc636
commit
6a2ca60b48
|
@ -45,15 +45,20 @@ export default ComboBox.extend(Tags, {
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
|
|
||||||
click(event) {
|
didInsertElement() {
|
||||||
if (event.target.tagName === "BUTTON") {
|
this._super(...arguments);
|
||||||
const $button = $(event.target);
|
|
||||||
|
|
||||||
if ($button.hasClass("selected-tag")) {
|
this.$(".select-kit-body").on("click", ".selected-tag", event => {
|
||||||
|
const $button = $(event.target);
|
||||||
this._destroyEvent(event);
|
this._destroyEvent(event);
|
||||||
this.destroyTags(this.computeContentItem($button.attr("data-value")));
|
this.destroyTags(this.computeContentItem($button.attr("data-value")));
|
||||||
}
|
});
|
||||||
}
|
},
|
||||||
|
|
||||||
|
willDestroyElement() {
|
||||||
|
this._super(...arguments);
|
||||||
|
|
||||||
|
this.$(".select-kit-body").off("click");
|
||||||
},
|
},
|
||||||
|
|
||||||
@computed("hasReachedMaximum")
|
@computed("hasReachedMaximum")
|
||||||
|
|
Loading…
Reference in New Issue