button add null color

master
小赖 4 years ago
parent 225956cbfc
commit 89d1e665c3

@ -29,8 +29,8 @@ class AkuMaterialButton extends MaterialButton {
this.padding = EdgeInsets.zero,
@required this.child,
this.color = Colors.transparent,
}) : nullColor = color.withOpacity(0.5),
super(
this.nullColor = Colors.transparent,
}) : super(
key: key,
onPressed: onPressed,
elevation: elevation,
@ -46,6 +46,7 @@ class AkuMaterialButton extends MaterialButton {
),
child: child,
color: color,
disabledColor: nullColor,
materialTapTargetSize: MaterialTapTargetSize.shrinkWrap,
);
}