-
-
Notifications
You must be signed in to change notification settings - Fork 315
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Button bar disappears #316
Comments
Maybe there is a way to detect the height in number of lines? |
Full screen also grants more space. Embeds can have almost no space. For SponsorBlock, I think it would be best just to disable extra buttons like the clear and info button as they are not required (and can be disabled in the options) |
I think if this was going to be done, making an npm library to handle the player buttons which both extensions use would be the way to go. |
The issue could already be there for us on embeds anyway as there's no way to know what size the player is going to be in certain conditions. |
I have seen it appear on embeds that are too small |
Change the width on https://youtubevideoembed.com/ to see the issue. The right controls move down to the next line to an area that is invisible |
Yeah, I say we fix it using a library that others can use to solve the problem too in a way that doesn't break compatibility. |
https://developer.mozilla.org/en-US/docs/Web/API/Element/getBoundingClientRect could be used. If |
Why not just attach a |
This is not so much a problem with SB, but the stylesheets used by YT and our manipulation of the DOM.
My own plugin adds 3 buttons to the toolbar (capture, download and mutate). SB in its default form has 2 (open and starts-now ). Clicking start will add the clear, clicking stop will add the submit; giving a total of 4 buttons.
These 7 buttons are too much for the all mighty google's youtube to handle. The whole ".ytp-right-controls" bar will flow to the next row, with parent having overflow hidden, it disappears from view.
No fault of a single extension, but combined...
My mutate button mentioned above offers 4 additional buttons (rotate L/R, flip V/H). Also, since I deem it not very important, I've appended rather then prepended. These 4 buttons are diplayed in a popout when the main button is hovered. I mention this because I think a solution to the disappearing toolbar is to add the rightmost buttons to a dropdown/dropup (with last visible button icon in the bar being a simple triangle which can be hovered).
Thoughts, ideas?
Any extension which adds buttons is going to face the same issue. Adding too many buttons breaks the bar for every extension. We need an extension/developer friendly solution.
I propose both of our extensions add a fix, but to be friendly, a data attribute should be added to the ".ytp-right-controls" element which would signify to a later loading extension that the problem has been fixed.
Update: Just noticed that hovering the volume, produces its slider, which also eats into the button bar real estate.
The text was updated successfully, but these errors were encountered: