mirror of
https://github.com/wallabag/wallabag.git
synced 2025-05-11 19:08:53 +00:00
15 lines
378 B
JavaScript
15 lines
378 B
JavaScript
import { Controller } from '@hotwired/stimulus';
|
|
|
|
export default class extends Controller {
|
|
static targets = ['item', 'tagAction'];
|
|
|
|
toggleSelection(e) {
|
|
this.itemTargets.forEach((item) => {
|
|
item.checked = e.currentTarget.checked; // eslint-disable-line no-param-reassign
|
|
});
|
|
}
|
|
|
|
tagSelection() {
|
|
this.element.requestSubmit(this.tagActionTarget);
|
|
}
|
|
}
|