tender screen changes

This commit is contained in:
amirrezaghabeli
2025-08-10 08:28:45 +03:30
parent 1973097a42
commit 988380e95e
8 changed files with 174 additions and 57 deletions
@@ -9,16 +9,24 @@ class TenderActionButtons extends StatelessWidget {
final VoidCallback? onLike;
final VoidCallback? onDislike;
final VoidCallback? onClose;
final VoidCallback? onReject;
final VoidCallback? onSubmit;
final bool isLiked;
final bool isDisliked;
final bool rejected;
final bool submitted;
const TenderActionButtons({
super.key,
this.onLike,
this.onDislike,
this.onClose,
this.onReject,
this.onSubmit,
this.isLiked = false,
this.isDisliked = false,
this.rejected = false,
this.submitted = false,
});
@override
@@ -31,31 +39,129 @@ class TenderActionButtons extends StatelessWidget {
// Dislike button
GestureDetector(
onTap: onDislike,
child: SvgPicture.asset(
width: 32.0.w(),
height: 32.0.w(),
fit: BoxFit.cover,
AssetsManager.dislike,
colorFilter: ColorFilter.mode(
isDisliked ? AppColors.errorColor : AppColors.grey50,
BlendMode.srcATop,
),
child: Column(
children: [
SvgPicture.asset(
width: 32.0.w(),
height: 32.0.w(),
fit: BoxFit.cover,
AssetsManager.dislike,
colorFilter: ColorFilter.mode(
isDisliked ? AppColors.errorColor : AppColors.grey50,
BlendMode.srcATop,
),
),
SizedBox(height: 8.0.h()),
Text(
'Like',
style: TextStyle(
fontSize: 12.0.sp(),
fontWeight: FontWeight.w400,
color: isDisliked ? AppColors.errorColor : AppColors.grey50,
),
),
],
),
),
SizedBox(width: 48.0.w()),
SizedBox(width: 32.0.w()),
//reject button
GestureDetector(
onTap: onReject,
child: Column(
children: [
Container(
width: 32.0.w(),
height: 32.0.w(),
decoration: BoxDecoration(
shape: BoxShape.circle,
border: Border.all(
color: rejected ? AppColors.errorColor : AppColors.grey60,
width: 1.5.w(),
),
),
alignment: Alignment.center,
child: Icon(
Icons.close,
color: rejected ? AppColors.errorColor : AppColors.grey60,
size: 16,
),
),
SizedBox(height: 8.0.h()),
Text(
'Reject',
style: TextStyle(
fontSize: 12.0.sp(),
fontWeight: FontWeight.w400,
color: rejected ? AppColors.errorColor : AppColors.grey60,
),
),
],
),
),
SizedBox(width: 32.0.w()),
//submit button
GestureDetector(
onTap: onSubmit,
child: Column(
children: [
Container(
width: 32.0.w(),
height: 32.0.w(),
decoration: BoxDecoration(
shape: BoxShape.circle,
border: Border.all(
color:
submitted ? AppColors.successColor : AppColors.grey60,
width: 1.5.w(),
),
),
alignment: Alignment.center,
child: SvgPicture.asset(
AssetsManager.tick,
colorFilter: ColorFilter.mode(
submitted ? AppColors.successColor : AppColors.grey60,
BlendMode.srcATop,
),
),
),
SizedBox(height: 8.0.h()),
Text(
'Submit',
style: TextStyle(
fontSize: 12.0.sp(),
fontWeight: FontWeight.w400,
color: submitted ? AppColors.successColor : AppColors.grey60,
),
),
],
),
),
SizedBox(width: 32.0.w()),
// Like button
GestureDetector(
onTap: onLike,
child: SvgPicture.asset(
width: 32.0.w(),
height: 32.0.w(),
fit: BoxFit.cover,
AssetsManager.like,
colorFilter: ColorFilter.mode(
isLiked ? AppColors.successColor : AppColors.grey50,
BlendMode.srcATop,
),
child: Column(
children: [
SvgPicture.asset(
width: 32.0.w(),
height: 32.0.w(),
fit: BoxFit.cover,
AssetsManager.like,
colorFilter: ColorFilter.mode(
isLiked ? AppColors.successColor : AppColors.grey50,
BlendMode.srcATop,
),
),
SizedBox(height: 8.0.h()),
Text(
'Like',
style: TextStyle(
fontSize: 12.0.sp(),
fontWeight: FontWeight.w400,
color: isLiked ? AppColors.successColor : AppColors.grey50,
),
),
],
),
),
],