Skip to content

Commit

Permalink
remove get assistance button
Browse files Browse the repository at this point in the history
  • Loading branch information
289Adam289 committed Mar 7, 2025
1 parent f96aa10 commit c5f180d
Show file tree
Hide file tree
Showing 24 changed files with 1 addition and 180 deletions.
15 changes: 1 addition & 14 deletions src/CONST.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3340,20 +3340,7 @@ const CONST = {
PREFIX: '__predefined_',
SELF_SELECT: '__predefined_selfSelect',
},
GUIDES_CALL_TASK_IDS: {
CONCIERGE_DM: 'NewExpensifyConciergeDM',
WORKSPACE_INITIAL: 'WorkspaceHome',
WORKSPACE_OVERVIEW: 'WorkspaceOverview',
WORKSPACE_INVOICES: 'WorkspaceSendInvoices',
WORKSPACE_MEMBERS: 'WorkspaceManageMembers',
WORKSPACE_EXPENSIFY_CARD: 'WorkspaceExpensifyCard',
WORKSPACE_WORKFLOWS: 'WorkspaceWorkflows',
WORKSPACE_COMPANY_CARDS: 'WorkspaceCompanyCards',
WORKSPACE_BANK_ACCOUNT: 'WorkspaceBankAccount',
WORKSPACE_SETTINGS: 'WorkspaceSettings',
WORKSPACE_FEATURES: 'WorkspaceFeatures',
WORKSPACE_RULES: 'WorkspaceRules',
},

