getBtnType method

Color getBtnType(
  1. BuildContext context
)

Returns the button color based on its type. If the type is BtnType.outline, BtnType.outline2x, or BtnType.transparent, returns Colors.transparent. Otherwise, returns FxColor.primary.

Implementation

Color getBtnType(BuildContext context) {
  if (BtnType.outline == type ||
      BtnType.outline2x == type ||
      BtnType.transparent == type) {
    return Colors.transparent;
  }
  return Theme.of(context).primaryColor;
}