import
'package:flutter/material.dart'
;
import
'package:flare_flutter/flare_actor.dart'
;
void
main() => runApp(MyApp());
class
MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return
MaterialApp(
title:
'GeeksforGeeks'
,
theme: ThemeData(
primarySwatch: Colors.blue,
),
home: MyHomePage(),
debugShowCheckedModeBanner:
false
,
);
}
}
class
MyHomePage extends StatefulWidget {
@override
_MyHomePageState createState() => _MyHomePageState();
}
class
_MyHomePageState extends State<MyHomePage> {
@override
Widget build(BuildContext context) {
return
Scaffold(
appBar: AppBar(title: Text(
"GeeksForGeeks"
)),
body: Container(
child: ListView(
children: <Widget>[
Padding(
padding:
const
EdgeInsets.all(8.0),
child: Container(
width: 700,
height: 300,
child: FlareActor(
"assets/test3.flr"
,
animation:
"day_and_night"
,
),
),
),
Padding(
padding:
const
EdgeInsets.all(10.0),
child: Container(
width: 700,
height: 300,
child: FlareActor(
"assets/my.flr"
,
animation:
"left2right"
,
),
),
),
Padding(
padding:
const
EdgeInsets.all(8.0),
child: Container(
width: 700,
height: 300,
child: FlareActor(
"assets/teddy.flr"
,
animation:
"success"
,
),
),
),
Padding(
padding:
const
EdgeInsets.all(8.0),
child: Container(
width: 700,
height: 300,
child: FlareActor(
"assets/test2.flr"
,
animation:
"Demo Mode"
,
),
),
),
],
),
),
);
}
}