import { type TemplateResult, type nothing } from 'lit';
export declare enum RenderingState {
    Idle = 0,
    Rendering = 1
}
/**
 * A class that manages rendering of the application screen.
 */
export declare abstract class Renderer {
    #private;
    /**
     * The root element where the activity or fragment will be rendered.
     */
    renderRoot: HTMLElement | null;
    /**
     * @type A promise resolved when the render finished.
     */
    get updateComplete(): Promise<void> | undefined;
    /**
     * Sets the root element where the application or activity will be rendered.
     *
     * @param renderRoot - The root element or a CSS selector string for the element.
     * If a string is provided, it will be queried from the document.
     */
    setRenderRoot(renderRoot: HTMLElement | string): void;
    /**
     * Requests an update of the UI. Schedules a render if one is not already pending.
     *
     * This will call the `renderer()` method and update the DOM in the next animation frame.
     * Ensures only one render is scheduled at a time.
     */
    requestUpdate(): void;
    protected firstRenderedFlag: boolean;
    /**
     * Indicates whether the initial render has occurred and `onFirstRender()` was called.
     */
    get firstRendered(): boolean;
    /**
     * Returns the current rendering state.
     *
     * @returns The current rendering state.
     */
    get state(): RenderingState;
    /**
     * Abstract method that must be implemented by subclasses to perform the actual rendering logic.
     *
     * Called by `requestUpdate()` when a render is scheduled.
     */
    protected abstract renderer(): void;
    /**
     * Resolves the update promise if one is pending, indicating that rendering has finished.
     */
    protected resolveUpdatePromise(): void;
    /**
     * Renders the given Lit template into the specified root element, setting the host context.
     *
     * @param content - The Lit template or `nothing` to render.
     * @param root - The root HTMLElement to render into.
     * @param host - The host object for Lit's context (usually the Application or Activity).
     */
    protected _render(content: TemplateResult | typeof nothing, root: HTMLElement, host: object): void;
    /**
     * Removes all child nodes from the given root element.
     *
     * Uses `replaceChildren()` for efficient DOM cleanup.
     * @param root - The root HTMLElement to clear.
     */
    protected _clearRoot(root: HTMLElement): void;
}
//# sourceMappingURL=Renderer.d.ts.map