Is there a way of making "${innerItem.key}" bold? Thanks
List<Map<String, dynamic>> incidentList = [
for (final json in listNode.map((x) => x.toJson()))
{
'Code': json['field'][0]['field_value'],
'Description': json['field'][1]['field_value'],
'Organisation Unit': json['field'][2]['field_value'],
'Date Reported': json['field'][3]['field_value'],
'Status': json['field'][4]['field_value'],
'RunHyperlink' : json['run_hyperlink']
}
];
final List<String> values = [];
for(final item in incidentList){
String groupedElement = "";
for(var innerItem in item.entries)
{
groupedElement += "${innerItem.key} : ${innerItem.value}\n";
}
values.add(groupedElement);
}
await WriteCache.setListString(key: 'cache4', value: values);
Navigator.of(context).push(
MaterialPageRoute(builder: (context) => LossEvent()));
The string will be stored in "values" and will then be accessed by "snapshot.data[index]". Is there a way of making "${innerItem.key} bold?" before storing it into "values"?