Interface that provides popups for the user.

interface Notifier {
    inform?: ((message, options?) => void);
    showBusy?: ((message, options?) => Promise<(() => void)> | (() => void));
    showError?: ((error) => void);
    showInputOptions?: ((options) => Promise<InputResults>);
    showOptions?: ((options) => Promise<string>);
    showWindow?: ((type, props?, options?) => void);
}

Properties

inform?: ((message, options?) => void)

Useful when informing the user of something but are not expecting a response

Type declaration

    • (message, options?): void
    • Parameters

      Returns void

showBusy?: ((message, options?) => Promise<(() => void)> | (() => void))

Useful when performing a long running operation and you want to inform the user.

A return type of a handler will be returned to allow for hideBusy. If multiple calls are made the consumer should continue to indicated blocked until all calls have been hideBusy

Type declaration

    • (message, options?): Promise<(() => void)> | (() => void)
    • Parameters

      Returns Promise<(() => void)> | (() => void)

showError?: ((error) => void)

Should return error object exception.

Type declaration

    • (error): void
    • Parameters

      • error: any

      Returns void

showInputOptions?: ((options) => Promise<InputResults>)

Provider a user with a way to enter a text input.

Type declaration

showOptions?: ((options) => Promise<string>)

Provide a user with a list of options to choose from.

Type declaration

showWindow?: ((type, props?, options?) => void)

Show a dialog for a given type.

Type declaration

    • (type, props?, options?): void
    • Parameters

      • type: string
      • Optional props: any
      • Optional options: {
            disableAutoDestroy?: boolean;
        }
        • Optional disableAutoDestroy?: boolean

      Returns void

Returns