Skip to content

Commit

Permalink
Merge pull request #42 from software-mansion-labs/@cdOut/ideal-nav-fi…
Browse files Browse the repository at this point in the history
…xes-2
  • Loading branch information
cdOut authored Jan 26, 2024
2 parents ed57401 + 2bdf278 commit 140229f
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/components/MenuItem.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -397,7 +397,7 @@ function MenuItem(
combinedStyle,
!interactive && styles.cursorDefault,
StyleUtils.getButtonBackgroundColorStyle(getButtonState(focused || isHovered, pressed, success, disabled, interactive), true),
(isHovered || pressed) && hoverAndPressStyle,
!focused && (isHovered || pressed) && hoverAndPressStyle,
...(Array.isArray(wrapperStyle) ? wrapperStyle : [wrapperStyle]),
shouldGreyOutWhenDisabled && disabled && styles.buttonOpacityDisabled,
] as StyleProp<ViewStyle>
Expand Down
3 changes: 2 additions & 1 deletion src/pages/home/sidebar/AllSettingsScreen.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,9 @@ function AllSettingsScreen() {
wrapperStyle: styles.sectionMenuItem,
isPaneMenu: true,
focused: item.focused,
hoverAndPressStyle: styles.hoveredComponentBG,
}));
}, [isSmallScreenWidth, styles.sectionMenuItem, translate, waitForNavigate]);
}, [isSmallScreenWidth, styles.hoveredComponentBG, styles.sectionMenuItem, translate, waitForNavigate]);

return (
<ScreenWrapper
Expand Down
15 changes: 14 additions & 1 deletion src/pages/settings/InitialSettingsPage.js
Original file line number Diff line number Diff line change
Expand Up @@ -262,6 +262,7 @@ function InitialSettingsPage(props) {
shouldStackHorizontally={item.shouldStackHorizontally}
floatRightAvatarSize={item.avatarSize}
ref={popoverAnchor}
hoverAndPressStyle={styles.hoveredComponentBG}
shouldBlockSelection={Boolean(item.link)}
onSecondaryInteraction={
!_.isEmpty(item.link) ? (e) => ReportActionContextMenu.showContextMenu(CONST.CONTEXT_MENU_TYPES.LINK, e, item.link, popoverAnchor.current) : undefined
Expand All @@ -274,7 +275,19 @@ function InitialSettingsPage(props) {
</View>
);
},
[styles.pb4, styles.mh3, styles.sectionTitle, styles.sectionMenuItem, translate, props.userWallet.currentBalance, isExecuting, singleExecution, activeRoute, waitForNavigate],
[
styles.pb4,
styles.mh3,
styles.sectionTitle,
styles.sectionMenuItem,
styles.hoveredComponentBG,
translate,
props.userWallet.currentBalance,
isExecuting,
singleExecution,
activeRoute,
waitForNavigate,
],
);

const accountMenuItems = useMemo(() => getMenuItemsSection(accountMenuItemsData), [accountMenuItemsData, getMenuItemsSection]);
Expand Down
1 change: 0 additions & 1 deletion src/pages/settings/Wallet/WalletPage/WalletPage.js
Original file line number Diff line number Diff line change
Expand Up @@ -443,7 +443,6 @@ function WalletPage({bankAccountList, cardList, fundList, isLoadingPaymentMethod
ref={buttonRef}
text={translate('walletPage.enableWallet')}
onPress={triggerKYCFlow}
style={styles.mh5}
isDisabled={network.isOffline}
success
large
Expand Down
2 changes: 1 addition & 1 deletion src/styles/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3184,7 +3184,7 @@ const styles = (theme: ThemeColors) =>
alignItems: 'center',
gap: 8,
paddingHorizontal: 24,
backgroundColor: theme.highlightBG,
backgroundColor: theme.hoverComponentBG,
borderRadius: variables.componentBorderRadiusRounded,
},

Expand Down

0 comments on commit 140229f

Please sign in to comment.