Skip to content
This repository has been archived by the owner on Aug 30, 2018. It is now read-only.

So about the header! #1393

Closed
Eisys opened this issue Jan 19, 2015 · 18 comments
Closed

So about the header! #1393

Eisys opened this issue Jan 19, 2015 · 18 comments
Labels

Comments

@Eisys
Copy link

Eisys commented Jan 19, 2015

So I'm gonna make a new issue about this!
Continuing this: #786

I'm glad it got implemented, Thanks @YePpHa and @Yonezpt !!

But it has some problems for me:
With it enabled, the header does go away but the video doesnt scroll up:
http://prntscr.com/5uhldh
Having the transition enabled or disabled makes no difference.
Sometimes the page tries to scroll down to the video but then pops back up.

On the other hand, @Yonezpt , your script works perfectly now alongside the latest dev build!

Edit: Also, a feature request, perhaps add a simple way to change the time it takes for the header to come and go.

@KDsMax
Copy link

KDsMax commented Jan 19, 2015

I confirm this behaviour.

@YePpHa YePpHa added the bug label Jan 19, 2015
@YePpHa
Copy link
Owner

YePpHa commented Jan 19, 2015

@Eisys Please, could you post what browser and what version of said browser you're using.

@Yonezpt
Copy link
Collaborator

Yonezpt commented Jan 19, 2015

@YePpHa According to his recent comment in the other thread, he is using Chrome Version 40.0.2214.85 beta-m (64-bit) #786 (comment)

@YePpHa
Copy link
Owner

YePpHa commented Jan 19, 2015

@Yonezpt thx.

@KDsMax
Copy link

KDsMax commented Jan 19, 2015

I have a suggestion regarding the header hiding, add a feature to show header via scrolling the mouse wheel up. So we don't have to pause the video to get the header visible.

@YePpHa
Copy link
Owner

YePpHa commented Jan 19, 2015

@KDsMax that will make the feature a lot more complicated, but it will be durable.

@Eisys
Copy link
Author

Eisys commented Jan 19, 2015

I am all for it if it's an option.. I scroll through the page alot when watching videos so this would be kind of annoying for me! But it would be a great feature!
And yes, that is the browser I use, sorry for not mentioning!

@Yonezpt
Copy link
Collaborator

Yonezpt commented Jan 19, 2015

Perhaps the best option would be to show it based on the mouse location, a certain top distance treshold which would show the header, stay visible when the element is active, hide again when the mouse moves downwards and away from the header. I'll try to mock up a concept example, I'm curious to see wether this will impact browser performance or not.

@Eisys
Copy link
Author

Eisys commented Jan 19, 2015

@Yonezpt That is definitely possible, the addon I was talking about in the other thread worked just like that! And I didn't see any performance issues but then again I have a decent PC!

@KDsMax
Copy link

KDsMax commented Jan 19, 2015

I agree @Yonezpt

@Yonezpt
Copy link
Collaborator

Yonezpt commented Jan 19, 2015

@Eisys You already know how it is, here is the userscript: https://gist.github.com/Yonezpt/cf655fe7f9751877fb3d

Move mouse to the top and the header should appear, move downwards and it will hide. Also this time the notifications window should show up, unlike with the other script.
Same preferences apply, if you want a faster transition simply decrease the seconds. If you put it at 0s then it should appear and disappear instantly.

If you want a different mouse-trigger distance then simply change the 90 to another value in line 26. A smaller number no less than 50 will make it so that the header will only show or hide when you are closer to it, a bigger number will have the opposite effect; it will show and hide when you are further from it.

EDIT: Once again I forgot to test with YTC and it is showing a problem already, will try to fix it asap.

EDIT2: Nothing is wrong, you just have to remember to disable the new YTC hide header option before using the userscript I linked.

@Yonezpt
Copy link
Collaborator

Yonezpt commented Jan 19, 2015

Made a quick update because I forgot to account for when a user is using the header and navigating away from a video page.

@Eisys
Copy link
Author

Eisys commented Jan 19, 2015

Oh wow. That is amazing @Yonezpt !

This works really well and I think this fits my needs better than it appearing when the video is paused, since it got a bit annoying that the video moves up and down all the time when pausing!
I think @YePpHa should implement this as a 3rd option so people could have the variety, as well as add an option to change the speed of the transition and how close the mouse has to be to activate it!

Again, thank you so much for making this as I can now fully enjoy Youtube!

@Yonezpt Yonezpt assigned Yonezpt and unassigned Yonezpt Jan 19, 2015
@Yonezpt
Copy link
Collaborator

Yonezpt commented Jan 19, 2015

Make sure you are using the version 6, there were some details I overlooked. Also clicked on assignees by mistake...

@Eisys
Copy link
Author

Eisys commented Jan 19, 2015

Yep, I am indeed on ver 6, but reinstalled just in case! Works perfectly so far. The 0s works best for me as anything slower just seems unnecessary!

@Eisys
Copy link
Author

Eisys commented Jan 19, 2015

I have the Tampermonkey addon for Chrome, that is used to install userscripts! Im guessing @Yonezpt has it too!

Also. @Yonezpt I think there might be one last bug in your script, sometimes when going to a video the page scrolls down the height of the header and stays down like that, sometimes it flickers down and up really fast, sometimes a bit slower! I tried setting the speed slower and then it seems not to do it as much but there is still that flicker, but at 0s or 0.1s or so it stays down more often it seems!

@Yonezpt
Copy link
Collaborator

Yonezpt commented Jan 19, 2015

@Eisys In that case it is best to simply change the following lines:

    var sheet =
        '#masthead-positioner,#masthead-positioner-height-offset{margin-top:0;transition:margin-top 1s}\n' +
        '#body #body-container .hide{margin-top:-50px}',

to this:

    var sheet = '#body #body-container .hide{display:none}',

Seeing that you prefer it without transition.

@Eisys
Copy link
Author

Eisys commented Jan 19, 2015

Ok yep, that works perfectly and doesn't flicker, thanks!
Now to wait and hope that @YePpHa fixes the original issue and implements your new mouse-proximity version as well! I don't mind it being a seperate script but just having it all in one place would be better.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

4 participants