Created login screen with logo inside
This commit is contained in:
parent
2ba6dbbbc6
commit
5bfafb2101
4 changed files with 32 additions and 10 deletions
|
|
@ -1,19 +1,14 @@
|
||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
import 'widgets/logo.dart';
|
import 'screens/login_screen.dart';
|
||||||
|
|
||||||
class App extends StatelessWidget {
|
class App extends StatelessWidget {
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
return MaterialApp(
|
return MaterialApp(
|
||||||
title: 'Do more',
|
title: 'Do more',
|
||||||
//home: Text('Start'),
|
//home: Text('Start'),
|
||||||
home: Scaffold(
|
home: LoginScreen(),
|
||||||
appBar: AppBar(
|
theme: ThemeData(
|
||||||
title: Text('DO>'),
|
canvasColor: Color.fromRGBO(23, 25, 29, 1.0),
|
||||||
),
|
|
||||||
body: Container(
|
|
||||||
color: Colors.blue,
|
|
||||||
child: Logo(),
|
|
||||||
),
|
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
27
lib/src/screens/login_screen.dart
Normal file
27
lib/src/screens/login_screen.dart
Normal file
|
|
@ -0,0 +1,27 @@
|
||||||
|
import 'package:flutter/material.dart';
|
||||||
|
|
||||||
|
import '../widgets/logo.dart';
|
||||||
|
|
||||||
|
class LoginScreen extends StatelessWidget {
|
||||||
|
Widget build(BuildContext context) {
|
||||||
|
return Scaffold(
|
||||||
|
body: Container(
|
||||||
|
color: Theme.of(context).canvasColor,
|
||||||
|
child: Column(
|
||||||
|
children: <Widget>[
|
||||||
|
Expanded(
|
||||||
|
child: Center(
|
||||||
|
child: Logo(),
|
||||||
|
),
|
||||||
|
flex: 4,
|
||||||
|
),
|
||||||
|
Expanded(
|
||||||
|
child: Text('Login Buton'),
|
||||||
|
flex: 1,
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -8,7 +8,7 @@ class Logo extends StatelessWidget {
|
||||||
|
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
return Container(
|
return Container(
|
||||||
width: 165,
|
width: 158,
|
||||||
child: Stack(
|
child: Stack(
|
||||||
children: <Widget>[
|
children: <Widget>[
|
||||||
Text(
|
Text(
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue