#030920
L 0.15 · C 0.05 · H 265
Midnight Indigo
Deep, serious indigo tones for high-contrast dark UIs.
- Mood
- Dark
- Colors
- 5
- Space
- OKLCH
Midnight Indigo, color by color
Deep, serious indigo tones for high-contrast dark UIs.
#0d153f
L 0.22 · C 0.08 · H 270
#202268
L 0.3 · C 0.12 · H 275
#3c3695
L 0.4 · C 0.15 · H 280
#6b5ad4
L 0.55 · C 0.18 · H 285
Create Midnight Indigo 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.15 0.05 265)',
'oklch(0.22 0.08 270)',
'oklch(0.30 0.12 275)',
'oklch(0.40 0.15 280)',
'oklch(0.55 0.18 285)',
]);
use PhpColor\Color\Palette\ColorPalette;
$palette = ColorPalette::parse([
'oklch(0.15 0.05 265)',
'oklch(0.22 0.08 270)',
'oklch(0.30 0.12 275)',
'oklch(0.40 0.15 280)',
'oklch(0.55 0.18 285)',
]);
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 Midnight Indigo 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();