From bf85c436fda14ae39a1404a57be826aefcd25c92 Mon Sep 17 00:00:00 2001 From: Rushat Gabhane Date: Thu, 19 Dec 2024 20:21:35 +0530 Subject: [PATCH 1/2] hide margin if no delegators --- src/pages/settings/Security/SecuritySettingsPage.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pages/settings/Security/SecuritySettingsPage.tsx b/src/pages/settings/Security/SecuritySettingsPage.tsx index fd60bfa6a32c..59ad56017c53 100644 --- a/src/pages/settings/Security/SecuritySettingsPage.tsx +++ b/src/pages/settings/Security/SecuritySettingsPage.tsx @@ -303,7 +303,7 @@ function SecuritySettingsPage() { icon={Expensicons.UserPlus} onPress={() => Navigation.navigate(ROUTES.SETTINGS_ADD_DELEGATE)} shouldShowRightIcon - wrapperStyle={[styles.sectionMenuItemTopDescription, styles.mb6]} + wrapperStyle={[styles.sectionMenuItemTopDescription, hasDelegators && styles.mb6]} /> )} {hasDelegators && ( From c2b0ad65a3aefa484dd41f551229026e01df0787 Mon Sep 17 00:00:00 2001 From: Rushat Gabhane Date: Thu, 19 Dec 2024 20:33:20 +0530 Subject: [PATCH 2/2] fix eslint --- src/pages/settings/Security/SecuritySettingsPage.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/pages/settings/Security/SecuritySettingsPage.tsx b/src/pages/settings/Security/SecuritySettingsPage.tsx index 59ad56017c53..ea6207b562dd 100644 --- a/src/pages/settings/Security/SecuritySettingsPage.tsx +++ b/src/pages/settings/Security/SecuritySettingsPage.tsx @@ -166,7 +166,7 @@ function SecuritySettingsPage() { title: personalDetail?.displayName ?? formattedEmail, description: personalDetail?.displayName ? formattedEmail : '', badgeText: translate('delegate.role', {role}), - avatarID: personalDetail?.accountID ?? -1, + avatarID: personalDetail?.accountID ?? CONST.DEFAULT_NUMBER_ID, icon: personalDetail?.avatar ?? FallbackAvatar, iconType: CONST.ICON_TYPE_AVATAR, numberOfLinesDescription: 1, @@ -195,7 +195,7 @@ function SecuritySettingsPage() { title: personalDetail?.displayName ?? formattedEmail, description: personalDetail?.displayName ? formattedEmail : '', badgeText: translate('delegate.role', {role}), - avatarID: personalDetail?.accountID ?? -1, + avatarID: personalDetail?.accountID ?? CONST.DEFAULT_NUMBER_ID, icon: personalDetail?.avatar ?? FallbackAvatar, iconType: CONST.ICON_TYPE_AVATAR, numberOfLinesDescription: 1,