A flutter package for displaying common picker dialogs.

Overview

Flutter Material Pickers

Pub Package GitHub stars GitHub forks GitHub repo size

CodeFactor Open Bugs Enhancement Requests Closed Issues

Buy Me A Coffee PRs Welcome Contributors License

A flutter package containing commonly used material design picker dialogs. Some are new, some wrap existing or built in pickers with a common dialog and access function.

It includes:

  • New Pickers
    • showMaterialScrollPicker:
      • Allows selection of a string via a slot machine carousel
    • showMaterialNumberPicker:
      • Allows selection of a number via a slot machine carousel
    • showMaterialRadioPicker:
      • Allows selection of a single from a radio list
    • showMaterialCheckboxPicker:
      • Allows selection of many values from a checkbox list
    • showMaterialSelectionPicker:
      • Allows selection of a single value via an icon label list
  • Convenience Pickers
    • showMaterialDatePicker:
      • Allows selection of a date (uses the core date picker)
    • showMaterialTimePicker:
      • Allows selection of a time (uses the core time picker)
    • showMaterialColorPicker:
      • Allows RGB selection of a color (uses the ColorPicker of flutter_colorpicker)
    • showMaterialPalettePicker:
      • Allows Material palette selection of a color (uses the MaterialPicker of flutter_colorpicker)
    • showMaterialSwatchPicker:
      • Allows selection of a color from swatches (uses the BlockPicker of flutter_colorpicker)
    • showMaterialFilePicker:
      • Allows selection of a file using the device's default picker
  • Dialog
    • showMaterialResponsiveDialog:
      • Extends Dialog by making it responsive to screen orientation changes

All helpers implement an onChange handler to return picked option(s). All helpers return Future with the picked option(s).

There are some breaking changes in 3.0.0 (from 2.1.1).

  • Pickers accept generic types passed to pickers and helpers.
  • There's no need to pass several lists (items, values, icons), just pass one list of generic type objects.
  • A selected item of generic type is passed as selectedItem not selectedValue to match name of items.
  • To convert an item to a string displayed to a user either override toString() in generic type class or pass transformer callback which accepts an item and returns a String. (see examples)
  • To provide item's icon in SelectionPicker (and alikes), pass iconizer callback which accepts an item and returns an Icon. (see example)

Example Usage

Empty Dialog Example

Although not a picker, per se, the showMaterialEmptyPicker helper displays the universal material design dialog wrapper that the pickers appear in. Using this directly, however, allows any content to be injected into the content area by passing in a custon Widget as the child. This code shows the basic structure of all the helpers:

showMaterialResponsiveDialog(
    context: context,
    child: Center(
        child: Container(
            padding: EdgeInsets.all(30.0),
            child: Text('Any content here.'),
            style: TextStyle(
                fontSize: 20.0,
                fontStyle: FontStyle.italic,
            ),
        ),
    ),
);

Scroll Picker Example

class StateModel {
  const StateModel(this.name, this.code);
  final String code;
  final String name;

  @override
  String toString() => name;
}
static const List<StateModel> usStates = <StateModel>[
  StateModel('Alabama', 'AL'),
  StateModel('Alaska', 'AK'),
  StateModel('Arizona', 'AZ'),
  StateModel('Arkansas', 'AR'),
  StateModel('California', 'CA'),
  StateModel('Colorado', 'CO'),
  StateModel('Connecticut', 'CT'),
  ...
];
StateModel selectedUsState = usStates[0];

showMaterialScrollPicker<StateModel>(
    context: context,
    title: 'Pick Your State',
    items: usStates,
    selectedItem: selectedUsState,
    onChanged: (value) => setState(() => selectedUsState = value),
);

Number Picker Example

var age = 25;

showMaterialNumberPicker(
  context: context,
  title: 'Pick Your Age',
  maxNumber: 100,
  minNumber: 14,
  selectedNumber: age,
  onChanged: (value) => setState(() => age = value),
);

Checkbox Picker Example

class ToppingModel {
  const ToppingModel(this.name, this.code);
  final String code;
  final String name;

  @override
  String toString() => name;
}
static const List<ToppingModel> iceCreamToppings = <ToppingModel>[
  ToppingModel('Hot Fudge', 'FUDGE'),
  ToppingModel('Sprinkles', 'SPRINK'),
  ToppingModel('Caramel', 'CARM'),
  ToppingModel('Oreos', 'OREO'),
  ...
];
List<ToppingModel> selectedIceCreamToppings = [
  iceCreamToppings[0],
  iceCreamToppings[2],
];

showMaterialCheckboxPicker<ToppingModel>(
  context: context,
  title: 'Pick Your Toppings',
  items: iceCreamToppings,
  selectedItems: selectedIceCreamToppings,
  onChanged: (value) => setState(() => selectedIceCreamToppings = value),
);

