mirror of
https://github.com/nisrulz/flutter-examples.git
synced 2025-06-03 10:54:02 +08:00
30 lines
725 B
Dart
30 lines
725 B
Dart
import 'package:flutter/material.dart';
|
|
|
|
class First extends StatelessWidget {
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return new Scaffold(
|
|
backgroundColor: Colors.red,
|
|
body: new Container(
|
|
child: new Center(
|
|
child: new Column(
|
|
// center the children
|
|
mainAxisAlignment: MainAxisAlignment.center,
|
|
children: <Widget>[
|
|
new Icon(
|
|
Icons.favorite,
|
|
size: 160.0,
|
|
color: Colors.white,
|
|
),
|
|
new Text(
|
|
"First Tab",
|
|
style: new TextStyle(color: Colors.white),
|
|
)
|
|
],
|
|
),
|
|
),
|
|
),
|
|
);
|
|
}
|
|
}
|