UIEvent
Represents different types of UI events that can be triggered by the user interaction on the UI templates.
Class Parameters
Parameter | Type | Description |
---|---|---|
T | Represents a UI template model which backs the composable on which the event has occurred. | |
S | Represents the state of the Adobe Experience Platform card composable on which the event has occurred. |
Syntax
Kotlin
Copied to your clipboardsealed class UIEvent<T : AepUITemplate, S : AepCardUIState>(open val aepUi: AepUI<T, S>)
Public Properties
Property | Type | Description |
---|---|---|
aepUI | The AepUI associated with the event. |
Display
Event that represents the display of a UI element.
Syntax
Kotlin
Copied to your clipboarddata class Display<T : AepUITemplate, S : AepCardUIState>(override val aepUi: AepUI<T, S>) :UIEvent<T, S>(aepUi)
Interact
Event that represents a user interaction with a UI element. The Interact
event captures the different types of interactions that a user can have with a UI component. Currently supported interactions types are can be seen in UIAction documentation.
Public Properties
Property | Type | Description |
---|---|---|
action | The UIAction that occurred. |
Syntax
Kotlin
Copied to your clipboarddata class Interact<T : AepUITemplate, S : AepCardUIState>(override val aepUi: AepUI<T, S>,val action: UIAction) : UIEvent<T, S>(aepUi)
Example
Kotlin
Copied to your clipboardobserver?.onEvent(AepUiEvent.Interact(ui, UIAction.Click(id = "purchaseID", actionUrl = "https://www.adobe.com"))
Dismiss
Event that represents the dismissal of a UI element.
Syntax
Kotlin
Copied to your clipboarddata class Dismiss<T : AepUITemplate, S : AepCardUIState>(override val aepUi: AepUI<T, S>) :UIEvent<T, S>(aepUi)