build method

  1. @override
Widget build(
  1. BuildContext context
)
override

Creates alert buttons based on constructor params

Implementation

@override
Widget build(BuildContext context) {
  return Container(
    width: width,
    height: height,
    decoration: BoxDecoration(
      color: color ?? Theme.of(context).colorScheme.secondary,
      gradient: gradient,
      borderRadius: radius ?? BorderRadius.circular(6),
    ),
    child: Material(
      color: Colors.transparent,
      child: InkWell(
        onTap: onPressed,
        child: Center(
          child: child,
        ),
      ),
    ),
  );
}