Users without a site are incorrectly asked to login by the widget
Expected behavior
Users without a site shouldn't be able to add any of the current widgets (Today stats or All Time stats).
Actual behavior
Users who don't have a site yet (e.g. chose "Not now" option after sign up) are shown the "Log in to WordPress..." message in the widget.
Steps to reproduce the behavior
- Sign up for a new account
- Skip the site creation process
- Background the app and notice you can add the stats widgets
- Notice that the widgets ask you to log in even though you're already logged in
Tested on iPhone 11, iOS 14.4, WPiOS 16.6
First reported here
@guarani
Should we allow adding widgets when user is not logged in, if we wouldn't allow users without a site add any of the current widgets? I think we could make behaviour more consistent
I have 2 proposals for the sake of consistency:
- If we wouldn't allow widgets without the site, then we shouldn't allow widgets if user is not logged in
- If we continue allowing widgets when user is not logged in, we should allow widgets without the site with "Select a site..." message.
I would choose an option number 2:
- Widgets are always discoverable as an option
- Users will know what is missing to make them work
Good point that ensuring discoverability of widgets should be a top priority, @staskus. I agree with your suggestion that allowing the widget to be added, but providing an actionable message, is a great approach.
Apologies for the delay responding to you here, @staskus.
Note: Added a new issue related to account having no site and widgets https://github.com/wordpress-mobile/WordPress-iOS/issues/18914
The task has already time invested and the issue is almost fixed in the PR so setting the priority to finish higher.
I remember that PR from months back 👍 I think Medium priority is accurate here because users will sometimes not create a site and as it stands the widgets aren't showing actionable info in this scenario.