mirror of
https://github.com/ajayyy/SponsorBlock.git
synced 2025-12-06 19:47:04 +03:00
Handle preview bar hover without js
This commit is contained in:
@@ -34,7 +34,7 @@
|
|||||||
height: 3px;
|
height: 3px;
|
||||||
}
|
}
|
||||||
|
|
||||||
#previewbar.hovered {
|
div:hover > #previewbar.sbNotInvidious {
|
||||||
transform: scaleY(1)
|
transform: scaleY(1)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -196,10 +196,7 @@ class PreviewBar {
|
|||||||
|
|
||||||
this.container.style.transform = "none";
|
this.container.style.transform = "none";
|
||||||
} else if (!this.onInvidious) {
|
} else if (!this.onInvidious) {
|
||||||
// Hover listener
|
this.container.classList.add("sbNotInvidious");
|
||||||
this.parent.addEventListener("mouseenter", () => this.container.classList.add("hovered"));
|
|
||||||
|
|
||||||
this.parent.addEventListener("mouseleave", () => this.container.classList.remove("hovered"));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// On the seek bar
|
// On the seek bar
|
||||||
|
|||||||
Reference in New Issue
Block a user