flutter_custom_dropdown_list 1.0.2 copy "flutter_custom_dropdown_list: ^1.0.2" to clipboard
flutter_custom_dropdown_list: ^1.0.2 copied to clipboard

A customizable dropdown package for Flutter that allows developers to display a dropdown using bottom sheets or a full-screen modal. This package supports dynamic item rendering with optional itemBuil [...]

example/lib/main.dart

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

import 'country_selector_example.dart';
import 'theme/example_theme.dart';

void main() {
  WidgetsFlutterBinding.ensureInitialized();
  SystemChrome.setEnabledSystemUIMode(SystemUiMode.edgeToEdge);
  SystemChrome.setSystemUIOverlayStyle(
    const SystemUiOverlayStyle(
      statusBarColor: Colors.transparent,
      systemNavigationBarColor: Colors.transparent,
      systemNavigationBarDividerColor: Colors.transparent,
      statusBarIconBrightness: Brightness.dark,
      systemNavigationBarIconBrightness: Brightness.dark,
    ),
  );
  runApp(const MyApp());
}

class MyApp extends StatefulWidget {
  const MyApp({super.key});

  @override
  State<MyApp> createState() => _MyAppState();
}

class _MyAppState extends State<MyApp> {
  ThemeMode _themeMode = ThemeMode.light;

  bool get _isDarkMode => _themeMode == ThemeMode.dark;

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      debugShowCheckedModeBanner: false,
      title: 'Country Selector',
      theme: ExampleTheme.light,
      darkTheme: ExampleTheme.dark,
      themeMode: _themeMode,
      home: CountrySelectorExample(
        isDarkMode: _isDarkMode,
        onThemeChanged: (isDarkMode) {
          setState(() {
            _themeMode = isDarkMode ? ThemeMode.dark : ThemeMode.light;
          });
        },
      ),
    );
  }
}
0
likes
150
points
86
downloads

Documentation

API reference

Publisher

unverified uploader

Weekly Downloads

A customizable dropdown package for Flutter that allows developers to display a dropdown using bottom sheets or a full-screen modal. This package supports dynamic item rendering with optional itemBuilder, search functionality, and three different bottom sheet display modes.

Homepage
Repository (GitHub)
View/report issues

License

GPL-3.0 (license)

Dependencies

flutter

More

Packages that depend on flutter_custom_dropdown_list