Constructor options for text input dialogs

interface ITextOptions {
    cancelLabel?: string;
    checkbox?: null | Partial<ICheckbox>;
    defaultButton?: number;
    host?: HTMLElement;
    label?: string;
    okLabel?: string;
    pattern?: string;
    placeholder?: string;
    prefix?: string;
    renderer?: Dialog.IRenderer;
    required?: boolean;
    selectionRange?: number;
    suffix?: string;
    text?: string;
    title: Header;

Hierarchy (view full)


cancelLabel?: string

Label for cancel button.

checkbox?: null | Partial<ICheckbox>

The checkbox to display in the footer. Defaults no checkbox.

defaultButton?: number

The index of the default button. Defaults to the last button.

The host element for the dialog. Defaults to document.body.

label?: string

Label of the requested input

okLabel?: string

Label for ok button.

pattern?: string

Pattern used by the browser to validate the input value.

placeholder?: string

Placeholder text

prefix?: string

Additional prefix string preceding the input (e.g. £).

renderer?: Dialog.IRenderer

An optional renderer for dialog items. Defaults to a shared default renderer.

required?: boolean

Whether the input is required (has to be non-empty).

selectionRange?: number

Selection range

Number of characters to pre-select when dialog opens. Default is to select the whole input text if present.

suffix?: string

Additional suffix string following the input (e.g. $).

text?: string

Default input text

title: Header

The top level text for the dialog. Defaults to an empty string.