import * as React from 'react'; /** * Base class for all ViewContoller classes in WDK. This base class is * responsible for: * - providing render hooks based on state predicates */ export default class ViewController extends React.PureComponent { /** * Renders the highest page component below the Page tag. */ renderView(): JSX.Element | null; /** * Renders data load error message */ renderDataLoadError(): JSX.Element; /** * Renders data not found message */ renderDataNotFound(): JSX.Element; /** * Renders data permission denied */ renderDataPermissionDenied(): JSX.Element; /** * Renders data loading message */ renderDataLoading(): JSX.Element; renderError(): JSX.Element; /** * This is a good place to perform side-effects, such as calling an action * creator to load data for a store. * * Called when the component is first mounted with the state of the store * and the initial props. Also called when new props are received, with the * state of the store, the new props, and the old props. On the first call * when the component is first mounted, the old props will be undefined. */ loadData(prevProps?: Props): void; /** * Returns whether an initial data load error has occurred which would prevent * the page from rendering. * @param {Object} state The current state. */ isRenderDataLoadError(): boolean; /** * Returns whether enough data has been loaded into the store to render the * page. */ isRenderDataLoaded(): boolean; /** * Returns whether required data resources are not found. */ isRenderDataNotFound(): boolean; /** * Returns whether access to required data resources are forbidden for current user. */ isRenderDataPermissionDenied(): boolean; componentDidMount(): void; componentDidUpdate(prevProps: Props): void; /** * Renders the page of this controller. Subclasses may override, but may * save effort by overriding renderView() instead. This method will call that * one but only after checking if data required for render has been not yet * fully loaded or has erred during loading. */ render(): JSX.Element; } //# sourceMappingURL=ViewController.d.ts.map