Skip to content

feature:(#305) Add support for oklab and oklch color functions#436

Merged
aeschli merged 2 commits into
microsoft:mainfrom
rgant:add-css-color-4-oklab-oklch
May 7, 2025
Merged

feature:(#305) Add support for oklab and oklch color functions#436
aeschli merged 2 commits into
microsoft:mainfrom
rgant:add-css-color-4-oklab-oklch

Conversation

@rgant

@rgant rgant commented Apr 24, 2025

Copy link
Copy Markdown
Contributor

RESOLVES:
feature - Add new CSS color functions [#305]

DESCRIPTION:
CSS Color Module Level 4 adds support for oklch and oklab to browsers. They are becoming more popular, and I wanted to use them with color previews in my editor.

This feature is built off of the original #306 which included steps for lab and lch but not the ok variants.

Generally this code was designed using real world color examples.

STEPS TO TEST:

Tests were added to relevant files following established patterns. Should be able to just run npm run test. However I don't use vscode, so I did not test in an actual editor.

rgant added 2 commits April 24, 2025 15:46
…ctions

__RESOLVES:__
_feature_ - *Add new CSS color functions* \[[microsoft#305](https://github.com/microsoft/vscode-css-languageservice/issues/305)\]

__DESCRIPTION:__
CSS Color Module Level 4 adds support for `oklch` and `oklab` to browsers. They are becoming more popular, and I wanted to use them with color previews in my editor.

This feature is built of of the original [microsoft#306](microsoft#306) which included steps for `lab` and `lch` but not the `ok` variants.

Generally this code was designed using real world color [examples](https://www.oddcontrast.com/#hex__*f00__*4d216f80__srgb).

__STEPS TO TEST:__
@rgant

rgant commented May 5, 2025

Copy link
Copy Markdown
Contributor Author

Any questions or concerns? Anything I can do to help move this along?

@aeschli

aeschli commented May 7, 2025

Copy link
Copy Markdown
Collaborator

@rgant Looks good, thanks a lot!

@vs-code-engineering vs-code-engineering Bot added this to the May 2025 milestone May 7, 2025
Comment thread src/languageFacts/colors.ts
@aeschli aeschli merged commit b947bea into microsoft:main May 7, 2025
@rgant rgant deleted the add-css-color-4-oklab-oklch branch May 7, 2025 15:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

3 participants