From f6af564d4e62a7e418cd5d92cd926c6b6db8fe5d Mon Sep 17 00:00:00 2001 From: Andy An <58932667+Yucheng-An@users.noreply.github.com> Date: Sat, 16 Nov 2024 17:47:41 -0800 Subject: [PATCH] feat: enhancement on UI/UX on user statistic view part. (#4122) Enhancement on UI/UX on user statistic view part. --- web/src/components/UserStatisticsView.tsx | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/web/src/components/UserStatisticsView.tsx b/web/src/components/UserStatisticsView.tsx index e35ecd29..4778ebcb 100644 --- a/web/src/components/UserStatisticsView.tsx +++ b/web/src/components/UserStatisticsView.tsx @@ -89,7 +89,13 @@ const UserStatisticsView = () => { data={activityStats} onClick={onCalendarClick} /> - {memoAmount > 0 && ( + {memoAmount === 0 ? ( +

No memos

+ ) : memoAmount === 1 ? ( +

+ {memoAmount} memo in {days} {days > 1 ? "days" : "day"} +

+ ) : (

{memoAmount} memos in {days} {days > 1 ? "days" : "day"}