EXPENSIFY_EMAILS_OBJECT: Object.entries(EMAIL).reduce((prev, [, email]) => {
// eslint-disable-next-line no-param-reassign
prev[email] = true;
Expand Down
4 changes: 0 additions & 4 deletions src/ROUTES.ts
Original file line number Diff line number Diff line change
Expand Up @@ -108,10 +108,6 @@ const ROUTES = {
getRoute: (accountID: number) => `a/${accountID}/avatar` as const,
},

GET_ASSISTANCE: {
route: 'get-assistance/:taskID',
getRoute: (taskID: string, backTo: string) => getUrlWithBackToParam(`get-assistance/${taskID}`, backTo),
},
DESKTOP_SIGN_IN_REDIRECT: 'desktop-signin-redirect',

// This is a special validation URL that will take the user to /workspace/new after validation. This is used
Expand Down
1 change: 0 additions & 1 deletion src/SCREENS.ts
Original file line number Diff line number Diff line change
Expand Up @@ -660,7 +660,6 @@ const SCREENS = {
},
FLAG_COMMENT_ROOT: 'FlagComment_Root',
REIMBURSEMENT_ACCOUNT: 'ReimbursementAccount',
GET_ASSISTANCE: 'GetAssistance',
REFERRAL_DETAILS: 'Referral_Details',
KEYBOARD_SHORTCUTS: 'KeyboardShortcuts',
TRANSACTION_RECEIPT: 'TransactionReceipt',
Expand Down
19 changes: 0 additions & 19 deletions src/components/HeaderWithBackButton/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ function HeaderWithBackButton({
iconWidth,
iconHeight,
iconStyles,
guidesCallTaskID = '',
onBackButtonPress = () => Navigation.goBack(),
onCloseButtonPress = () => Navigation.dismissModal(),
onDownloadButtonPress = () => {},
Expand All @@ -43,8 +42,6 @@ function HeaderWithBackButton({
shouldShowCloseButton = false,
shouldShowDownloadButton = false,
isDownloading = false,
shouldShowGetAssistanceButton = false,
shouldDisableGetAssistanceButton = false,
shouldShowPinButton = false,
shouldSetModalVisibility = true,
shouldShowThreeDotsButton = false,
Expand Down Expand Up @@ -232,22 +229,6 @@ function HeaderWithBackButton({
color={theme.spinner}
/>
))}
{shouldShowGetAssistanceButton && (
<Tooltip text={translate('getAssistancePage.questionMarkButtonTooltip')}>
<PressableWithoutFeedback
disabled={shouldDisableGetAssistanceButton}
onPress={() => Navigation.navigate(ROUTES.GET_ASSISTANCE.getRoute(guidesCallTaskID, Navigation.getActiveRoute()))}
style={[styles.touchableButtonImage]}
role="button"
accessibilityLabel={translate('getAssistancePage.questionMarkButtonTooltip')}
>
<Icon
src={Expensicons.QuestionMark}
fill={iconFill ?? theme.icon}
/>
</PressableWithoutFeedback>
</Tooltip>
)}
{shouldShowPinButton && !!report && <PinButton report={report} />}
{shouldShowThreeDotsButton && (
<ThreeDotsMenu
Expand Down
9 changes: 0 additions & 9 deletions src/components/HeaderWithBackButton/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,12 +68,6 @@ type HeaderWithBackButtonProps = Partial<ChildrenProps> & {
/** Whether we should show a loading indicator replacing the download button */
isDownloading?: boolean;

/** Whether we should show a get assistance (question mark) button */
shouldShowGetAssistanceButton?: boolean;

/** Whether we should disable the get assistance button */
shouldDisableGetAssistanceButton?: boolean;

/** Whether we should show a pin button */
shouldShowPinButton?: boolean;

Expand Down Expand Up @@ -104,9 +98,6 @@ type HeaderWithBackButtonProps = Partial<ChildrenProps> & {
/** Whether we should show a back button */
shouldShowBackButton?: boolean;

/** The guides call taskID to associate with the get assistance button, if we show it */
guidesCallTaskID?: string;

/** Data to display a step counter in the header */
stepCounter?: StepCounterParams;

Expand Down
5 changes: 0 additions & 5 deletions src/components/InteractiveStepWrapper.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,6 @@ type InteractiveStepWrapperProps = {
// Should enable picker avoiding
shouldEnablePickerAvoiding?: boolean;

// Call task ID for the guides
guidesCallTaskID?: string;

// Offline indicator style
offlineIndicatorStyle?: StyleProp<ViewStyle>;
};
Expand All @@ -57,7 +54,6 @@ function InteractiveStepWrapper(
shouldEnableMaxHeight,
shouldShowOfflineIndicator,
shouldEnablePickerAvoiding = false,
guidesCallTaskID,
offlineIndicatorStyle,
}: InteractiveStepWrapperProps,
ref: React.ForwardedRef<View>,
Expand All @@ -78,7 +74,6 @@ function InteractiveStepWrapper(
title={headerTitle}
subtitle={headerSubtitle}
onBackButtonPress={handleBackButtonPress}
guidesCallTaskID={guidesCallTaskID}
/>
{!!stepNames && (
<View style={[styles.ph5, styles.mb5, styles.mt3, {height: CONST.BANK_ACCOUNT.STEPS_HEADER_HEIGHT}]}>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -385,7 +385,6 @@ const SettingsModalStackNavigator = createModalStackNavigator<SettingsNavigatorP
require<ReactComponentModule>('../../../../pages/workspace/accounting/qbd/import/QuickbooksDesktopCustomersDisplayedAsPage').default,
[SCREENS.WORKSPACE.ACCOUNTING.QUICKBOOKS_DESKTOP_ITEMS]: () => require<ReactComponentModule>('../../../../pages/workspace/accounting/qbd/import/QuickbooksDesktopItemsPage').default,
[SCREENS.REIMBURSEMENT_ACCOUNT]: () => require<ReactComponentModule>('../../../../pages/ReimbursementAccount/ReimbursementAccountPage').default,
[SCREENS.GET_ASSISTANCE]: () => require<ReactComponentModule>('../../../../pages/GetAssistancePage').default,
[SCREENS.SETTINGS.REPORT_CARD_LOST_OR_DAMAGED]: () => require<ReactComponentModule>('../../../../pages/settings/Wallet/ReportCardLostPage').default,
[SCREENS.KEYBOARD_SHORTCUTS]: () => require<ReactComponentModule>('../../../../pages/KeyboardShortcutsPage').default,
[SCREENS.SETTINGS.EXIT_SURVEY.REASON]: () => require<ReactComponentModule>('../../../../pages/settings/ExitSurvey/ExitSurveyReasonPage').default,
Expand Down
3 changes: 0 additions & 3 deletions src/libs/Navigation/linkingConfig/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -869,9 +869,6 @@ const config: LinkingOptions<RootNavigatorParamList>['config'] = {
path: ROUTES.BANK_ACCOUNT_WITH_STEP_TO_OPEN.route,
exact: true,
},
[SCREENS.GET_ASSISTANCE]: {
path: ROUTES.GET_ASSISTANCE.route,
},
[SCREENS.KEYBOARD_SHORTCUTS]: {
path: ROUTES.KEYBOARD_SHORTCUTS,
},
Expand Down
3 changes: 0 additions & 3 deletions src/libs/Navigation/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -787,9 +787,6 @@ type SettingsNavigatorParamList = {
policyID: string;
connection: ValueOf<typeof CONST.POLICY.CONNECTIONS.ROUTE>;
};
[SCREENS.GET_ASSISTANCE]: {
backTo: Routes;
};
[SCREENS.TWO_FACTOR_AUTH.DISABLED]: undefined;
[SCREENS.TWO_FACTOR_AUTH.DISABLE]: undefined;
[SCREENS.SETTINGS.DELEGATE.ADD_DELEGATE]: undefined;
Expand Down
100 changes: 0 additions & 100 deletions src/pages/GetAssistancePage.tsx

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,6 @@ function ConnectedVerifiedBankAccount({reimbursementAccount, onBackButtonPress,
>
<HeaderWithBackButton
title={translate('workspace.common.connectBankAccount')}
guidesCallTaskID={CONST.GUIDES_CALL_TASK_IDS.WORKSPACE_BANK_ACCOUNT}
onBackButtonPress={onBackButtonPress}
/>
<ScrollView style={[styles.flex1]}>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,6 @@ function BusinessInfo({onBackButtonPress}: BusinessInfoProps) {
shouldEnablePickerAvoiding={false}
shouldEnableMaxHeight
headerTitle={translate('businessInfoStep.businessInfo')}
guidesCallTaskID={CONST.GUIDES_CALL_TASK_IDS.WORKSPACE_BANK_ACCOUNT}
handleBackButtonPress={handleBackButtonPress}
startStepIndex={3}
stepNames={CONST.BANK_ACCOUNT.STEP_NAMES}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -182,9 +182,7 @@ function VerifiedBankAccountFlowEntryPoint({
<HeaderWithBackButton
title={translate('workspace.common.connectBankAccount')}
subtitle={policyName}
shouldShowGetAssistanceButton
onBackButtonPress={onBackButtonPress}
guidesCallTaskID={CONST.GUIDES_CALL_TASK_IDS.WORKSPACE_BANK_ACCOUNT}
/>

<ScrollView style={styles.flex1}>
Expand Down
1 change: 0 additions & 1 deletion src/pages/ReportParticipantsPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -398,7 +398,6 @@ function ReportParticipantsPage({report, route}: ReportParticipantsPageProps) {
Navigation.goBack(ROUTES.REPORT_WITH_ID_DETAILS.getRoute(report.reportID, backTo));
}
}}
guidesCallTaskID={CONST.GUIDES_CALL_TASK_IDS.WORKSPACE_MEMBERS}
subtitle={StringUtils.lineBreaksToSpaces(getReportName(report))}
/>
<View style={[styles.pl5, styles.pr5]}>{headerButtons}</View>
Expand Down
2 changes: 0 additions & 2 deletions src/pages/workspace/WorkspaceInviteMessagePage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -183,8 +183,6 @@ function WorkspaceInviteMessagePage({policy, route, currentUserPersonalDetails}:
<HeaderWithBackButton
title={translate('workspace.inviteMessage.confirmDetails')}
subtitle={policyName}
shouldShowGetAssistanceButton
guidesCallTaskID={CONST.GUIDES_CALL_TASK_IDS.WORKSPACE_MEMBERS}
shouldShowBackButton
onCloseButtonPress={() => Navigation.dismissModal()}
onBackButtonPress={() => Navigation.goBack(route.params.backTo)}
Expand Down
2 changes: 0 additions & 2 deletions src/pages/workspace/WorkspaceInvitePage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -313,8 +313,6 @@ function WorkspaceInvitePage({route, policy}: WorkspaceInvitePageProps) {
<HeaderWithBackButton
title={translate('workspace.invite.invitePeople')}
subtitle={policyName}
shouldShowGetAssistanceButton
guidesCallTaskID={CONST.GUIDES_CALL_TASK_IDS.WORKSPACE_MEMBERS}
onBackButtonPress={() => {
Policy.clearErrors(route.params.policyID);
Navigation.goBack();
Expand Down
1 change: 0 additions & 1 deletion src/pages/workspace/WorkspaceMembersPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -671,7 +671,6 @@ function WorkspaceMembersPage({personalDetails, route, policy, currentUserPerson
<WorkspacePageWithSections
headerText={selectionModeHeader ? translate('common.selectMultiple') : translate('workspace.common.members')}
route={route}
guidesCallTaskID={CONST.GUIDES_CALL_TASK_IDS.WORKSPACE_MEMBERS}
icon={!selectionModeHeader ? ReceiptWrangler : undefined}
headerContent={!shouldUseNarrowLayout && getHeaderButtons()}
testID={WorkspaceMembersPage.displayName}
Expand Down
1 change: 0 additions & 1 deletion src/pages/workspace/WorkspaceOverviewPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,6 @@ function WorkspaceOverviewPage({policyDraft, policy: policyProp, route}: Workspa
<WorkspacePageWithSections
headerText={translate('workspace.common.profile')}
route={route}
guidesCallTaskID={CONST.GUIDES_CALL_TASK_IDS.WORKSPACE_OVERVIEW}
// When we create a new workspaces, the policy prop will not be set on the first render. Therefore, we have to delay rendering until it has been set in Onyx.
shouldShowLoading={policy === undefined}
shouldUseScrollView
Expand Down
5 changes: 0 additions & 5 deletions src/pages/workspace/WorkspacePageWithSections.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,6 @@ type WorkspacePageWithSectionsProps = WithPolicyAndFullscreenLoadingProps &
/** Content to be added as fixed footer */
footer?: ReactNode;

/** The guides call task ID to associate with the workspace page being shown */
guidesCallTaskID: string;

/** The route where we navigate when the user press the back button */
backButtonRoute?: Route;

Expand Down Expand Up @@ -101,7 +98,6 @@ function WorkspacePageWithSections({
children = () => null,
footer = null,
icon = undefined,
guidesCallTaskID = '',
headerText,
policy,
policyDraft,
Expand Down Expand Up @@ -183,7 +179,6 @@ function WorkspacePageWithSections({
>
<HeaderWithBackButton
title={headerText}
guidesCallTaskID={guidesCallTaskID}
onBackButtonPress={() => (onBackButtonPress ? onBackButtonPress() : Navigation.goBack(backButtonRoute))}
shouldShowBackButton={shouldUseNarrowLayout || shouldShowBackButton}
icon={icon ?? undefined}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,6 @@ function WorkspaceCompanyCardPage({route}: WorkspaceCompanyCardPageProps) {
icon={Illustrations.CompanyCard}
headerText={translate('workspace.common.companyCards')}
route={route}
guidesCallTaskID={CONST.GUIDES_CALL_TASK_IDS.WORKSPACE_COMPANY_CARDS}
shouldShowOfflineIndicatorInWideScreen
includeSafeAreaPaddingBottom
showLoadingAsFirstRender={false}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,6 @@ function WorkspaceExpensifyCardPageEmptyState({route, policy}: WorkspaceExpensif
icon={Illustrations.HandCard}
headerText={translate('workspace.common.expensifyCard')}
route={route}
guidesCallTaskID={CONST.GUIDES_CALL_TASK_IDS.WORKSPACE_EXPENSIFY_CARD}
showLoadingAsFirstRender={false}
shouldShowOfflineIndicatorInWideScreen
>
Expand Down
1 change: 0 additions & 1 deletion src/pages/workspace/invoices/WorkspaceInvoicesPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ function WorkspaceInvoicesPage({route}: WorkspaceInvoicesPageProps) {
<WorkspacePageWithSections
shouldUseScrollView
headerText={translate('workspace.common.invoices')}
guidesCallTaskID={CONST.GUIDES_CALL_TASK_IDS.WORKSPACE_INVOICES}
shouldShowOfflineIndicatorInWideScreen
shouldSkipVBBACall={false}
route={route}
Expand Down
1 change: 0 additions & 1 deletion src/pages/workspace/rules/PolicyRulesPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ function PolicyRulesPage({route}: PolicyRulesPageProps) {
testID={PolicyRulesPage.displayName}
shouldUseScrollView
headerText={translate('workspace.common.rules')}
guidesCallTaskID={CONST.GUIDES_CALL_TASK_IDS.WORKSPACE_RULES}
shouldShowOfflineIndicatorInWideScreen
route={route}
icon={Illustrations.Rules}
Expand Down
1 change: 0 additions & 1 deletion src/pages/workspace/workflows/WorkspaceWorkflowsPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -357,7 +357,6 @@ function WorkspaceWorkflowsPage({policy, route}: WorkspaceWorkflowsPageProps) {
headerText={translate('workspace.common.workflows')}
icon={Workflows}
route={route}
guidesCallTaskID={CONST.GUIDES_CALL_TASK_IDS.WORKSPACE_WORKFLOWS}
shouldShowOfflineIndicatorInWideScreen
shouldShowNotFoundPage={!isPaidGroupPolicy || !isPolicyAdmin}
isLoading={isLoading}
Expand Down

0 comments on commit c5f180d

Please sign in to comment.