We all watch YouTube videos frequently. While watching some videos, especially in full screen mode, it is annoying to see annotations and subscribe us links. It totally spoils our video watching enjoyment. You can manually close those pop-ups such as annotations and links, but it is not a permanent solution. There are two ways to hide those things in a hassle-free manner.
This problem is a big burden for most of us, because the close button can't be clicked while watching in full screen mode. Most of the time spotting the x button to close those links becomes quite difficult. when it is more than two, you will be outraged.
You can permanently hide those annotations by changing your YouTube settings as explained in this guide. The demerit of this method is you will no longer see links over the videos you watch which may include some useful links at the end of the video. Those links could be there as connecting links to other videos of the same channel or it may take you to the related blog post or transcription of the video.
There is an alternate way which you may find useful for the videos with incessant annotations and suggestions. While watching a random video of this kind on YouTube, this method is helpful.
I have coded a bookmarklet to make this happen. Just drag and drop the below link to your bookmarks tool bar. Now, whenever you are about to watch a video like the one mentioned above, just click on the bookmarklet. It will clear all annotations, channel promotions and interactive cards pop-ups on the videos. This will be in effect, until you reload the browser window.
So, once you click on the bookmarklet you can watch any number of YouTube videos without any annotations or pop-ups. In other words, you need not click on it for every video.
The beauty of this trick is, the changes made by the bookmarklet will perish after reloading the browser window.
What to do if this doesn't work
By default, Mozilla firefox don't use HTML5 player to play YouTube videos. But, the code has been written for HTML5 player. So in firefox or any other browsers to get things done, visit this page and click on 'Request the HTML5 player' (Refer the image below).
If you browser don't support HTML5 player, there is no other way, you should either upgrade your browser or start using Google chrome.
Technical side of this method
You can actually use this trick without caring about the following piece of writing, though I write this for the geeks who are eager to know how it works.
Every YouTube video's HTML contains the annotations, channel promotions and suggested videos in div elements which has
annotation annotation-type-custom iv-promo iv-promo-video,
branding-img-container, as classes respectively.
What I have done to make those pop-ups disappear is simply adding a class to those div elements with
display: none; rule. YouTube has a class named
hid in its css by default with
display: none rule.
While you click on the bookmarklet, it simply adds
hid class to those div elements to hide the annotations & pop-ups from the YouTube video you are watching.