/** * Theme token model. * * A theme is typed data, never CSS. Every token is declared here with its kind * and its bounds, so a preset — built-in or user-authored — can only set values * the compiler knows how to validate. There is deliberately no token kind that * accepts a free-form declaration, which is what makes "no CSS escape hatch" a * property of the type system rather than a promise. */ export type TokenKind = 'color' | 'length' | 'font-stack' | 'elevation' | 'easing' | 'enum' | 'number'; export interface TokenSpec { kind: TokenKind; group: string; description: string; /** Allowed values for `enum` tokens. */ values?: readonly string[]; min?: number; max?: number; } export declare const TOKEN_SPECS: Readonly>; export type Tokens = Record; /** Long-form descriptions keyed by token name, for `describe()`-style surfaces. */ export declare function tokenNames(): string[]; /** True when a font stack cannot escape a CSS declaration. */ export declare function isSafeFontStack(value: string): boolean; export interface TokenProblem { token: string; message: string; } /** Validate one token value against its declared kind. */ export declare function validateTokenValue(token: string, value: unknown): TokenProblem | undefined; /** Validate a partial token set, returning every problem found. */ export declare function validateTokens(tokens: Record): TokenProblem[]; /** Resolve a token to its CSS value, mapping symbolic tokens to fixed values. */ export declare function tokenCssValue(token: string, value: string): string; /** The CSS custom property name for a token. */ export declare function tokenVariable(token: string): string; //# sourceMappingURL=tokens.d.ts.map