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

Show site selector as text only when only one site is available #16972

Merged
merged 3 commits into from Jan 19, 2021

Conversation

sgiehl
Copy link
Member

@sgiehl sgiehl commented Dec 17, 2020

Description:

When only one website is available, the site selector will no longer work as selector. Instead all highlight effects are removed and the dropdown arrow is hidden as well. (Let me know if the UI should be modified even more.)

The site selector will also be shown this way while the list of available sites is loaded.
The list of sites will now be loaded automatically when the site selector is initialized. Before that was done on open only.

fixes #16789

Review

  • Functional review done
  • Usability review done (is anything maybe unclear or think about anything that would cause people to reach out to support)
  • Security review done see checklist
  • Code review done
  • Tests were added if useful/possible
  • Reviewed for breaking changes
  • Developer changelog updated if needed
  • Documentation added if needed
  • Existing documentation updated if needed

@sgiehl sgiehl added not-in-changelog For issues or pull requests that should not be included in our release changelog on matomo.org. Needs Review PRs that need a code review labels Dec 17, 2020
@sgiehl sgiehl added this to the 4.1.0 milestone Dec 17, 2020
@tsteur
Copy link
Member

tsteur commented Dec 17, 2020

Thanks for this @sgiehl it actually looks still like a button now and when I click on it, nothing happens and it feels like a bug. Also it doesn't really help making the UI easier etc.

I would say lets remove the border but it looks not quite right and isn't helping that much either
image

Ideally we would remove the entire site selector which be fine for > 90% of users (and therefore would make UI better) but I think that's not wanted. So can we instead, when there's only one site, change the "All websites" button and make it a "create new website" button (when user is super user and keep "all websites" for all other users)? Only if it's easily doable though. Otherwise we can also postpone this issue.

@mattab
Copy link
Member

mattab commented Dec 18, 2020

After all, maybe we could remove the selector completely when there's only one website, as making the UI simpler for most people is probably more valuable indeed..

@sgiehl
Copy link
Member Author

sgiehl commented Dec 21, 2020

After all, maybe we could remove the selector completely when there's only one website, as making the UI simpler for most people is probably more valuable indeed..

You mean one website at all or one website available for the user?

@tsteur
Copy link
Member

tsteur commented Dec 21, 2020

@sgiehl when only one site exists overall

@sgiehl
Copy link
Member Author

sgiehl commented Dec 22, 2020

Ok. The site selector is now hidden in the top controls when only one website exists overall.
I've not reverted the other changes yet, as they imho improve the behavior when the site selector is used on admin pages.

@sgiehl sgiehl force-pushed the siteselector branch 2 times, most recently from 70e6e60 to 9479a22 Compare December 22, 2020 10:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Needs Review PRs that need a code review not-in-changelog For issues or pull requests that should not be included in our release changelog on matomo.org.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

If only one website exists, remove the site selector from reporting page
4 participants