Built-in screens
The SDK ships three screens and shows them by default:- The maintenance and required-update screens cover the whole app and can’t be dismissed. They go away by themselves when the state clears.
- The update prompt is shown at most once per app session, never on top of a blocking screen, and only after your app’s first screen is ready.
- Titles, messages and release notes come from the dashboard. Button labels, the “What’s new” heading and the “Expected back at” line are built in, in English and Arabic (right to left), picked from the device language.
Your own screens
Turn the built-in screens off withui: false and listen to the state
instead. The SDK keeps fetching, caching and applying the
offline rules;
only the drawing is yours.
The state
The state has three parts, each one empty (null, nil) when nothing
applies. It is already filtered for the current time, Later and
Skip, so you can draw whatever you receive.
maintenanceis set only while a window is active. A scheduled window stays inside the SDK until its start time.storeUrlis always empty on the web.- Field names are the same in every SDK.
stateandreasonare enums in the native SDKs:LerixUpdateState(Flutter.required, Swift.required, KotlinREQUIRED) andLerixUpdateReason(Flutter and Swift usebelowMinimum,blockedVersionanddeadlinePassed). Kotlin and the web SDKs keepreasonas the string above. A reason the SDK doesn’t know reads asnull. - Times are
DateTime(Flutter),Date(Swift), epoch milliseconds (Kotlin), or ISO strings (web).
Helpers
The helpers also record the matching
$update_prompt_action event, so the
update funnel in Analytics stays complete with your own UI.
$update_prompt_shown is recorded only by the built-in UI; in Flutter, call
Lerix.appControl.reportPromptShown(update) when your own prompt appears.
See
Events, webhooks and permissions.
Per SDK
- Flutter
- Swift
- Kotlin
- React
- Angular
- Web (JS)
Turning it off completely
enabled: false stops release control in that app: no checks, no screens and
no events. A Lerix SDK switch the device saved earlier still applies until its
end time (see
Delivery and offline behaviour).