diff --git a/src/components/TextLink.js b/src/components/TextLink.js
index c7df1ce6cd597..17e73e02c8192 100644
--- a/src/components/TextLink.js
+++ b/src/components/TextLink.js
@@ -22,20 +22,24 @@ const propTypes = {
/** Overwrites the default link behavior with a custom callback */
onPress: PropTypes.func,
+
+ /** Callback that is called when mousedown is triggered */
+ onMouseDown: PropTypes.func,
};
const defaultProps = {
href: undefined,
style: [],
onPress: undefined,
+ onMouseDown: undefined,
};
const TextLink = (props) => {
const additionalStyles = _.isArray(props.style) ? props.style : [props.style];
/**
- * @param {Event} event
- */
+ * @param {Event} event
+ */
const openLink = (event) => {
event.preventDefault();
if (props.onPress) {
@@ -47,8 +51,8 @@ const TextLink = (props) => {
};
/**
- * @param {Event} event
- */
+ * @param {Event} event
+ */
const openLinkIfEnterKeyPressed = (event) => {
if (event.key !== 'Enter') {
return;
@@ -62,6 +66,7 @@ const TextLink = (props) => {
accessibilityRole="link"
href={props.href}
onPress={openLink}
+ onMouseDown={props.onMouseDown}
onKeyDown={openLinkIfEnterKeyPressed}
>
{props.children}
diff --git a/src/pages/ReimbursementAccount/BankAccountManualStep.js b/src/pages/ReimbursementAccount/BankAccountManualStep.js
index c42b0f7186f4f..45c73b109b334 100644
--- a/src/pages/ReimbursementAccount/BankAccountManualStep.js
+++ b/src/pages/ReimbursementAccount/BankAccountManualStep.js
@@ -119,7 +119,12 @@ class BankAccountManualStep extends React.Component {
{this.props.translate('common.iAcceptThe')}
-
+ e.preventDefault()}
+ >
{`Expensify ${this.props.translate('common.termsOfService')}`}