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

Metadata layout in 3.0/3.1 version #189

Closed
rubinatorz opened this issue Jun 30, 2020 · 13 comments
Closed

Metadata layout in 3.0/3.1 version #189

rubinatorz opened this issue Jun 30, 2020 · 13 comments
Assignees
Labels
enhancement New feature or request seeking feedback Seeking feedback from the community on this issue timescale/imminent Ready to be assigned to developers
Milestone

Comments

@rubinatorz
Copy link

Hi @isaisabel

The layout of the metadata in the new 3.0/3.1 version of the Navigator is slightly changed compared to the 2.0 version. Values are now aligned with each other, the line height of each line is increased and the width of the tooltip is smaller:

Screenshot 2020-06-29 at 17 13 00

In the previous version it was like this:
Screenshot 2020-06-29 at 17 12 51

I can imagine the choice for this, but in our case it just looks less nice and a bit messy in the new version of the metadata. Is there a chance of having an option to influence this behaviour?

Thanks!

@isaisabel isaisabel added seeking feedback Seeking feedback from the community on this issue timescale/short-term Becomes timescale/imminent in weeks or months labels Jun 30, 2020
@isaisabel
Copy link
Contributor

Hi @rubinatorz,

Sorry, I did see your comment on the other issue yesterday I just haven't had time to respond until now.

The new tooltip implementation uses a borderless table instead of just a line by line listing. This theoretically improves readability although apparently not in your specific case. Two possible ways to improve the readability for your case:

  1. remove the bullet points
  2. Empty values could be represented as "" instead of "-".
  3. Remove the section breaks, or represent them as empty keys and values to make a blank line:
     { "name": "", "value": ""}

One thing we could possibly change is setting white-space to nowrap for the lefthand side of the key-value pair. This way the metadata name wouldn't wrap when there are multiple words. In practice I'm not sure this actually improves things though:

Screen Shot 2020-06-30 at 2 33 47 PM
above: add the following to line 13 of nav-app/src/app/matrix/technique-cell/tooltip/tooltip.component.scss:

        td:first-child {
            white-space: nowrap;
        }

Screen Shot 2020-06-30 at 2 33 15 PM
above: how the same metadata looks with the current implementation.

If you wanted to modify the tooltip template yourself, it should be pretty straightforward to modify nav-app/src/app/matrix/technique-cell/tooltip/tooltip.component.html (and the associated SCSS linked above) into a format you find more pleasant. Even if you're not familiar with the ins and outs of Angular the template for the tooltip is quite close to plain HTML.

I'll leave this issue open and marked as "seeking feedback" in case other users want to chime in with their thoughts.

@marcusbakker
Copy link

@isaisabel having the option nowrap would be of great help to allow a different style of formatting. Would it be possible to include this in the official version of the Navigator?

@rubinatorz
Copy link
Author

Hi @isaisabel

Thanks for getting back on this. I did indeed put this also in a comment on issue #188, but I thought it might be better to make a separate issue for it.

I tried your suggestions and this helps a bit. However empty names and/or values are not allowed, an error is shown when loading the layer into the Navigator:
Screenshot 2020-07-01 at 14 34 07

Having an option to enter empty names and values is indeed useful to have section breaks. I can use a space in both name as value, but then still a colon is shown.

Regarding the no-wrap you suggested: I really love this formatting. So it would be very nice if you could include that in the release.

@isaisabel
Copy link
Contributor

Yeah we can include no-wrap on the key as part of the v3.1 release. @clemiller could you please make sure it makes its way into the branch? The change should be in my comment above (the addition to the tooltip SCSS)

@rubinatorz You're right that it doesn't work. The typechecking we implemented doesn't like empty values on required fields (and empty strings are considered an empty value). However, whitespace does work... except that it includes the colon delimiter which I had forgotten about:
image

"metadata": [
                {
                    "name": "hello",
                    "value": "world"
                }, 
                {
                    "name": " ",
                    "value": " "
                },
                {
                    "name": "how",
                    "value": "goes"
                }
            ],

@isaisabel isaisabel added timescale/imminent Ready to be assigned to developers and removed timescale/short-term Becomes timescale/imminent in weeks or months labels Jul 1, 2020
@isaisabel
Copy link
Contributor

We can explore adding a section break feature to the metadata format in future updates (the v3.1 deadline is too soon for us to add to that milestone)

@rubinatorz
Copy link
Author

Hi @isaisabel

Thanks for planning to incorporate the nowrap in 3.1! Very happy with that!

Regarding the section break, we can for now work around the colon and it would be great to have the section break in the future update.

@isaisabel
Copy link
Contributor

The nowrap change has now been implemented in v3.1. I'm leaving this open to document the need for further improvements in that UI, namely allowing section breaks.

@rubinatorz
Copy link
Author

Looks great @isaisabel and @clemiller! Thanks a lot.

Screenshot 2020-07-02 at 15 01 22

We have a temporary workaround for the section break as you can see. Looking forward to a real section break.

@isaisabel isaisabel added timescale/short-term Becomes timescale/imminent in weeks or months and removed timescale/imminent Ready to be assigned to developers labels Jul 6, 2020
@isaisabel isaisabel added this to the Version 4.1 milestone Jul 17, 2020
@isaisabel isaisabel added timescale/imminent Ready to be assigned to developers enhancement New feature or request and removed timescale/short-term Becomes timescale/imminent in weeks or months labels Oct 23, 2020
@clemiller clemiller self-assigned this Oct 30, 2020
@clemiller
Copy link
Contributor

Hi all!

We are implementing the section break feature as a part of the next update (v4.1). We're planning to add the option for a "divider” property, which will add a section break where the property occurs in the list of metadata. This will be shown as a horizontal bar across the table. Before finalizing this implementation, we'd like to seek some feedback. Please feel free to share your thoughts!

Here's an example of the format:

"metadata": [
	{
		"name": "Overlay",
		"value": "Detection"
	},
	{
		"divider": true
	},
	{
		"name": "Applicable to",
		"value": "All"
	},
        ...,
]

@rubinatorz
Copy link
Author

Hi @clemiller and @isaisabel, this is great! It looks good and exactly what we need. The way the section break can be inserted looks handy.

@marcusbakker
Copy link

Hi @clemiller, that looks awesome!

@clemiller
Copy link
Contributor

Great, we will go ahead with this implementation for the next release. Thank you everyone!

@isaisabel
Copy link
Contributor

The divider feature is now present in the develop branch. We'll be releasing it to the live instance soon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request seeking feedback Seeking feedback from the community on this issue timescale/imminent Ready to be assigned to developers
Projects
None yet
Development

No branches or pull requests

4 participants