-
Notifications
You must be signed in to change notification settings - Fork 0
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
Single session #239
Single session #239
Conversation
This is great, thanks for working on this! |
Good point, I'm not sure what the best solution is here. When encountering multiple sessions, we could:
|
What about this? |
Sadly, it doesn't seem to be possible to know which session is the most recent. So I'll go with option 1.? |
Don't they have ids? I'd go with the last in the list and log all the others out. |
The id is a random alphanumeric string, it's not incremental.
Alright, going with this one. |
799235f
to
3d8467b
Compare
The screen recording doesn't shown it, but only one of the sessions was kept, the other one was logged out. |
Maybe it's my local setup but when I try to build this I get:
|
Mmm, that's weird. The build succeeded so must be something about your local setup indeed. You could try: rm -rf node_modules vendor
make Hopefully that will fix it |
Still the same problem. I just wanted to help and test but I suppose I need to leave it to others. |
It's weird, it should just work, not sure what could be the culprit. |
I noticed some other places where the session picker is shown (before a session exists), working on fixing those here too. |
AFAICT, the session picker is now never shown. I added another screen recording that shows the login/logout flow. |
7ea2ba5
to
da7e68c
Compare
I force-pushed to remove a useless wip commit that only changed whitespace. |
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.
LGTM! Testing it to be functional as expected!
Thanks for testing @ashfame! Merging. |
Fixes #236 #224 #200
This PR makes it so that the session picker is only shown when there is no session, so that users can click "Sign in". Once a session exists (user has logged-in), it will always automatically enter the existing session on page load. Additionally, when a session exists, "Back" buttons that would lead to the session picker will no longer be rendered.
This effectively makes it so that Chatrix is a single-session client.
TODO
Screen recordings
Screen.Recording.2023-11-30.at.13.27.22.mov
Screen.Recording.2023-11-30.at.15.49.58.mov