|
|
|
@ -7,7 +7,7 @@ class QuillDropdownButton<T> extends StatefulWidget { |
|
|
|
|
required this.items, |
|
|
|
|
required this.rawitemsmap, |
|
|
|
|
required this.onSelected, |
|
|
|
|
this.height = 40, |
|
|
|
|
this.iconSize = 40, |
|
|
|
|
this.fillColor, |
|
|
|
|
this.hoverElevation = 1, |
|
|
|
|
this.highlightElevation = 1, |
|
|
|
@ -15,7 +15,7 @@ class QuillDropdownButton<T> extends StatefulWidget { |
|
|
|
|
Key? key, |
|
|
|
|
}) : super(key: key); |
|
|
|
|
|
|
|
|
|
final double height; |
|
|
|
|
final double iconSize; |
|
|
|
|
final Color? fillColor; |
|
|
|
|
final double hoverElevation; |
|
|
|
|
final double highlightElevation; |
|
|
|
@ -43,7 +43,7 @@ class _QuillDropdownButtonState<T> extends State<QuillDropdownButton<T>> { |
|
|
|
|
@override |
|
|
|
|
Widget build(BuildContext context) { |
|
|
|
|
return ConstrainedBox( |
|
|
|
|
constraints: BoxConstraints.tightFor(height: widget.height), |
|
|
|
|
constraints: BoxConstraints.tightFor(height: (widget.iconSize * 2) - (widget.iconSize / 3)), |
|
|
|
|
child: RawMaterialButton( |
|
|
|
|
visualDensity: VisualDensity.compact, |
|
|
|
|
shape: RoundedRectangleBorder( |
|
|
|
@ -105,9 +105,9 @@ class _QuillDropdownButtonState<T> extends State<QuillDropdownButton<T>> { |
|
|
|
|
child: Row( |
|
|
|
|
mainAxisSize: MainAxisSize.min, |
|
|
|
|
children: [ |
|
|
|
|
Text(_currentValue.toString()), |
|
|
|
|
SizedBox(width: 6), |
|
|
|
|
const Icon(Icons.arrow_drop_down, size: 17) |
|
|
|
|
Text(_currentValue.toString(), style: TextStyle(fontSize: widget.iconSize / 1.3)), |
|
|
|
|
SizedBox(width: widget.iconSize / 3.83), |
|
|
|
|
Icon(Icons.arrow_drop_down, size: widget.iconSize / 1.3) |
|
|
|
|
], |
|
|
|
|
), |
|
|
|
|
); |
|
|
|
|