Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Strange lottie animation effect #360

Open
bruce3x opened this issue Jun 11, 2024 · 0 comments
Open

Strange lottie animation effect #360

bruce3x opened this issue Jun 11, 2024 · 0 comments

Comments

@bruce3x
Copy link

bruce3x commented Jun 11, 2024

I don't know why the animation was spinning inexplicably in Flutter. But its preview on the web is normal and as expected.

❌ Preview lottie in Flutter:
https://github.com/xvrh/lottie-flutter/assets/15318754/3e227f4d-6f9a-40bc-8dad-ac143838e4b4

✅ Preview lottie in Web:

Kapture.2024-06-11.at.21.17.14.mp4

Versions:

Flutter 3.19.5 • channel stable • https://github.com/flutter/flutter.git
Framework • revision 300451adae (3 months ago) • 2024-03-27 21:54:07 -0500
Engine • revision e76c956498
Tools • Dart 3.3.3 • DevTools 2.31.1

pubspec.lock

lottie:
  dependency: "direct main"
  description:
    name: lottie
    sha256: "6a24ade5d3d918c306bb1c21a6b9a04aab0489d51a2582522eea820b4093b62b"
    url: "https://pub.dev"
  source: hosted
  version: "3.1.2"

Code:

SizedBox(
  width: 400,
  height: 400,
  child: AspectRatio(
    aspectRatio: 1.0,
    child: Lottie.asset(
      "assets/lottie/cloud_bird.json",
      repeat: true,
      animate: true,
      fit: BoxFit.fitWidth,
    ),
  ),
),

Lottie file:
cloud_bird.json

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant