/** * The CSS a `look:` value lowers to: the condition terms a Look condition * decomposes into, the token that names one lowered rule, and the selector, * media query and declaration that rule is written as. * * D115 P4 R3d: these are pure functions over the Look AST and the module's * static values — no emitter state reaches them — so both `emit/look.ts` (the * stylesheet) and `emit/jsx.ts` (an inline `look:` attribute) read the same * lowering rather than two spellings of it. */ import type { Expression } from "@velarscript/compiler/extension"; import { type LookStaticValue } from "../look-static.ts"; export interface LookStaticAtom { readonly kind: "hook" | "media" | "scheme" | "motion"; readonly name: string; readonly operator?: "<" | "<=" | ">" | ">="; readonly value?: string; readonly negated: boolean; } export interface LookRuntimeAtom { readonly expression: Expression; readonly negated: boolean; } export interface LookConditionTerm { readonly staticAtoms: readonly LookStaticAtom[]; readonly runtimeAtoms: readonly LookRuntimeAtom[]; } export interface LookRule { readonly token: string; readonly property: string; readonly target: string; readonly staticAtoms: readonly LookStaticAtom[]; /** Declaration order of the token's first appearance, the last tie-break. */ readonly sequence: number; } export declare const EMPTY_LOOK_TERM: LookConditionTerm; export declare function lookConditionTerms(expression: Expression, negated?: boolean, staticValues?: ReadonlyMap): readonly LookConditionTerm[]; export declare function combineLookTerms(left: readonly LookConditionTerm[], right: readonly LookConditionTerm[]): readonly LookConditionTerm[]; export declare function lookToken(atoms: readonly LookStaticAtom[], target: string, property: string): string; export declare function lookConditionDepth(atoms: readonly LookStaticAtom[]): number; export declare function lookDeclaration(token: string, property: string): string; export declare function lookMediaQuery(atom: LookStaticAtom): string; export declare function lookSelectors(base: string, atoms: readonly LookStaticAtom[], target: string): readonly string[]; //# sourceMappingURL=look-css.d.ts.map