AssistSuggestionSettings constructor

const AssistSuggestionSettings({
  1. Color? backgroundColor,
  2. WidgetStateProperty<Color?>? itemBackgroundColor,
  3. ShapeBorder? shape,
  4. WidgetStateProperty<ShapeBorder?>? itemShape,
  5. WidgetStateProperty<TextStyle?>? textStyle,
  6. EdgeInsetsGeometry margin = const EdgeInsetsDirectional.symmetric(vertical: 5.0),
  7. EdgeInsetsGeometry itemPadding = const EdgeInsets.symmetric(horizontal: 12.0, vertical: 8.0),
  8. Axis orientation = Axis.horizontal,
  9. AssistSuggestionOverflow itemOverflow = AssistSuggestionOverflow.wrap,
  10. AssistSuggestionSelectionType selectionType = AssistSuggestionSelectionType.single,
  11. double runSpacing = 12.0,
  12. double spacing = 16.0,
})

Implementation

const AssistSuggestionSettings({
  this.backgroundColor,
  this.itemBackgroundColor,
  this.shape,
  this.itemShape,
  this.textStyle,
  this.margin = const EdgeInsetsDirectional.symmetric(vertical: 5.0),
  this.itemPadding = const EdgeInsets.symmetric(
    horizontal: 12.0,
    vertical: 8.0,
  ),
  this.orientation = Axis.horizontal,
  AssistSuggestionOverflow itemOverflow = AssistSuggestionOverflow.wrap,
  AssistSuggestionSelectionType selectionType =
      AssistSuggestionSelectionType.single,
  this.runSpacing = 12.0,
  this.spacing = 16.0,
}) : itemOverflow =
         itemOverflow == AssistSuggestionOverflow.wrap
             ? SuggestionOverflow.wrap
             : SuggestionOverflow.scroll,
     selectionType =
         selectionType == AssistSuggestionSelectionType.single
             ? SuggestionSelectionType.single
             : SuggestionSelectionType.multiple;