button static method
Implementation
static Widget button({required String title, icon, onPress}) {
return ElevatedButton(
style: ElevatedButton.styleFrom(padding: const EdgeInsets.all(5.0)),
onPressed: onPress,
child: Row(
mainAxisSize: MainAxisSize.min,
children: [
if (icon != null) Icon(icon, size: 20),
if (icon != null)
const SizedBox(
width: 5,
),
Text(title),
],
));
}