/** * A single entry in the `classes()` array or values in a class map. * * Accepts strings and the falsy values that fall out of JS conditional * expressions — no pre-filtering needed at the call site. * * Also accepts tuples for conditional application: * [true, "btn"] — apply "btn" if true * [false, "btn"] — don't apply "btn" if false * [condition, "a", "b"] — apply "a" if condition, else "b" * * ```ts * html`
` * ``` * * `0` is included so that numeric short-circuit expressions (`count && "cls"`) * compile without a cast when `count` is zero. */ export type ClassEntry = string | false | null | undefined | 0 | [boolean, string] | [boolean, string, string]; export type ClassesInput = string | ClassEntry[] | Record; /** * Apply a dynamic list of class names to an element. * * Used as an **element directive**: * * ```ts * html`
` * ``` * * Falsy values (`false`, `null`, `undefined`) are silently ignored, so * inline JS conditions work without any manual filtering: * * ```ts * html`
` * ``` * * Also supports conditional and ternary tuples for cleaner syntax: * * ```ts * html`
` * ``` * * Or an object map for class name mapping: * * ```ts * html`
` * ``` * * Stale classes are removed automatically on every re-render. All managed * classes are cleaned up when the element disconnects from the DOM. * * @param names - Array of class entries or object map of classes. * - Array elements can be: * - Strings (applied as-is) * - Falsy values (silently ignored) * - `[condition, "class"]` (apply class if condition is truthy) * - `[condition, "classA", "classB"]` (apply classA if true, else classB) * - Object keys are applied if their values are truthy. */ export declare function classes(names: ClassesInput): import("lit-html/directive").DirectiveResult; /** No-op — kept for backwards compatibility. */ export declare function removeClasses(_el: Element): void; //# sourceMappingURL=classesDirective.d.ts.map