Radio Picker Example

class StateModel {
  const StateModel(this.name, this.code);
  final String code;
  final String name;

  @override
  String toString() => name;
}
static const List<StateModel> usStates = <StateModel>[
  StateModel('Alabama', 'AL'),
  StateModel('Alaska', 'AK'),
  StateModel('Arizona', 'AZ'),
  StateModel('Arkansas', 'AR'),
  StateModel('California', 'CA'),
  StateModel('Colorado', 'CO'),
  StateModel('Connecticut', 'CT'),
  ...
];
StateModel selectedUsState = usStates[3];

showMaterialRadioPicker<StateModel>(
  context: context,
  title: 'Pick Your State',
  items: usStates,
  selectedItem: selectedUsState,
  onChanged: (value) => setState(() => selectedUsState = value),
);

Selection Picker Example

item.name, iconizer: (item) => item.icon, onChanged: (value) => setState(() => speed = value), ); ">
class SpeedModel {
  const SpeedModel(this.name, this.icon);
  final String name;
  final Icon icon;
}
// Selection Picker Model
static const List<SpeedModel> speedOptions = <SpeedModel>[
  SpeedModel('Light', Icon(Icons.sort)),
  SpeedModel('Ridiculous', Icon(Icons.clear_all)),
  SpeedModel('Ludicrous', Icon(Icons.swap_calls)),
  SpeedModel('Plaid', Icon(Icons.select_all)),
];
SpeedModel speed = speedOptions[2];

showMaterialSelectionPicker(
  context: context,
  title: "Starship Speed",
  items: speedOptions,
  selectedItem: speed,
  icons: speedIcons,
  transformer: (item) => item.name,
  iconizer: (item) => item.icon,
  onChanged: (value) => setState(() => speed = value),
);

Time Picker Example

var time = TimeOfDay.now();

showMaterialTimePicker(
  context: context,
  selectedTime: time,
  onChanged: (value) => setState(() => time = value),
);

Date Picker Example

var date = DateTime.now();

showMaterialDatePicker(
  context: context,
  selectedDate: date,
  onChanged: (value) => setState(() => date = value),
);

Color Picker Example

Color color = Colors.red;

showMaterialColorPicker(
  context: context,
  selectedColor: color,
  onChanged: (value) => setState(() => color = value),
);

Palette Picker Example

Color palette = Colors.green;

showMaterialPalettePicker(
  context: context,
  selectedColor: palette,
  onChanged: (value) => setState(() => palette = value),
);

Swatch Picker Example

Color swatch = Colors.blue;

showMaterialSwatchPicker(
  context: context,
  selectedColor: swatch,
  onChanged: (value) => setState(() => swatch = value),
);

Picker Model

If you don't already have or want to build a custom object to hold selction items, this library includes a general purpose one called PickerModel that you would use like this:

  static const List<PickerModel> items = <PickerModel>[
    PickerModel('First', code: 1, icon: Icon(Icons.sort)),
    PickerModel('Second', code: 2, icon: Icon(Icons.clear_all)),
    PickerModel('Third', code: 3, icon: Icon(Icons.swap_calls)),
    PickerModel('Fourth', code: 4, icon: Icon(Icons.select_all)),
  ];

The code and icon fields are optional.

Theming

It is highly recommended you use Flutter's built in theme styling with primarySwatch to automatically style all controls across your entire application.

ThemeData(
  primarySwatch: Colors.indigo,
)

If you desire to override the color for a given control, here is how to customize the theme:

var theme = ThemeData();
theme = theme.copyWith(
  primaryColor: Colors.green, // background color of the header area
  accentColor: Colors.black, // color of selected controls and button bar text
  dialogBackgroundColor: Colors.green[300], // background color of the entire dialog
  primaryTextTheme: theme.primaryTextTheme.copyWith(
    title: theme.primaryTextTheme.title.copyWith(
      color: Colors.lightGreen[50], // text color of the header area
    ),
  ),
  textTheme: theme.textTheme.copyWith(
    body1: theme.textTheme.body1.copyWith(
      color: Colors.green[900], // text color of dialog text
    ),
    button: theme.textTheme.button.copyWith(
      color: Colors.lightGreen[50], // text color of the action bar buttons
    ),
  ),
);

The example app demonstrates switching between light and dark themes globally.

However, if for some reason you want to change colors in an individual dialog, several parameters are exposed to allow this:

showMaterialResponsiveDialog(
    context: context,
    headerColor: Colors.green, // background color of the header area
    headerTextColor: Colors.white, // text fcolor of the header
    backgroundColor: Colors.lightGreen, // background color of the entire dialog
    buttonTextColor: Colors.red, // text color of the action bar buttons
    child: Text('Custom dialog colors'),
);

