import { LitElement, PropertyValues } from 'lit'; import { ContextConsumer } from '@lit/context'; import { WeavyType } from '../contexts/weavy-context'; import { UserType } from '../types/users.types'; import { ContextIdType } from '../contexts/context-id-context'; import { WeavyComponentActionProps, WeavyComponentContextProps } from '../types/component.types'; import { WyActionEventDetailType } from '../types/action.events'; /** * Base class for exposed/public weavy components. This class provides common external properties and internal data provided as contexts for sub components. * * @fires ready - When the component has rendered. */ export declare class WeavyComponent extends LitElement implements WeavyComponentContextProps, WeavyComponentActionProps { #private; /** @internal */ protected weavyContextConsumer?: ContextConsumer<{ __context__: WeavyType; }, this>; /** * The consumed weavy context. */ weavy: WeavyType | undefined; /** * Contextual guid that is unique for the client context. * * @type {ContextIdType} */ contextId: ContextIdType; /** * The current user. * * @type {UserType | undefined} */ user: UserType | undefined; /** * Resolves when a contextual id is available. * * @internal * @returns {Promise} */ whenContextId(): Promise; /** * Resolves when current user data is available. * * @returns {Promise} */ whenUser(): Promise; /** * Resolves when a weavy context is available. * * @returns {Promise} */ whenWeavy(): Promise; /** * Resolves when the component has rendered first time. * * @returns {Promise} */ whenReady(): Promise; /** * Dispatch a `wy-action` event on the component. * * @fires {WyActionEventType} wy-action - Emitted when an action takes place. */ dispatchAction(detail: WyActionEventDetailType): boolean; connectedCallback(): void; protected scheduleUpdate(): Promise; protected willUpdate(changedProperties: PropertyValues): Promise; protected firstUpdated(changedProperties: PropertyValues): void; } //# sourceMappingURL=weavy-component.d.ts.map