import { ReactiveController, ReactiveControllerHost } from 'lit'; import { Context, ContextType } from '@lit/context'; import { ContextConsumer } from '../utils/context/controllers/context-consumer'; /** * Support controller to consume a context. * Can be used to bridge the context consumer to external frameworks such as React. */ export declare class ContextController> implements ReactiveController { private host; private resolveContext?; private resolveRef?; private _ref?; /** * The DOM connected element that can subscribe to a context */ get ref(): HTMLElement | undefined; set ref(ref: HTMLElement | undefined); /** * Set the DOM connected element that can subscribe to a context. * Wrapper function for React linting compatibility. */ setRef(refElement?: HTMLElement): void; /** * Promise that resolves when a ref element is set. * @resolves The ref element. */ whenRef: Promise; /** * The context consumer. Use `context.value` to get the value of the consumed context. */ context?: ContextConsumer; /** * Promise that resolves when the context is consumed. * @resolves The value of the consumed context. */ whenContext?: Promise>; /** * @param host - The host element * @param context - The Context to use. Should be constructed using createContext(). */ constructor(host: ReactiveControllerHost, context: TContext, ref?: HTMLElement); private setContext; hostUpdate(): void; } //# sourceMappingURL=context-controller.d.ts.map