delivery information design update

design_update
hussam al-habibeh 5 years ago
parent 00e108e36c
commit c5987bcbdf

File diff suppressed because one or more lines are too long

@ -1,3 +1,4 @@
import 'package:driverapp/widgets/data_display/circle-container.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import '../../uitl/date_uitl.dart'; import '../../uitl/date_uitl.dart';
@ -16,25 +17,27 @@ class CustomerBriefCard extends StatelessWidget {
final double latitude; final double latitude;
final bool showDistance; final bool showDistance;
CustomerBriefCard( CustomerBriefCard({
{this.itemId, this.itemId,
this.time, this.time,
this.customerFirstName, this.customerFirstName,
this.customerLastName, this.customerLastName,
this.mobileNo, this.mobileNo,
this.direction, this.direction,
this.totalPayment, this.totalPayment,
this.deliveryTime, this.deliveryTime,
this.longitude, this.longitude,
this.latitude, this.latitude,
this.showDistance = true, this.showDistance = true,
}); });
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
return Center( return Center(
child: Container( child: Container(
width: 350, width: MediaQuery.of(context).orientation == Orientation.landscape
? 580
: 370,
height: 270, height: 270,
decoration: BoxDecoration( decoration: BoxDecoration(
color: Colors.white, color: Colors.white,
@ -66,43 +69,39 @@ class CustomerBriefCard extends StatelessWidget {
style: TextStyle(color: Color(0xFFADACAD)), style: TextStyle(color: Color(0xFFADACAD)),
), ),
), ),
Visibility( Expanded(
visible: showDistance, child: Padding(
child: Expanded( padding: EdgeInsets.all(8.0),
child: CircleAvatar( child: CircleContainer(
backgroundColor: Colors.black45, borderWidth: 0.9,
radius: 28.0, child: Text(
child: CircleAvatar( '0 K.m\naway',
backgroundColor: Colors.white, style: TextStyle(
maxRadius: 26.1, color: Color(0xff42B6AD),
child: Padding( fontWeight: FontWeight.w800,
padding: const EdgeInsets.only(left: 3), fontStyle: FontStyle.normal),
child: Text(
'3 K.m \n away',
style: TextStyle(
color: Color(0xff30B7B9),
fontSize: 12.5,
fontWeight: FontWeight.w600),
),
),
), ),
), ),
), ),
), ),
], ],
), ),
SizedBox(height: MediaQuery.of(context).size.width * 0.02,), SizedBox(
height: MediaQuery.of(context).size.width * 0.02,
),
Text( Text(
'${customerFirstName} ${customerLastName}', '${customerFirstName} ${customerLastName}',
style: TextStyle(fontSize: 20, fontWeight: FontWeight.w900), style: TextStyle(fontSize: 20, fontWeight: FontWeight.w900),
), ),
SizedBox(height: MediaQuery.of(context).size.width * 0.019,), SizedBox(
height: MediaQuery.of(context).size.width * 0.019,
),
Text( Text(
mobileNo, mobileNo,
style: TextStyle(color: Color(0xFF50BDC5)), style: TextStyle(color: Color(0xFF50BDC5)),
), ),
SizedBox( SizedBox(
height:MediaQuery.of(context).size.width*0.005, height: MediaQuery.of(context).size.width * 0.005,
), ),
// Text( // Text(
// 'Olaya street, behind KFC resturant, next to kingdom towers 2nd floor ofice 277', // 'Olaya street, behind KFC resturant, next to kingdom towers 2nd floor ofice 277',
@ -149,7 +148,7 @@ class CustomerBriefCard extends StatelessWidget {
], ],
), ),
SizedBox( SizedBox(
height: MediaQuery.of(context).size.width*0.03, height: MediaQuery.of(context).size.width * 0.03,
), ),
Row( Row(
children: <Widget>[ children: <Widget>[

Loading…
Cancel
Save