core2-jvm (latest)
core2-jvm (latest)core-jvm
  • Home
  • Features
  • Spec
  • Guides
  • Sandbox
  • Step Studio
  • Step
    • Action
    • External
    • Help
    • Link Handler
    • Navigation
    • Persist Async
    • Polling
    • Refresh On Change
    • Schema On Change
    • Step Error
    • Suggestions
    • Summary
    • Toolbar
    • Upload
    • Validate Async
    • Schema
    • All Of Schema
    • Array Schema
    • Blob Schema
    • Boolean Schema
    • Const Schema
    • Integer Schema
    • Number Schema
    • Object Schema
    • One Of Schema
    • String Schema
    • Layout
    • Alert Layout
    • Box Layout
    • Button Layout
    • Columns Layout
    • Decision Layout
    • Divider Layout
    • Form Layout
    • Heading Layout
    • Image Layout
    • Instructions Layout
    • List Layout
    • Loading Indicator Layout
    • Markdown Layout
    • Media Layout
    • Modal Layout
    • Paragraph Layout
    • Progress Layout
    • Review Layout
    • Search Layout
    • Section Layout
    • Status List Layout
    • Tabs Layout
    • Upsell Layout
    • Behavior
    • Action Behavior
    • Copy Behavior
    • Dismiss Behavior
    • Link Behavior
    • Modal Behavior
    • Refresh Behavior
    • Subflow Behavior
    • Subflow
    • Dynamic Launch Config
    • Launch Config
    • Modal Presentation
    • Native Launch Config
    • Presentation
    • Push Presentation
    • Action Response Body
    • Error Response Body
    • Flow Response
    • Modal Response Body
    • No Op Response Body
    • Search Initial Layout Config
    • Search Initial Results Config
    • Search Initial State
    • Search Layout Response Body
    • Search Response
    • Search Response Body
    • Search Result
    • Search Results Response Body
    • Subflow Response Body
    • Additional Info
    • Align
    • Autocapitalization Type
    • Autocomplete Token
    • Context
    • Icon
    • Image
    • Inline Alert
    • Media
    • Native Capabilities
    • Request
    • Size
    • Supporting Values
    • Control
    • Tag

Modal Behavior

Android - 8.111.0 iOS - 8.105 Web - 4.10.0

Opens a modal when the behavior is triggered.

button {
    control = "primary"
    title = "Card details"
    behavior = ModalBehavior.build {
        title = "Card details"
        content {
            review {
                fields {
                    field {
                        label = "Cardholder name"
                        value = "Emmett Brown"
                        callToAction {
                            title = "Copy"
                            behavior = CopyBehavior.build {
                                content = "Emmett Brown"
                            }
                        }
                    }
                    field {
                        label = "Card number"
                        value = "0118 0135 2610 1985"
                        callToAction {
                            title = "Copy"
                            behavior = CopyBehavior.build {
                                content = "0118 0135 2610 1985"
                            }
                        }
                    }
                    field {
                        label = "Expiry date"
                        value = "10/85"
                        callToAction {
                            title = "Copy"
                            behavior = CopyBehavior.build {
                                content = "10/85"
                            }
                        }
                    }
                    field {
                        label = "Security code"
                        value = "088"
                        callToAction {
                            title = "Copy"
                            behavior = CopyBehavior.build {
                                content = "088"
                            }
                        }
                    }
                    field {
                        label = "Billing address"
                        value = "1646 Riverside Drive, Hill Valley, CA 95420, United States"
                    }
                }
            }
        }
    }
}

Properties

PropertyTypeRequiredDescription
contentArray<Layout>YesThe content which should be displayed within the modal. Please note that we discourage the use of form components within modals as this can lead to an undesirable user experience with validation.
titleStringNoThe user-facing title of the modal.
typeStringYesIt must be modal.