-
Notifications
You must be signed in to change notification settings - Fork 3.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
bd3e4f4
commit 43eb00d
Showing
5 changed files
with
30 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import CONST from '../../CONST'; | ||
import GetReturnKeyType from './types'; | ||
|
||
/** | ||
* Return returnKeyType passed as function parameter on Android | ||
* Due to the fact that in the Android browser some keyboardTypes change the confirmation icon and ignore keyboardType, the ability to change the confirmation icon in the Android app to the one used in the browser has been added | ||
*/ | ||
const getReturnKeyType: GetReturnKeyType = (returnKeyType, keyboardType) => { | ||
if (keyboardType === CONST.KEYBOARD_TYPE.URL || keyboardType === CONST.KEYBOARD_TYPE.EMAIL_ADDRESS) { | ||
return 'go'; | ||
} | ||
|
||
return returnKeyType; | ||
}; | ||
|
||
export default getReturnKeyType; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
import GetReturnKeyType from './types'; | ||
|
||
/** | ||
* Return returnKeyType passed as function parameter on Web/Desktop/iOS | ||
*/ | ||
const getReturnKeyType: GetReturnKeyType = (returnKeyType) => returnKeyType; | ||
|
||
export default getReturnKeyType; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
type GetReturnKeyType = (returnKeyType: string, keyboardType: string) => string; | ||
|
||
export default GetReturnKeyType; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters