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

Contributions matrix gradient lacks contrast #26

Open
cdlm opened this issue May 30, 2024 · 3 comments
Open

Contributions matrix gradient lacks contrast #26

cdlm opened this issue May 30, 2024 · 3 comments

Comments

@cdlm
Copy link

cdlm commented May 30, 2024

At least with the frappe green theme, the contributions matrix looks mostly binary. There is a big jump in contrast between dark gray squares with no commits and green squares with few commits, and then from few to most commits the gradient is quite shallow.

This makes contribution peaks barely distinguishable from baseline days, when they should contrast enough to be picked up preattentively.

@sgoudham
Copy link
Contributor

Hey 👋,

Could you please give a screenshot example of what you mean and if you're comfortable with digging through inspect element, a screenshot with what you expect / are looking for?

@cdlm
Copy link
Author

cdlm commented Sep 19, 2024

Here's a quick screenshot. Most days are 1-3 contributions and the couple darker ones are at ~15, but they are really hard to find (I don't see them preattentively). I'll come back with a mockup or color propositions when I find time.

Screenshot 2024-09-19 at 10 00 52

@cdlm
Copy link
Author

cdlm commented Sep 21, 2024

Ok so if one looks at the bottom-right legend, the colors are, from left/less to right/more:

  • --color-secondary-alpha-6 (low-contrast background gray)
  • --color-primary-light-4 (lighter green)
  • --color-primary-light-2
  • --color-primary
  • --color-primary-dark-2
  • --color-primary-dark-4

I see three problems:

  • The gradient of greens lacks contrast and the few days with above average contributions don't stand out.
  • The gradient is reversed from what it should be: days with less contributions should use more muted, darker greens and days with more contributions should use a flashy lighter green to pop.
  • The colors are named in terms of light/dark values rather than contrast relative to the background. The theme does provides a range of --color-primary-alpha-XX variables which would work, but picking semantically correct colors is the responsibility of Gitea…

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

No branches or pull requests

2 participants