The Modal frame
A container that appears above other content.
The Modal frame is a container that appears as an overlay in the center of the app when visible. You can add multiple instances of the Modal frame that operate independently.
Properties
All properties for this object with supported data types or values. You can write JavaScript almost anywhere in Retool to manipulate or read property values.
enableFullBleed
Whether to expand the contents to fill available space.
Type | boolean | ||||
Format | True/False | ||||
Mutability |
| ||||
Default |
|
Examples
footerPadding
The amount of padding used within the footer.
Type | string | |||||||||
Format | Plain Text | |||||||||
Mutability |
| |||||||||
Allowed Values |
| |||||||||
Default |
|
Examples
headerPadding
The amount of padding used within the header.
Type | string | |||||||||
Format | Plain Text | |||||||||
Mutability |
| |||||||||
Allowed Values |
| |||||||||
Default |
|
Examples
hidden
Whether this object is hidden from view.
Type | boolean | ||||||
Format | True/False | ||||||
Mutability |
| ||||||
Default |
|
Examples
hideOnEscape
Whether to toggle hidden
to true
when the Esc
key is pressed.
Type | boolean | ||||
Format | True/False | ||||
Mutability |
| ||||
Default |
|
Examples
loading
Whether to display a loading indicator.
Type | boolean | ||||
Format | True/False | ||||
Mutability |
| ||||
Default |
|
Examples
overlayInteraction
Whether to toggle hidden
to true
if the user clicks outside of the content area.
Type | boolean | ||||
Format | True/False | ||||
Mutability |
| ||||
Default |
|
Examples
padding
The amount of padding to render inside.
Type | string | ||||||
Format | Plain Text | ||||||
Mutability |
| ||||||
Allowed Values |
| ||||||
Default |
|
Examples
showBorder
Whether to show a border.
Type | boolean | ||||
Format | True/False | ||||
Mutability |
| ||||
Default |
|
Examples
showFooter
Whether to show the footer area.
Type | boolean | ||||||
Mutability |
|
showFooterBorder
Whether to show a border above the footer.
Type | boolean | ||||
Format | True/False | ||||
Mutability |
|
Examples
showHeader
Whether to show the header area.
Type | boolean | ||||||
Format | True/False | ||||||
Mutability |
| ||||||
Default |
|
Examples
showHeaderBorder
Whether to show a border under the header.
Type | boolean | ||||
Format | True/False | ||||
Mutability |
| ||||
Default |
|
Examples
showOverlay
Whether to display a darkened overlay when visible.
Type | boolean | ||||
Format | True/False | ||||
Mutability |
|
Examples
tooltipText
The tooltip text to display next to the label on hover.
Type | string | ||||
Format | Markdown | ||||
Mutability |
| ||||
Default |
|
Examples
width
The width.
Type | string | ||||||||||
Format | Integer | ||||||||||
Mutability |
| ||||||||||
Allowed Values |
|
Examples
Methods
JavaScript API methods for this object. You can write JavaScript almost anywhere in Retool and use methods to manipulate data and property values.
modal.setHidden()
Set the hidden
value to toggle whether the component is visible. Defaults to true
without a parameter.
modal.setHidden(hidden)
Parameters
Examples
modal.showFooter(showFooter)
Parameters
Examples
modal.showHeader(showHeader)
Parameters
Examples
modal.toggleHidden()
Examples
Events
Events triggered by user interactions. You can configure event handlers in the IDE to trigger queries or other actions in response to events.
Event | Description |
---|