Fix chapter text sometimes being hidden

This commit is contained in:
Ajay
2025-12-16 21:33:56 -05:00
parent 2c019468a7
commit a58bec2ebb

View File

@@ -950,7 +950,7 @@ class PreviewBar {
chapterButton.disabled = false;
}
const chapterTitle = chaptersContainer.querySelector(".ytp-chapter-title-content") as HTMLDivElement;
const chapterTitle = chaptersContainer.querySelector(".ytp-chapter-title-content:not(.sponsorChapterText)") as HTMLDivElement;
chapterTitle.style.display = "none";
const chapterCustomText = (chapterTitle.parentElement.querySelector(".sponsorChapterText") || (() => {