stoop
Version:
CSS-in-JS library with type inference, theme creation, and variants support.
20 lines (19 loc) • 988 B
TypeScript
/**
* CSS compilation engine.
* Converts CSS objects to CSS strings and generates unique class names.
* Handles nested selectors, media queries, styled component targeting, and theme tokens.
*/
import type { CSS, Theme, ThemeScale, UtilityFunction } from "../types";
/**
* Compiles CSS objects into CSS strings and generates unique class names.
* Handles nested selectors, media queries, styled component targeting, and theme tokens.
*
* @param styles - CSS object to compile
* @param currentTheme - Theme for token resolution
* @param prefix - Optional prefix for generated class names
* @param media - Optional media query breakpoints
* @param utils - Optional utility functions
* @param themeMap - Optional theme scale mappings
* @returns Generated class name
*/
export declare function compileCSS(styles: CSS, currentTheme: Theme, prefix?: string, media?: Record<string, string>, utils?: Record<string, UtilityFunction>, themeMap?: Record<string, ThemeScale>): string;