textColumn<T extends Object> method
Build a simple text column.
title is the header label, value extracts the string to render from
the row item. sizeFactor follows the same semantics as the underlying
TableColumn.sizeFactor (fraction of the available width).
Implementation
TableColumn<T> textColumn<T extends Object>({
required String title,
required String Function(T) value,
double sizeFactor = .1,
bool sortable = false,
String? id,
bool isMain = false,
}) {
return TableColumn<T>(
id: id,
title: Text(title),
cellBuilder: (item) => Text(value(item)),
sizeFactor: sizeFactor,
sortable: sortable,
isMain: isMain,
);
}