From 8104bf0982c900da8d9f0cf5a7c930d39fbb6e3e Mon Sep 17 00:00:00 2001 From: aliraza556 Date: Thu, 21 Mar 2024 18:41:08 +0500 Subject: [PATCH] Fixed default photo not showing --- src/pages/leaderboard/userInfo/index.tsx | 2 +- .../widgetViews/wantedViews/DesktopView.tsx | 28 +++++++++---------- .../widgetViews/wantedViews/MobileView.tsx | 9 ++---- 3 files changed, 17 insertions(+), 22 deletions(-) diff --git a/src/pages/leaderboard/userInfo/index.tsx b/src/pages/leaderboard/userInfo/index.tsx index 69aab48e..e31cd810 100644 --- a/src/pages/leaderboard/userInfo/index.tsx +++ b/src/pages/leaderboard/userInfo/index.tsx @@ -57,7 +57,7 @@ export const UserInfo = observer(({ id }: { id: string }) => {
diff --git a/src/people/widgetViews/wantedViews/DesktopView.tsx b/src/people/widgetViews/wantedViews/DesktopView.tsx index e3365d5c..f4df01a7 100644 --- a/src/people/widgetViews/wantedViews/DesktopView.tsx +++ b/src/people/widgetViews/wantedViews/DesktopView.tsx @@ -41,7 +41,7 @@ function DesktopView(props: WantedViewsProps) { titleString } = props; - const { ui } = useStores(); + const { ui, main } = useStores(); const color = colors['light']; return ( @@ -105,20 +105,18 @@ function DesktopView(props: WantedViewsProps) { marginTop: '8px' }} > - assignee_img + {assignee && ( + assignee_img + )} { e.stopPropagation(); diff --git a/src/people/widgetViews/wantedViews/MobileView.tsx b/src/people/widgetViews/wantedViews/MobileView.tsx index 9b2fb975..fdeea69a 100644 --- a/src/people/widgetViews/wantedViews/MobileView.tsx +++ b/src/people/widgetViews/wantedViews/MobileView.tsx @@ -44,7 +44,7 @@ function MobileView(props: any) { titleString } = props; - const { ui } = useStores(); + const { ui, main } = useStores(); const color = colors['light']; return ( @@ -116,11 +116,7 @@ function MobileView(props: any) { }} > assignee_img ); } + export default observer(MobileView);