@wix/css-property-parser
Version:
A comprehensive TypeScript library for parsing and serializing CSS property values with full MDN specification compliance
42 lines (41 loc) • 2.06 kB
TypeScript
import { BorderIndividualValue } from '../types';
import { BorderWidthPropertyValue } from './shared-border-width';
import { BorderStylePropertyValue } from './shared-border-style';
import { BorderColorPropertyValue } from './shared-border-color';
export type { BorderIndividualValue } from '../types';
/**
* Parse logical border shorthand property value (border-inline-start, border-inline-end)
* Uses the same syntax as individual border shorthand properties
*/
export declare function parseLogicalBorderProperty(value: string): BorderIndividualValue | null;
/**
* Convert logical border shorthand value to CSS string
*/
export declare function logicalBorderToCSSValue(parsed: BorderIndividualValue | null): string | null;
/**
* Parse logical border width property value (border-inline-start-width, border-inline-end-width)
* Uses the same syntax as individual border width properties
*/
export declare function parseLogicalBorderWidthProperty(value: string): BorderWidthPropertyValue | null;
/**
* Convert logical border width value to CSS string
*/
export declare function logicalBorderWidthToCSSValue(parsed: BorderWidthPropertyValue | null): string | null;
/**
* Parse logical border style property value (border-inline-start-style, border-inline-end-style)
* Uses the same syntax as individual border style properties
*/
export declare function parseLogicalBorderStyleProperty(value: string): BorderStylePropertyValue | null;
/**
* Convert logical border style value to CSS string
*/
export declare function logicalBorderStyleToCSSValue(parsed: BorderStylePropertyValue | null): string | null;
/**
* Parse logical border color property value (border-inline-start-color, border-inline-end-color)
* Uses the same syntax as individual border color properties
*/
export declare function parseLogicalBorderColorProperty(value: string): BorderColorPropertyValue | null;
/**
* Convert logical border color value to CSS string
*/
export declare function logicalBorderColorToCSSValue(parsed: BorderColorPropertyValue | null): string | null;