CPListTemplate constructor

CPListTemplate({
  1. String? title,
  2. required List<CPListSection> sections,
  3. List<String>? emptyViewTitleVariants,
  4. List<String>? emptyViewSubtitleVariants,
  5. String? tabTitle,
  6. bool showsTabBadge = false,
  7. String? systemIcon,
  8. VoidCallback? onPop,
  9. CPBarButton? backButton,
  10. String? id,
})

Creates CPListTemplate to display a list of items, grouped into one or more sections. Each section contains an array of list items — objects that is CPListItem

Consider that some vehicles limit the number of items that CPListTemplate displays.

Implementation

CPListTemplate({
  this.title,
  required this.sections,
  this.emptyViewTitleVariants,
  this.emptyViewSubtitleVariants,
  super.tabTitle,
  super.showsTabBadge = false,
  super.systemIcon,
  super.onPop,
  this.backButton,
  String? id,
}) : _elementId = id ?? const Uuid().v4();