Skip to content

Commit

Permalink
Fix missing VSC overlay on fullscreen amazon product-page videos (#995)
Browse files Browse the repository at this point in the history
The special case that was added for Amazon Prime Video messes up the
overlay in product-page videos in full screen mode.

Example product page: https://www.amazon.com/Sony-WH-1000XM5-Canceling-Headphones-Hands-Free/dp/B09XS7JWHH
  • Loading branch information
russelldavis authored May 24, 2024
1 parent aea4f32 commit 5bcfcd2
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion inject.js
Original file line number Diff line number Diff line change
Expand Up @@ -351,7 +351,9 @@ function defineVideoController() {
fragment.appendChild(wrapper);

switch (true) {
case location.hostname == "www.amazon.com":
// Only special-case Prime Video, not product-page videos (which use
// "vjs-tech"), otherwise the overlay disappears in fullscreen mode
case location.hostname == "www.amazon.com" && !this.video.classList.contains("vjs-tech"):
case location.hostname == "www.reddit.com":
case /hbogo\./.test(location.hostname):
// insert before parent to bypass overlay
Expand Down

0 comments on commit 5bcfcd2

Please sign in to comment.