MaibornWolff / codecharta

CodeCharta visualizes multiple code metrics using 3D tree maps.
https://maibornwolff.github.io/codecharta/
BSD 3-Clause "New" or "Revised" License
190 stars 30 forks source link

Metric Attribute list side bar #527

Closed Richargh closed 4 years ago

Richargh commented 5 years ago

Feature request

Let's incrementally change our UI. Next stop, move the metric attribute list to the right side.

Currently the metric attribute list can be opened by clicking on the file path indicator. In the settings this is called the detail panel. This issue replaces this detail panel and it can be removed.

Description

The new metric side bar is useful when users want to check out other metrics beside the three selected ones for size, height and color: "this building has high complexity, bad line coverage but how often is it actually changed?". The features are:

The result looks something like this:

Metric-Bar

While I do like the radial buttons proposed in the screen shot I think we should implement these buttons with a later story.

Inspiration

I was inspired by this UI mockup:

UI-Refactoring

Richargh commented 5 years ago

I updated the description.

alschmut commented 5 years ago

@Richargh this looks awesome! A lot better than a simple key-value table.

Richargh commented 5 years ago

I updated the description :)

  • only show metrics for the selected building

--> yes

  • I am not yet convinced to "duplicate" the treeView though.

Wasn't the intention. I only wanted to show the path to the selected file using the vertical space instead of the horizontal space. Instead of showing the path like this:

/root/de/maibornwolff/codecharta/visualization/app/settings/services/foo/service.spec.ts

we can show it like this:

root
  de.maibornwolff.codecharta.visualization --> compatacted because the folders are empty
   app
      settings
         services
           foo
             service.spec.ts
alschmut commented 5 years ago

@Richargh I couldn't wait to start implementing this issue 😄

Here is a current state of an AttributeSideBar:

Ideas

In single mode: Screenshot 2019-08-25 at 00 36 50

In delta mode: Screenshot 2019-08-26 at 02.05.09.jpg

Richargh commented 5 years ago

@alschmut what happened to #693 and #529 ? Don't you work on these issues as well?

Richargh commented 5 years ago

as for the layout: I like the visuals. It's nicely split up between top and bottom.

Having the primary metrics (inside the upper box) side by side

Hmm. What about placing the symbols with their values side by side but the potentially long metric names under their symbols?

(symbolArea) (valueArea) (deltaArea) (nameOfArea) (symbolHeight) (valueHeight) (deltaHeight) (nameOfHeight)

becomes

(symbolArea) (valueArea) (deltaArea) (symbolHeight) (valueHeight) (deltaHeight)
(nameOfArea) (nameOfHeight)

The left upper cross closes the panel and the right upper external link icon opens the file using the provided weblink

I'm not sure if it's clear it's a link. Does the hover show the url?

The legendPanel is (again) distracting at its current position...

Yes. Can you change the z-Order and place it below the side bar, so we can only see it when the sidebar is closed?

How do we wanna display long file names?

Hadn't thought of that. Is there anything in Angular that helps us here? Changing the font size to fit maybe? Or only show beginning and end of the word?

I have another problem I did not consider before: what about the viewcube? :) It's useful to have even when the sidebar is open and now it's covered.

alexhunziker commented 5 years ago

The legendPanel is (again) distracting at its current position...

How about we just move the viewCube and the legend Panel to the left when the side bar is opened, so that they are not covered. something like that:

sidebar_mockup
alschmut commented 5 years ago

Current status with new screenshots

It might not look like a lot has changed, but it actually did (see above commits).

Ideas

Screenshot 2019-09-12 at 13 07 58 2 Screenshot 2019-09-12 at 13 07 58

alschmut commented 5 years ago

@Richargh What do you think about this draft?

alschmut commented 5 years ago

Thanks a lot for your feedback @Richargh:

I like the 4 quadrants for our four metrics. Nice choice. Can you switch around the grey boxes for the metrics? Suppose the map that is „current“ is codecharta-master. What if we surround that label with a grey box? Then we can surround the metrics for that map also with grey boxes and link the concepts. So instead of the grey box around the deltas we have them around the current values.

I am slightly confused about this. So I guess you want the up-to-date values to be in that grey box and the delta values next by, correct? The label you mention, is actually the source-origin, which gets generated, when using multiple/delta mode (the "cc.json" string is missing at the end). And I would rather not want to set background colors for the filename. Another idea is also to copy or implement a similar solution to what we plan with #696. Using the same light colors grey and red/green as in the map.

Have the details plop in place seems like the right move to me. Otherwise it‘s probably annoying if you click on different buildings a lot.

Sorry, I was writing the wrong word. I actually meant the legendPanel doesn't move in anymore... I quite like the sidebar to move in from the right. Of course the sidebar stays, where it is, when you select another building.

Can you add a label to the link in the top right corner? Something simple like „Link“. Or make it more visible in some other way. Currently it‘s very easy to overlook.

There is a nice tooltip with the exact link showing up when you hover the link icon.

alschmut commented 5 years ago

New current status:

Screenshot 2019-09-14 at 20 09 13 Screenshot 2019-09-14 at 20 09 05

fatihi commented 5 years ago

I would actually prefer if the sidebar closed when a building is not selected. I moved up the bug that keeps the selection when settings are changed and would prefer if both this bug and the other one are released together.

alschmut commented 5 years ago

@fatihi

@NearW and me just fixed the bug on a separate branch. After some new tests are added and a review both are ready to merge.

fatihi commented 5 years ago

Oh that's nice! In that case could you link them together?