import "../../CommonImports"; import "../../Core/core.css"; import * as React from "react"; import { IObserverProps, IUncheckedObserverProps } from "./Observer.Props"; export interface IObserverState { values: { [propName: string]: any; }; oldProps: Partial; } /** * Handles subscription to properties that are IObservableValues, so that components don't have to handle on their own. * * Usage: * * * * * * Your component will get re-rendered with the new value of myObservableValue whenever that value changes. * Additionally, any additional props set on the Observer will also get passed down. */ declare class ObserverBase void; }> extends React.Component> { static getDerivedStateFromProps(props: Readonly, state: Readonly>): Partial>; private subscribedProps; private subscriptions; constructor(props: Readonly); render(): JSX.Element; componentDidMount(): void; componentDidUpdate(): void; componentWillUnmount(): void; subscribe(propName: string, props: TProps): void; unsubscribe(propName: string, props: TProps): void; private updateSubscriptionsAndStateAfterRender; private onValueChanged; } /** * Handles subscription to properties that are IObservableValues, so that components don't have to handle on their own. * * Usage: * * * {(props: {myObservableValue: string}) => * * } * * * Your component will get re-rendered with the new value of myObservableValue whenever that value changes. */ export declare class Observer extends ObserverBase> { } /** * UncheckedObserver is like Observer, except that it performs less (no) typechecking on the child observer function, * and allows child React elements. * * Usage: * * * {(props: {myObservableValue: string}) => * * } * * * -or- * * * * * * Your component will get re-rendered with the new value of myObservableValue whenever that value changes. * Additionally, any additional props set on the Observer will also get passed down. */ export declare class UncheckedObserver extends ObserverBase { } export {};