Lucas.Xu d1c1449cf6
feat: support notification on mobile (#5831)
* feat: add inbox/unread/archived tabs

* feat: dump notification info

* chore: add reminder bloc

* feat: support unread / archive notification tab

* feat: support archive all & mark all as read

* feat: add empty page

* chore: optimize gesture

* feat: add red dot above notification icon

* chore: optimize code logic

* feat: optimize tabbar animation

* fix: notification align issue

* fix: todo list icon align issue

* feat: disable emoji button inside callout in read-only mode

* feat: optimize icon size in editor

* chore: improve text color in dark mode
2024-07-31 15:15:15 +08:00

32 lines
894 B
Dart

import 'package:appflowy_backend/protobuf/flowy-user/protobuf.dart';
class ReminderMetaKeys {
static String includeTime = "include_time";
static String blockId = "block_id";
static String rowId = "row_id";
static String createdAt = "created_at";
static String isArchived = "is_archived";
}
extension ReminderExtension on ReminderPB {
bool? get includeTime {
final String? includeTimeStr = meta[ReminderMetaKeys.includeTime];
return includeTimeStr != null ? includeTimeStr == true.toString() : null;
}
String? get blockId => meta[ReminderMetaKeys.blockId];
String? get rowId => meta[ReminderMetaKeys.rowId];
int? get createdAt {
final t = meta[ReminderMetaKeys.createdAt];
return t != null ? int.tryParse(t) : null;
}
bool get isArchived {
final t = meta[ReminderMetaKeys.isArchived];
return t != null ? t == true.toString() : false;
}
}