Skip to content

Conversation

sebastianwd
Copy link

Fixes #3058

oklch() is a new way to define CSS colors. In oklch(L C H) or oklch(L C H / a), each item corresponds as follows:

L is perceived lightness (0-1). “Perceived” means that it has consistent lightness for our eyes, unlike L in hsl().
C is chroma, from gray to the most saturated color.
H is the hue angle (0-360).
a is opacity (0-1 or 0-100%).

It's the default color format for the TailwindCSS v4 and shadcn themes.

Added a oklch to rgba converter based on the implementation in the culori library

@sebastianwd sebastianwd marked this pull request as ready for review August 18, 2025 02:25
@sebastianwd
Copy link
Author

Tests pass locally, not sure what's wrong with ci.
image

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.

[BUG] animation fails when transitioning between oklch and hex color formats
1 participant