decorated_dropdownbutton

Creator: coderz1093

Last updated:

0 purchases

decorated_dropdownbutton Image
decorated_dropdownbutton Images

Languages

Categories

Add to Cart

Description:

decorated dropdownbutton

Use decorated_dropdown button to add DropdownButton with decoration properties like box shadow, border, background color, border radius, gradient background, icons, and many more in Flutter App.
Features #
This package will help you to add decoration on DropdownButton
Getting started #
To start using this package, add the following lines in pubspec.yaml file.
dependencies:
decorated_dropdownbutton: ^0.0.3
copied to clipboard
Import package in your script:
import 'package:decorated_dropdownbutton/decorated_dropdownbutton.dart';
copied to clipboard
Usage #
You can use DecoratedDropdownButton() like below:
DecoratedDropdownButton(
value: "item1",
items: [
DropdownMenuItem(
child: Text("Dropdown Item I"),
value: "item1"
),

DropdownMenuItem(
child: Text("Dropdown Item II"),
value: "item2"
)
],
onChanged: (value){
print("You selected $value");
},
)
copied to clipboard
Add More Design to DecoratedDropdownButton():
DecoratedDropdownButton(
value: "item1",
items: [
DropdownMenuItem(
child: Text("Dropdown Item I"),
value: "item1"
),

DropdownMenuItem(
child: Text("Dropdown Item II"),
value: "item2"
)
],
onChanged: (value){
print("You selected $value");
},
color: Colors.orange, //background color
border: Border.all(color:Colors.redAccent, width: 2), //border
borderRadius: BorderRadius.circular(20), //border radius
style: TextStyle( //text style
color:Colors.white,
fontSize: 20
),
icon: Icon(Icons.arrow_downward), //icon
iconEnableColor: Colors.white, //icon enable color
dropdownColor: Colors.orange, //dropdown background color
)
copied to clipboard
Additional information #
You can get further more information regarding dropdown button in Flutter.

How to Solve DropdownButton Errors in Flutter
How to Style DropdownButton in Flutter

Visit, FlutterCampus.com for Flutter Tutorials, Guides and App Templates

License

For personal and professional use. You cannot resell or redistribute these repositories in their original state.

Files In This Product:

Customer Reviews

There are no reviews.