@wix/css-property-parser
Version:
A comprehensive TypeScript library for parsing and serializing CSS property values with full MDN specification compliance
15 lines (14 loc) • 547 B
TypeScript
import { Length, LengthValue } from '../types';
/**
* Parses a CSS length value into structured components
* @param value - The CSS length value string
* @returns Parsed length object or null if invalid
*/
export declare function parse(value: string): LengthValue | null;
/**
* Converts a parsed length back to a CSS value string
* @param parsed - The parsed length object
* @returns CSS value string or null if invalid
*/
export declare function toCSSValue(parsed: LengthValue | null): string | null;
export type { Length, LengthValue };