FileTreeItem constructor

const FileTreeItem({
  1. required String name,
  2. bool isFolder = false,
  3. bool isOpen = false,
  4. bool isHighlighted = false,
  5. Component? comment,
  6. List<FileTreeItem> children = const [],
})

Implementation

const FileTreeItem({
  required this.name,
  this.isFolder = false,
  this.isOpen = false,
  this.isHighlighted = false,
  this.comment,
  this.children = const [],
}) : assert(children.length > 0 || !isOpen, 'Only items with children can be open.');