# parseColor (@salmonui/export/graphics)

> The parseColor function of @salmonui/export/graphics: Parses a CSS color as browsers serialize computed values (hex, rgb(), hsl(), oklch(), oklab(), color(srgb ...), a few names); null for none, transparent and anything unknown.

Canonical: https://salmonui.dev/docs/reference/export/graphics/parseColor

```ts
import { parseColor } from '@salmonui/export/graphics';
```

Entry index: https://salmonui.dev/docs/reference/export/graphics (Markdown with every symbol of the entry: https://salmonui.dev/docs/reference/export/graphics.md).

## Reference

Kind: function

```ts
function parseColor(input: string | undefined): Rgba | null;
```

Parses a CSS color as browsers serialize computed values (hex, `rgb()`,
`hsl()`, `oklch()`, `oklab()`, `color(srgb ...)`, a few names); null for
`none`, `transparent` and anything unknown.
