import { Context } from '../context'; import { ContextBindingController } from '../ContextBindingController'; import { ContextConsumerController } from '../ContextConsumerController'; /** * Binds CSS variables to a context. */ export declare class ContextCssVarsController extends ContextBindingController { protected _transformers: Map any>; /** * Binds a context to a CSS variable on the current `ref` element. By binds we mean as the * context value changes it will update the given CSS custom property on the current `ref` * element. * * @param context The context to bind to. * @param varName The name of the CSS custom property to bind the context to. This is will * result in `--${varName}`. * @param transformer An optional transformer to transform the context value before it is * stringified and applied as the CSS custom property value. Returning `null` or `undefined` * will remove the custom property. */ bind(context: Context, varName: string, transformer?: (value: T) => any): this; protected _handleBindToContext(): void; protected _handleBindingUpdate(consumer: ContextConsumerController, varName: string): void; protected _handleUnbindFromContext(_: ContextConsumerController, varName: string): void; /** * Override to transform CSS variable names. */ protected _transformVarName(varName: string): string; /** * Override to transform context values to be used as CSS property values. Returning `null` * or `undefined` will remove the CSS property. This is provided as the default transformer when * one isn't provided in the `bind()` method call.. */ protected _transformVarValue(varName: string, value: unknown): any; }