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

systemd: improve graphs layout and color #10282

Merged
merged 1 commit into from
Oct 31, 2018

Conversation

garrett
Copy link
Member

@garrett garrett commented Oct 11, 2018

No description provided.

@garrett garrett added the blocked Don't land until something else happens first (see task list) label Oct 11, 2018
@garrett
Copy link
Member Author

garrett commented Oct 11, 2018

Currently depends on #10101

@garrett
Copy link
Member Author

garrett commented Oct 11, 2018

TODO

@garrett garrett self-assigned this Oct 11, 2018
@garrett
Copy link
Member Author

garrett commented Oct 11, 2018

On IRC, @Gundersanne mentioned opacity probably being related to color in host.js:1571/2. The colors may need to be specified in rgba() or hex+alpha.

@garrett garrett force-pushed the graphs-layout-and-color branch from 7d81cd6 to df46dbd Compare October 17, 2018 12:53
@croissanne
Copy link
Contributor

What the fill changes look like on the detailed graphs:

image

@garrett
Copy link
Member Author

garrett commented Oct 17, 2018

Thanks for the screenshot!

I need to select new colors for the CPU chart. I think I rounded existing ones into PatternFly equivalents... but in the CSS only. I'll need to modify the JS too.

It is probably worth figuring out different colors that work well with all forms of colorblindness too. (I hand-picked PF colors for the memory mockups specifically for this. Perhaps I should re-use those for this?)

@croissanne croissanne force-pushed the graphs-layout-and-color branch from df46dbd to eaf2e28 Compare October 17, 2018 13:58
@croissanne
Copy link
Contributor

@garrett Just pushed the fill changes (and added a closes).

Feel free to change the colours still.

@garrett garrett force-pushed the graphs-layout-and-color branch from 0d52ab0 to 32c3ee4 Compare October 24, 2018 08:45
@croissanne croissanne added needs-rebase and removed blocked Don't land until something else happens first (see task list) labels Oct 26, 2018
@garrett garrett force-pushed the graphs-layout-and-color branch from 32c3ee4 to 14e0702 Compare October 29, 2018 09:01
@croissanne
Copy link
Contributor

some screenshots:

image

image

@garrett
Copy link
Member Author

garrett commented Oct 29, 2018

@Gundersanne: Thanks!

Oh, odd. I see the horizontal & vertical lines in the details graph here — but I'm not using the patched version of Cockpit (can't get it to compile no matter what today), so the memory reporting is quite a bit off.

screenshot_2018-10-29 system - sunny

However, graphs in overview don't show the lines here:

screenshot_2018-10-29 system - sunny 1

I wonder if there's some CSS we can apply to ensure that lines are above the graph. Probably z-index related.

@garrett
Copy link
Member Author

garrett commented Oct 29, 2018

Ah, the flot sandwich doesn't have a separate layer for the grid lines, just for the text and an invisible "overlay" layer (which I wrongly assumed was the lines). All the chart magic happens in .flot-base, so this would need JavaScript changes.

Oddly, it works as expected on my machine in the memory & CPU overview.

@martinpitt martinpitt added the release-blocker Targetted for next release label Oct 31, 2018
@martinpitt martinpitt requested a review from croissanne October 31, 2018 08:17
@martinpitt
Copy link
Member

This should go into the same release as @Gundersanne's original rework, so marking priority.

croissanne
croissanne previously approved these changes Oct 31, 2018
Copy link
Contributor

@croissanne croissanne left a comment

Choose a reason for hiding this comment

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

Looks good to me, but should we squash these commits?

@garrett
Copy link
Member Author

garrett commented Oct 31, 2018

@Gundersanne yeah, these commits should be squashed before / during merging — they're all related to improving the color & layout of the graphs

@garrett
Copy link
Member Author

garrett commented Oct 31, 2018

Squashed & rebased.

Copy link
Contributor

@croissanne croissanne left a comment

Choose a reason for hiding this comment

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

LGTM

@mvollmer
Copy link
Member

Tests were green enough before the rebase, I'll merge this.

@mvollmer mvollmer merged commit b8bb861 into cockpit-project:master Oct 31, 2018
@croissanne
Copy link
Contributor

Screenshots:
CPU:
image

Memory:
image

Overview:
image

@testman42
Copy link

Would it be possible to allow users to set custom colours?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release-blocker Targetted for next release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants