[英]how to add text before the animation flutter
I'm new to flutter and creating an onboard screen.我是 flutter 的新手,正在创建一个板载屏幕。 I want to add text before the animation. how can I do that?
我想在 animation 之前添加文本。我该怎么做? appreciate your help on this.
感谢您对此的帮助。
import 'package:flutter/material.dart';
import 'package:lottie/lottie.dart';
class IntroPageOne extends StatelessWidget {
const IntroPageOne({Key? key}) : super(key: key);
@override
Widget build(BuildContext context) {
return Scaffold(
backgroundColor: Colors.white,
body: Column(
children: [
Center(
child: Lottie.network('https://assets5.lottiefiles.com/packages/lf20_u5nd9awf.json'),
),
],
),
);
}
}
I found a way.我找到了一个方法。
return Scaffold( backgroundColor: Colors.white, body: Center(返回脚手架(背景颜色:Colors.white,身体:中心(
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: [
Text("ghdwg"),
Lottie.network('https://assets8.lottiefiles.com/packages/lf20_xkxecivz.json'),
],
),
),
);
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.