flutter_group_button
A flutter package which contains basics grouped buttons like radio buttons and checkboxes
VERSION
[2.0.1]
Table of content
Getting start
To use this package, add flutter_group_button^[version]
as a dependency in your pubspec.yaml file
dependencies:
flutter_group_button: ^1.0.1
Fast Overview
Make sure that dependencie is add to your pubsec.yaml file.
RadioGroup Overview
RadioGroup(
children: [
Text("Choice 1"),
Text("Choice 2"),
Text("Choice 3")
],
/// no default selected item
defaultSelectedItem: -1,
onSelectionChanged: (selection) {
/// print the index of the selected item
print(selection);
})
CheckBoxGroup Overview
CheckboxGroup(
child: {
Text("Choice 1"): false,
Text("Choice 2"): true,
Text("Choice 3"): false
},
///
onNewChecked: (l) {
/// print a list of the checked item name
print(l);
})
comment: <> ( * CheckboxGroup