FlutterInputChips constructor

const FlutterInputChips({
  1. Key? key,
  2. required ValueChanged<List<String>> onChanged,
  3. List<String> initialValue = const [],
  4. bool enabled = true,
  5. TextInputAction inputAction = TextInputAction.done,
  6. Brightness keyboardAppearance = Brightness.light,
  7. TextCapitalization textCapitalization = TextCapitalization.none,
  8. bool autofocus = false,
  9. InputDecoration inputDecoration = const InputDecoration(),
  10. TextOverflow textOverflow = TextOverflow.clip,
  11. TextInputType inputType = TextInputType.text,
  12. EdgeInsets padding = const EdgeInsets.symmetric(horizontal: 16, vertical: 10),
  13. bool chipCanDelete = true,
  14. double chipSpacing = 5,
  15. int? maxChips,
  16. BoxDecoration? decoration,
  17. TextStyle? chipTextStyle,
  18. Color? chipBackgroundColor,
  19. Widget? chipDeleteIcon,
  20. Color? chipDeleteIconColor,
  21. InputChipsController? controller,
  22. VoidCallback? onMaxChipsReached,
})

Implementation

const FlutterInputChips({
  super.key,
  required this.onChanged,
  this.initialValue = const [],
  this.enabled = true,
  this.inputAction = TextInputAction.done,
  this.keyboardAppearance = Brightness.light,
  this.textCapitalization = TextCapitalization.none,
  this.autofocus = false,
  this.inputDecoration = const InputDecoration(),
  this.textOverflow = TextOverflow.clip,
  this.inputType = TextInputType.text,
  this.padding = const EdgeInsets.symmetric(horizontal: 16, vertical: 10),
  this.chipCanDelete = true,
  this.chipSpacing = 5,
  this.maxChips,
  this.decoration,
  this.chipTextStyle,
  this.chipBackgroundColor,
  this.chipDeleteIcon,
  this.chipDeleteIconColor,
  this.controller,
  this.onMaxChipsReached,
}) : assert(maxChips == null || initialValue.length <= maxChips);