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

return complement of black and white #117

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

return complement of black and white #117

wants to merge 2 commits into from

Conversation

khisakuni
Copy link

complement method returns white as the complement of black, and black as the complement of white.

@bgrins
Copy link
Owner

bgrins commented Dec 22, 2015

I'm not sure how this should be defined with grayscale colors. Special casing white/black would still leave the same issue with something like:

tinycolor("rgb(1,1,1)").complement().toRgbString(); // "rgb(1, 1, 1)"

@khisakuni
Copy link
Author

@bgrins Maybe the greyscale colors could have their lightness inverted too. For example if we have something like tinycolor({ h: 0, s: 0, l: .3 });, we would make that tinycolor({ h: 0, s: 0, l: .7 });

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

Successfully merging this pull request may close these issues.

2 participants