Skip to content

Commit

Permalink
Merge pull request #29723 from Krishna2323/krishna2323/issue/27543
Browse files Browse the repository at this point in the history
fix: Android - Keyboard stays open when getting back to amount input page.
  • Loading branch information
Beamanator committed Oct 18, 2023
2 parents 9664f8c + 1e937f2 commit 9d79fd1
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/pages/iou/IOUCurrencySelection.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import React, {useState, useMemo, useCallback, useRef} from 'react';
import {Keyboard} from 'react-native';
import PropTypes from 'prop-types';
import {withOnyx} from 'react-native-onyx';
import _ from 'underscore';
Expand Down Expand Up @@ -78,6 +79,8 @@ function IOUCurrencySelection(props) {
const confirmCurrencySelection = useCallback(
(option) => {
const backTo = lodashGet(props.route, 'params.backTo', '');
Keyboard.dismiss();

// When we refresh the web, the money request route gets cleared from the navigation stack.
// Navigating to "backTo" will result in forward navigation instead, causing disruption to the currency selection.
// To prevent any negative experience, we have made the decision to simply close the currency selection page.
Expand Down

0 comments on commit 9d79fd1

Please sign in to comment.