Skip to content

v0.2.0 — Screen Flow & Loading Flow Sample

Choose a tag to compare

@dyCuong03 dyCuong03 released this 21 Aug 15:00
· 25 commits to main since this release
acf0970

Added

  • Screen flow system (Runtime/Flow/). A stack-based screen navigator with full lifecycle:
    PushAsync, PopAsync, ReplaceAsync, PopToRootAsync, PopAllAsync. Screens are UXML
    documents managed by presenters with lifecycle hooks: OnBindAsync, OnActivate,
    OnDeactivate, OnSuspend, OnResume, OnBackRequested. Model-parameterized variants
    (PushAsync<TPresenter, TModel>(model)) pass data to a screen at open time.
    • ScreenNavigator — the stack, per-scene scoped via VContainer.
    • BaseUIToolkitScreenPresenter<TView> / <TView, TModel> — presenter bases.
    • BaseUIToolkitPopupPresenter<TView> / <TView, TModel> — popup convenience with Close().
    • ScreenOptions — None (full screen), Modal (overlay layer), DimsBelow (dims without
      suspending the screen below).
    • ScreenSubscriptions — scoped cleanup for button clicks and events.
    • ScreenRegistry — maps presenter type to view type, asset key, and options.
    • ScreenLifecycleState — 9 states from Registered to Disposed.
    • IScreenScopeFactory / VContainerScreenScopeFactory — one VContainer child scope per screen.
    • ScreenFlowRegistration — RegisterUIToolkit(), RegisterScreenFlow(),
      RegisterScreen<T,V>(), RegisterPopup<T,V>() extension methods for VContainer.
  • Back navigation (Runtime/Input/BackNavigationSource). Wires Escape, gamepad B, and
    Android back to the navigator. One-line setup: source.BackHandler = navigator.HandleBack.
    RootBackPolicy controls what happens at the bottom of the stack: NotHandled (platform
    default), Consume (swallow), or Raise (event).
  • Assembly definitions for all samples. Samples could not compile when imported via Package
    Manager because they had no .asmdef. Each sample now ships its own.
  • Loading Flow sample (Samples~/LoadingFlow). Two-scene flow demonstrating every package
    feature: LoadingScene (MonoBehaviour-driven progress bar with tips and spinner) transitions to
    MainScene (ScreenNavigator with Push, Pop, Replace, PopToRoot, Modal+DimsBelow overlay, model
    parameters, lifecycle hooks, OnBackRequested override, BackNavigationSource,
    UIToolkitListAdapter collection adapter, and per-scene navigator scoping).
  • A DOTS/ECS presentation adapter (Runtime/Ecs/), optional behind com.unity.entities
    and the CUVARA_UITOOLKIT_ENTITIES versionDefine.
    • IViewModelSink<TViewModel> — the contract a host's Presenter implements.
    • EcsViewModelBridge<TComponent, TViewModel> — managed SystemBase in
      PresentationSystemGroup that converts component data to a plain ViewModel.
    • EcsSinkRegistration — binds a sink for a screen's lifetime and unbinds on Dispose.
    • Samples~/EcsHud — the five layers end to end.
  • CI improvements: samples compile job, samples gate (check_samples.py), real Unity test
    job, install probes, check_standalone.py wired into CI.
  • A test that [UpdateInGroup] inherits onto a host's bridge subclass.

Fixed

  • A sink registered mid-session received nothing until the simulation next wrote the component.
    The next pass after a registration now runs unfiltered exactly once.
  • CI failed on its own dependency check after the com.gdk.core dependency was removed.
  • check_standalone.py was never wired into CI.