-
Notifications
You must be signed in to change notification settings - Fork 797
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
Menu does not appear after scrolling to the top on Chrome #313
Comments
Confirmed and found out the problem may be caused by this I'm wondering if it's possible to use Edit: double checked and turned out my pr didn't modify the |
Reproduced this issue on Microsoft Edge. |
Bug can be reproduced in Chrome as stated before. May be related to how DOM elements are accessed by different browsers (in this case position value relative to the document). See for details. It can be fixed by changing topDistance value from < 50 to < 100 (any value above 90 may work) in source/js/main.js
|
At first it seemed that I had succeeded, but then the problem recurred. |
From some very limited testing, I see that on Chrome On FF initially it is Seems like this is a jQuery issue? Or a chromium issue causing that offset to be incorrect. |
Would an acceptable fix be to also check the
Appreciate that it's not quite the same - as the current code would make it visible before reaching the top - but at least it avoids the menu never re-appearing? |
You can check on demo page:
https://probberechts.github.io/hexo-theme-cactus/cactus-white/public/2016/11/14/hello-world/
Scroll down a little bit and the get back to the top using button or just by scrolling and the menu not appear again.
https://user-images.githubusercontent.com/2175271/49327673-2ae53800-f564-11e8-8636-b14c7573693f.gif
On Chromium based browsers it doesn't work, In Firefox it is ok.
I found somewhere that changing it from
onclick="$('html, body')
toonclick="$('document')
in actions_desktop.ejs could help, but it does not.The text was updated successfully, but these errors were encountered: