diff --git a/src/js-components/previewBar.ts b/src/js-components/previewBar.ts index e0fa6464..57bf8296 100644 --- a/src/js-components/previewBar.ts +++ b/src/js-components/previewBar.ts @@ -74,6 +74,10 @@ class PreviewBar { setupHoverText(): void { if (this.onMobileYouTube || this.onInvidious) return; + // delete old ones + document.querySelectorAll(`.sponsorCategoryTooltip`) + .forEach((e) => e.remove()); + // Create label placeholder this.categoryTooltip = document.createElement("div"); this.categoryTooltip.className = "ytp-tooltip-title sponsorCategoryTooltip";