Skip to content

Commit

Permalink
Cart three page (lohanidamodar#57)
Browse files Browse the repository at this point in the history
* cart three page design

* cart three screenshot and readme

* cart three page design

* Cart three Readme

* deleting old pictures

Co-authored-by: Aparna16 <[email protected]>
  • Loading branch information
Ambikadulal and Aparna16 authored Jan 28, 2021
1 parent 18d4481 commit 21f048d
Show file tree
Hide file tree
Showing 9 changed files with 203 additions and 1 deletion.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ The code for Springy Widget is taken and refactored from (https://github.com/mat

## Ecommerce

<img height="480px" src="screenshots/cart2.png"> <img height="480px" src="screenshots/ecommerce4.png"> <img height="480px" src="screenshots/checkout1.png"> <img height="480px" src="screenshots/ecommerce_details3.png"> <img height="480px" src="screenshots/home_page1.png"> <img height="480px" src="screenshots/confirm_order1.png"> <img height="480px" src="screenshots/cart1.png"> <img height="480px" src="screenshots/ecommerce1.png"> <img height="480px" src="screenshots/ecommerce2.png"> <img height="480px" src="screenshots/ecommerce_detail1.png"> <img height="480px" src="screenshots/ecommerce_detail2.png">
<img height="480px" src="screenshots/cart3.jpg"> <img height="480px" src="screenshots/cart2.png"> <img height="480px" src="screenshots/ecommerce4.png"> <img height="480px" src="screenshots/checkout1.png"> <img height="480px" src="screenshots/ecommerce_details3.png"> <img height="480px" src="screenshots/home_page1.png"> <img height="480px" src="screenshots/confirm_order1.png"> <img height="480px" src="screenshots/cart1.png"> <img height="480px" src="screenshots/ecommerce1.png"> <img height="480px" src="screenshots/ecommerce2.png"> <img height="480px" src="screenshots/ecommerce_detail1.png"> <img height="480px" src="screenshots/ecommerce_detail2.png">

## User Flow Screens

Expand Down
Binary file added assets/fooditem/plate1.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/fooditem/plate2.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/fooditem/plate3.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/fooditem/plate4.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 2 additions & 0 deletions lib/core/presentation/routes.dart
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ import 'package:flutter_ui_challenges/src/pages/dialogs/dialogs.dart';
import 'package:flutter_ui_challenges/src/pages/todo/todo_home2.dart';
import 'package:flutter_ui_challenges/src/pages/todo/todo_home1.dart';
import 'package:flutter_ui_challenges/src/pages/ecommerce/cart1.dart';
import 'package:flutter_ui_challenges/src/pages/ecommerce/cart3.dart';
import 'package:flutter_ui_challenges/src/pages/profile/profile3.dart';
import 'package:flutter_ui_challenges/src/pages/profile/profile2.dart';
import 'package:flutter_ui_challenges/src/pages/profile/profile1.dart';
Expand Down Expand Up @@ -193,6 +194,7 @@ final List<dynamic> pages = [
path: InvitationPageOne.path),
]),
MenuItem(title: "Ecommerce", icon: Icons.shopping_basket, items: [
SubMenuItem("Cart Three", CartThreePage(), path: CartThreePage.path),
SubMenuItem("Cart Two", CartTwoPage(), path: CartTwoPage.path),
SubMenuItem("Ecommerce Four", EcommerceFourPage(),
path: EcommerceFourPage.path),
Expand Down
199 changes: 199 additions & 0 deletions lib/src/pages/ecommerce/cart3.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,199 @@
import 'package:flutter/material.dart';

/**
* Author: Aparna Dulal
* profile: https://github.com/ambikadulal
*/

class CartThreePage extends StatefulWidget {
static final String path = "lib/src/pages/ecommerece/cart3.dart";

@override
_CartThreePageState createState() => _CartThreePageState();
}

class _CartThreePageState extends State<CartThreePage> {
@override
Widget build(BuildContext context) {
return Scaffold(
backgroundColor: Color(0xFF21BFBD),
body: ListView(
children: <Widget>[
Padding(
padding: EdgeInsets.only(top: 15.0, left: 10.0),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: <Widget>[
IconButton(
icon: Icon(Icons.arrow_back_ios),
color: Colors.white,
onPressed: () {},
),
Container(
width: 125.0,
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: <Widget>[
IconButton(
icon: Icon(Icons.filter_list),
color: Colors.white,
onPressed: () {},
),
IconButton(
icon: Icon(Icons.menu),
color: Colors.white,
onPressed: () {},
)
],
))
],
),
),
SizedBox(height: 25.0),
Padding(
padding: EdgeInsets.only(left: 40.0),
child: Row(
children: <Widget>[
Text('Delicious',
style: TextStyle(
fontFamily: 'Montserrat',
color: Colors.white,
fontWeight: FontWeight.bold,
fontSize: 25.0)),
SizedBox(width: 10.0),
Text('Food',
style: TextStyle(
fontFamily: 'Montserrat',
color: Colors.white,
fontSize: 25.0))
],
),
),
SizedBox(height: 40.0),
Container(
height: MediaQuery.of(context).size.height - 185.0,
decoration: BoxDecoration(
color: Colors.white,
borderRadius: BorderRadius.only(topLeft: Radius.circular(75.0)),
),
child: ListView(
primary: false,
padding: EdgeInsets.only(left: 25.0, right: 20.0),
children: <Widget>[
Padding(
padding: EdgeInsets.only(top: 45.0),
child: Container(
height: MediaQuery.of(context).size.height - 300.0,
child: ListView(children: [
_buildFoodItem('assets/fooditem/plate1.jpg',
'Salmon bowl', '\$25.00'),
_buildFoodItem('assets/fooditem/plate2.jpg',
'Spring bowl', '\$20.00'),
_buildFoodItem('assets/fooditem/plate3.jpg',
'Avocado bowl', '\$26.00'),
_buildFoodItem('assets/fooditem/plate4.jpg',
'Berry bowl', '\$14.00')
]))),
Row(
mainAxisAlignment: MainAxisAlignment.spaceEvenly,
children: <Widget>[
Container(
height: 65.0,
width: 60.0,
decoration: BoxDecoration(
border: Border.all(
color: Colors.grey,
style: BorderStyle.solid,
width: 1.0),
borderRadius: BorderRadius.circular(10.0),
),
child: Center(
child: Icon(Icons.search, color: Colors.black),
),
),
Container(
height: 65.0,
width: 60.0,
decoration: BoxDecoration(
border: Border.all(
color: Colors.grey,
style: BorderStyle.solid,
width: 1.0),
borderRadius: BorderRadius.circular(10.0),
),
child: Center(
child: Icon(Icons.shopping_basket, color: Colors.black),
),
),
Container(
height: 65.0,
width: 120.0,
decoration: BoxDecoration(
border: Border.all(
color: Colors.grey,
style: BorderStyle.solid,
width: 1.0),
borderRadius: BorderRadius.circular(10.0),
color: Color(0xFF1C1428)),
child: Center(
child: Text('Checkout',
style: TextStyle(
fontFamily: 'Montserrat',
color: Colors.white,
fontSize: 15.0))),
)
],
)
],
),
)
],
),
);
}

Widget _buildFoodItem(String imgPath, String foodName, String price) {
return Padding(
padding: EdgeInsets.only(left: 10.0, right: 10.0, top: 10.0),
child: InkWell(
onTap: () {
Navigator.of(context).push(MaterialPageRoute(
//builder:
));
},
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: <Widget>[
Container(
child: Row(children: [
Hero(
tag: imgPath,
child: Image(
image: AssetImage(imgPath),
fit: BoxFit.cover,
height: 75.0,
width: 75.0)),
SizedBox(width: 10.0),
Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(foodName,
style: TextStyle(
fontFamily: 'Montserrat',
fontSize: 17.0,
fontWeight: FontWeight.bold)),
Text(price,
style: TextStyle(
fontFamily: 'Montserrat',
fontSize: 15.0,
color: Colors.grey))
])
])),
IconButton(
icon: Icon(Icons.add),
color: Colors.black,
onPressed: () {})
],
)));
}
}
1 change: 1 addition & 0 deletions pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ flutter:
- assets/smwallet/
- assets/hotel/
- assets/icon/
- assets/fooditem/
- assets/flare/
- lib/src/pages/animations/
- lib/src/pages/animations/animation1/
Expand Down
Binary file added screenshots/cart3.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 21f048d

Please sign in to comment.