From d222c60cef289b57f0ce350e9f24ce2df4792ef5 Mon Sep 17 00:00:00 2001 From: Dessalines Date: Thu, 9 Jul 2020 19:59:02 -0400 Subject: A few cake day fixes. #916 --- ui/src/components/user-listing.tsx | 35 +++++++++++++++++++++++------------ 1 file changed, 23 insertions(+), 12 deletions(-) (limited to 'ui/src/components/user-listing.tsx') diff --git a/ui/src/components/user-listing.tsx b/ui/src/components/user-listing.tsx index 0e150b94..58475d3e 100644 --- a/ui/src/components/user-listing.tsx +++ b/ui/src/components/user-listing.tsx @@ -1,7 +1,13 @@ import { Component } from 'inferno'; import { Link } from 'inferno-router'; import { UserView } from '../interfaces'; -import { pictrsAvatarThumbnail, showAvatars, hostname } from '../utils'; +import { + pictrsAvatarThumbnail, + showAvatars, + hostname, + isCakeDay, +} from '../utils'; +import { CakeDay } from './cake-day'; interface UserOther { name: string; @@ -9,6 +15,7 @@ interface UserOther { avatar?: string; local?: boolean; actor_id?: string; + published?: string; } interface UserListingProps { @@ -35,17 +42,21 @@ export class UserListing extends Component { } return ( - - {user.avatar && showAvatars() && ( - - )} - {name_} - + <> + + {user.avatar && showAvatars() && ( + + )} + {name_} + + + {isCakeDay(user.published) && } + ); } } -- cgit v1.2.3