import * as React from 'react'; import { ConnectHost } from './ConnectHost'; import { ConnectIframeInterface } from './ConnectIframeInterface'; import { AppOptions } from '../../definitions/AppContext'; import { ConnectIframeProvider, ConnectIframeContext } from './ConnectIframeProvider'; import IFrameLifecycleEventManager from './IFrameLifecycleEventManager'; export declare const LoadingState: Readonly<{ INIT: symbol; LOADED: symbol; FAILED: symbol; TIMEOUT: symbol; LOADING: symbol; RESOLVING: symbol; }>; declare module ConnectIframeDefinitions { interface Props { connectHost: ConnectHost; appKey: string; moduleKey: string; iframeContainer: new () => React.PureComponent<{ width: string | number | undefined; height: string | number | undefined; }, {}>; loadingIndicator: typeof React.PureComponent; failedToLoadIndicator: typeof React.PureComponent; timeoutIndicator: new () => React.PureComponent<{ failedCallback: Function; }, {}>; url: string; width: string; height: string; options: AppOptions; connectIframeProvider: ConnectIframeProvider; } interface State { width?: string; height?: string; hostFrameOffset?: number; loadingState?: symbol; } } /** * ConnectIframe represents an add-on within a view. */ declare class ConnectIframe extends React.PureComponent { unmountCallbacks: Function[]; iframeContext: ConnectIframeContext; iframeAttributes: ConnectIframeInterface; iframeLifecycleEventManager: IFrameLifecycleEventManager; static propTypes: object; static defaultProps: object; constructor(props: ConnectIframeDefinitions.Props); resize: (width: string, height: string) => void; sizeToParent: () => void; registerUnmountCallback: (callback: Function) => void; hideInlineDialog: () => void; getId: () => string | null; getIFrameLifecycleEventManager: () => IFrameLifecycleEventManager | undefined; iframeEstablishedCallback: () => void; iframeFailedToLoadCallback: () => void; iframeTimeoutCallback: () => void; _createIFrameLifecycleManager: () => void; _unregisterIFrameLifecycleManager: () => void; _createExtension: () => void; _destroyExtension: () => void; _isSubIframe: () => boolean; _initialise: () => void; componentWillReceiveProps(nextProps: ConnectIframeDefinitions.Props): void; componentWillUnmount(): void; render(): React.ReactElement | null; componentDidMount(): void; componentDidUpdate(): void; } export { ConnectIframeDefinitions, ConnectIframe };