Skip to content

feat: add button to quickly switch accounts#36

Merged
pd4d10 merged 4 commits intopd4d10:masterfrom
phillipthelen:account-switcher
Oct 8, 2020
Merged

feat: add button to quickly switch accounts#36
pd4d10 merged 4 commits intopd4d10:masterfrom
phillipthelen:account-switcher

Conversation

@phillipthelen
Copy link
Contributor

Fixes #35

I had to do this slightly hacky, since the way BottomMenuItem works, does not allow it to be wrapped in a gesturerecognizer. So I wrapped the icon and text widgets individually. This does seem to work pretty well though.

As described in the issue, this PR adds a long-press gesture to the "Me" tabbar item. It brings up a bottom modal where you can quickly choose a different account. Choosing the currently active one doesn't reload the app but instead just closes the modal. I also added a "Manage" link, that opens the regular login view where the user can also add new accounts or delete existing ones.

Simulator Screen Shot - iPhone 11 Pro Max - 2020-02-12 at 10 19 41 Simulator Screen Shot - iPhone 11 Pro Max - 2020-02-12 at 10 19 56

@pd4d10
Copy link
Owner

pd4d10 commented Feb 13, 2020

Thanks for your contribution! I'll review it ASAP

@pd4d10
Copy link
Owner

pd4d10 commented Feb 26, 2020

Hi, @phillipthelen , sorry for the late review. This feature is really helpful!

Perhaps there is a point that can be improved that the entry is a bit hidden(long press Me tab item). Most users may not notice this behavior.

If you don't mind I'd like to add some commits to this PR to give users some tips for this feature.

@phillipthelen
Copy link
Contributor Author

I 100% agree with you! Do you have an idea for how to better surface this feature? Are there other places in the app where tutorials/hints are shown?

@pd4d10
Copy link
Owner

pd4d10 commented Oct 8, 2020

Hi, @phillipthelen , sorry for the long wait.

I still don't figure out how to add the hints. Instead of that, my new proposal is to add a 'switch accounts' button to the Me screen's header. It also works for quick account switch. The only drawback is that it would appear a bit slowly (waiting for user data fetching), and not work offline.

The code base has changed significantly after 8 months, which would cause lots of conflicts on merge/rebase, so I'm going to rewrite these code and force push to this PR's branch.

@pd4d10
Copy link
Owner

pd4d10 commented Oct 8, 2020

Simulator Screen Shot - iPhone 11 Pro Max - 2020-10-08 at 17 06 28

@pd4d10 pd4d10 changed the title Add menu to quickly switch accounts fix: add button to quickly switch accounts Oct 8, 2020
@pd4d10 pd4d10 changed the title fix: add button to quickly switch accounts feat: add button to quickly switch accounts Oct 8, 2020
@pd4d10 pd4d10 merged commit 62b02ed into pd4d10:master Oct 8, 2020
@pd4d10
Copy link
Owner

pd4d10 commented Oct 8, 2020

Thank you for all your efforts!

Feel free to ping me if there are other ideas

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

Successfully merging this pull request may close these issues.

Quickly switch between accounts

2 participants