SCION Workbench Client - v1.0.0-beta.35
    Preparing search index...

    Interface WorkbenchMessageBoxOptions

    Controls the appearance and behavior of a message box.

    interface WorkbenchMessageBoxOptions {
        actions?: { [key: string]: string };
        contentSelectable?: boolean;
        context?:
            | null
            | `view.${string}`
            | `part.${string}`
            | `dialog.${string}`
            | `popup.${string}`
            | Context;
        cssClass?: string
        | string[];
        modality?: "view" | "none" | "context" | "application";
        params?: Map<string, unknown> | { [param: string]: unknown };
        severity?: "error" | "info" | "warn";
        title?: string;
    }
    Index

    Properties

    actions?: { [key: string]: string }

    Defines buttons of the message box. If not set, an OK button is displayed by default.

    Each property in the object literal represents a button, with the property value used as the button label. The label can be text or a translation key. A translation key starts with the percent symbol (%) and may include parameters in matrix notation for text interpolation.

    Clicking a button closes the message box and returns the property key to the message box opener.

    A button with the key 'cancel' is also assigned the Escape keystroke.

    Example:

    {
    yes: 'Yes',
    no: 'No',
    cancel: 'Cancel',
    }
    contentSelectable?: boolean

    Specifies if the user can select text displayed in the message box. Defaults to false.

    context?:
        | null
        | `view.${string}`
        | `part.${string}`
        | `dialog.${string}`
        | `popup.${string}`
        | Context

    Binds the message box to a context (e.g., a part or view). Defaults to the calling context.

    The message box is displayed only if the context is visible and closes when the context is disposed. The message box is opened in the center of its context, if any, unless opened from the peripheral area.

    Set to null to open the message box outside a context.

    cssClass?: string | string[]

    Specifies CSS class(es) to add to the message box, e.g., to locate the message box in tests.

    modality?: "view" | "none" | "context" | "application"

    Controls which area of the application to block by the message box. Defaults to context.

    One of:

    • 'none': Non-blocking message box.
    • context: Blocks a specific part of the application, as specified in context, defaulting to the calling context.
    • application: Blocks the workbench or browser viewport, based on global workbench settings.
    • view: Deprecated. Same as context. Marked for removal.
    params?: Map<string, unknown> | { [param: string]: unknown }

    Passes data to the message box.

    The message box can declare mandatory and optional parameters. No additional parameters are allowed. Refer to the documentation of the capability for more information.

    severity?: "error" | "info" | "warn"

    Specifies the severity of the message. Defaults to info.

    title?: string

    Specifies the title of the message box.

    Can be text or a translation key. A translation key starts with the percent symbol (%) and may include parameters in matrix notation for text interpolation.