344 lines
12 KiB
Dart
344 lines
12 KiB
Dart
import 'package:easycook_mobile/pages/home.dart';
|
|
import 'package:easycook_mobile/theme.dart';
|
|
import 'package:flutter/material.dart';
|
|
import 'package:google_fonts/google_fonts.dart';
|
|
|
|
class GoalsPage extends StatefulWidget {
|
|
@override
|
|
State<GoalsPage> createState() => _GoalsPageState();
|
|
}
|
|
|
|
class _GoalsPageState extends State<GoalsPage> {
|
|
int? _radioValue = 0;
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return Scaffold(
|
|
body: Container(
|
|
padding: EdgeInsets.only(top: 112, left: 45, right: 45, bottom: 50),
|
|
decoration: BoxDecoration(
|
|
image: DecorationImage(
|
|
image: AssetImage('images/BG.png'),
|
|
fit: BoxFit.fill,
|
|
),
|
|
),
|
|
child: Column(
|
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
children: [
|
|
// Tittle
|
|
Text(
|
|
'Apa tujuan anda?',
|
|
style: GoogleFonts.montserrat().copyWith(
|
|
fontSize: 14,
|
|
fontWeight: FontWeight.bold,
|
|
),
|
|
textAlign: TextAlign.center,
|
|
),
|
|
// Personalisasi
|
|
Row(
|
|
mainAxisAlignment: MainAxisAlignment.center,
|
|
children: [
|
|
// Belajar Memasak
|
|
Container(
|
|
decoration: BoxDecoration(
|
|
color: Colors.white,
|
|
borderRadius: BorderRadius.circular(10),
|
|
),
|
|
width: 130,
|
|
height: 140,
|
|
child: Column(
|
|
children: <Widget>[
|
|
Container(
|
|
width: 130,
|
|
height: 90,
|
|
decoration: BoxDecoration(
|
|
image: DecorationImage(
|
|
image: AssetImage('images/Learn.png'),
|
|
fit: BoxFit.cover,
|
|
),
|
|
borderRadius: BorderRadius.only(
|
|
topLeft: Radius.circular(10),
|
|
topRight: Radius.circular(10),
|
|
),
|
|
),
|
|
),
|
|
Row(
|
|
children: [
|
|
Radio(
|
|
value: 1,
|
|
groupValue: _radioValue,
|
|
onChanged: (value) {
|
|
setState(() {
|
|
_radioValue = value as int?;
|
|
});
|
|
},
|
|
),
|
|
Expanded(
|
|
child: Text(
|
|
'Belajar Memasak',
|
|
style: GoogleFonts.montserrat().copyWith(
|
|
fontSize: 14,
|
|
fontWeight: FontWeight.bold,
|
|
),
|
|
),
|
|
),
|
|
],
|
|
),
|
|
],
|
|
),
|
|
),
|
|
SizedBox(
|
|
width: 29,
|
|
),
|
|
// Mencoba Resep
|
|
Container(
|
|
decoration: BoxDecoration(
|
|
color: Colors.white,
|
|
borderRadius: BorderRadius.circular(10),
|
|
),
|
|
width: 130,
|
|
height: 140,
|
|
child: Column(
|
|
children: <Widget>[
|
|
Container(
|
|
width: 130,
|
|
height: 90,
|
|
decoration: BoxDecoration(
|
|
image: DecorationImage(
|
|
image: AssetImage('images/Try.png'),
|
|
fit: BoxFit.cover,
|
|
),
|
|
borderRadius: BorderRadius.only(
|
|
topLeft: Radius.circular(10),
|
|
topRight: Radius.circular(10),
|
|
),
|
|
),
|
|
),
|
|
Row(
|
|
children: [
|
|
Radio(
|
|
value: 2,
|
|
groupValue: _radioValue,
|
|
onChanged: (value) {
|
|
setState(() {
|
|
_radioValue = value as int?;
|
|
});
|
|
},
|
|
),
|
|
Expanded(
|
|
child: Text(
|
|
'Mencoba Resep',
|
|
style: GoogleFonts.montserrat().copyWith(
|
|
fontSize: 14,
|
|
fontWeight: FontWeight.bold,
|
|
),
|
|
),
|
|
),
|
|
],
|
|
),
|
|
],
|
|
),
|
|
),
|
|
],
|
|
),
|
|
Row(
|
|
mainAxisAlignment: MainAxisAlignment.center,
|
|
children: [
|
|
// Menabung
|
|
Container(
|
|
decoration: BoxDecoration(
|
|
color: Colors.white,
|
|
borderRadius: BorderRadius.circular(10),
|
|
),
|
|
width: 120,
|
|
height: 140,
|
|
child: Column(
|
|
children: <Widget>[
|
|
Container(
|
|
width: 130,
|
|
height: 90,
|
|
decoration: BoxDecoration(
|
|
image: DecorationImage(
|
|
image: AssetImage('images/Saving.png'),
|
|
fit: BoxFit.cover,
|
|
),
|
|
borderRadius: BorderRadius.only(
|
|
topLeft: Radius.circular(10),
|
|
topRight: Radius.circular(10),
|
|
),
|
|
),
|
|
),
|
|
Row(
|
|
children: [
|
|
Radio(
|
|
value: 3,
|
|
groupValue: _radioValue,
|
|
onChanged: (value) {
|
|
setState(() {
|
|
_radioValue = value as int?;
|
|
});
|
|
},
|
|
),
|
|
Expanded(
|
|
child: Text(
|
|
'Menabung',
|
|
style: GoogleFonts.montserrat().copyWith(
|
|
fontSize: 14,
|
|
fontWeight: FontWeight.bold,
|
|
),
|
|
),
|
|
),
|
|
],
|
|
),
|
|
],
|
|
),
|
|
),
|
|
SizedBox(
|
|
width: 29,
|
|
),
|
|
// Makanan Sehat
|
|
Container(
|
|
decoration: BoxDecoration(
|
|
color: Colors.white,
|
|
borderRadius: BorderRadius.circular(10),
|
|
),
|
|
width: 120,
|
|
height: 140,
|
|
child: Column(
|
|
children: <Widget>[
|
|
Container(
|
|
width: 130,
|
|
height: 90,
|
|
decoration: BoxDecoration(
|
|
image: DecorationImage(
|
|
image: AssetImage('images/Healty.png'),
|
|
fit: BoxFit.cover,
|
|
),
|
|
borderRadius: BorderRadius.only(
|
|
topLeft: Radius.circular(10),
|
|
topRight: Radius.circular(10),
|
|
),
|
|
),
|
|
),
|
|
Row(
|
|
children: [
|
|
Radio(
|
|
value: 4,
|
|
groupValue: _radioValue,
|
|
onChanged: (value) {
|
|
setState(() {
|
|
_radioValue = value as int?;
|
|
});
|
|
},
|
|
),
|
|
Expanded(
|
|
child: Text(
|
|
'Makanan Sehat',
|
|
style: GoogleFonts.montserrat().copyWith(
|
|
fontSize: 14,
|
|
fontWeight: FontWeight.bold,
|
|
),
|
|
),
|
|
),
|
|
],
|
|
),
|
|
],
|
|
),
|
|
),
|
|
],
|
|
),
|
|
Row(
|
|
mainAxisAlignment: MainAxisAlignment.center,
|
|
children: [
|
|
// Dijual
|
|
Container(
|
|
decoration: BoxDecoration(
|
|
color: Colors.white,
|
|
borderRadius: BorderRadius.circular(10),
|
|
),
|
|
width: 120,
|
|
height: 140,
|
|
child: Column(
|
|
children: <Widget>[
|
|
Container(
|
|
width: 130,
|
|
height: 90,
|
|
decoration: BoxDecoration(
|
|
image: DecorationImage(
|
|
image: AssetImage('images/Sale.png'),
|
|
fit: BoxFit.cover,
|
|
),
|
|
borderRadius: BorderRadius.only(
|
|
topLeft: Radius.circular(10),
|
|
topRight: Radius.circular(10),
|
|
),
|
|
),
|
|
),
|
|
Row(
|
|
children: [
|
|
Radio(
|
|
value: 5,
|
|
groupValue: _radioValue,
|
|
onChanged: (value) {
|
|
setState(() {
|
|
_radioValue = value as int?;
|
|
});
|
|
},
|
|
),
|
|
Expanded(
|
|
child: Text(
|
|
'Dijual',
|
|
style: GoogleFonts.montserrat().copyWith(
|
|
fontSize: 14,
|
|
fontWeight: FontWeight.bold,
|
|
),
|
|
),
|
|
),
|
|
],
|
|
),
|
|
],
|
|
),
|
|
),
|
|
SizedBox(
|
|
width: 29,
|
|
),
|
|
],
|
|
),
|
|
// Button
|
|
Row(
|
|
children: [
|
|
SizedBox(
|
|
height: 48,
|
|
width: 300,
|
|
child: TextButton(
|
|
style: TextButton.styleFrom(
|
|
backgroundColor: Colors.amber,
|
|
shape: RoundedRectangleBorder(
|
|
borderRadius: BorderRadius.circular(20),
|
|
),
|
|
),
|
|
onPressed: () {
|
|
Navigator.push(
|
|
context,
|
|
MaterialPageRoute(
|
|
builder: (context) => HomePage(),
|
|
),
|
|
);
|
|
},
|
|
child: Text(
|
|
'Selesai',
|
|
style: GoogleFonts.montserrat().copyWith(
|
|
color: Colors.white,
|
|
fontWeight: FontWeight.bold,
|
|
),
|
|
),
|
|
),
|
|
),
|
|
],
|
|
)
|
|
],
|
|
),
|
|
),
|
|
);
|
|
}
|
|
}
|