InputToolBar spacing on iPhoneX
See original GitHub issueIssue Description
There is an issue with iPhoneX where you either have the message that you are typing overlap with the bottom bar and can’t see all of your text, or if you add a marginBottom you overlap with the avatar from the most recent message.
Here is some text entered into the text box:
If you add one more character you get this strange artifact:
If you style the input toolbar then it overlaps the Initials Avatar of the last message:
Steps to Reproduce / Code Snippets
Default inputToolbar code:
renderInputToolbar(props) {
return <InputToolbar {...props} containerStyle={styles.inputToolbarStyle} />;
}
Here is the styling:
inputToolbarStyle: {
marginLeft: 15,
marginRight: 15,
marginBottom: 10,
borderWidth: StyleSheet.hairlineWidth,
borderColor: CommonStyles.colors.middleGrey,
borderRadius: 25
},
Expected Results
Should be able to add some padding below the avatar or at least line up the bottom of the avatar with the bottom of the last message
Additional Information
- Nodejs version: 9.3.0
- React version: 16.3.1
- React Native version: Expo version 27
- react-native-gifted-chat version: 0.4.3
- Platform(s) (iOS, Android, or both?): Both
Issue Analytics
- State:
- Created 5 years ago
- Reactions:1
- Comments:10
Top Results From Across the Web
jsqmessagesviewcontroller inputToolBar IOS 11 iphone X Swift4
I'm currently working on the solution I gave in that answer, as it did not solve all problems, and the new approach possibly...
Read more >Toolbars - Menus and actions - Human Interface Guidelines
A toolbar automatically adopts translucency when placed above a scroll view or when the window is configured as a full-size content view.
Read more >jsqmessagesviewcontroller inputToolBar IOS 11 iphone X ...
Open JSQMessagesViewController.xib; Click File Inspector and choose "Use safe area layout guides"; Change deployment target of JSQMessagesViewController to 9.0 ...
Read more >Apple - Preowned iPhone X 64GB (Unlocked) - Space Gray
Shop Apple Preowned iPhone X 64GB (Unlocked) Space Gray at Best Buy. Find low everyday prices and buy online for delivery or in-store...
Read more >iPhone X Owners Complain About Keyboard's 'Wasted Space'
The iOS keyboard on iPhone X. On the new keyboard, the Globe or Emoji icon and the Dictation icon both sit below the...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@ewal and what to do when you have it inside of
SafeAreaView
? it created some nasty bottom spacing when the keyboard is open 😦OK, i found out you can use
bottomOffset
and offset the chat by the height of bottom safeArea… nice 😃@msqar
Solved it by setting
bottomOffset
andreact-native-iphone-x-helper.getBottomSpace
like this: