import 'package:diplomaticquarterapp/config/size_config.dart'; import 'package:diplomaticquarterapp/routes.dart'; import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart'; import 'package:diplomaticquarterapp/widgets/buttons/defaultButton.dart'; import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart'; import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; class WelcomeLogin extends StatefulWidget { @override _WelcomeLogin createState() => _WelcomeLogin(); } class _WelcomeLogin extends State { bool isLoading = true; @override void initState() { isLoading = true; // checkUser(context); super.initState(); } Widget build(BuildContext context) { return AppScaffold( appBarTitle: TranslationBase.of(context).welcome, isShowDecPage: false, isShowAppBar: true, body: Padding( padding: EdgeInsets.all(20), child: Column( children: [ Expanded( flex: 6, child: Column( mainAxisAlignment: MainAxisAlignment.spaceEvenly, crossAxisAlignment: CrossAxisAlignment.start, children: [ Image.asset('assets/images/DQ/dq_logo_icon.png', height: 90, width: 90), Text( TranslationBase.of(context).welcome, style: TextStyle( fontSize: 30, fontWeight: FontWeight.bold), textAlign: TextAlign.start, ), Text( TranslationBase.of(context).welcomeText, style: TextStyle(fontSize: 24), textAlign: TextAlign.start, ), Text( TranslationBase.of(context).welcomeText2, style: TextStyle(fontSize: 24), textAlign: TextAlign.start, ), SizedBox( height: SizeConfig.realScreenHeight * .15, ) ]), ), Expanded( flex: 2, child: Column( //mainAxisAlignment: MainAxisAlignment.end, mainAxisAlignment: MainAxisAlignment.spaceEvenly, children: [ Row( children: [ Expanded( child: DefaultButton( TranslationBase.of(context).yes, () => { Navigator.of(context).pushNamed( LOGIN_TYPE, ), }, color: Color(0xFF40ACC9), textColor: Colors.white, )) ], ), Row( children: [ Expanded( child: DefaultButton( TranslationBase.of(context).no, () => { Navigator.of(context).pushNamed( REGISTER, ) }, )) ], ), ], )) ], ))); } }