/** * @packageDocumentation This package provides a Semantic UI theme that fits to * the default Element theme. */ import { BackendModule } from 'i18next'; import { Capability } from 'matrix-widget-api'; import LanguageDetector from 'i18next-browser-languagedetector'; import { PropsWithChildren } from 'react'; import { ReactElement } from 'react'; import { WidgetApi } from '@matrix-widget-toolkit/api'; import { WidgetEventCapability } from 'matrix-widget-api'; import { WidgetRegistration } from '@matrix-widget-toolkit/api'; /** * A guard that ask the user for capabilities and only shows the `children` * if all capabilities were accepted. * If capabilities are denined, a message and a button to retry is displayed * instead. * @param param0 - {@link SemanticUiCapabilitiesGuardProps} */ export declare function SemanticUiCapabilitiesGuard({ capabilities, children, }: SemanticUiCapabilitiesGuardProps): ReactElement; /** * Props for the {@link SemanticUiCapabilitiesGuard} component. */ export declare type SemanticUiCapabilitiesGuardProps = PropsWithChildren<{ /** * Required capabilities to display the `children`. */ capabilities: Array; }>; /** * Provide a semantic UI based theme to the child components. * @param param0 - {@link SemanticUiThemeProviderProps} */ export declare function SemanticUiThemeProvider({ children, }: SemanticUiThemeProviderProps): ReactElement; /** * Props for the {@link SemanticUiThemeProvider} component. */ export declare type SemanticUiThemeProviderProps = PropsWithChildren<{}>; /** * Provides the `WidgetApi` in the React context once it's fully * initialized without errors. * Use `useWidgetApi` to access it. * @param param0 - {@link SemanticUiWidgetApiProviderProps} */ export declare function SemanticUiWidgetApiProvider({ widgetRegistration, widgetApiPromise, children, }: SemanticUiWidgetApiProviderProps): ReactElement; /** * Props for the {@link (SemanticUiWidgetApiProvider:function)} component. */ export declare type SemanticUiWidgetApiProviderProps = PropsWithChildren<{ /** * Configuration to set during Widget registration. */ widgetRegistration?: WidgetRegistration; /** * Result from a call to `WidgetApiImpl.create`. */ widgetApiPromise: Promise; }>; /** * A language detector that reads the language from the widget url. */ export declare class WidgetApiLanguageDetector extends LanguageDetector { constructor(); } /** * Backend for usage with `i18n-next` that provides translations for internal * messages. */ export declare const WidgetToolkitI18nBackend: BackendModule; export { }