select2dot1 0.0.2 select2dot1: ^0.0.2 copied to clipboard
Select2dot1 give you a customizable single/multiple select box with support for searching, group option, extra info and avatar. Select2dot1 works using overlay (web, desktop) and modal (mobile) and is [...]
Select2dot1 #
Select2dot1 give you a customizable single/multiple select box with support for searching, group option, extra info and avatar. Select2dot1 works using overlay (web, desktop) and modal (mobile) and is fully customizable by settings and builder.
Demo web example: https://select2dot1.site
Author site: https://romanjrdykyj.site
Screenshots #
Desktop Example | Mobile Example |
---|---|
Installation #
- Add following dependency in pubspec.yaml file.
flutter pub add select2dot1
- Add this import to your file.
import 'package:select2dot1/select2dot1.dart';
- Now you can use Select2dot1 widget. Go to Usage section and see how to use it.
Usage #
- On the first step you need to create a list of data that you want to display in.
const List<SingleCategoryModel> exampleData1 = [
SingleCategoryModel(
nameCategory: 'Team Leader',
singleItemCategoryList: [
SingleItemCategoryModel(
nameSingleItem: 'David Eubanks',
extraInfoSingleItem: 'Full time',
avatarSingleItem: CircleAvatar(
backgroundColor: Colors.transparent,
foregroundColor: Colors.transparent,
backgroundImage: AssetImage('assets/images/avatar1.jpg'),
),
),
SingleItemCategoryModel(
nameSingleItem: 'Stuart Resch',
extraInfoSingleItem: 'Part time',
avatarSingleItem: CircleAvatar(
backgroundColor: Colors.blue,
child: Text('SR', style: TextStyle(color: Colors.white)),
),
),
],
),
- Use Select2dot1 widget and pass your data to it. You can also pass scrollController if you want to use it.
Select2dot1(
selectDataController: SelectDataController(data: ExampleData.exampleData1),
scrollController: scrollController,
),