1
0
mirror of https://git.sr.ht/~cadence/cloudtube synced 2025-07-06 19:32:04 +00:00
cloudtube/html/static/js/filters.js
2021-05-12 00:29:44 +12:00

17 lines
374 B
JavaScript

import {ElemJS, q} from "./elemjs/elemjs.js"
class FilterType extends ElemJS {
constructor(element) {
super(element)
this.notice = q("#title-pattern-matching")
this.on("input", this.updateNotice.bind(this))
this.updateNotice()
}
updateNotice() {
this.notice.style.display = this.element.value !== "title" ? "none" : ""
}
}
new FilterType(q("#filter-type"))