fix coloring issue

merge-requests/420/head
Elham Rababh 5 years ago
parent 58d43f7e46
commit 7de8c2588f

@ -31,7 +31,7 @@ class FooterWidget extends StatefulWidget {
}
class _FooterWidgetState extends State<FooterWidget> {
double quantityUI = 70;
double quantityUI = 80;
bool showUI = false;
AuthenticatedUserObject authenticatedUserObject =
locator<AuthenticatedUserObject>();
@ -77,7 +77,7 @@ class _FooterWidgetState extends State<FooterWidget> {
child: Icon(Icons.close, color: Colors.black),
onTap: () {
setState(() {
quantityUI = 70;
quantityUI = 80;
showUI = false;
});
},
@ -172,7 +172,7 @@ class _FooterWidgetState extends State<FooterWidget> {
onPressed: () {
setState(() {
if (showUI) {
quantityUI = 70;
quantityUI = 80;
showUI = false;
} else {
quantityUI = 150;
@ -189,7 +189,7 @@ class _FooterWidgetState extends State<FooterWidget> {
disabled: !widget.isAvailable && widget.quantity > 0 ||
widget.quantity > widget.quantityLimit ||
widget.item.rxMessage != null,
disableColor: Colors.green[400],
disableColor: Color(0xFF4CAF50),
onTap: () async {
if (!authenticatedUserObject.isLogin) {
Navigator.of(context).pushNamed(
@ -199,8 +199,9 @@ class _FooterWidgetState extends State<FooterWidget> {
await widget.addToCartFunction(
widget.quantity, widget.item.id, context);
},
borderColor: Color(0xFF4CAF50),
borderRadius: 5,
color: Colors.green,
color: Color(0xFF4CAF50),
),
),
SizedBox(

@ -64,12 +64,12 @@ class _ProductNameAndPriceState extends State<ProductNameAndPrice> {
: Colors.green,
),
// SizedBox(width: 20),
if(widget.authenticatedUserObject.isLogin)
if (widget.authenticatedUserObject.isLogin)
widget.item.stockAvailability == 'Out of stock' &&
widget.customerId != null
? InkWell(
onTap: () =>
widget.notifyMeWhenAvailable(context, widget.item.id),
onTap: () => widget.notifyMeWhenAvailable(
context, widget.item.id),
child: Row(children: [
Texts(
TranslationBase.of(context).notifyMe,
@ -88,7 +88,9 @@ class _ProductNameAndPriceState extends State<ProductNameAndPrice> {
icon: !widget.isInWishList
? Icons.favorite_border
: Icons.favorite,
color: !widget.isInWishList ? Colors.white : Colors.red,
color: !widget.isInWishList
? Colors.white
: Colors.red[800],
onPress: () async {
{
if (widget.customerId != null) {
@ -163,29 +165,32 @@ class _ProductNameAndPriceState extends State<ProductNameAndPrice> {
"(${widget.item.approvedTotalReviews}${TranslationBase.of(context).review})",
fontSize: 12,
),
],
),
),
SizedBox(
width: 70,
),
Expanded(
flex: 1,
child: Container(
child: widget.item.rxMessage != null
? Text(
if (widget.item.rxMessage != null)
Row(
children: [
Text(
projectViewModel.isArabic
? widget.item.rxMessagen.toString()
: widget.item.rxMessage.toString(),
style: TextStyle(color: Colors.red, fontSize: 10),
)
: Container()),
),
widget.item.rxMessage != null
? Icon(
SizedBox(
width: 5,
),
Icon(
FontAwesomeIcons.questionCircle,
color: Colors.red,
size: 15.0,
)
: Container(),
],
)
],
),
),
),
],
),
),

@ -17,12 +17,14 @@ class IconWithBg extends StatelessWidget {
color: Colors.grey[200],
borderRadius: BorderRadius.circular(30),
),
child: Center(
child: IconButton(
icon: Icon(icon),
icon: Icon(icon, size: 20,),
color: color,
onPressed: () async {
onPress();
},
),
));
}
}

@ -43,7 +43,7 @@ class ProductAppBar extends StatelessWidget with PreferredSizeWidget {
Row(
children: [
IconWithBg(
icon: Icons.arrow_back_ios,
icon: Icons.arrow_back,
color: Colors.grey,
onPress: () {
Navigator.pop(context);
@ -56,7 +56,7 @@ class ProductAppBar extends StatelessWidget with PreferredSizeWidget {
children: [
IconWithBg(
icon: Icons.shopping_cart,
color: Colors.grey,
color: Colors.grey[800],
onPress: () {
Navigator.push(
context,

Loading…
Cancel
Save