multiselect 0.0.4 copy "multiselect: ^0.0.4" to clipboard
multiselect: ^0.0.4 copied to clipboard

outdated

A simple multiselect dropdown. It provide a concise way to create a Multi Selct ComboBox/SelectBox

example/lib/main.dart

import 'package:flutter/material.dart';
import 'package:multiselect/multiselect.dart';

void main() {
  runApp(MyApp());
}

class MyApp extends StatelessWidget {
  // This widget is the root of your application.
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Flutter Demo',
      theme: ThemeData(
        primarySwatch: Colors.blue,
      ),
      home: Home(),
    );
  }
}

class Home extends StatefulWidget {
  const Home({Key? key}) : super(key: key);

  @override
  _HomeState createState() => _HomeState();
}

class _HomeState extends State<Home> {

  List<String> selected = [];

  @override
  Widget build(BuildContext context) {
    return Scaffold(
        body: Center(
      child: Padding(
        padding: const EdgeInsets.all(20.0),
        child: DropDownMultiSelect(
          onChanged: (List<String> x) {
            setState(() {
              selected =x;
            });
          },
          options: ['a' , 'b' , 'c' , 'd'],
          selectedValues: selected,
          whenEmpty: 'Select Something',
        ),
      ),
    ));
  }
}
copied to clipboard
115
likes
0
points
10.8k
downloads

Publisher

verified publishertaimoorhassan.ml

Weekly Downloads

2024.09.27 - 2025.04.11

A simple multiselect dropdown. It provide a concise way to create a Multi Selct ComboBox/SelectBox

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

flutter, states_rebuilder

More

Packages that depend on multiselect