Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Search v1] Implement Bottom Tab Bar Changes #40293

Merged
merged 10 commits into from
Jun 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions assets/images/inbox.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
16 changes: 16 additions & 0 deletions assets/images/money-search.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 4 additions & 0 deletions src/components/Icon/Expensicons.ts
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ import Home from '@assets/images/home.svg';
import Hourglass from '@assets/images/hourglass.svg';
import ImageCropCircleMask from '@assets/images/image-crop-circle-mask.svg';
import ImageCropSquareMask from '@assets/images/image-crop-square-mask.svg';
import Inbox from '@assets/images/inbox.svg';
import Info from '@assets/images/info.svg';
import QBOSquare from '@assets/images/integrationicons/qbo-icon-square.svg';
import XeroSquare from '@assets/images/integrationicons/xero-icon-square.svg';
Expand All @@ -106,6 +107,7 @@ import Menu from '@assets/images/menu.svg';
import Meter from '@assets/images/meter.svg';
import MoneyBag from '@assets/images/money-bag.svg';
import MoneyCircle from '@assets/images/money-circle.svg';
import MoneySearch from '@assets/images/money-search.svg';
import MoneyWaving from '@assets/images/money-waving.svg';
import Monitor from '@assets/images/monitor.svg';
import Mute from '@assets/images/mute.svg';
Expand Down Expand Up @@ -251,6 +253,7 @@ export {
History,
Home,
Hourglass,
Inbox,
ImageCropCircleMask,
ImageCropSquareMask,
Info,
Expand All @@ -271,6 +274,7 @@ export {
Megaphone,
MoneyBag,
MoneyCircle,
MoneySearch,
MoneyWaving,
Monitor,
Mute,
Expand Down
14 changes: 0 additions & 14 deletions src/components/TestToolMenu.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,11 @@ import useLocalize from '@hooks/useLocalize';
import useThemeStyles from '@hooks/useThemeStyles';
import * as ApiUtils from '@libs/ApiUtils';
import compose from '@libs/compose';
import Navigation from '@libs/Navigation/Navigation';
import * as Network from '@userActions/Network';
import * as Session from '@userActions/Session';
import * as User from '@userActions/User';
import CONFIG from '@src/CONFIG';
import CONST from '@src/CONST';
import ONYXKEYS from '@src/ONYXKEYS';
import ROUTES from '@src/ROUTES';
import type {Network as NetworkOnyx, User as UserOnyx} from '@src/types/onyx';
import Button from './Button';
import {withNetwork} from './OnyxProvider';
Expand Down Expand Up @@ -92,17 +89,6 @@ function TestToolMenu({user = USER_DEFAULT, network}: TestToolMenuProps) {
onPress={() => Session.invalidateCredentials()}
/>
</TestToolRow>

{/* Navigate to the new Search Page. This button is temporary and should be removed after passing QA tests. */}
<TestToolRow title="New Search Page">
<Button
small
text="Navigate"
onPress={() => {
Navigation.navigate(ROUTES.SEARCH.getRoute(CONST.TAB_SEARCH.ALL));
}}
/>
</TestToolRow>
</>
);
}
Expand Down
2 changes: 1 addition & 1 deletion src/languages/en.ts
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ export default {
magicCode: 'Magic code',
twoFactorCode: 'Two-factor code',
workspaces: 'Workspaces',
chats: 'Chats',
inbox: 'Inbox',
group: 'Group',
profile: 'Profile',
referral: 'Referral',
Expand Down
2 changes: 1 addition & 1 deletion src/languages/es.ts
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ export default {
magicCode: 'Código mágico',
twoFactorCode: 'Autenticación de dos factores',
workspaces: 'Espacios de trabajo',
chats: 'Chats',
inbox: 'Bandeja de entrada',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This text overflows #42772 (comment)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@s77rt do we have a fix for that yet?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fix here #43429

group: 'Grupo',
profile: 'Perfil',
referral: 'Remisión',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,19 +70,19 @@ function BottomTabBar({isLoadingApp = false}: PurposeForUsingExpensifyModalProps

return (
<View style={styles.bottomTabBarContainer}>
<Tooltip text={translate('common.chats')}>
<Tooltip text={translate('common.inbox')}>
<PressableWithFeedback
onPress={() => {
Navigation.navigate(ROUTES.HOME);
}}
role={CONST.ROLE.BUTTON}
accessibilityLabel={translate('common.chats')}
accessibilityLabel={translate('common.inbox')}
wrapperStyle={styles.flex1}
style={styles.bottomTabBarItem}
>
<View>
<Icon
src={Expensicons.ChatBubble}
src={Expensicons.Inbox}
fill={currentTabName === SCREENS.HOME ? theme.iconMenu : theme.icon}
width={variables.iconBottomBar}
height={variables.iconBottomBar}
Expand All @@ -93,8 +93,30 @@ function BottomTabBar({isLoadingApp = false}: PurposeForUsingExpensifyModalProps
</View>
</PressableWithFeedback>
</Tooltip>
<BottomTabBarFloatingActionButton />
<Tooltip text={translate('common.search')}>
<PressableWithFeedback
onPress={() => {
Navigation.navigate(ROUTES.SEARCH.getRoute(CONST.TAB_SEARCH.ALL));
}}
role={CONST.ROLE.BUTTON}
accessibilityLabel={translate('common.search')}
wrapperStyle={styles.flex1}
style={styles.bottomTabBarItem}
>
<View>
<Icon
src={Expensicons.MoneySearch}
fill={currentTabName === SCREENS.SEARCH.BOTTOM_TAB || currentTabName === SCREENS.SEARCH.CENTRAL_PANE ? theme.iconMenu : theme.icon}
width={variables.iconBottomBar}
height={variables.iconBottomBar}
/>
</View>
</PressableWithFeedback>
</Tooltip>
<BottomTabAvatar isSelected={currentTabName === SCREENS.SETTINGS.ROOT} />
<View style={[styles.flex1, styles.bottomTabBarItem]}>
<BottomTabBarFloatingActionButton />
</View>
</View>
);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ function BaseSidebarScreen() {
{({insets}) => (
<>
<TopBar
breadcrumbLabel={translate('common.chats')}
breadcrumbLabel={translate('common.inbox')}
activeWorkspaceID={activeWorkspaceID}
/>
<View style={[styles.flex1]}>
Expand Down
Loading