UNPKG

@wix/css-property-parser

Version:

A comprehensive TypeScript library for parsing and serializing CSS property values with full MDN specification compliance

18 lines (17 loc) 775 B
import { CSSLengthValue, BorderWidthKeywordValue, CSSVariableValue } from '../types'; export type BorderWidthPropertyValue = CSSLengthValue | BorderWidthKeywordValue | CSSVariableValue | null; /** * Parse a border width property value (length or keyword) * Accepts non-negative lengths and border width keywords * * @param value - CSS border width value string * @returns Parsed border width value or null if invalid */ export declare function parseBorderWidthProperty(value: string): BorderWidthPropertyValue; /** * Convert border width value back to CSS string * * @param parsed - Parsed border width value * @returns CSS string representation or null if invalid */ export declare function borderWidthToCSSValue(parsed: BorderWidthPropertyValue): string | null;