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

Rgb #53

Merged
merged 9 commits into from Dec 17, 2016
Merged

Rgb #53

merged 9 commits into from Dec 17, 2016

Conversation

nikgraf
Copy link
Member

@nikgraf nikgraf commented Dec 15, 2016

The one thing missing is to reduce the hex values e.g. #ffffff to #fff. I will add this sometime later.

@codecov-io
Copy link

codecov-io commented Dec 15, 2016

Current coverage is 100% (diff: 100%)

Merging #53 into master will not change coverage

@@           master   #53   diff @@
===================================
  Files          18    21     +3   
  Lines          73    84    +11   
  Methods         0     0          
  Messages        0     0          
  Branches        0     0          
===================================
+ Hits           73    84    +11   
  Misses          0     0          
  Partials        0     0          

Powered by Codecov. Last update c800b90...b69fc1d


function toHex(value) {
const hex = value.toString(16)
return hex.length === 1 ? `0${hex}` : hex
Copy link
Member

Choose a reason for hiding this comment

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

When is hex ever just one character and why do we prefix 0 in that case?

Copy link
Member Author

Choose a reason for hiding this comment

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

If you create the hex of 0 it will be '0'. The issue here at hand is that only of 3 parts of a hex color can be reduced only then it should be. Otherwise two characters e.g. prefixed with a 0 are required.

@mxstbr
Copy link
Member

mxstbr commented Dec 15, 2016

Looks amazing, just the short hex notations and then let's 🚢

Copy link
Member

@mxstbr mxstbr left a comment

Choose a reason for hiding this comment

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

Can you add a new heading called "Color" below mixins and add this util to .documentation.json into the ToC and rebuild the docs? Then we can ship this!

@mxstbr mxstbr merged commit f8ee951 into master Dec 17, 2016
@mxstbr mxstbr deleted the rgb branch December 17, 2016 18:23
@bhough
Copy link
Contributor

bhough commented Dec 17, 2016

Great to see the color portion of this underway, thanks for the contribution @nikgraf!

@mxstbr mxstbr mentioned this pull request Dec 17, 2016
50 tasks
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.

None yet

4 participants