Skip to content

Commit

Permalink
update all screen
Browse files Browse the repository at this point in the history
  • Loading branch information
LongKhoa0706 committed Aug 29, 2021
1 parent cf7acea commit a8cdbfc
Show file tree
Hide file tree
Showing 15 changed files with 287 additions and 56 deletions.
2 changes: 1 addition & 1 deletion ios/Podfile
@@ -1,5 +1,5 @@
# Uncomment this line to define a global platform for your project
# platform :ios, '9.0'
# platform :ios, '10.0'

# CocoaPods analytics sends network stats synchronously affecting flutter build latency.
ENV['COCOAPODS_DISABLE_STATS'] = 'true'
Expand Down
2 changes: 1 addition & 1 deletion ios/Podfile.lock
Expand Up @@ -24,6 +24,6 @@ SPEC CHECKSUMS:
fluttertoast: 6122fa75143e992b1d3470f61000f591a798cc58
Toast: 91b396c56ee72a5790816f40d3a94dd357abc196

PODFILE CHECKSUM: 8e679eca47255a8ca8067c4c67aab20e64cb974d
PODFILE CHECKSUM: 1d5103e59c34489a395ae7f46690437f27451f42

COCOAPODS: 1.10.1
1 change: 0 additions & 1 deletion lib/main.dart
Expand Up @@ -28,7 +28,6 @@ class MyApp extends StatelessWidget {
ChangeNotifierProvider(create: (_)=>AuthViewModel())
],
child: MaterialApp(
title: 'Flutter Demo',
debugShowCheckedModeBanner: false,
theme: ThemeData(
primarySwatch: Colors.blue,
Expand Down
6 changes: 4 additions & 2 deletions lib/src/view/screen/cart_tab.dart
Expand Up @@ -8,11 +8,13 @@ import 'component/carttab/cart_scroll.dart';
class CartTab extends StatelessWidget {
@override
Widget build(BuildContext context) {
final cartViewModel =Provider.of<CartViewModel>(context,listen: false);

return SafeArea(
child: Container(
child: cartViewModel.listCart.isNotEmpty ? CartScroll(listCart: cartViewModel.listCart) : CartEmptyScreen(),
child: Consumer<CartViewModel>(
builder: (BuildContext context, value, Widget? child) {
return value.listCart.isNotEmpty ? CartScroll(listCart: value.listCart) : CartEmptyScreen() ;
},),
),
);
}
Expand Down
6 changes: 2 additions & 4 deletions lib/src/view/screen/component/carttab/cart_scroll.dart
Expand Up @@ -12,8 +12,6 @@ class CartScroll extends StatelessWidget {
final List<Cart> listCart;
const CartScroll({Key? key, required this.listCart}) : super(key: key);



@override
Widget build(BuildContext context) {
final cartViewModel = Provider.of<CartViewModel>(context, listen: true);
Expand Down Expand Up @@ -52,7 +50,7 @@ class CartScroll extends StatelessWidget {
Row(
children: [
Text(
"MR LONG KHOAr",
"MR JOIN",
style: AppFont.medium.copyWith(
fontWeight: FontWeight.w500,
fontSize: 15,
Expand All @@ -77,7 +75,7 @@ class CartScroll extends StatelessWidget {
height: 10,
),
Text(
"0927827763",
"123456678",
style: AppFont.regular.copyWith(
fontWeight: FontWeight.w400,
color: Colors.black,
Expand Down
30 changes: 30 additions & 0 deletions lib/src/view/screen/component/hometab/body_page.dart
Expand Up @@ -53,6 +53,36 @@ class _BodyPageState extends State<BodyPage> {
},
)
),
SizedBox(
height: 30,
),
buildHeaderBody(title: "New", description: "Supper new"),

SizedBox(
height: 20,
),
SizedBox(
height: cardWidth / 0.59,
child: ListView.builder(
itemCount: prductVM.listProduct?.length,
padding: EdgeInsets.all(0.0),
scrollDirection: Axis.horizontal,
itemBuilder: (_,index){
Product? product = prductVM.listProduct![index];
return InkWell(
onTap: (){
prductVM.addRecentView(product);
Navigator.pushNamed(context,DetailProductScreens,arguments: product);
},
child: CartProduct(
index: index,
product: product,

),
);
},
)
),
// SizedBox(
// height: 40,
// ),
Expand Down
8 changes: 8 additions & 0 deletions lib/src/view/screen/component/otp_screen.dart
@@ -0,0 +1,8 @@
import 'package:flutter/material.dart';

class OtpScreen extends StatelessWidget {
@override
Widget build(BuildContext context) {
return Container();
}
}
2 changes: 1 addition & 1 deletion lib/src/view/screen/detail_product_screen.dart
Expand Up @@ -163,7 +163,7 @@ class _DetailProductScreenState extends State<DetailProductScreen> {
height: 15,
),
Text(
widget.product!.description!,
"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi eget massa ac tellus mattis aliquet ac eu ex. Sed in ex iaculis, mattis ex a, dapibus lectus. Suspendisse aliquam ipsum sit amet nibh lacinia, vel laoreet velit facilisis. Ut lobortis erat velit, vel pulvinar nisi rutrum vitae. Sed fringilla condimentum erat eu sagittis. Maecenas eget lectus accumsan, imperdiet augue ac, commodo tortor. Nulla commodo tempor nisl, a elementum magna vulputate ut. Maecenas augue quam, pulvinar non fermentum non, dignissim quis augue. Sed pretium scelerisque eros, nec blandit diam tempus eu. In hac habitasse platea dictumst. Integer arcu lectus, blandit ut imperdiet pellentesque, laoreet id dolor. Praesent vel nisi vel nisi imperdiet facilisis. Sed metus augue, semper sit amet turpis ac, interdum vestibulum turpis. Nullam vestibulum justo laoreet accumsan efficitur.Cras ac elit a urna tristique suscipit ac a magna. Duis auctor in est sed egestas. Nullam in fringilla tortor, in laoreet tortor. Aliquam ex orci, pellentesque nec sapien ac, ornare mattis erat. Sed a metus metus. Donec urna lacus, iaculis commodo dictum id, fermentum maximus sapien. Phasellus quis ipsum magna. Sed in convallis nibh, ut vehicula augue. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Morbi placerat facilisis metus. Morbi lacinia in enim quis dignissim. Aenean enim justo, tristique at fringilla sed, consequat dapibus orci. Aenean elit urna, porta id ultrices tempus, mollis sed velit.",
style: AppFont.regular.copyWith(
fontWeight: FontWeight.w400,
fontSize: 15,
Expand Down
105 changes: 104 additions & 1 deletion lib/src/view/screen/forgot_pass_screen.dart
@@ -1,8 +1,111 @@
import 'package:fashion_app/src/const/app_colors.dart';
import 'package:fashion_app/src/const/app_font.dart';
import 'package:flutter/material.dart';

class ForgotPassScreen extends StatelessWidget {
@override
Widget build(BuildContext context) {
return Container();
return Container(
color: Colors.white,
child: SafeArea(
child: Scaffold(
resizeToAvoidBottomInset: false,
body: Container(
padding: EdgeInsets.symmetric(horizontal: 15, vertical: 10),
child: Column(
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
IconButton(
onPressed: () => Navigator.pop(context),
alignment: Alignment.topLeft,
padding: EdgeInsets.all(0.0),
icon: Icon(
Icons.arrow_back_ios_rounded,
color: Colors.black,
size: 20,
)),
SizedBox(
height: 15,
),
Text(
"Forgot password",
style: AppFont.bold.copyWith(
color: Colors.black,
fontSize: 32,
fontWeight: FontWeight.bold,
),
),
SizedBox(
height: MediaQuery.of(context).size.height * .1,
),
Text('Please, enter your email address. You will receive a link to create a new password via email.',style: AppFont.medium.copyWith(
fontSize: 14,
fontWeight: FontWeight.normal,
),),
SizedBox(
height: 20,
),
Container(
width: double.infinity,
padding: EdgeInsets.symmetric(horizontal: 10, vertical: 5),
decoration: BoxDecoration(
color: Colors.white,
borderRadius: BorderRadius.circular(5),
boxShadow: [
BoxShadow(
color: Colors.grey.withOpacity(.2),
blurRadius: 1,
spreadRadius: 1,
offset: Offset(1, 1),
),
]),
child: TextFormField(
// controller: passController,
// obscureText: isShowPass,
decoration: InputDecoration(
border: InputBorder.none,
labelText: "Email",
alignLabelWithHint: true,
// center labastyle
labelStyle: AppFont.regular.copyWith(
fontSize: 13,
color: Colors.grey,
fontWeight: FontWeight.w500,
),
),
),
),
SizedBox(
height: 40,
),
SizedBox(
width: double.infinity,
height: 45,
child: ElevatedButton(
style: ElevatedButton.styleFrom(
primary: AppColors.primaryColorRed,
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(40.0),
),
),
onPressed: () {
// authViewModel
// .login()
// .then((value) => Navigator.pop(context));
},
child: Text(
"send".toUpperCase(),
style: AppFont.medium
.copyWith(fontSize: 15, color: Colors.white),
),
),
),
],
),
),
),
),
);
}
}

0 comments on commit a8cdbfc

Please sign in to comment.