Skip to content

Commit

Permalink
Merge pull request #36472 from MrMuzyk/fix/followup-fixes-for-vbba-re…
Browse files Browse the repository at this point in the history
…factor

[CP Staging] fix: followup fixes for vbba refactor

(cherry picked from commit 4021904)
  • Loading branch information
mountiny authored and OSBotify committed Feb 14, 2024
1 parent 7550cf3 commit cf005ea
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/components/InteractiveStepSubHeader.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ function InteractiveStepSubHeader({stepNames, startStepIndex = 0, onStepSelected
isLockedStep && styles.interactiveStepHeaderLockedStepButton,
isCompletedStep && styles.interactiveStepHeaderCompletedStepButton,
]}
disabled={isLockedStep}
disabled={isLockedStep || !onStepSelected}
onPress={moveToStep}
accessible
accessibilityLabel={stepName[index]}
Expand Down
3 changes: 3 additions & 0 deletions src/pages/ReimbursementAccount/BankInfo/substeps/Manual.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import FormProvider from '@components/Form/FormProvider';
import InputWrapper from '@components/Form/InputWrapper';
import Text from '@components/Text';
import TextInput from '@components/TextInput';
import useAutoFocusInput from '@hooks/useAutoFocusInput';
import useLocalize from '@hooks/useLocalize';
import type {SubStepProps} from '@hooks/useSubStep/types';
import useThemeStyles from '@hooks/useThemeStyles';
Expand All @@ -30,6 +31,7 @@ const STEP_FIELDS = [BANK_INFO_STEP_KEYS.ROUTING_NUMBER, BANK_INFO_STEP_KEYS.ACC
function Manual({reimbursementAccount, onNext}: ManualProps) {
const {translate} = useLocalize();
const styles = useThemeStyles();
const {inputCallbackRef} = useAutoFocusInput();

const defaultValues: FormValues = {
[BANK_INFO_STEP_KEYS.ROUTING_NUMBER]: reimbursementAccount?.achData?.[BANK_INFO_STEP_KEYS.ROUTING_NUMBER] ?? '',
Expand Down Expand Up @@ -78,6 +80,7 @@ function Manual({reimbursementAccount, onNext}: ManualProps) {
<ExampleCheckImage />
<InputWrapper
InputComponent={TextInput}
ref={inputCallbackRef}
inputID={BANK_INFO_STEP_KEYS.ROUTING_NUMBER}
label={translate('bankAccount.routingNumber')}
aria-label={translate('bankAccount.routingNumber')}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,6 @@ function VerifyIdentity({reimbursementAccount, onBackButtonPress, onfidoApplican
/>
<View style={[styles.ph5, styles.mt3, {height: CONST.BANK_ACCOUNT.STEPS_HEADER_HEIGHT}]}>
<InteractiveStepSubHeader
onStepSelected={() => {}}
startStepIndex={2}
stepNames={CONST.BANK_ACCOUNT.STEP_NAMES}
/>
Expand Down

0 comments on commit cf005ea

Please sign in to comment.