mirror of
https://github.com/ilyakooo0/urbit.git
synced 2025-01-01 19:46:36 +03:00
interface: address hunter review
This commit is contained in:
parent
743130829e
commit
c2437a3e35
@ -24,13 +24,15 @@ function useAssociationStatus(resource: string) {
|
||||
const { count, each } = stats;
|
||||
const hasNotifications = false;
|
||||
const hasUnread = count > 0 || each.length > 0;
|
||||
return !isSubscribed
|
||||
? 'unsubscribed'
|
||||
: hasNotifications
|
||||
? 'notification'
|
||||
: hasUnread
|
||||
? 'unread'
|
||||
: undefined;
|
||||
if(!isSubscribed) {
|
||||
return 'unsubscribed';
|
||||
} else if (hasNotifications) {
|
||||
return 'notification';
|
||||
} else if (hasUnread) {
|
||||
return 'unread';
|
||||
} else {
|
||||
return undefined;
|
||||
}
|
||||
}
|
||||
|
||||
function SidebarItemBase(props: {
|
||||
|
Loading…
Reference in New Issue
Block a user