Sunteți pe pagina 1din 3

import 'package:flutter/material.

dart';
import 'package:percent_indicator/percent_indicator.dart';
import 'add_note.dart';
import 'package:page_transition/page_transition.dart';
void main() => runApp(MyApp());

class MyApp extends StatelessWidget {


// This widget is the root of your application.
@override
Widget build(BuildContext context) {
return MaterialApp(
title: 'Flutter Demo',
debugShowCheckedModeBanner: false,
theme: ThemeData(
primarySwatch: Colors.blue,
),
home: HomePage(),
);
}
}

class HomePage extends StatefulWidget {


@override
_HomePageState createState() => _HomePageState();
}

class _HomePageState extends State<HomePage> {


@override
Widget build(BuildContext context) {
return Hero(
tag: "Hero",
child: Scaffold(
backgroundColor: Color(0xffE8816D),
appBar: AppBar(
backgroundColor: Color(0xffE8816D),
title: Text(
"TODO",
style: TextStyle(fontSize: 20.0,letterSpacing: 1),
),
actions: <Widget>[
Container(
child: FlatButton(
child: Icon(Icons.add,size: 30,color: Colors.white,),
onPressed: ()
{
// Navigator.push(context, MaterialPageRoute(builder: (context) =>
AddNote() ));
Navigator.push(context, PageTransition(type:
PageTransitionType.rotate,duration: Duration(seconds: 5), child: AddNote()));
},
),
),
],
centerTitle: true,
elevation: 0.0,
),
drawer: Drawer(),
body: Padding(
padding: const EdgeInsets.only(left: 20.0, right: 20.0, top: 10),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: <Widget>[
Container(
padding: EdgeInsets.only(left: 10),
child: Icon(
Icons.account_circle,
size: 50.0,
color: Colors.white,
)),
Container(
padding: EdgeInsets.only(left: 10, top: 10),
child: Text(
"Hello",
style: TextStyle(
fontSize: 50.0,
color: Colors.white,
fontWeight: FontWeight.bold),
),
),
Container(
padding: EdgeInsets.only(left: 10),
child: Text(
"Looks like feel good",
style: TextStyle(
fontSize: 25.0, color: Colors.white70, letterSpacing: 1),
),
),
Container(
padding: EdgeInsets.only(left: 10),
child: Text(
"You have 3 task today",
style: TextStyle(
fontSize: 25.0, color: Colors.white70, letterSpacing: 1),
),
),
Container(
child: Card(
clipBehavior: Clip.antiAliasWithSaveLayer,
child: Column(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
crossAxisAlignment: CrossAxisAlignment.start,
children: <Widget>[
Padding(
padding: const EdgeInsets.only(
top: 10.0, bottom: 10.0, left: 3.0, right: 3.0),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
crossAxisAlignment: CrossAxisAlignment.start,
children: <Widget>[
Icon(
Icons.account_circle,
size: 25,
color: Color(0xffE8816D),
),
Icon(
Icons.more_vert,
size: 25,
color: Color(0xffE8816D),
)
],
),
),
Column(
mainAxisAlignment: MainAxisAlignment.spaceAround,
crossAxisAlignment: CrossAxisAlignment.start,
children: <Widget>[
Container(
padding: EdgeInsets.only(left: 10, top: 70),
child: Text(
"9 Tasks",
style: TextStyle(
color: Colors.black45, fontSize: 25.0),
),
),
Container(
padding: EdgeInsets.only(top: 10, left: 10),
child: Text(
"PERSONAL",
style: TextStyle(
color: Colors.grey,
fontSize: 30.0,
fontWeight: FontWeight.bold),
),
),
Container(
margin: EdgeInsets.only(
top: 40, left: 8.0, right: 8.0, bottom: 20),
padding: EdgeInsets.all(10.0),
child: new LinearPercentIndicator(
width: MediaQuery.of(context).size.width - 100,
lineHeight: 20.0,
percent: 0.9,
center: Text("90.0%"),
progressColor: Color(0xffE8816D),
),
),
],
)
],
),
),
)
],
),
),
),
);
}
}

S-ar putea să vă placă și