selectable_icon

Last updated:

0 purchases

selectable_icon Image
selectable_icon Images
Add to Cart

Description:

selectable icon

Selectable Box #


Use SelectableIcon to create a selectable box in your flutter app, SelectableIcon comes with a lot of customization options mentioned below.
Convert any widget into a selectable box.

Installation #
Add selectable_icon: ^1.0.4 in your project's pubspec.yaml:
dependencies:
selectable_icon: ^1.0.4
copied to clipboard
Usage #
Import selectable_icon in your dart file:
import 'package:selectable_icon/selectable_icon.dart';
copied to clipboard
Then use SelectableIcon in your widget tree:
bool isSelected = false;
int count = 0;

SelectableIcon(
onTap: () {
setState(() {
isSelected = !isSelected;
if (isSelected) {
count++;
} else {
count--;
}
});
},
isSelected: isSelected,
selectedIcon: Icons.thumb_up,
unSelectedIcon: Icons.thumb_up,
size: 70,
selectedColor: Colors.blue,
unSelectedColor: Colors.grey,
count: count,
showCount: true,
animationDuration: const Duration(milliseconds: 500),
padding: const EdgeInsets.all(10),
),
copied to clipboard

License:

For personal and professional use. You cannot resell or redistribute these repositories in their original state.

Files In This Product:

Customer Reviews

There are no reviews.