Themes

Components/Components/es-action-with-confirmation
es-action-with-confirmation

An action with a confirmation modal.

Props

Name
Description
Type
Default
action

The action to take when the button is clicked.

() => any
disabled

if the action should be disabled.

boolean
false
dot

If a dot should be shown on the action, to indicate attention being required.

error
or
okay
or
warning
or
undefined
dropdownItem

If the action is within an es-action-dropdown.

boolean
false
icon

The icon to show for the action.

[namespace: string
or
symbol, name: string]
or
string
modal

The text to display within the modal.

ConfirmModalOptions
typeToConfirm

If the user needs to type the passed string to enable confirmation.

string
or
undefined

ConfirmModalOptions

What to display within a modal.

Name
Description
Type
body

Text or component to display in the body of the modal.

string | FunctionalComponent<unknown>
confirm

Text to display within the confirm button.

string
confirmVariant

Which variant to display the button as.

ButtonVariant
heading

Text to display in the heading.

string
preHeading

Text to display above the heading.

string
warning

Text to display in red below the body.

string