Skip to content
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

Auto-scrolling doesn't work #159

Open
Bagunda opened this issue Feb 5, 2019 · 22 comments
Open

Auto-scrolling doesn't work #159

Bagunda opened this issue Feb 5, 2019 · 22 comments

Comments

@Bagunda
Copy link

Bagunda commented Feb 5, 2019

Auto-scrolling doesn't work
https://www.youtube.com/watch?v=iqamAAtSTu0

@ravening
Copy link

Facing the same issue. Autoscroll doesnt work and everytime I have to scroll down manually to see the latest logs

@mthenw
Copy link
Owner

mthenw commented Aug 23, 2019

@Bagunda @rakgenius which browser do you use?

@andrelung
Copy link

I am encountering the same issue with the latest chrome (76.0.3809.100). I might also add, that I am using frontail with openhabian

@ravening
Copy link

@mthenw Im using chrome browser Version 76.0.3809.100 (Official Build) (64-bit)

@Bagunda
Copy link
Author

Bagunda commented Aug 24, 2019

@Bagunda @rakgenius which browser do you use?
Chrome. It doesn't work about 1.5 years

@mthenw
Copy link
Owner

mthenw commented Aug 24, 2019

Can you paste me the exact command that you are running (or openhabian is running)?

@mthenw
Copy link
Owner

mthenw commented Aug 24, 2019

@Bagunda I cannot see that on your video but what happens when the window is scrolled to the bottom and you refresh the page? Does it go back to top?

mthenw added a commit that referenced this issue Aug 24, 2019
@mthenw
Copy link
Owner

mthenw commented Aug 24, 2019

@Bagunda @andrelung @rakgenius can I ask you to validate the fix from #180?

@andrelung
Copy link

Openhabian is using the npm-based installation.
Line 30 you can see how it is installed: https://github.com/openhab/openhabian/blob/master/functions/nodejs-apps.bash
And here is the exact command (/service):
https://github.com/openhab/openhabian/blob/master/includes/frontail.service

I'll try uninstalling the npm version and installing your fix later today.

@Bagunda
Copy link
Author

Bagunda commented Aug 25, 2019

Can you paste me the exact command that you are running (or openhabian is running)?

frontail -d -n 100 --ui-highlight --ui-highlight-preset /usr/lib/node_modules/frontail/preset/default.json /var/log/openhab2/openhab.log /var/log/openhab2/events.log
or
frontail -d -n 1000 --ui-highlight --ui-highlight-preset /usr/lib/node_modules/frontail/preset/default.json /var/log/openhab2/openhab.log /var/log/openhab2/events.log

@Bagunda
Copy link
Author

Bagunda commented Aug 25, 2019

@Bagunda I cannot see that on your video but what happens when the window is scrolled to the bottom and you refresh the page? Does it go back to top?

Here is new video https://www.youtube.com/watch?v=2Y6H5Qb7IGs

@Bagunda
Copy link
Author

Bagunda commented Aug 25, 2019

@Bagunda @andrelung @rakgenius can I ask you to validate the fix from #180?

Today I try fix #180. At the end of the video https://www.youtube.com/watch?v=2Y6H5Qb7IGs
Autoscroll doesn't work.

@mthenw
Copy link
Owner

mthenw commented Aug 26, 2019

I merged the PR and release new version (4.7.0) as it fixes @andrelung issue.

@Bagunda could you scroll your window to the bottom and run the following command in the dev tools?

console.log(window.innerHeight, window.scrollY, document.body.offsetHeight)

@Bagunda
Copy link
Author

Bagunda commented Aug 27, 2019

console.log(window.innerHeight, window.scrollY, document.body.offsetHeight)

https://youtu.be/iKUkM_MkApc
2019-08-27_19-13-36

@mthenw
Copy link
Owner

mthenw commented Aug 27, 2019

OK, looks like I know the culprit. Basically, your view is zoomed in. That's why the measurements are different than usual. Let me try to fix it.

@Bagunda
Copy link
Author

Bagunda commented Sep 25, 2019

Basically, your view is zoomed in.

In the settings of windows 10, I zoomed thescale.
Are you talking about this?

@mthenw
Copy link
Owner

mthenw commented Sep 28, 2019

@Bagunda yeah, that's probably it.

@riotm0de
Copy link

riotm0de commented Dec 10, 2019

Openhabian 2.4 (stable)
Frontail 4.8.0
Raspb. 3 B
Chrome and Edge

no Auto-Scroll for me :(
Using "Simple-Autoscroll" Extension for Chrome in the meanwhile.

@radokristof
Copy link

Same problem on a zoomed scale. On normal scale it works as it should...

@sujitrp
Copy link

sujitrp commented Apr 8, 2020

This is browser issue . works good in firefox or edge browser

@Wikibear
Copy link

Wikibear commented Jul 27, 2020

This is not a browser issue. If you check scrollY you get a float. This float is to small and you be stay all the time under body height value.
What i recommand a math round in line 305 at app.js:

from

var wasScrolledBottom = window.innerHeight + window.scrollY >= document.body.offsetHeight;

to this:

var wasScrolledBottom = window.innerHeight + Math.round(window.scrollY) >= document.body.offsetHeight;

Maybe a button for auto scroll is a bit better.

I have this issue in all modern Browser like Edge, Chrom, Opera and Firefox.

NPM is version 4.9.1 with this bug.

@ak2766
Copy link

ak2766 commented Nov 21, 2021

No auto-scroll on Firefox (v94.0) on Linux...

Only change in Firefox is making fonts bigger - would that affect auto-scroll?

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

No branches or pull requests

9 participants