Customization

You can customize the text that appears in various areas of the screen. The button labels automatically localize to the native language versions of "Ok" and "Cancel", unless replacement text is provided.

showMaterialNumberPicker(
  title: 'Pick Your Age',
  confirmText: 'Count me in',
  cancelText: 'Negatory',
);

Sizing

To prevent dialogs from growing to full screen on larger devices (or web) two properties control the maxmium size that it will grow:

  maxLongSide: 600,
  maxShortSide: 400,

The sides relate to if the dialog is showing in landscape or portrait mode. If you wish larger (or smaller) dialogs you can overide these values.

Supported Platforms

  • Android
  • iOS
  • Web

Dependencies

This widget set relies on these external third-party components:

Changelog

Please see the Changelog page to know what's recently changed.

Contributions

If you find a bug or want a feature, but don't know how to fix/implement it, please fill an issue.

If you fixed a bug or implemented a new feature, please send a pull request. Please include a note about your change in CHANGELOG.md with your pull request.

Comments
  • Feature request: Ability to split label and value on scrollpicker

    Feature request: Ability to split label and value on scrollpicker

    The scrollpicker is currently taking a list of Strings as items parameter.

    I have a use case where I'd like to pass a list of objects as items and specify which object property to use as label (showing in the list), but when selected the returning value would be another object property.

    Here's what the show function call might look like:

    showSplitScrollPicker(
    context: context,
    title: 'my split scrollpicker',
    items: [{
     id: 1,
     label: 'first item',
     whatever: 'bla'
    },{
     id: 2,
     label: 'second',
     whatever: 'bla 2'
    },{
     id: 3,
     label: 'third',
     whatever: 'bla 3'
    }],
    itemLabel: 'label',
    itemValue: 'id'
    )
    
    enhancement 
    opened by avrelaun 15
  • Null Safety Support

    Null Safety Support

    Hey everyone,

    So, with the stable release of Flutter 2.0, migrating packages to null safety is something we need to think about.

    Currently, all packages that flutter_material_pickers depend on have stable/beta releases that do support null safety, so the only question is, is support for null satefy planned?

    If not, I'm more than ready to fork and submit a PR, just do not want to duplicate work if someone is already on it.

    opened by 6h4n3m 9
  • Doesn't build in iOS

    Doesn't build in iOS

    pod install fails and receiving the following error

    [!] Automatically assigning platform iOS with version 8.0 on target Runner because no platform was specified. Please specify a platform for this target in your Podfile. See https://guides.cocoapods.org/syntax/podfile.html#platform.

    opened by halahmadi 8
  • A problem occurred configuring project ':file_picker'.

    A problem occurred configuring project ':file_picker'.

    Hello, whenI added your plugin the build failed for some reason. can you please help me to figure out what is the problem! I will provide you some info that may help you: android/build.gradle: ` buildscript { ext.kotlin_version = '1.3.50' repositories { google() maven { url 'https://dl.google.com/dl/android/maven2' } jcenter() }

    dependencies {
        classpath 'com.android.tools.build:gradle:3.5.0'
        classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
    }
    

    `

    app/build.gradle:

    compileSdkVersion 29 targetSdkVersion 29

    details of the error is as follows:

    FAILURE:` Build failed with an exception.

    *` What went wrong:

    A problem occurred configuring project ':file_picker'.

    Could not resolve all artifacts for configuration ':file_picker:classpath'.

    Could not find aapt2-proto.jar (com.android.tools.build:aapt2-proto:0.3.1).

     Searched in the following locations:
         https://dl.google.com/dl/android/maven2/com/android/tools/build/aapt2-proto/0.3.1/aapt2-proto-0.3.1.jar
    

    Failed to notify project evaluation listener.

    Could not get unknown property 'android' for project ':file_picker' of type org.gradle.api.Project. Could not find method implementation() for arguments [project ':flutter_plugin_android_lifecycle'] on object of type

    org.gradle.api.internal.artifacts.dsl.dependencies.DefaultDependencyHandler.

    • Try:

    Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to

    get full insights.

    • Get more help at https://help.gradle.org

    BUILD FAILED in 582ms

    Finished with error: Gradle task assembleDebug failed with exit code 1

    `

    opened by WijdanMTak 7
  • Use flutter_colorpicker latest version

    Use flutter_colorpicker latest version

    Can this be updated to use the latest version of flutter_colorpicker? I’m having this issue https://github.com/mchome/flutter_colorpicker/issues/48#issuecomment-861138447 and it was resolved on the latest version

    opened by armandojimenez 5
  • Add null safety support

    Add null safety support

    Hey,

    So as discussed, I've taken care of the changes necessary to support null safety for Flutter 2.0 and Dart version from 2.12 and above.

    Changes made:

    1. Bumped SDK restriction from 2.7.0 to 2.12.0 (new minimum).
    2. Removed the meta package dependency since the @required annotation has been replaced and is not needed for named parameters anymore.
    3. Added the required modifier to any required parameters in widgets and/or functions.
    4. Changed the types of any optional named parameters to be nullable (ex. from String to String?).
    5. Removed unnecessary not null asserts for required parameters as package users cannot send nullable values for these anymore.
    6. Replaced the DynamicTheme dependency with the actively maintained AdaptiveTheme in order to make sure the package supports sound null safety and is not in mixed mode (ie. depends on packages with no null safety).
    7. Replaced deprecated widget FlatButton with the replacement ElevatedButton where applicable (no changes to api surface of the package were made).

    I ran the example app and everything works smoothly including theme switching.

    You'd probably need to bump this into a new major version since it requires and SDK upgrade on the user's part.

    Resolves codegrue/flutter_material_pickers#25

    opened by 6h4n3m 5
  • Flutter 2.5.0 - Error: The argument type 'PointerEvent' can't be assigned to the parameter type 'PointerDownEvent'

    Flutter 2.5.0 - Error: The argument type 'PointerEvent' can't be assigned to the parameter type 'PointerDownEvent'

    After updating to Flutter 2.5.0 error started showing up.

    Launching lib/main.dart on macOS in debug mode... Building macOS application... ../../../Developer/flutter/.pub-cache/hosted/pub.dartlang.org/flutter_colorpicker-0.4.0/lib/src/hsv_picker.dart:731:29: Error: The argument type 'PointerEvent' can't be assigned to the parameter type 'PointerDownEvent'.

    • 'PointerEvent' is from 'package:flutter/src/gestures/events.dart' ('../../../Developer/flutter/packages/flutter/lib/src/gestures/events.dart').
    • 'PointerDownEvent' is from 'package:flutter/src/gestures/events.dart' ('../../../Developer/flutter/packages/flutter/lib/src/gestures/events.dart'). super.addAllowedPointer(event); ^

    Command PhaseScriptExecution failed with a nonzero exit code note: Using new build system note: Building targets in parallel note: Planning build note: Analyzing workspace note: Constructing build description note: Build preparation complete ** BUILD FAILED **

    Exception: Build process failed

    flutter --version Flutter 2.5.0 • channel stable • https://github.com/flutter/flutter.git Framework • revision 4cc385b4b8 (13 hours ago) • 2021-09-07 23:01:49 -0700 Engine • revision f0826da7ef Tools • Dart 2.14.0

    opened by NikolaGrujic91 4
  • Support generic types

    Support generic types

    This PR adds supprt of generic types to the pickers. The changes break compatibility with older version, see README.md. The changes in calling code are quite simple.

    opened by edlman 3
  • error when update package intl 0.17.0

    error when update package intl 0.17.0

    Because flutter_material_pickers >=1.9.2 depends on intl >=0.16.0 <=0.17.0-nullsafety.2 and waitingwork depends on intl ^0.17.0, flutter_material_pickers >=1.9.2 is forbidden. So, because waitingwork depends on flutter_material_pickers ^1.9.2, version solving failed. pub get failed (1; So, because waitingwork depends on flutter_material_pickers ^1.9.2, version solving failed.) Process finished with exit code 1

    Thanks.

    opened by tuemaytinh1981 3
  • Issue with running

    Issue with running

    Hi,

    when I am starting my project i get the following error message. I can avoid it by running the project without the "flutter_material_pickers" dependency then adding it again and use run again without stopping the program.

    If I stop it and rerun it, I have to do the precedure again.

    Any help is welcome

    `FAILURE: Build failed with an exception.

    • What went wrong: Execution failed for task ':app:processDebugResources'.

    A failure occurred while executing com.android.build.gradle.internal.tasks.Workers$ActionFacade Android resource linking failed C:\Users[Username]\Desktop\mgs\build\file_picker\intermediates\library_manifest\debug\AndroidManifest.xml:9:5-15:15: AAPT: error: unexpected element found in .

    • Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

    • Get more help at https://help.gradle.org

    BUILD FAILED in 1s The built failed likely due to AndroidX incompatibilities in a plugin. The tool is about to try using Jetfier to solve the incompatibility. Building plugin file_picker... Running Gradle task 'assembleAarRelease'...

    C:\Users[Username]\Flutter\flutter.pub-cache\hosted\pub.dartlang.org\file_picker-2.1.0\android\src\main\java\com\mr\flutter\plugin\filepicker\FilePickerPlugin.java:10: error: cannot find symbol import androidx.lifecycle.DefaultLifecycleObserver; ^ symbol: class DefaultLifecycleObserver location: package androidx.lifecycle C:\Users[Username]\Flutter\flutter.pub-cache\hosted\pub.dartlang.org\file_picker-2.1.0\android\src\main\java\com\mr\flutter\plugin\filepicker\FilePickerPlugin.java:20: error: cannot find symbol import io.flutter.embedding.engine.plugins.lifecycle.FlutterLifecycleAdapter; ^ symbol: class FlutterLifecycleAdapter location: package io.flutter.embedding.engine.plugins.lifecycle C:\Users[Username]\Flutter\flutter.pub-cache\hosted\pub.dartlang.org\file_picker-2.1.0\android\src\main\java\com\mr\flutter\plugin\filepicker\FilePickerPlugin.java:38: error: cannot find symbol implements Application.ActivityLifecycleCallbacks, DefaultLifecycleObserver { ^ symbol: class DefaultLifecycleObserver location: class FilePickerPlugin C:\Users[Username]\Flutter\flutter.pub-cache\hosted\pub.dartlang.org\file_picker-2.1.0\android\src\main\java\com\mr\flutter\plugin\filepicker\FilePickerPlugin.java:45: error: method does not override or implement a method from a supertype @Override ^ C:\Users[Username]\Flutter\flutter.pub-cache\hosted\pub.dartlang.org\file_picker-2.1.0\android\src\main\java\com\mr\flutter\plugin\filepicker\FilePickerPlugin.java:49: error: method does not override or implement a method from a supertype @Override ^ C:\Users[Username]\Flutter\flutter.pub-cache\hosted\pub.dartlang.org\file_picker-2.1.0\android\src\main\java\com\mr\flutter\plugin\filepicker\FilePickerPlugin.java:53: error: method does not override or implement a method from a supertype @Override ^ C:\Users[Username]\Flutter\flutter.pub-cache\hosted\pub.dartlang.org\file_picker-2.1.0\android\src\main\java\com\mr\flutter\plugin\filepicker\FilePickerPlugin.java:57: error: method does not override or implement a method from a supertype @Override ^ C:\Users[Username]\Flutter\flutter.pub-cache\hosted\pub.dartlang.org\file_picker-2.1.0\android\src\main\java\com\mr\flutter\plugin\filepicker\FilePickerPlugin.java:61: error: method does not override or implement a method from a supertype @Override ^ C:\Users[Username]\Flutter\flutter.pub-cache\hosted\pub.dartlang.org\file_picker-2.1.0\android\src\main\java\com\mr\flutter\plugin\filepicker\FilePickerPlugin.java:66: error: method does not override or implement a method from a supertype @Override ^ C:\Users[Username]\Flutter\flutter.pub-cache\hosted\pub.dartlang.org\file_picker-2.1.0\android\src\main\java\com\mr\flutter\plugin\filepicker\FilePickerPlugin.java:277: error: cannot find symbol this.lifecycle = FlutterLifecycleAdapter.getActivityLifecycle(activityBinding); ^ symbol: variable FlutterLifecycleAdapter location: class FilePickerPlugin C:\Users[Username]\Flutter\flutter.pub-cache\hosted\pub.dartlang.org\file_picker-2.1.0\android\src\main\java\com\mr\flutter\plugin\filepicker\FilePickerPlugin.java:278: error: incompatible types: FilePickerPlugin.LifeCycleObserver cannot be converted to LifecycleObserver this.lifecycle.addObserver(this.observer); ^ C:\Users[Username]\Flutter\flutter.pub-cache\hosted\pub.dartlang.org\file_picker-2.1.0\android\src\main\java\com\mr\flutter\plugin\filepicker\FilePickerPlugin.java:287: error: incompatible types: FilePickerPlugin.LifeCycleObserver cannot be converted to LifecycleObserver this.lifecycle.removeObserver(this.observer); ^ Note: Some messages have been simplified; recompile with -Xdiags:verbose to get full output 12 errors

    FAILURE: Build failed with an exception.

    • What went wrong: Execution failed for task ':compileReleaseJavaWithJavac'.

    Compilation failed; see the compiler error output for details.

    • Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

    • Get more help at https://help.gradle.org

    BUILD FAILED in 1s

    Exception: The plugin file_picker could not be built due to the issue above.`

    opened by Jannik-dev 3
  • Error with old version of flutter_colorpicker

    Error with old version of flutter_colorpicker

    When I use color picker on my app in the new version of dart I got the error:

    Because flutter_material_pickers 3.1.0 depends on flutter_colorpicker ^0.4.0 and no versions of flutter_material_pickers match >3.1.0 <4.0.0, flutter_material_pickers ^3.1.0 requires flutter_colorpicker ^0.4.0.
    And because every version of card_settings from path depends on flutter_material_pickers ^3.1.0, every version of card_settings from path requires flutter_colorpicker ^0.4.0.
    So, because "ebarge" depends on both flutter_colorpicker ^0.6.0 and card_settings from path, version solving failed.
    pub get failed (1; So, because "ebarge" depends on both flutter_colorpicker ^0.6.0 and card_settings from path, version solving failed.)
    

    environment: sdk: ">=2.13.4 <3.0.0"

    opened by wahidanvary 2
  • intl update to 0.18 fail due to flutter_material_pickers

    intl update to 0.18 fail due to flutter_material_pickers

    Trying to update all my packages and ran across this issue on ios. Just upgraded flutter as well to see if that would help.

    Because flutter_material_pickers >=2.0.0 depends on intl ^0.17.0 and niks depends on intl ^0.18.0, flutter_material_pickers >=2.0.0 is forbidden. So, because niks depends on flutter_material_pickers ^3.1.2, version solving failed. Running "flutter pub get" in niks...
    pub get failed (1; So, because niks depends on flutter_material_pickers ^3.1.2, version solving failed.)

    Doctor summary (to see all details, run flutter doctor -v): [✓] Flutter (Channel stable, 3.3.10, on macOS 12.6.1 21G217 darwin-x64, locale en-US) [✓] Android toolchain - develop for Android devices (Android SDK version 30.0.3) [✓] Xcode - develop for iOS and macOS (Xcode 14.1) [✓] Chrome - develop for the web [✓] Android Studio (version 2021.2) [✓] VS Code (version 1.74.2) [✓] Connected device (2 available) [✓] HTTP Host Availability

    • No issues found!

    opened by jodymac 0
  • showMaterialCheckboxPicker

    showMaterialCheckboxPicker

    Hello,

    Is it possible for the checkbox to be in the left instead of the right side of the label

    currently: check 1 [] check 2 []

    but need the below: [] check1 [] check2

    Thanks in advance,

    opened by xdamien7 0
  • [BUG] Scroll doesn't work on web

    [BUG] Scroll doesn't work on web

    With Flutter 3.3 the scroll doesn't work.

    In the class "selection_picker.dart" the Scrollbar must have the same ScrollController of the ListView

    ScrollController _controller = ScrollController();
    
    ....
    Scrollbar(
            controller: _controller,
            child: ListView.builder(
                    controller: _controller,
                    ....
    
    opened by Carmelo992 0
  • [REQUEST] Customization of text color

    [REQUEST] Customization of text color

    Hi, thanks for the awesome package. It would be awesome if the text color within the dialog could be configured with an optional argument like most of the rest of the colors.

    Changing the bodyText2 in the theme is not always appropriate for the entire app.

    [As for me, it the background Color is white and the bodyText2 color is white, too. But in use, text is always placed in Containers that are blue.]

    showMaterialResponsiveDialog(
        context: context,
        headerColor: Colors.green, // background color of the header area
        headerTextColor: Colors.white, // text fcolor of the header
        backgroundColor: Colors.lightGreen, // background color of the entire dialog
        buttonTextColor: Colors.red, // text color of the action bar buttons
      // add this: itemTextColor: Colors.black,
        child: Text('Custom dialog colors'),
    );
    

    Have a wonderful week everyone!

    opened by fior-di-latte 0
  • [BUG] Error when archiving

    [BUG] Error when archiving

    When im trying to archive to upload my app to the App Store im having this problem and i archive to upload my app

    when running flutter build ipa

    Expected behavior LLVM ERROR: out of memory Allocation failed Please submit a bug report (https://swift.org/contributing/#reporting-bugs) and include the project and the crash backtrace. Stack dump: 0. Program arguments: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/swift-frontend -frontend -c -primary-file /Users/antonio/Library/Developer/Xcode/DerivedData/Runner-ehcesfvkcqvyvqbczxhksmdloeeu/Build/Intermediates.noindex/ArchiveIntermediates/Runner/IntermediateBui ldFilesPath/Pods.build/Release-iphoneos/DKImagePickerController.build/Objects-normal/arm64/DKPopoverViewController.bc -embed-bitcode -target arm64-apple-ios9.0 -Xllvm -aarch64-use-tbi -O -disable-llvm-optzns -module-name DKImagePickerController -o /Users/antonio/Library/Developer/Xcode/DerivedData/Runner-ehcesfvkcqvyvqbczxhksmdloeeu/Build/Intermediates.noindex/ArchiveIntermediates/Runner/IntermediateBui ldFilesPath/Pods.build/Release-iphoneos/DKImagePickerController.build/Objects-normal/arm64/DKPopoverViewController.o

    1. Apple Swift version 5.6 (swiftlang-5.6.0.323.62 clang-1316.0.20.8)
    2. Compiling with the current language version
    3. Running pass 'Function Pass Manager' on module '/Users/antonio/Library/Developer/Xcode/DerivedData/Runner-ehcesfvkcqvyvqbczxhksmdloeeu/Build/Intermediates.noindex/ArchiveIntermediates/Runner/IntermediateBu ildFilesPath/Pods.build/Release-iphoneos/DKImagePickerController.build/Objects-normal/arm64/DKPopoverViewController.bc'.
    4. Running pass 'ObjC ARC contraction' on function '@UI_USER_INTERFACE_IDIOM' Stack dump without symbol names (ensure you have llvm-symbolizer in your PATH or set the environment var LLVM_SYMBOLIZER_PATH to point to it): 0 swift-frontend 0x000000010e2dfde7 llvm::sys::PrintStackTrace(llvm::raw_ostream&, int) + 39 1 swift-frontend 0x000000010e2dee38 llvm::sys::RunSignalHandlers() + 248 2 swift-frontend 0x000000010e2e0440 SignalHandler(int) + 288 3 libsystem_platform.dylib 0x00007ff80684ce2d _sigtramp + 29 4 libsystem_malloc.dylib 0x00007ff80666fad6 _malloc_zone_malloc + 125 5 libsystem_c.dylib 0x00007ff806783d10 abort + 123 6 swift-frontend 0x000000010e22ccda llvm::report_bad_alloc_error(char const, bool) + 106 7 swift-frontend 0x000000010e22ccf2 out_of_memory_new_handler() + 18 8 libc++abi.dylib 0x00007ff8067f59bb operator new(unsigned long) + 43 9 swift-frontend 0x000000010dfedefd llvm::Function::BuildLazyArguments() const + 77 10 swift-frontend 0x000000010bdd6e87 llvm::objcarc::BundledRetainClaimRVs::insertRVCallWithColors(llvm::Instruction, llvm::CallBase*, llvm::DenseMap<llvm::BasicBlock*, llvm::TinyPtrVectorllvm::BasicBlock*, llvm::DenseMapInfollvm::BasicBlock*, llvm::detail::DenseMapPair<llvm::BasicBlock*, llvm::TinyPtrVectorllvm::BasicBlock* > > const&) + 151 11 swift-frontend 0x000000010bde9f88 (anonymous namespace)::ObjCARCContract::run(llvm::Function&, llvm::AAResults*, llvm::DominatorTree*) + 1384 12 swift-frontend 0x000000010e025380 llvm::FPPassManager::runOnFunction(llvm::Function&) + 1488 13 swift-frontend 0x000000010e02c073 llvm::FPPassManager::runOnModule(llvm::Module&) + 67 14 swift-frontend 0x000000010e025b39 llvm::legacy::PassManagerImpl::run(llvm::Module&) + 1161 15 swift-frontend 0x00000001095436df swift::performLLVMOptimizations(swift::IRGenOptions const&, llvm::Module*, llvm::TargetMachine*) + 3791 16 swift-frontend 0x00000001095448cc swift::performLLVM(swift::IRGenOptions const&, swift::DiagnosticEngine&, llvm::sys::SmartMutex, llvm::GlobalVariable, llvm::Module*, llvm::TargetMachine*, llvm::StringRef, swift::UnifiedStatsReporter*) + 2812 17 swift-frontend 0x000000010954daa5 swift::performLLVM(swift::IRGenOptions const&, swift::ASTContext&, llvm::Module*, llvm::StringRef) + 213 18 swift-frontend 0x0000000109008795 swift::performFrontend(llvm::ArrayRef<char const*>, char const*, void*, swift::FrontendObserver*) + 16565 19 swift-frontend 0x0000000108fc75d4 swift::mainEntry(int, char const**) + 1108 20 dyld 0x0000000115fc74fe start + 462 error: Abort trap: 6 (in target 'DKImagePickerController' from project 'Pods') error: backend command failed due to signal 6 (use -v to see invocation) Command CompileSwiftSources failed with a nonzero exit code note: Using new build system note: Planning note: Build preparation complete note: Building targets in dependency order

    Result bundle written to path: /var/folders/6l/q6rrfd6x73n8__3wr8q9m8br0000gn/T/flutter_tools.YIF6sz/flutter_ios_build_temp_dirTokLtE/temporary_xcresult_bundle Error (Xcode): Abort trap: 6

    Uncategorized (Xcode): Command CompileSwiftSources failed with a nonzero exit code

    Version information -Xcode version: 13.3

    Flutter Version: v2.10.3 Please help, i cant upload new versions of my app.

    opened by chander1411 1
  • Suggestion : Hide cancel options

    Suggestion : Hide cancel options

    Hello,

    Could be useful to add an option : hideCancelButton to just hide the cancel button. It will allow to use showMaterialResponsiveDialog as an alert dialog.

    opened by vptcnt 0
Owner
CodeGrue
Technologist, Hobbyist, Gamer, Author
CodeGrue
Dialog-manager - A Flutter package that allows for neater declaration, abstraction and use of customisable dialogs

flutter_dialog_manager A Flutter package that allows for neater declaration, abs

Lucky Ebere 2 Dec 28, 2022
A new Flutter package project for simple a awesome dialogs

awesome_dialog A new Flutter package project for simple and awesome dialogs Usage To use this package, add awesome_dialog as a dependency in your pubs

Marcos Rodriguez Toranzo 286 Jan 6, 2023
A new flutter package for collection of common popular social media widgets

Social Media Widgets - package A new flutter package for collection of common popular social media widgets Currently available widgets Snapchat screen

theboringdeveloper 34 Nov 12, 2022
RFlutter Alert is super customizable and easy-to-use alert/popup dialogs for Flutter.

RFlutter Alert is super customizable and easy-to-use alert/popup dialogs for Flutter. You may create reusable alert styles or add buttons as much as you want with ease.

Ratel 362 Jan 1, 2023
A widget displaying children in a line with an overflow indicator at the end if there is not enough space.

overflow_view A widget displaying children in a line with an overflow indicator at the end if there is not enough space. Features Renders children hor

Romain Rastel 153 Dec 19, 2022
Flutter debug helper widget with common and custom actions

Flutter debug helper widget with common and custom actions

Stanislav Ilin 43 Dec 7, 2022
A Flutter library to add the Common effect (line, bubble, dot ...) of tab indicator.

flutter_tab_indicator A Flutter library to add the Common effect (line, bubble, dot ...) of tab indicator. Showcases Installation Showcases Showcases

CrabMan 14 Jun 19, 2022
A template folder for common widgets and useful scripts

Useful-Templates A template folder for common widgets and useful scripts Co-author: PratikJH153 REST API Dart Code: A ready to use repository containi

Atharv Karbhari 2 Mar 3, 2022
A flutter horizontal date picker that always shift the selected date to center.

horizontal_center_date_picker A flutter widget provides a horizontal date picker and always aligns selected date in center of the widget. Usage This s

May Lau 5 Jul 2, 2022
A time picker widget for flutter

time_picker A new Flutter project. Getting Started This project is a starting point for a Flutter application. A few resources to get you started if t

Ramon Alex 4 Dec 3, 2022
Flutter picker plugin

flutter_picker Flutter plugin picker. Include NumberPicker, DateTimePicker, ArrayPicker, and default linkage Picker. Provide flexible parameters to me

null 614 Dec 23, 2022
A Flutter Country Picker Widget with support to country dialing codes

flutter_country_picker A Flutter Country Picker Widget with support to country dialing codes Usage Add the CountryPicker widget in your layout and use

Alessandro Biessek 49 Apr 6, 2022
A beautiful circle color picker for flutter.

A beautiful circle color picker for flutter.

Takeshi Tsukamoto 46 Dec 29, 2022
Flutter Number Picker is a custom widget designed for choosing an integer or decimal number by using add and minus buttons

Flutter Number Picker is a custom widget designed for choosing an integer or decimal number by using add and minus buttons. Getting Started Head to /p

Vũ Phương 2 Jul 4, 2022
Flutter Color Picker Wheel - an easy to use widget which can be heavily customized

Flutter Color Picker Wheel Flutter Color Picker Wheel is an easy to use widget which can be heavily customized. You can use the WheelColorPicker direc

Kexin Lu 35 Oct 4, 2022
A Highly customizable Phone input Flutter widget that supports country code, validation and contact picker.

A Highly customizable Phone input Flutter widget that supports country code, validation and contact picker.

null 6 Jun 7, 2022
An assets picker in WeChat style, support multi assets picking.

An assets picker in WeChat style, support multi assets picking.

FlutterCandies 1.1k Jan 8, 2023
A camera picker in WeChat style.

A camera picker which is an extension for wechat_assets_picker. Based on camera for camera functions and photo_manager for asset implementation.

FlutterCandies 265 Dec 28, 2022
starlight_country_picker is a country picker.

Starlight Country Picker starlight_country_picker is a country picker. Features ☑️ Add New Country ☑️ Search Your Country ⭐ Our package was not used s

Ye Myo Aung 1 Nov 29, 2021