Video Speed Buttons

Add speed buttons to any HTML5 <video> element. Comes with a loader for YouTube and Vimeo

< Feedback on Video Speed Buttons

Review: Good - script works

§
Posted: 07-12-2019
Edited: 07-12-2019

How to match only Flickr video pages?

I test your script on Flickr. Seems work: Maybe some videos don't accept speed buttons, but in general it's ok. Problem: I see the video speed buttons on not video content too (by example, just photos pages).

I use this include because i can't find more specific: // FLICKR // @include https://www.flickr.com/photos/*

Can you help me about that? Test links: https://www.flickr.com/search/?text=video&media=videos

Another request : I modify by CSS, the position of the Speed Buttons container, but it's sometime difficult to match it: the container have not a div name or class specific. By example for flickr, i use: .fluid.html-photo-page-scrappy-view .view.fluid-droparound-view + div[style^="position: fixed; top: 0px; right: 0px; z-index: 100;"] Can you give a specific class/div name ?

§
Posted: 28-02-2020

no news ?

Braden BestAuthor
§
Posted: 29-02-2020
Edited: 29-02-2020

@decembre I don't use Flickr. But if it's a video site, it should work. There are some "gotchas" though.

In order for VSB to work on a given site, there are a couple minimum prerequisites.

  1. The script header must have the site's domain in the @match section. (see the top of the userscript). You said something about an @include. I suggest you change it to @match and follow the pattern.
  2. The page must have an actual <video> element to attach VSB to. If it is an <object> or some other weirdness, it definitely won't work.

It's also nice to have a place to inject the buttons, but if there's nowhere to inject them, the script will create a floating box on the top right and inject them there. You seem to know your way around CSS. The part of the script that decides where to inject the buttons is at the bottom of the script. You'll see a variable named container_candidates. Add your possible injection sites, in the form of CSS selectors, to that array.

I'm having difficulty understanding what your issue is with the last part, but it sounds like you didn't put in a candidate and had the aforementioned default injection site take over. The buttons are, in fact, in a container: .vsb-container.

Let me know if this helps, and if it doesn't, please be more specific and precise in your language.

I'm also on discord. http://discord.gg/EvYSH8Z

Discord is good because we can chat live. It's a bit like IRC. Just make sure to ping me (@braden) so that I actually see your message.

§
Posted: 29-02-2020
Edited: 29-02-2020

Thanks for this big explanation!

@match and @include are not identical?: many userscripts use @include And when i use @match, greasemonkey v.3.17 send an error message.... but work fine with @include.

About CSS selector i need: As i remember the selector .vsb-container is not the first one container (with a black backgound). So i need of this selector to move it at the right place (it contain the vbs buttons). For flickr it was: .fluid.html-photo-page-scrappy-view .view.fluid-droparound-view + div[style^="position: fixed; top: 0px; right: 0px; z-index: 100;"]

But for a general use (if not another div have these specificity): div[style^="position: fixed; top: 0px; right: 0px; z-index: 100;"]

(PS: i re-tested on flickr and now i can't find a videos where the script work, it's not very important)

So, it should more easy to have not a general div as selector but something more specific. By example: #vbs

Another request: It should be possible to always positioning the vbs button under the player ?. That's because when i am on page with youtube video enable or a site where i want to test your script, i need to tweak its position each time.

That's all , i hope to more clear , not certain... :-)

Post reply

Sign in to post a reply.