Constructor options for item selection input dialogs

interface IItemOptions {
    cancelLabel?: string;
    checkbox?: null | Partial<ICheckbox>;
    current?: string | number;
    defaultButton?: number;
    editable?: boolean;
    host?: HTMLElement;
    items: string[];
    label?: string;
    okLabel?: string;
    placeholder?: string;
    prefix?: string;
    renderer?: Dialog.IRenderer;
    suffix?: string;
    title: Header;
}

Hierarchy (view full)

Properties

cancelLabel?: string

Label for cancel button.

checkbox?: null | Partial<ICheckbox>

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

current?: string | number

Default choice

If the list is editable a string with a default value can be provided otherwise the index of the default choice should be given.

defaultButton?: number

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

editable?: boolean

Is the item editable?

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

items: string[]

List of choices

label?: string

Label of the requested input

okLabel?: string

Label for ok button.

placeholder?: string

Placeholder text for editable input

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.

suffix?: string

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

title: Header

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