This repository has been archived on 2023-03-18. You can view files and clone it, but cannot push or open issues or pull requests.
osr-discourse-src/app/assets/javascripts/discourse/components/track-selected.js.es6
2019-05-27 10:15:39 +02:00

15 lines
320 B
JavaScript

export default Ember.Component.extend({
tagName: "span",
selectionChanged: function() {
const selected = this.selected;
const list = this.selectedList;
const id = this.selectedId;
if (selected) {
list.addObject(id);
} else {
list.removeObject(id);
}
}.observes("selected")
});