notificationItem function
ListItem
notificationItem(
{ - required String title,
- required String subtitle,
- bool on = false,
- required dynamic onTap(),
})
Implementation
ListItem notificationItem(
{required String title,
required String subtitle,
bool on = false,
required Function() onTap}) {
return ListItem(
title: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(title,
style: const TextStyle(
color: Colors.black,
fontSize: 14,
fontWeight: FontWeight.w400)),
const SizedBox(
height: 4,
),
Text(
subtitle,
style: const TextStyle(fontSize: 13, color: textColor),
),
],
),
dividerPadding: const EdgeInsets.symmetric(horizontal: 16),
trailing: AppUtils.svgIcon(
icon: on ? tickRoundBlue : tickRound,
),
onTap: onTap);
}