Closed Raphaelinyang closed 3 years ago
@Raphaelinyang did u solved this problem ? i m also facing same issue .
hi @Raphaelinyang
Issue Description
All messages align to the right, please check the image below for more details
Steps to Reproduce / Code Snippets
<GiftedChat messages={messages.slice()} onSend={ handleSend} user={{id: user.uid, name: user.displayName, avatar: user.photoURL,}} renderBubble={renderBubble} placeholder='Type your message here...' isTyping= {true} renderSend={renderSend} alwaysShowSend loadEarlier={true} showAvatarForEveryMessage={true} scrollToBottom scrollToBottomComponent={scrollToBottomComponent} renderSystemMessage={renderSystemMessage} alignTop={true} renderLoading={renderLoading} />
Expected Results
expect foreign messages to appear at the left, while the current user's message appears on the right
Additional Information
- Nodejs version: latest version
- React Native version: latest version
- react-native-gifted-chat version: latest version
- Platform(s) (iOS, Android, or both?): Android
you should maintain your chat data like this {_id:(userID) text:(chat messages) createdAt: formatted time user: { _id: senderID/receiver id name: sender/receiver name } } may be this will help you ..
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Issue Description
All messages align to the right, please check the image below for more details
Steps to Reproduce / Code Snippets
<GiftedChat messages={messages.slice()} onSend={ handleSend} user={{id: user.uid, name: user.displayName, avatar: user.photoURL,}} renderBubble={renderBubble} placeholder='Type your message here...' isTyping= {true} renderSend={renderSend} alwaysShowSend loadEarlier={true} showAvatarForEveryMessage={true} scrollToBottom scrollToBottomComponent={scrollToBottomComponent} renderSystemMessage={renderSystemMessage} alignTop={true} renderLoading={renderLoading} />
Expected Results
expect foreign messages to appear at the left, while the current user's message appears on the right
Additional Information