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

feat(css): Add missing css color() function #858

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

skyclouds2001
Copy link
Contributor

@skyclouds2001 skyclouds2001 commented Dec 26, 2024

Description

this feature is supported in all major platform per bcd

some test log in chromium:

CSS.supports('color','color(from hsl(0 100% 50%) xyz calc(x - 0.3) calc(y + 0.3) calc(z + 0.3) / calc(alpha - 0.1))')
true
CSS.supports('color','color(from hsl(0 100% 50%) srgb calc(r - 0.4) calc(g + 0.1) calc(b + 0.6) / calc(alpha - 0.1))')
true
CSS.supports('color','color(from hsl(0 100% 50%) srgb calc(r - 0.4) calc(g + 0.1) calc(b + 0.6) / none)')
true
CSS.supports('color','color(display-p3 0.3804 0.9921 0.1412)')
true

Motivation

Additional details

https://developer.mozilla.org/en-US/docs/Web/CSS/color_value/color
https://drafts.csswg.org/css-color-5/#funcdef-color
https://drafts.csswg.org/css-color/#funcdef-color

Related issues and pull requests

reported in #819

since this is the last case that not done in #819, so closes #819

@skyclouds2001 skyclouds2001 marked this pull request as ready for review December 26, 2024 07:49
@skyclouds2001 skyclouds2001 requested a review from a team as a code owner December 26, 2024 07:49
@skyclouds2001 skyclouds2001 requested review from bsmth and removed request for a team December 26, 2024 07:49
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.

Missed syntaxes in 2.13.0
1 participant