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

fix: Profile - There is tooltip for Profile Share button but no tooltip for Workspace Share button. #49193

Merged
merged 3 commits into from
Sep 20, 2024
Merged
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
32 changes: 8 additions & 24 deletions src/pages/settings/Profile/ProfilePage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,16 @@ import {View} from 'react-native';
import {useOnyx} from 'react-native-onyx';
import AvatarSkeleton from '@components/AvatarSkeleton';
import AvatarWithImagePicker from '@components/AvatarWithImagePicker';
import Button from '@components/Button';
import FullScreenLoadingIndicator from '@components/FullscreenLoadingIndicator';
import HeaderWithBackButton from '@components/HeaderWithBackButton';
import Icon from '@components/Icon';
import * as Expensicons from '@components/Icon/Expensicons';
import * as Illustrations from '@components/Icon/Illustrations';
import MenuItemGroup from '@components/MenuItemGroup';
import MenuItemWithTopDescription from '@components/MenuItemWithTopDescription';
import {PressableWithFeedback} from '@components/Pressable';
import ScreenWrapper from '@components/ScreenWrapper';
import ScrollView from '@components/ScrollView';
import Section from '@components/Section';
import Text from '@components/Text';
import Tooltip from '@components/Tooltip';
import useCurrentUserPersonalDetails from '@hooks/useCurrentUserPersonalDetails';
import useLocalize from '@hooks/useLocalize';
import useResponsiveLayout from '@hooks/useResponsiveLayout';
Expand All @@ -26,7 +23,6 @@ import * as LocalePhoneNumber from '@libs/LocalePhoneNumber';
import Navigation from '@libs/Navigation/Navigation';
import * as PersonalDetailsUtils from '@libs/PersonalDetailsUtils';
import * as UserUtils from '@libs/UserUtils';
import variables from '@styles/variables';
import * as PersonalDetails from '@userActions/PersonalDetails';
import CONST from '@src/CONST';
import type {TranslationPaths} from '@src/languages/types';
Expand Down Expand Up @@ -169,25 +165,13 @@ function ProfilePage() {
brickRoadIndicator={detail.brickRoadIndicator}
/>
))}
<View style={[styles.alignSelfStart, styles.pt3]}>
<Tooltip text={translate('common.shareCode')}>
<PressableWithFeedback
accessibilityLabel={translate('common.shareCode')}
accessibilityRole="button"
accessible
onPress={() => Navigation.navigate(ROUTES.SETTINGS_SHARE_CODE)}
style={[styles.button, styles.flexRow, styles.gap1, styles.ph4]}
>
<Icon
src={Expensicons.QrCode}
width={variables.iconSizeNormal}
height={variables.iconSizeNormal}
fill={theme.icon}
/>
<Text style={styles.buttonText}>{translate('common.share')}</Text>
</PressableWithFeedback>
</Tooltip>
</View>
<Button
accessibilityLabel={translate('common.shareCode')}
text={translate('common.share')}
onPress={() => Navigation.navigate(ROUTES.SETTINGS_SHARE_CODE)}
icon={Expensicons.QrCode}
style={[styles.alignSelfStart, styles.mt6]}
/>
</Section>
<Section
title={translate('profilePage.privateSection.title')}
Expand Down
Loading