Skip to main content

Overlay In-App

An in-app overlay is a view displayed above the currently visible activity, view, or page. It covers the content beneath it and prevents interaction with the application while visible. By default, it has a close button. Use the following methods to pause, resume, or check the display state of in-app overlays.

Resuming

Enables or resumes the display of in-app overlays. This is the default state.

EngagementCloud.inApp.resume()

Pausing

Pauses the display of in-app overlays. Call this method to prevent in-app overlays from appearing during sensitive flows, such as payment or data entry. For more details, see SDK Lifecycle.

EngagementCloud.inApp.pause()

Checking Pause State

Returns the current setting for in-app display as a boolean value.

EngagementCloud.inApp.isPaused

Display Lifecycle

StageDescription
EligibleTriggered event matches campaign conditions
QueuedWaiting for a safe display moment, for example when the overlay is not paused
DisplayedOverlay visible, underlying UI blocked
DismissedUser closes overlay or an action triggers navigation

Overlay Content and Navigation

Ensure your overlays do not replicate native navigation components. Keep overlay content focused on its headline and call to action.

When to Pause an Overlay

Pause during the following contexts:

  • Payment and checkout flows
  • Sensitive data entry
  • Onboarding tutorials

To restore engagement, resume the overlay when the user leaves those contexts.

Action Handling

For more information, refer to event handling.