Skip to main content

Crate day_piece_lottie

Crate day_piece_lottie 

Source
Expand description

day-piece-lottie — an EXTERNAL Day Piece rendering a Lottie animation, on iOS + Android only. It is the reference for a piece that pulls an EXTERNAL native package: the lottie-ios SwiftPM package on iOS (via the [package.metadata.day.ios] mechanism this piece introduces) and com.airbnb.android:lottie on Android. One Rust API, a native LottieAnimationView per platform, registered link-time into each backend’s renderer slice without touching day.

lottie("name") loads name(.json), bundled with the app (iOS: the app bundle; Android: assets), and plays it. It’s a growing leaf, so constrain it with .frame(w, h).

Structs§

Lottie
A native Lottie animation view. Configure with .looping(false) / .autoplay(false) and bind the playback rate reactively with .speed(signal).
LottieProps
Full props (realize). name/looping/autoplay are set once at build; speed seeds the playback rate and thereafter patches (see LottiePatch).

Enums§

LottiePatch
Sparse reconcile patch — only speed changes after build (name/looping/autoplay are fixed).

Constants§

KIND

Functions§

lottie
lottie("hello") — render the bundled hello.json Lottie animation (looping, autoplaying, 1× speed).
Day API ↩ Guides· daybrite.dev