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

[Spaces] - Space-aware Settings UI #22886

Merged
merged 6 commits into from
Sep 13, 2018

Conversation

legrego
Copy link
Member

@legrego legrego commented Sep 10, 2018

[skip ci]
This PR updates the Advanced Settings screen to make it clear to users that most settings within the UI are space-aware.

@legrego legrego added WIP Work in progress Team:Security Team focused on: Auth, Users, Roles, Spaces, Audit Logging, and more! labels Sep 10, 2018
@legrego
Copy link
Member Author

legrego commented Sep 10, 2018

@cchaos I started working on this, but (as usual), I'd like your input if you have time! You'll be happy to know that this is likely the last significant UI change for Spaces Phase 1 😄

Here's what I have so far:

  1. Update the page title to include the SpaceAvatar
  2. Add a callout to the top of the screen informing users that the settings (mostly) apply to the current space. I don't love the two stacked callouts here, so I'm open to suggestions if you have a better idea.

image

What I'm missing:

  1. Update the "Usage Data" section to make it clear that this setting applies to all of Kibana, regardless of which space you are in. Do you have any ideas on how to convey this?

image

@elastic elastic deleted a comment from elasticmachine Sep 10, 2018
@cchaos
Copy link
Contributor

cchaos commented Sep 10, 2018

Quick question, what does it do if you only have one (the default) space?

@legrego
Copy link
Member Author

legrego commented Sep 10, 2018

It will behave the same way regardless of the number of spaces. Keep in mind though that the current user will only see the spaces they have access to. There might appear to be 1 space, even if there are many. It will depend on the user’s configured access within Kibana.

The settings screen will only know what the current user has access to. It won’t know if there are additional spaces available to other users.

If the spaces plugin is disabled or uninstalled, then the screen will revert to its previous look and feel, without any references to Spaces

@cchaos
Copy link
Contributor

cchaos commented Sep 11, 2018

I think what you have will be fine. When we do a K7 overhaul of the management index page, we will need to figure out a better naming/placement for the "Advanced settings (per space)".

I would just change the icon in the callout to iconType="spacesApp" and use the same callout specs inside the telemetry panel above the title with a new message about it NOT applying only to the current space. Get with @gchaps for language.

@legrego
Copy link
Member Author

legrego commented Sep 11, 2018

Thanks @cchaos!

@gchaps what are your thoughts on the wording for these two blue callouts?

image

Unless otherwise specified, settings on this page apply only to the marketing space.

This setting applies to all of Kibana, not just the marketing space.

@cchaos
Copy link
Contributor

cchaos commented Sep 11, 2018

Aside from the text itself, in the callout in the telemetry section, I would bold "all of Kibana" or whatever text will hint at all spaces within kibana, not the space name as when I just scanned it, it looks similar to the first banner than I just assumed it said the same thing.

@legrego legrego requested a review from kobelb September 11, 2018 21:18
@legrego legrego changed the title [Spaces] - WIP - Space-aware Settings UI [Spaces] - Space-aware Settings UI Sep 11, 2018
@legrego legrego removed the WIP Work in progress label Sep 11, 2018
@legrego
Copy link
Member Author

legrego commented Sep 11, 2018

@kobelb I'll likely be changing the wording a bit, but otherwise, this is ready for review

@@ -25,8 +25,13 @@ const module = uiModules.get('spaces_nav', ['kibana']);

let spacesManager;

module.controller('spacesNavController', ($scope, $http, chrome, activeSpace, spaceSelectorURL) => {
module.controller('spacesNavController', ($scope, $http, chrome, spacesEnabled, activeSpace) => {
if (!spacesEnabled) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need this? I thought that we didn't load any of the plugin's client-side code when it's disabled.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When I was testing, it appeared to still load assets, but that was with dev auto-reloading running. I'll retest without that and verify

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

figured it out! this wasn't needed

@@ -139,7 +139,7 @@ export function uiRenderMixin(kbnServer, server, config) {
try {
const request = reply.request;
const translations = await server.getUiTranslations();
const basePath = config.get('server.basePath');
const basePath = request.getBasePath();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would you mind explaining why we're using the space relative base path here as opposed to the root path?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We're using the space relative base path here because this is what gets injected into ui/chrome for addBasePath and getBasePath. The bigger why is because Spencer told me this is what I needed to do for Spaces to be compatible with his recent base path API work 😄

Copy link
Contributor

@kobelb kobelb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is looking great! Just one question for my own edification, otherwise LGTM.

@gchaps
Copy link
Contributor

gchaps commented Sep 13, 2018

@legrego For the first one, I like putting the space name first:

The settings on this page apply to the Marketing space, unless otherwise specified.

For the second one, I think we can simply say:

This setting applies to all of Kibana.

@legrego
Copy link
Member Author

legrego commented Sep 13, 2018

Thanks, @gchaps!

@legrego legrego merged commit 5ed4427 into elastic:spaces-phase-1 Sep 13, 2018
@legrego legrego deleted the space-aware-advanced-settings branch April 29, 2019 14:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Team:Security Team focused on: Auth, Users, Roles, Spaces, Audit Logging, and more!
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants