Skip to content

Commit

Permalink
Merge pull request #23864 from vipin87/fix/23369
Browse files Browse the repository at this point in the history
  • Loading branch information
francoisl authored Aug 7, 2023
2 parents 0dcb699 + 5671c62 commit 2ce4328
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 1 deletion.
6 changes: 6 additions & 0 deletions src/components/Onfido/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -47,3 +47,9 @@
height: 92% !important;
}
}

.onfido-sdk-ui-NavigationBar-back {
/* This keeps onfido back button hidden since there is already a back button in the top header which
programatically clicks onfido button. */
visibility: hidden;
}
12 changes: 11 additions & 1 deletion src/pages/ReimbursementAccount/RequestorOnfidoStep.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,16 @@ class RequestorOnfidoStep extends React.Component {
constructor(props) {
super(props);
this.submit = this.submit.bind(this);
this.goBack = this.goBack.bind(this);
}

goBack() {
const onfidoBack = document.querySelector('.onfido-sdk-ui-NavigationBar-back');
if (onfidoBack && !onfidoBack.classList.contains('onfido-sdk-ui-NavigationBar-disabled')) {
onfidoBack.click();
} else {
this.props.onBackButtonPress();
}
}

submit(onfidoData) {
Expand All @@ -50,7 +60,7 @@ class RequestorOnfidoStep extends React.Component {
stepCounter={{step: 3, total: 5}}
shouldShowGetAssistanceButton
guidesCallTaskID={CONST.GUIDES_CALL_TASK_IDS.WORKSPACE_BANK_ACCOUNT}
onBackButtonPress={this.props.onBackButtonPress}
onBackButtonPress={this.goBack}
/>
<FullPageOfflineBlockingView>
<ScrollView contentContainerStyle={styles.flex1}>
Expand Down

0 comments on commit 2ce4328

Please sign in to comment.