casesandberg / casesandberg/react-color

Wrong Brightness Coefficients

Open
#184 11 comments 0 reactions 0 assignees View on GitHub
bug help wanted
Dominant language
JavaScript
Stars
12.3k
Forks
920
PR merge metrics
No merged PRs in 30d

Description

https://github.com/casesandberg/react-color/blob/master/modules/tinycolor2/index.js#L76

For now there are coefficients for NTSC, not sRGB.
And i think that w3c is little bit outdated.

Also see this demo: http://codepen.io/dom1n1k/pen/LZWjbj

See sRGB table: http://www.brucelindbloom.com/index.html?WorkingSpaceInfo.html
Or point 9 here: http://www.poynton.com/notes/colour_and_gamma/ColorFAQ.html

Contributor guide

Open the contributing guide

Research direction

Start at modules/tinycolor2/index.js#L76 and compare the current brightness coefficients with the linked sRGB references and demo. Confirm which coefficients are appropriate for the intended brightness calculation, then verify that the resulting behavior matches the reported sRGB expectations.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, react
Domain
frontend
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.