【问题标题】:Lottie animation is not repeating even after 'repeat' is set as true in flutter即使在颤振中将“重复”设置为真后,洛蒂动画也不会重复
【发布时间】:2022-01-14 10:44:12
【问题描述】:

我正在使用 pub.dev 上的 Lottie package 来显示 Lottie 文件。动画只播放一次,即使在“重复”设置为 true 后也不会重复。请向我建议我所缺少的。谢谢

 Lottie.asset(
              'assets/lottiefiles/40912-new-year-loop-background.json',
              width: MediaQuery.of(context).size.width,
              height: 450,
              repeat: true,
              fit: BoxFit.fill,
              
            ),

【问题讨论】:

    标签: flutter flutter-animation lottie


    【解决方案1】:

    代码看起来不错。我自己试过,似乎这个lottie动画本身有问题(一些油漆边界问题)。因此,您可以寻找一些其他的抽签动画。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2021-09-08
      • 2021-01-13
      • 1970-01-01
      相关资源
      最近更新 更多