Skip to main content

Crate aura_anim_iced

Crate aura_anim_iced 

Source
Expand description

Iced-first animation primitives.

aura-anim-iced models advanced animation as sampled Iced UI properties that can be applied from normal update, subscription, and view code. The public API is Iced-first: user-facing values use Iced types and Iced’s animation primitives wherever they already exist.

The foundation layer covers typed Iced UI properties, timing, property keyframes, timelines, a small runtime, and Iced integration helpers. The v0.2 behavior layer adds property-change transitions, state-driven transitions, retargeting, interruption, and route screen transitions on top of that base.

Runtime integration follows a simple loop:

  1. Store an AnimationRuntime in application state.
  2. Register keyframes or timelines when update receives user events.
  3. Subscribe to ticks only while the runtime is active.
  4. Sample snapshots on each tick and apply them while building view.

Runnable examples live under examples/:

  • animated_button.rs for hover, press, focus, scale, color, and shadow animation.
  • keyframes_popup.rs for opacity and scale keyframes.
  • timeline_toast.rs for enter, hold, exit, and cleanup sequencing.
  • behavior_width.rs for property-change animation from the current visual value.
  • route_transition.rs for outgoing and incoming screen transition flow.

Re-exports§

pub use behavior::ActivePropertyTransition;
pub use behavior::BehaviorRule;
pub use behavior::PropertyTransition;
pub use behavior::PropertyTransitionProgress;
pub use behavior::PropertyTransitionRegistration;
pub use behavior::TransitionValueKind;
pub use iced_ext::EffectSnapshot;
pub use iced_ext::effect_snapshot;
pub use iced_ext::tick_effect_snapshot_for;
pub use keyframes::Keyframe;
pub use keyframes::Keyframes;
pub use keyframes::KeyframesBuilder;
pub use property::BACKGROUND;
pub use property::BORDER_COLOR;
pub use property::HEIGHT;
pub use property::OPACITY;
pub use property::PADDING;
pub use property::PropertyKey;
pub use property::PropertySnapshot;
pub use property::PropertySpec;
pub use property::PropertyValue;
pub use property::RADIUS;
pub use property::SCALE;
pub use property::SHADOW;
pub use property::TEXT_COLOR;
pub use property::TRANSLATE;
pub use property::TransformValue;
pub use property::WIDTH;
pub use route::ActiveRouteScreenTransition;
pub use route::ActiveRouteTransition;
pub use route::RouteAnimator;
pub use route::RouteIncomingMotion;
pub use route::RouteScreenTargets;
pub use route::RouteScreenTransition;
pub use route::RouteScreenTransitionRegistration;
pub use route::RouteTransition;
pub use route::RouteTransitionRegistration;
pub use route::RouteTransitionSet;
pub use runtime::AnimationHandle;
pub use runtime::AnimationPlaybackState;
pub use runtime::AnimationRegistration;
pub use runtime::AnimationRuntime;
pub use runtime::AnimationTargetId;
pub use runtime::AnimationTick;
pub use runtime::TargetedPropertySnapshot;
pub use runtime::TickPolicy;
pub use state::ActiveStateTransition;
pub use state::StateAnimator;
pub use state::StateTransition;
pub use state::StateTransitionProgress;
pub use state::StateTransitionRegistration;
pub use state::StateTransitionSet;
pub use timeline::Hold;
pub use timeline::Parallel;
pub use timeline::PropertyTrackBuilder;
pub use timeline::Sequence;
pub use timeline::Timeline;
pub use timeline::TimelineMarker;
pub use timeline::TimelineStep;
pub use timeline::Track;
pub use timing::Delay;
pub use timing::Direction;
pub use timing::Duration;
pub use timing::FillMode;
pub use timing::IterationCount;
pub use timing::NormalizedTiming;
pub use timing::Timing;
pub use timing::TimingPhase;
pub use timing::TimingSampleState;

Modules§

behavior
Behavior helpers for property-driven animation.
iced_ext
Iced integration helpers.
keyframes
Property-snapshot keyframe storage and lookup.
prelude
Common imports for the v0.2 public API.
property
Visual property identifiers, value containers, and composition helpers.
route
Route transition helpers for screen-to-screen animation.
runtime
Runtime storage for active Iced-first animations.
state
State-driven animation helpers.
timeline
Timeline orchestration primitives.
timing
Timing configuration and elapsed-time normalization.

Enums§

Easing