![screenshot](https://private-user-images.githubusercontent.com/7013023/390449719-7d809284-3c2b-48ed-a558-ed1c7cc41dd5.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mzc1MjU4MTIsIm5iZiI6MTczNzUyNTUxMiwicGF0aCI6Ii83MDEzMDIzLzM5MDQ0OTcxOS03ZDgwOTI4NC0zYzJiLTQ4ZWQtYTU1OC1lZDFjN2NjNDFkZDUucG5nP1gtQW16LUFsZ29yaXRobT1BV1M0LUhNQUMtU0hBMjU2JlgtQW16LUNyZWRlbnRpYWw9QUtJQVZDT0RZTFNBNTNQUUs0WkElMkYyMDI1MDEyMiUyRnVzLWVhc3QtMSUyRnMzJTJGYXdzNF9yZXF1ZXN0JlgtQW16LURhdGU9MjAyNTAxMjJUMDU1ODMyWiZYLUFtei1FeHBpcmVzPTMwMCZYLUFtei1TaWduYXR1cmU9Mzk3MDNjYzI5MTUwN2ZiM2Y3MGJlYTE0ZjQ1ZDQ3NTA0ZDY2OTMzNTZiOTNlNzNkZmNmNWNmYTM1YjhmMGI5NiZYLUFtei1TaWduZWRIZWFkZXJzPWhvc3QifQ.1gxyesMbuo4gmw8_uw6Z94Bdrg7oa0kp9cuPbHoS94w)
Try the web demo: https://oklch.eerolehtinen.fi/
NOTE: This is an application, even though crates.io detects it as a library. The "library" part only exposes lua bindings for color parsing in Neovim.
- Takes an input color as a cli argument and ouputs the edited color to stdout
- Uses a perceptual colorspace (Oklch) to allow intuitive editing
- Consists of lightness, chroma and hue
- Motivation: An article by the Oklab creator
- Oklch uses the same theory as Oklab, but uses parameters that are easier to understand
- Lr estimate is used instead of L as specified in another article by the same guy
- Supports many color formats for input and output (editing uses only Oklch):
- Hex (
#RGB
,#RGBA
,#RRGGBB
,#RRGGBBAA
) - Other common CSS formats (
rgb(..)
,hsl(..)
,oklch(..)
) - Hex literal (
0xRRGGBB
,0xAARRGGBB
) - Any list of 3 or 4 numbers can be used as a color (e.g.
0.5, 0.5, 0.5
or120, 120, 120, 255
)
- Hex (
- Hardware accelerated for maximum smoothness and high resolutions
Download from Releases.
If you have cargo, you can also install with:
cargo install oklch-color-picker --locked
Check out the neovim plugin that this picker was made for eero-lehtinen/oklch-color-picker.nvim.
Inspired by https://oklch.com/.