import 'package:flutter/material.dart';
import 'package:flutter_svg/svg.dart';

class RoundIconButton extends StatelessWidget {
  final String icon;
  final Function onPressed;
  final Color color;
  const RoundIconButton({
    required this.icon,
    required this.onPressed,
    required this.color,
    super.key,
  });

  @override
  Widget build(BuildContext context) {
    return ElevatedButton(
      onPressed: () {onPressed();},
      style: ElevatedButton.styleFrom(
        minimumSize: const Size(45, 45),
        elevation: 0,
        backgroundColor: color,
        shape: const CircleBorder(side: BorderSide(style: BorderStyle.none)),
      ),
      child: SvgPicture.asset(icon),
    );
  }
}