apache / apache/echarts

[Bug] color parse() does not understand new spec rgb and hsl colors

Open
#19,604 4 comments 1 reaction 0 assignees View on GitHub
en new-feature pending
Dominant language
TypeScript
Stars
67.3k
Forks
19.8k
Avg merge
11d 14h
Merged PRs (30d)
8

Description

### Version

5.4.3

### Link to Minimal Reproduction

NA

### Steps to Reproduce

I have a bar chart with gradient fill of colors using the new w3c standard for hsl, a la., `hsl(229deg 73% 50%)` When I hover my chart the tooltip animation code tries to parse these colors for the keyframes and throws because the color.parse function does not understand this color format and is returning undefined where a color is expected by the keyframe anim code.

### Current Behavior

color.parse('hsl(0deg 100% 100%)`) returns undefined

### Expected Behavior

color.parse('hsl(0deg 100% 100%)`) returns some valid color value.

### Environment

```markdown
- OS: NA
- Browser: NA
- Framework: NA
```

### Any additional comments?

_No response_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.