mirror of
https://github.com/ajayyy/SponsorBlock.git
synced 2024-11-10 01:01:55 +01:00
Deletew all custom chapter bars we don't know about when clearing preview bar
This commit is contained in:
parent
08181c1d5f
commit
dabc63af73
1 changed files with 6 additions and 0 deletions
|
@ -218,6 +218,12 @@ class PreviewBar {
|
|||
if (this.customChaptersBar) this.customChaptersBar.style.display = "none";
|
||||
this.originalChapterBar?.style?.removeProperty("display");
|
||||
this.chapterVote?.setVisibility(false);
|
||||
|
||||
document.querySelectorAll(`.sponsorBlockChapterBar`).forEach((e) => {
|
||||
if (e !== this.customChaptersBar) {
|
||||
e.remove();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
set(segments: PreviewBarSegment[], videoDuration: number): void {
|
||||
|
|
Loading…
Reference in a new issue