upgrade-to-flutter-3 #1
|
@ -2,6 +2,7 @@ import 'package:flutter/material.dart';
|
||||||
import 'package:pin_code_fields/pin_code_fields.dart';
|
import 'package:pin_code_fields/pin_code_fields.dart';
|
||||||
import 'package:robo_advisory/utils/constants.dart';
|
import 'package:robo_advisory/utils/constants.dart';
|
||||||
import 'package:robo_advisory/config/Routes.dart';
|
import 'package:robo_advisory/config/Routes.dart';
|
||||||
|
import 'package:robo_advisory/widgets/buttons.dart';
|
||||||
|
|
||||||
class LoginScreen extends StatelessWidget {
|
class LoginScreen extends StatelessWidget {
|
||||||
bool rememberSwitch = false;
|
bool rememberSwitch = false;
|
||||||
|
@ -21,7 +22,7 @@ class LoginScreen extends StatelessWidget {
|
||||||
Expanded(
|
Expanded(
|
||||||
child: Container(
|
child: Container(
|
||||||
child: Center(
|
child: Center(
|
||||||
child: TextButton(
|
child: ElevatedButton(
|
||||||
onPressed: () {
|
onPressed: () {
|
||||||
Navigator.pushNamed(context, Routes.register);
|
Navigator.pushNamed(context, Routes.register);
|
||||||
},
|
},
|
||||||
|
@ -123,14 +124,7 @@ class LoginScreen extends StatelessWidget {
|
||||||
SizedBox(
|
SizedBox(
|
||||||
width: double.infinity,
|
width: double.infinity,
|
||||||
child: ElevatedButton(
|
child: ElevatedButton(
|
||||||
style: ElevatedButton.styleFrom(
|
style: mainButtonStyle(),
|
||||||
padding: EdgeInsets.all(18.0),
|
|
||||||
shape: RoundedRectangleBorder(
|
|
||||||
borderRadius: BorderRadius.circular(18.0),
|
|
||||||
),
|
|
||||||
backgroundColor:Color(0xFF495057),
|
|
||||||
foregroundColor: Colors.white,
|
|
||||||
),
|
|
||||||
onPressed: () {
|
onPressed: () {
|
||||||
Navigator.pushNamed(context, Routes.dashboard);
|
Navigator.pushNamed(context, Routes.dashboard);
|
||||||
},
|
},
|
||||||
|
|
|
@ -2,6 +2,7 @@ import 'package:flutter/material.dart';
|
||||||
import 'package:pin_code_fields/pin_code_fields.dart';
|
import 'package:pin_code_fields/pin_code_fields.dart';
|
||||||
import 'package:robo_advisory/utils/constants.dart';
|
import 'package:robo_advisory/utils/constants.dart';
|
||||||
import 'package:robo_advisory/screens/register/register_step_2.dart';
|
import 'package:robo_advisory/screens/register/register_step_2.dart';
|
||||||
|
import 'package:robo_advisory/widgets/buttons.dart';
|
||||||
|
|
||||||
class RegisterFirstScreen extends StatelessWidget {
|
class RegisterFirstScreen extends StatelessWidget {
|
||||||
@override
|
@override
|
||||||
|
@ -90,15 +91,7 @@ class RegisterFirstScreen extends StatelessWidget {
|
||||||
SizedBox(
|
SizedBox(
|
||||||
width: double.infinity,
|
width: double.infinity,
|
||||||
child: ElevatedButton(
|
child: ElevatedButton(
|
||||||
style: ElevatedButton.styleFrom(
|
style: mainButtonStyle(),
|
||||||
backgroundColor: Color(0xFF495057),
|
|
||||||
foregroundColor: Colors.white,
|
|
||||||
padding: EdgeInsets.all(18.0),
|
|
||||||
shape: RoundedRectangleBorder(
|
|
||||||
borderRadius: BorderRadius.circular(18.0),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
|
|
||||||
onPressed: () {
|
onPressed: () {
|
||||||
Navigator.push(
|
Navigator.push(
|
||||||
context,
|
context,
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
import 'package:robo_advisory/utils/constants.dart';
|
import 'package:robo_advisory/utils/constants.dart';
|
||||||
import 'package:robo_advisory/config/Routes.dart';
|
import 'package:robo_advisory/config/Routes.dart';
|
||||||
|
import 'package:robo_advisory/widgets/buttons.dart';
|
||||||
|
|
||||||
class RegisterSecondScreen extends StatelessWidget {
|
class RegisterSecondScreen extends StatelessWidget {
|
||||||
@override
|
@override
|
||||||
|
@ -57,14 +58,7 @@ class RegisterSecondScreen extends StatelessWidget {
|
||||||
SizedBox(
|
SizedBox(
|
||||||
width: double.infinity,
|
width: double.infinity,
|
||||||
child: ElevatedButton(
|
child: ElevatedButton(
|
||||||
style: ElevatedButton.styleFrom(
|
style: mainButtonStyle(),
|
||||||
backgroundColor: Color(0xFF495057),
|
|
||||||
foregroundColor: Colors.white,
|
|
||||||
padding: EdgeInsets.all(18.0),
|
|
||||||
shape: RoundedRectangleBorder(
|
|
||||||
borderRadius: BorderRadius.circular(18.0),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
onPressed: () {
|
onPressed: () {
|
||||||
Navigator.pushNamed(context, Routes.dashboard);
|
Navigator.pushNamed(context, Routes.dashboard);
|
||||||
print('Next Step');
|
print('Next Step');
|
||||||
|
|
11
lib/widgets/buttons.dart
Normal file
11
lib/widgets/buttons.dart
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
import 'package:flutter/material.dart';
|
||||||
|
|
||||||
|
mainButtonStyle() {
|
||||||
|
return ElevatedButton.styleFrom(
|
||||||
|
backgroundColor: Color(0xFF495057),
|
||||||
|
foregroundColor: Colors.white,
|
||||||
|
padding: EdgeInsets.all(18.0),
|
||||||
|
shape: RoundedRectangleBorder(
|
||||||
|
borderRadius: BorderRadius.circular(18.0),
|
||||||
|
));
|
||||||
|
}
|
Loading…
Reference in a new issue