MultiColumnListWidget constructor

MultiColumnListWidget({
  1. required List<PickerEntity>? items,
  2. Color normalColor = const Color(0Xff4a4e59),
  3. Color selectedColor = const Color(0xff41bc6a),
  4. double maxHeight = 0,
  5. Color? backgroundColor,
  6. Color? selectedBackgroundColor,
  7. required int flex,
  8. int? focusedIndex,
  9. BrnOnEntityTap? singleListItemPick,
  10. OnSelectEntityInterceptor? onSelectEntityInterceptor,
})

Implementation

MultiColumnListWidget({
  required this.items,
  this.normalColor = const Color(0Xff4a4e59),
  this.selectedColor = const Color(0xff41bc6a),
  this.maxHeight = 0,
  this.backgroundColor,
  this.selectedBackgroundColor,
  required this.flex,
  this.focusedIndex,
  this.singleListItemPick,
  this.onSelectEntityInterceptor,
}) {
  items ??= [];
  items!.forEach((element) {
    element.configRelationship();
  });

  currentListIndex = MultiColumnPickerUtil.getCurrentColumnIndex(
      items!.isNotEmpty ? items![0] : null);

  _selectedItems = items?.where((f) => f.isSelected).toList();
  _selectedItems ??= [];
}