[919e07]: / lib / welcome.dart

Download this file

124 lines (119 with data), 4.7 kB

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
import 'package:flutter/material.dart';
import 'package:fyp/HeartDiseaseMonitor/Monitor.dart';
import 'package:fyp/HeartDiseasePrediction/Prediction.dart';
import 'package:fyp/Onboarding/size_config.dart';
import 'package:fyp/utils/side_menu.dart';
class welcome extends StatefulWidget {
welcome({Key? key}) : super(key: key);
@override
State<welcome> createState() => _welcomeState();
}
class _welcomeState extends State<welcome> {
@override
Widget build(BuildContext context) {
SizeConfig().init(context);
double width = SizeConfig.screenW!;
double height = SizeConfig.screenH!;
double blockH = SizeConfig.blockH!;
double blockV = SizeConfig.blockV!;
return Scaffold(
appBar: AppBar(
backgroundColor: const Color.fromRGBO(26, 93, 160, 1),
title: Text(
"CARDIO",
style: TextStyle(fontSize: 20.0, fontWeight: FontWeight.bold),
),
),
endDrawer: const SideMenu(),
body: SafeArea(
child: Column(
children: [
Expanded(
child: Padding(
padding:
EdgeInsets.only(top: 0, bottom: 120, left: 12, right: 12),
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: [
Container(
child: Image.asset(
'assets/images/MainScreen.png',
height: 380,
width: 420,
fit: BoxFit.fill,
),
),
Text(
"CARDIO",
textAlign: TextAlign.center,
style: TextStyle(
fontFamily: "Mulish",
fontSize: 35.0,
fontWeight: FontWeight.w600,
color: Color.fromRGBO(26, 93, 160, 1),
),
),
SizedBox(
height: 15,
),
ElevatedButton(
onPressed: () {
Navigator.pushReplacement(context,
MaterialPageRoute(builder: (context) => Hdp()));
},
child: Text(
"Heart Disease Detector",
),
style: ElevatedButton.styleFrom(
primary: Color.fromRGBO(26, 93, 160, 1),
shape: new RoundedRectangleBorder(
borderRadius: BorderRadius.circular(50),
),
padding: (width <= 550)
? EdgeInsets.symmetric(
horizontal: 50, vertical: 20)
: EdgeInsets.symmetric(
horizontal: width * 0.2, vertical: 25),
textStyle: TextStyle(
fontFamily: "Mulish",
fontWeight: FontWeight.w600,
fontSize: 18,
),
)),
SizedBox(
height: 20,
),
ElevatedButton(
onPressed: () {
Navigator.pushReplacement(context,
MaterialPageRoute(builder: (context) => Htest()));
},
child: Text(
"Heart Disease Monitor",
),
style: ElevatedButton.styleFrom(
primary: Color.fromRGBO(26, 93, 160, 1),
shape: new RoundedRectangleBorder(
borderRadius: BorderRadius.circular(50),
),
padding: (width <= 450)
? EdgeInsets.symmetric(
horizontal: 50, vertical: 20)
: EdgeInsets.symmetric(
horizontal: width * 0.2, vertical: 25),
textStyle: TextStyle(
fontFamily: "Mulish",
fontWeight: FontWeight.w600,
fontSize: 18,
),
)),
],
),
),
),
],
),
),
);
}
}