@electrovir/color
Version:
A wrapper for culori with an extremely simple API.
16 lines (15 loc) • 558 B
TypeScript
import { type CSSResult } from 'element-vir';
import { type SingleCssVarDefinition } from 'lit-css-vars';
/**
* A foreground/background color pair.
*
* @category Internal
*/
export type ColorPair = Record<'foreground' | 'background', SingleCssVarDefinition>;
/**
* Creates foreground and background CSS code. The foreground color is applied to the CSS `color`
* property and the background color is applied to the CSS `background-color` property.
*
* @category Color Theme
*/
export declare function colorCss(color: Readonly<ColorPair>): CSSResult;