Citrus

Zesty yellows, oranges, and a single cold-green punch.

Mood
Vivid
Colors
5
Space
OKLCH

Citrus, color by color

Zesty yellows, oranges, and a single cold-green punch.

#ffed5f L 0.94 · C 0.16 · H 100
#ffc600 L 0.86 · C 0.22 · H 90
#ff9100 L 0.78 · C 0.24 · H 70
#ff6600 L 0.7 · C 0.22 · H 50
#19c63c L 0.72 · C 0.22 · H 145

Create Citrus in PHP

Parse the catalog values as one ordered scale. The input remains readable while PHPColor normalizes every color.

<?php

use PhpColor\Color\Palette\ColorPalette;

$palette = ColorPalette::parse([
    'oklch(0.94 0.16 100)',
    'oklch(0.86 0.22 90)',
    'oklch(0.78 0.24 70)',
    'oklch(0.70 0.22 50)',
    'oklch(0.72 0.22 145)',
]);
use PhpColor\Color\Palette\ColorPalette; $palette = ColorPalette::parse([ 'oklch(0.94 0.16 100)', 'oklch(0.86 0.22 90)', 'oklch(0.78 0.24 70)', 'oklch(0.70 0.22 50)', 'oklch(0.72 0.22 145)', ]);

Inspect every palette color

Palette operations preserve order, so iteration and conversion produce values in the same visual sequence.

<?php

foreach ($palette->to('oklch') as $color) {
    echo $color->toCss().PHP_EOL;
}
foreach ($palette->to('oklch') as $color) { echo $color->toCss().PHP_EOL; }

Format Citrus for CSS

Export hexadecimal values for compact tokens or convert the full palette to perceptual CSS notation.

<?php

$hex = $palette->toHex();
$css = $palette->to('oklch')->toCss();
$hex = $palette->toHex(); $css = $palette->to('oklch')->toCss();