/** * Performance lint matcher: is a declaration reading a --sv-* value (direct * or through one level of custom-property indirection) into a property that * cannot be composited? Pure, so it is unit-testable without a browser; the * runtime scanner in index.ts walks the real CSSOM and calls lintDeclaration * per rule. */ export declare const NON_COMPOSITABLE: Set; export declare function stripComments(css: string): string; export interface LintViolation { selector: string; property: string; reason: string; } /** customProps: declared-name -> every distinct value seen for it, for * one-level indirection (`top: var(--x); --x: var(--sv-t)`). A name can have * more than one candidate value (the caller resolves same-rule declarations * unambiguously; a name declared in more than one rule, without a real * cascade, can only be "one of these"), so every candidate is checked: any * of them reading a --sv-* value is enough to flag the declaration, rather * than picking whichever a plain last-write-wins map happened to keep. * Resolution stops after a few hops to stay cheap and never loop on a * self-referencing custom property. */ export declare function lintDeclaration(selector: string, property: string, value: string, customProps?: Map): LintViolation | null; /** Naive selector { decls } extraction for unit tests: not a CSS parser, * good enough for fixture text (no nested @media). The runtime scanner in * overlay.ts's scanStylesheets() uses the real CSSOM the same way: a name * declared and consumed inside the SAME rule resolves to that rule's own * value regardless of stylesheet order; a name declared elsewhere falls * back to every distinct value seen for it anywhere (ADU review: a global * last-write-wins map missed a same-rule violation depending on the order * two unrelated rules happened to declare the same custom property name). */ export declare function scanCssText(cssText: string): LintViolation[];