Modal

Overview

Modals focus the user’s attention exclusively on one task or piece of information via a window that sits on top of the page content.

Demo

Props

PropertyDescriptionTypeValuesDefaultRequired
primaryLabelThe label for the primary actionstringstring
contentThe modal contentstring | undefinedstring | undefined
secondaryLabelThe label for the secondary actionstring | undefinedstring | undefined
titleThe title for the modalstring | undefinedstring | undefined
showOpen and close the modalboolean | undefinedboolean | undefined
closeOnOutsideClickWhether the modal should close on outside clickboolean | undefinedboolean | undefinedtrue
primaryFocusSets the focus to the primary buttonboolean | undefinedboolean | undefinedtrue
showSpinnerShow a spinnerboolean | undefinedboolean | undefined
spinnerTextThe text for the spinnerstring | undefinedstring | undefined
qaNameOptional QA name for id attributesstring | undefinedstring | undefined

Slots

NameDescriptionType
defaultThe content for the modal.any
iconThe icon for the modal.any

Events

NameReturn Type
modalClosevoid
primaryActionvoid
secondaryActionvoid