feat(EpisodeOptions): loading icon
This commit is contained in:
@@ -16,12 +16,15 @@ export default class extends Controller {
|
||||
|
||||
static targets = ['list']
|
||||
|
||||
static outlets = ['loading-icon']
|
||||
|
||||
connect() {
|
||||
if (true === this.activeValue) {
|
||||
fetch(`/torrentio/tvshows/${this.tmdbIdValue}/${this.imdbIdValue}/${this.seasonValue}/${this.episodeValue}`)
|
||||
.then(res => res.text())
|
||||
.then(response => {
|
||||
this.element.innerHTML = response;
|
||||
this.loadingIconOutlet.increaseCount();
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user