Package-level declarations

Types

Link copied to clipboard
data class AlertOverlay(val buttons: Map<AlertOverlay.Button, String> = emptyMap(), val message: String = "", val title: String = "", val cancelable: Boolean = true, val onEvent: (AlertOverlay.Event) -> Unit) : ModalOverlay

Models a typical "You sure about that?" alert box.

Link copied to clipboard

Informs views whether they're children of a BackStackScreen, and if so whether they're the first frame or not.

Link copied to clipboard

Represents an active screen (top), and a set of previously visited screens to which we may return (backStack). By rendering the entire history we allow the UI to do things like maintain cached view state, implement drag-back gestures without waiting for the workflow, etc.

Link copied to clipboard
class BodyAndOverlaysScreen<B : Screen, O : Overlay>(val body: B, val overlays: List<O> = emptyList(), val name: String = "") : Screen, Compatible, Composite<Any>

A screen that may stack a number of Overlays over a body. If any members of overlays are ModalOverlay, the body and lower-indexed members of that list are expected to ignore input events -- touch, keyboard, etc.

Link copied to clipboard
class FullScreenModal<out C : Screen>(val content: C) : ScreenOverlay<C> , ModalOverlay

A basic ScreenOverlay that covers its container with the wrapped content.

Link copied to clipboard
interface ModalOverlay : Overlay

Marker interface identifying Overlay renderings whose presence indicates that events are blocked from lower layers.

Link copied to clipboard
class NavigationMonitor(skipFirstScreen: Boolean = false, onNavigate: (Any) -> Unit = { println(Compatible.keyFor(it)) })

Reports navigation across a series of calls to update, probably made for each rendering posted by com.squareup.workflow1.renderWorkflowIn.

Link copied to clipboard
interface Overlay

Marker interface implemented by window-like renderings that map to a layer above a base Screen by being placed in a BodyAndOverlaysScreen.overlays list. See BodyAndOverlaysScreen for more details.

Link copied to clipboard

An Overlay built around a root content.

Functions

Link copied to clipboard

Returns a new BackStackScreen with the BackStackScreen.frames of other added to those of the receiver. other is nullable for convenience when using with toBackStackScreenOrNull.

Link copied to clipboard
fun <T : Any> Flow<T>.reportNavigation(skipFirstScreen: Boolean = false, onNavigate: (Any) -> Unit = { println(it) }): Flow<T>

Creates a NavigationMonitor and updates it with each element collected by the receiving Flow.

Link copied to clipboard
Link copied to clipboard