diff --git a/src/js-components/previewBar.ts b/src/js-components/previewBar.ts index 959864c8..922b6b2a 100644 --- a/src/js-components/previewBar.ts +++ b/src/js-components/previewBar.ts @@ -314,11 +314,11 @@ class PreviewBar { createChaptersBar(segments: PreviewBarSegment[]): void { if (!this.progressBar || !this.originalChapterBar || this.originalChapterBar.childElementCount <= 0) { - if (this.customChaptersBar) this.customChaptersBar.style.display = "none"; if (this.originalChapterBar) this.originalChapterBar.style.removeProperty("display"); // Make sure other video types lose their chapter bar document.querySelectorAll(".sponsorBlockChapterBar").forEach((element) => element.remove()); + this.customChaptersBar = null; return; }