Skip to main content

Crate mobiler_ui

Crate mobiler_ui 

Source
Expand description

Mobiler’s fixed UI wire ABI.

These types are the stable contract between any Mobiler app’s Rust core and the native shell. Because they never change per app, a single shell is built once and renders any Mobiler app — the shell only ever knows these types, never an app’s domain events or widgets.

  • The core emits a Widget tree (the ViewModel).
  • The shell sends back an Action (the Event).
  • App domain events ride inside actions as opaque ActionTokens that the shell round-trips without interpreting.

Style is expressed as intent tokens (e.g. TextStyle, Tone); the shell maps each to a concrete look (font, color, dp), so dark mode and theme come for free on the native side.

Structs§

Tab
A bottom-navigation tab. selected marks the active one; tapping sends on_select.

Enums§

Action
What the shell sends back to the core. Fixed across all apps.
BoxAlign
ButtonStyle
CardStyle
Icon
A small, finite icon set (maps to Material icons in the shell).
ImageRatio
ImageShape
InputValue
A value produced by an input widget at runtime.
ProjectColor
Project-identity colors (distinct from semantic Tone). Concrete RGB decided in the render layer.
Spacing
TextStyle
Tone
Semantic status color (distinct from brand/identity color).
Widget
The app-agnostic widget tree the shell renders. Fixed across all apps.

Type Aliases§

ActionToken
An opaque, serialized app event (e.g. JSON of the app’s domain action).