-
Notifications
You must be signed in to change notification settings - Fork 318
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
NAS-130956 / 25.04 / Reduce numbers of layout shifts on login page #10612
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Loading of the login page looks good!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- If you restart middleware with
service middlewared restart
you'll still getPlease wait
with the message, even though you are not being logged in and waiting may not help if there is no connectivity. We should only show that message when we are actively logging user in. - We should change
Please wait
toLogging in...
- There is a lot of empty space on main login form now, I think we should do something about it.
- If the system is managed by truecommand and has HA, there is a scrollbar.
- I'm fine with changing how
FailoverStatusComponent
works. For example, we could showHA is enabled (?)
with a tooltip for active IP addresses. We could showHA is disabled: reason
when there is one reason andHA is disabled (?)
when there are many. - We could also avoid showing validation errors in the form, but we need to make snackbar more prominent then.
- Page doesn't look correct when you connect to a standby controller. This is how used to look. You can test it by connecting by adding
a
orb
to hostname of our m40.
- If set password form has scrollbar, we need to make to make adjustments to it as well. I'm fine with it having a different height there.
@undsoft please give it a try now. It's a bit tricky with that I think we can remove it, if it created more problems than benefits? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Initial login flow looks fine, however I could live without Logging you in after submitting the form.
When reloading the page, I could live without "Connecting to TrueNAS" message at least for some time. I think there should be some period where we expect connection to happen and we don't show this dialog.
Also "Connecting to TrueNAS" is too wide now for some reason.
@undsoft - updatred: Screen.Recording.2024-09-10.at.15.28.25.mov |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Better, but still some things to fix:
- When connecting to a standby controller, I think it would be helpful to disable inputs as well, otherwise it's not immediately obvious why I cannot click Login.
- I've used Reset Configuration option in General Settings and it kept saying Logging in.
- If you use non-existent url for webui, it will still present a login form for a second before switching to "Connecting to TrueNAS" message. I think we should keep longer in previous loading state before showing login form as we attempt to establish a WS connection.
@undsoft we show |
Problem is that if we'll show loading screen on invalid url, it as well will be shown before valid TRUE NAS url for web ui. And we'll loose that immediate sign in form rendering. We show LOGGING IN message only if user has As discussed - |
I understand how it currently works, but I am saying that maybe we could keep showing flashing TrueNAS login animation until websocket connection is established. This way we won't have situations where it says "logging in" for an offline system. |
Yeah, I got it, I think that's the only way. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's a bit worse now. My WS connection took 500ms to establish, yet I still saw establishing connection on initial page load.
2024-09-16.14.07.48.mov
@undsoft now it's updated to show True NAS logo as a fallback if we are not logged in or not connected to the WS (for < 1 second) User Logged In and connected to WS Screen.Recording.2024-09-16.at.15.47.31.movAnd screen like that if we are not connected and more than 1 sec waiting Screen.Recording.2024-09-16.at.15.48.32.mov |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks. Nice work 👍🏼
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #10612 +/- ##
==========================================
- Coverage 79.78% 79.72% -0.07%
==========================================
Files 1563 1564 +1
Lines 51483 51521 +38
Branches 5852 5856 +4
==========================================
- Hits 41075 41073 -2
- Misses 10408 10448 +40 ☔ View full report in Codecov by Sentry. |
This PR has been merged and conversations have been locked. |
Changes:
Reduced numbers of layout shifts on login page
Testing:
See ticket and try it in action.
See how it works if I log in for the first time, see layout shifts fixes.
As well once I was logged in, I reloaded the page. (see)👇
BEFORE:
Screen.Recording.2024-09-03.at.13.52.19.mov
AFTER:
Screen.Recording.2024-09-03.at.15.24.23.mov
Note: No tests added before the final approve.