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

Add ability to generate random themes #19

Open
paracycle opened this issue Mar 31, 2015 · 2 comments
Open

Add ability to generate random themes #19

paracycle opened this issue Mar 31, 2015 · 2 comments

Comments

@paracycle
Copy link
Owner

There should be a way to generate random themes that would be pleasing to the eye. Don't know enough about harmonious colors and color theory to pull it off though. Any thoughts @atesgoral?

@atesgoral
Copy link
Collaborator

It wouldn't be too hard to add a "randomize" button to:

  1. Randomly pick a base HSV colour (I'd normalize all components to [0-1) for cleaner computation)
  2. Randomly pick a colour scheme, or use a fixed scheme
  3. Pick the complementary colours based on the scheme - e.g. just offset the initial hue by 1/3, 1/2 etc.
  4. Use luminance computation to pick light/dark text (see what we did for the RelayRobin theme customizer) -- this might be the trickiest part to keep the text readable
  5. Go from HSV to RGB

Some inspiration:

http://paletton.com/
http://app.coolors.co/
https://color.adobe.com/create/color-wheel/
http://www.perbang.dk/color+scheme/

I can jsfiddle around with this when I have the time...

@atesgoral
Copy link
Collaborator

Could use https://github.com/avp/spectra

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