feat: add unlink confirmation dialog, enable agent navigation, update notification read status UI, and increment app version
This commit is contained in:
@@ -93,26 +93,32 @@ class _NotificationsScreenState extends ConsumerState<NotificationsScreen> {
|
||||
return _buildFilterChip(label, 'unread');
|
||||
}),
|
||||
const Spacer(),
|
||||
GestureDetector(
|
||||
onTap: () async {
|
||||
await ref
|
||||
.read(notificationListProvider.notifier)
|
||||
.markAllAsRead();
|
||||
// Reload current filter to reflect changes
|
||||
ref
|
||||
.read(notificationListProvider.notifier)
|
||||
.loadNotifications(filter: _activeFilter);
|
||||
},
|
||||
child: const Text(
|
||||
'Mark all as read',
|
||||
style: TextStyle(
|
||||
fontFamily: 'SourceSerif4',
|
||||
fontSize: 13,
|
||||
fontWeight: FontWeight.w400,
|
||||
color: AppColors.accentOrange,
|
||||
Builder(builder: (context) {
|
||||
final hasUnread = ref.watch(unreadCountProvider) > 0;
|
||||
return GestureDetector(
|
||||
onTap: hasUnread
|
||||
? () async {
|
||||
await ref
|
||||
.read(notificationListProvider.notifier)
|
||||
.markAllAsRead();
|
||||
ref
|
||||
.read(notificationListProvider.notifier)
|
||||
.loadNotifications(filter: _activeFilter);
|
||||
}
|
||||
: null,
|
||||
child: Text(
|
||||
'Mark all as read',
|
||||
style: TextStyle(
|
||||
fontFamily: 'SourceSerif4',
|
||||
fontSize: 13,
|
||||
fontWeight: FontWeight.w400,
|
||||
color: hasUnread
|
||||
? AppColors.accentOrange
|
||||
: AppColors.accentOrange.withValues(alpha: 0.4),
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
}),
|
||||
],
|
||||
),
|
||||
),
|
||||
|
||||
Reference in New Issue
Block a user