16 lines
217 B
JavaScript
16 lines
217 B
JavaScript
|
class loader {
|
||
|
div = null
|
||
|
constructor(node){
|
||
|
this.div = node
|
||
|
}
|
||
|
set(loading){
|
||
|
if (loading)
|
||
|
this.div.classList.add("is-loading")
|
||
|
else
|
||
|
this.div.classList.remove("is-loading")
|
||
|
}
|
||
|
}
|
||
|
|
||
|
|
||
|
export default loader
|