[Feat] CSS color support
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 14.6k
- Forks
- 2.3k
- Avg merge
- 2d 9h
- Merged PRs (30d)
- 42
Description
Target Use Case
The fillColor in deck.gl uses alpha values between 0 and 255 while W3C uses 0 and 1.
It would be great to use 0 and 1 since this is in use in CSS.
Also support for hex color strings #ffffff and rgbaString rgba(255, 255, 255, 1) as well as color name strings 'black' would be great.
https://www.w3schools.com/css/css_colors_rgb.asp
This would also ensure compatibility to librarys like colormap.
Proposal
let attributes = {
getColor: 'black',
getFillColor: 'rgb(100, 0, 0)',
}
or
let attributes = {
getColor: '#000000',
getFillColor: 'rgba(0, 100, 0, 0.5)',
}
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating deck.gl's handling of fillColor and getColor attributes, then compare the current accepted values with the CSS color forms listed in the issue. Done means the proposed hex, rgb/rgba, and named-color examples work while preserving the requested alpha behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- css, typescript
- Domain
- data-visualization, frontend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100