class Login extends StatefulWidget{ @override _loginUser createState()=>_loginUser(); } class _loginUser extends State<Login>{ @override Widget build(BuildContext context) { // TODO: implement build return MaterialApp( debugShowCheckedModeBanner: false, home: Container( decoration: BoxDecoration( image: DecorationImage( image: AssetImage("images/images.png"), fit: BoxFit.cover)), child: Scaffold( backgroundColor: Colors.transparent, body: Container( child: Center( child: Column( mainAxisAlignment: MainAxisAlignment.center, children: <Widget>[ Text( "Login", style: TextStyle( color: Colors.black, fontSize: 30.0, fontWeight: FontWeight.bold), ), Padding( padding: EdgeInsets.only(top: 40.0), ), Padding( padding: EdgeInsets.fromLTRB(22.0, 0.0, 22.0, 10.0), child: TextFormField( textAlign: TextAlign.left, style: TextStyle( color: Colors.black, ), decoration: InputDecoration( prefixIcon: Icon(Icons.email,color: Colors.white,), hintText: 'Email', contentPadding: EdgeInsets.fromLTRB(10.0, 10.0, 10.0, 10.0), border: OutlineInputBorder( borderSide: BorderSide(color: Colors.white), ), ), ), ), Padding( padding: EdgeInsets.fromLTRB(22.0, 0.0, 22.0, 10.0), child: TextFormField( textAlign: TextAlign.left, style: TextStyle( color: Colors.black, ), decoration: InputDecoration( prefixIcon: Icon(Icons.lock_open,color: Colors.white,), hintText: 'Password', contentPadding: EdgeInsets.fromLTRB(10.0, 10.0, 10.0, 10.0), border: OutlineInputBorder( borderSide: BorderSide(color: Colors.grey), ), ), ), ), Padding( padding: EdgeInsets.fromLTRB(22.0, 0.0, 22.0, 22.0), child: Row( children: <Widget>[ Expanded( flex: 1, child: ButtonTheme( minWidth: 200.0, height: 40.0, buttonColor: Colors.lightBlue, child: RaisedButton( elevation: 8.0, shape: OutlineInputBorder( borderSide: BorderSide(color: Colors.lightBlue), borderRadius: BorderRadius.circular(5.0), ), onPressed: () { Navigator.push(context, MaterialPageRoute(builder: (context)=>HomePage())); }, child: Text( 'Login', style: TextStyle( fontSize: 16.0, color: Colors.white), ), ), ), ), Padding(padding: EdgeInsets.fromLTRB(5.0,0.0,5.0,0.0),), Expanded( flex: 1, child: ButtonTheme( minWidth: 200.0, height: 40.0, buttonColor: Colors.orangeAccent, child: RaisedButton( elevation: 8.0, shape: OutlineInputBorder( borderSide: BorderSide(color: Colors.orangeAccent), borderRadius: BorderRadius.circular(5.0), ), onPressed: () { Navigator.push(context, MaterialPageRoute(builder: (context)=>Register())); }, child: Text( 'Register', style: TextStyle( fontSize: 16.0, color: Colors.white), ), ), ), ), ], ), ), ], ), )), ), ), ); } }
Saturday, December 8, 2018
Login Page
Subscribe to:
Post Comments (Atom)
How to save contact number in flutter
with contacts_service: 0.3.10 https://pub.dev/packages/contacts_service Future < void > contactSave (){ Contact contac...
-
class Login extends StatefulWidget{ @override _loginUser createState()=>_loginUser(); } class _loginUser extends State<Login>{...
-
1) Hot Reload You modified your code won’t to be re – executed. This codes are sent into a running Dart Virtual Machine. VM reloads all t...
No comments:
Post a Comment