import { WebbitConnector, WebbitConfig } from '@webbitjs/webbit'; import { Store, SourceProvider } from '@webbitjs/store'; declare type ComponentRenderer = (params: { dashboard: Dashboard; element: HTMLElement; config: Record; }) => (() => void) | undefined; interface DashboardComponent { type: string; id: string; mount: ComponentRenderer; } export default class Dashboard { private store; private connector; private components; private mountedElements; private subscribers; private componentKeys; private dashboardState; private provider; constructor(rootElement?: HTMLElement); addSourceProvider(providerName: string, sourceProvider: SourceProvider): void; setDefaultSourceProvider(providerName: string): void; setStoreValue(key: string, value: unknown): void; getStoreValue(key: string, defaultValue?: unknown): unknown; getConnector(): WebbitConnector; getRootElement(): HTMLElement; getStore(): Store; addComponent(component: DashboardComponent): void; hasComponent(type: string, id: string): boolean; getComponentIdsOfType(type: string): string[]; create(componentType: string, componentId: string, config?: Record): HTMLElement | undefined; /** * Unmounts the mounted component from a particular element * @param {HTMLElement} element */ unmount(element: HTMLElement): void; /** * * @returns {() => void} A function to unsubscribe */ subscribe(subscriberId: string, subscriber: (...args: unknown[]) => unknown): () => void; /** * * @param {string} subscriberId * @param {unknown} context */ publish(subscriberId: string, context?: Record): void; addElements(elementConfigs?: Record>, group?: string): void; getHtml(): string; setHtml(html: string): void; getElementDisplayName(element: HTMLElement): string; getSelectorDisplayName(selector: string): string; getElementHtml(element: HTMLElement, inner?: boolean): string; private setClonedElementPropAttributes; } export {};