Skip to content

UI system: motion substrate (phase clock + motion helpers + composite dim, drop tachyonfx) #61

Description

@tamirelazar

Part of the UI-system unification. Hand-rolled motion substrate (verdict: hand-roll, drop the tachyonfx dependency — it beat the library on every axis and the library was unused). Independent of the token/widget foundation; can run in parallel.

What to build

A small, allocation-light animation layer that every overlay fade and the identity "breath" ride on.

  • A persistent phase clock on the runtime state, advanced each frame by dt, that outlives overlay open/close (so fade-OUT can play).
  • A motion helper module: lerp_rgb, ease curves (ease_out_cubic, ease_in_out), a bounded breath oscillator, dim_overlay, crossfade, clip_rows.
  • Extend the composite stage so a rich overlay can be drawn with a dim: f32 (lerps set fg/bg toward the background). Existing draw path becomes a dim = 1.0 wrapper so current renders are byte-identical.
  • Remove tachyonfx from the manifest (terminal feature + deps). Note: there is no spike code to delete on this base — motion is greenfield here.

Acceptance criteria

  • Phase clock advances by dt and wraps safely (unit test)
  • Motion helpers unit-tested (lerp endpoints, ease clamping, breath bounded)
  • dim = 1.0 composite path leaves all existing visual-regression goldens unchanged
  • tachyonfx removed; cargo build --features terminal + cargo test + clippy pass

Blocked by

None - can start immediately

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestroadmapPlanned future work

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions