player: use CSS :has() for volume slider hover (pure CSS solution)
This commit is contained in:
@@ -502,13 +502,12 @@ const initPlayer = (): void => {
|
||||
})
|
||||
|
||||
muteBtn?.addEventListener('mouseenter', () => {
|
||||
volumeWrap?.classList.add('show-volume')
|
||||
muteBtn.classList.add('show-volume')
|
||||
isHoveringVolume = true
|
||||
showControls()
|
||||
})
|
||||
|
||||
muteBtn?.addEventListener('mouseleave', () => {
|
||||
volumeWrap?.classList.remove('show-volume')
|
||||
isHoveringVolume = false
|
||||
showControls()
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user