A simple 3D flat button with click animation!
dependencies:
flat_3d_button: ^1.0.3
import 'package:flat_3d_button/flat_3d_button.dart';
Flat3dButton.icon(
color: Colors.red,
onPressed: _decrementCounter,
icon: Icons.remove,
),
const SizedBox(width: 10),
Flat3dButton.text(
onPressed: _resetCounter,
text: 'reset',
),
const SizedBox(width: 10),
Flat3dButton.icon(
color: Colors.green,
onPressed: _incrementCounter,
icon: Icons.add,
),
refer to the main.dart
in the example for complete source code.
Flat3dButton.text(
onPressed: () => print('clicked'),
text: 'Flat',
);
Flat3dButton.icon(
onPressed: () => print('clicked'),
icon: Icons.rocket,
);
MIT License