Skip to content

Commit

Permalink
fix: Extra spaces are not trimmed in the next page for the routing nu…
Browse files Browse the repository at this point in the history
…mber and Account number.

Signed-off-by: Krishna Gupta <[email protected]>
  • Loading branch information
Krishna2323 committed Jun 14, 2024
1 parent 2144fc6 commit 6056f3c
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion src/pages/ReimbursementAccount/BankInfo/substeps/Manual.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import Text from '@components/Text';
import TextInput from '@components/TextInput';
import useAutoFocusInput from '@hooks/useAutoFocusInput';
import useLocalize from '@hooks/useLocalize';
import useReimbursementAccountStepFormSubmit from '@hooks/useReimbursementAccountStepFormSubmit';
import type {SubStepProps} from '@hooks/useSubStep/types';
import useThemeStyles from '@hooks/useThemeStyles';
import * as ValidationUtils from '@libs/ValidationUtils';
Expand Down Expand Up @@ -59,10 +60,16 @@ function Manual({reimbursementAccount, onNext}: ManualProps) {

const shouldDisableInputs = !!(reimbursementAccount?.achData?.bankAccountID ?? '');

const handleSubmit = useReimbursementAccountStepFormSubmit({
fieldIds: STEP_FIELDS,
onNext,
shouldSaveDraft: true,
});

return (
<FormProvider
formID={ONYXKEYS.FORMS.REIMBURSEMENT_ACCOUNT_FORM}
onSubmit={onNext}
onSubmit={handleSubmit}
validate={validate}
submitButtonText={translate('common.next')}
style={[styles.mh5, styles.flexGrow1]}
Expand Down

0 comments on commit 6056f3c

Please sign in to comment.