DataDisplayBuilder<T>.string constructor
const
DataDisplayBuilder<T>.string ({
- required String labelBuilder(
- T data
- Color? backgroundColor,
- TextStyle? labelStyle,
- OutlinedBorder? shape,
- Color? deleteIconColor,
- Widget? deleteIcon,
- Widget? avatar,
- BoxConstraints? avatarBoxConstraints,
- EdgeInsetsGeometry? labelPadding,
- @Default.new(BorderSide.none) BorderSide side,
A pre-defined string builder that can be used to display a piece of data.
This builder will create a Chip widget with the following properties:
labelBuilderis used to generate the label of the chip.backgroundColoris used to set the background color of the chip.labelStyleis used to set the style of the label.shapeis used to set the shape of the chip.deleteIconColoris used to set the color of the delete icon.deleteIconis used to set the delete icon.avataris used to set the avatar of the chip.avatarBoxConstraintsis used to set the box constraints of the avatar.labelPaddingis used to set the padding of the label.sideis used to set the side of the chip where the delete icon is placed.
See DataDisplayBuilderWidget for a custom widget builder.
Implementation
const factory DataDisplayBuilder.string({
required String Function(T data) labelBuilder,
Color? backgroundColor,
TextStyle? labelStyle,
OutlinedBorder? shape,
Color? deleteIconColor,
Widget? deleteIcon,
Widget? avatar,
BoxConstraints? avatarBoxConstraints,
EdgeInsetsGeometry? labelPadding,
@Default(BorderSide.none) BorderSide side,
}) = DataDisplayBuilderString;