InputDecoration field
Hey,
thanks for the wonderful plugin. Is it possible to use custom InputDecoration with this select?
I believe many people use it in forms, and use either custom InputDecoration or InputDecorationTheme to style form. With this select it seems to be impossible at the moment. To add to the confusion, the inputDecoration field has type Decoration, which is for styling Container, not the inputs.
One option is to use this Decoration property to mimic other inputs' style in the form. However, it doesn't solve the problem with stuff like errorText or helper text. Wrapping it up with InputDecorator class kind of helps, but still looks bad (hovering over the field with a rounded corner produces a highlighted box behind the field, etc), plus looks like a hack.
Is there a discussion of allowing users to provide custom InputDecoration for the field?
Came across the same issue
I tried to apply them with
MultiSelectDropDown<T>(
hintStyle: Theme.of(context).inputDecorationTheme.hintStyle,
inputDecoration: BoxDecoration(
color: Theme.of(context).inputDecorationTheme.fillColor,
border: Theme.of(context).inputDecorationTheme.border != null
? Border.fromBorderSide(Theme.of(context).inputDecorationTheme.border!.borderSide)
: Border(bottom: BorderSide(color: Theme.of(context).inputDecorationTheme.outlineBorder?.color ?? Colors.black45)),
),
...
)
However, it's pretty hard to get borders to work correctly.
On top of that, there's a constraint put in the widget that forces a min height of 52 which can be problematic in most forms
Try out Dev version
Check Beta version.
v3.0.0 now supports this. Please migrate to the latest version.