diff --git a/core/lib/presentation/views/button/tmail_button_widget.dart b/core/lib/presentation/views/button/tmail_button_widget.dart index 85927c923..a42a2de2e 100644 --- a/core/lib/presentation/views/button/tmail_button_widget.dart +++ b/core/lib/presentation/views/button/tmail_button_widget.dart @@ -14,6 +14,7 @@ class TMailButtonWidget extends StatelessWidget { final double borderRadius; final double? width; + final double? height; final double maxWidth; final double maxHeight; final double minWidth; @@ -50,6 +51,7 @@ class TMailButtonWidget extends StatelessWidget { this.onLongPressActionCallback, this.borderRadius = 20, this.width, + this.height, this.maxWidth = double.infinity, this.maxHeight = double.infinity, this.minWidth = 0, @@ -86,6 +88,7 @@ class TMailButtonWidget extends StatelessWidget { OnLongPressActionCallback? onLongPressActionCallback, double borderRadius = 20, double? width, + double? height, double maxWidth = double.infinity, double maxHeight = double.infinity, double minWidth = 0, @@ -110,6 +113,7 @@ class TMailButtonWidget extends StatelessWidget { onLongPressActionCallback: onLongPressActionCallback, borderRadius: borderRadius, width: width, + height: height, maxWidth : maxWidth, maxHeight: maxHeight, minWidth: minWidth, @@ -137,6 +141,7 @@ class TMailButtonWidget extends StatelessWidget { OnLongPressActionCallback? onLongPressActionCallback, double borderRadius = 20, double? width, + double? height, double maxWidth = double.infinity, double maxHeight = double.infinity, double minWidth = 0, @@ -161,6 +166,7 @@ class TMailButtonWidget extends StatelessWidget { onLongPressActionCallback: onLongPressActionCallback, borderRadius: borderRadius, width: width, + height: height, maxWidth : maxWidth, maxHeight: maxHeight, minWidth: minWidth, @@ -354,6 +360,7 @@ class TMailButtonWidget extends StatelessWidget { onLongPressActionCallback: onLongPressActionCallback, borderRadius: borderRadius, width: width, + height: height, maxWidth: maxWidth, maxHeight: maxHeight, minWidth: minWidth, diff --git a/core/lib/presentation/views/container/tmail_container_widget.dart b/core/lib/presentation/views/container/tmail_container_widget.dart index a23bc1136..e19df69f3 100644 --- a/core/lib/presentation/views/container/tmail_container_widget.dart +++ b/core/lib/presentation/views/container/tmail_container_widget.dart @@ -12,6 +12,7 @@ class TMailContainerWidget extends StatelessWidget { final Widget child; final double borderRadius; final double? width; + final double? height; final double maxWidth; final double maxHeight; final double minWidth; @@ -31,6 +32,7 @@ class TMailContainerWidget extends StatelessWidget { this.onLongPressActionCallback, this.borderRadius = 20, this.width, + this.height, this.maxWidth = double.infinity, this.maxHeight = double.infinity, this.minWidth = 0, @@ -45,6 +47,24 @@ class TMailContainerWidget extends StatelessWidget { @override Widget build(BuildContext context) { + final item = Container( + decoration: BoxDecoration( + color: backgroundColor ?? AppColor.colorButtonHeaderThread, + borderRadius: BorderRadius.all(Radius.circular(borderRadius)), + border: border, + boxShadow: boxShadow, + ), + width: width, + height: height, + constraints: BoxConstraints( + maxWidth: maxWidth, + maxHeight: maxHeight, + minWidth: minWidth, + ), + padding: padding ?? const EdgeInsetsDirectional.all(8), + child: child, + ); + final materialChild = Material( type: MaterialType.transparency, child: InkWell( @@ -70,39 +90,9 @@ class TMailContainerWidget extends StatelessWidget { child: tooltipMessage != null ? Tooltip( message: tooltipMessage, - child: Container( - decoration: BoxDecoration( - color: backgroundColor ?? AppColor.colorButtonHeaderThread, - borderRadius: BorderRadius.all(Radius.circular(borderRadius)), - border: border, - boxShadow: boxShadow - ), - width: width, - constraints: BoxConstraints( - maxWidth: maxWidth, - maxHeight: maxHeight, - minWidth: minWidth - ), - padding: padding ?? const EdgeInsetsDirectional.all(8), - child: child - ) - ) - : Container( - decoration: BoxDecoration( - color: backgroundColor ?? AppColor.colorButtonHeaderThread, - borderRadius: BorderRadius.all(Radius.circular(borderRadius)), - border: border, - boxShadow: boxShadow - ), - width: width, - constraints: BoxConstraints( - maxWidth: maxWidth, - maxHeight: maxHeight, - minWidth: minWidth - ), - padding: padding ?? const EdgeInsetsDirectional.all(8), - child: child + child: item, ) + : item ), ); diff --git a/lib/features/mailbox_dashboard/presentation/widgets/compose_button_widget.dart b/lib/features/mailbox_dashboard/presentation/widgets/compose_button_widget.dart index f6d7bf821..bc20858c2 100644 --- a/lib/features/mailbox_dashboard/presentation/widgets/compose_button_widget.dart +++ b/lib/features/mailbox_dashboard/presentation/widgets/compose_button_widget.dart @@ -35,8 +35,9 @@ class ComposeButtonWidget extends StatelessWidget { icon: imagePaths.icComposeWeb, borderRadius: 10, iconSize: 24, + height: 44, iconColor: Colors.white, - padding: const EdgeInsetsDirectional.symmetric(vertical: 8), + padding: const EdgeInsetsDirectional.symmetric(horizontal: 12), backgroundColor: AppColor.blue700, textStyle: ThemeUtils.textStyleBodyBody2(color: Colors.white), onTapActionCallback: onTapAction,