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: TextStyle(
color: MirrorflyUikit.getTheme?.textPrimaryColor,
fontSize: 14,
fontWeight: FontWeight.w400)),
const SizedBox(
height: 4,
),
Text(
subtitle,
style: TextStyle(
fontSize: 13,
color: MirrorflyUikit.getTheme?.textSecondaryColor),
),
],
),
dividerPadding: const EdgeInsets.symmetric(horizontal: 16),
trailing:
// SvgPicture.asset(package: package,
// on ? tickRoundBlue : tickRound,package: package,
// ),
on
? Icon(
Icons.check_circle_rounded,
color: MirrorflyUikit.getTheme?.primaryColor,
size: 20,
)
: const Icon(
Icons.check_circle_rounded,
color: Colors.grey,
size: 20,
),
onTap: onTap);
}