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). - Lottie
Props - Full props (realize).
name/looping/autoplayare set once at build;speedseeds the playback rate and thereafter patches (seeLottiePatch).
Enums§
- Lottie
Patch - Sparse reconcile patch — only
speedchanges after build (name/looping/autoplay are fixed).
Constants§
Functions§
- lottie
lottie("hello")— render the bundledhello.jsonLottie animation (looping, autoplaying, 1× speed).