added new design for tenders desktop
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_svg/flutter_svg.dart';
|
||||
|
||||
import '../../core/theme/colors.dart';
|
||||
import '../../core/utils/size_config.dart';
|
||||
@@ -16,6 +17,8 @@ class BaseButton extends StatelessWidget {
|
||||
final double? elevation;
|
||||
final double? width;
|
||||
final bool isLoading;
|
||||
final String? icon;
|
||||
final Color? iconColor;
|
||||
|
||||
const BaseButton({
|
||||
required this.isEnabled,
|
||||
@@ -29,6 +32,8 @@ class BaseButton extends StatelessWidget {
|
||||
this.elevation,
|
||||
this.width,
|
||||
this.isLoading = false,
|
||||
this.icon,
|
||||
this.iconColor,
|
||||
super.key,
|
||||
});
|
||||
|
||||
@@ -72,14 +77,38 @@ class BaseButton extends StatelessWidget {
|
||||
),
|
||||
),
|
||||
),
|
||||
child: Text(
|
||||
text ?? LoginStrings.loginButton,
|
||||
style: TextStyle(
|
||||
fontSize: 16.0.sp(),
|
||||
fontWeight: FontWeight.bold,
|
||||
color: textColor ?? AppColors.white,
|
||||
),
|
||||
),
|
||||
child:
|
||||
icon != null
|
||||
? Row(
|
||||
crossAxisAlignment: CrossAxisAlignment.center,
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
SvgPicture.asset(
|
||||
icon!,
|
||||
colorFilter: ColorFilter.mode(
|
||||
iconColor ?? AppColors.white,
|
||||
BlendMode.srcIn,
|
||||
),
|
||||
),
|
||||
SizedBox(width: 7.0.w()),
|
||||
Text(
|
||||
text ?? LoginStrings.loginButton,
|
||||
style: TextStyle(
|
||||
fontSize: 16.0.sp(),
|
||||
fontWeight: FontWeight.bold,
|
||||
color: textColor ?? AppColors.white,
|
||||
),
|
||||
),
|
||||
],
|
||||
)
|
||||
: Text(
|
||||
text ?? LoginStrings.loginButton,
|
||||
style: TextStyle(
|
||||
fontSize: 16.0.sp(),
|
||||
fontWeight: FontWeight.bold,
|
||||
color: textColor ?? AppColors.white,
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user