feature/IO-3000-messaging-sockets-migrations2 -
- testing and edge cases Signed-off-by: Dave Richer <dave@imexsystems.ca>
This commit is contained in:
@@ -19,12 +19,7 @@ const mapDispatchToProps = (dispatch) => ({
|
||||
setSelectedConversation: (conversationId) => dispatch(setSelectedConversation(conversationId))
|
||||
});
|
||||
|
||||
function ChatConversationListComponent({
|
||||
conversationList,
|
||||
selectedConversation,
|
||||
setSelectedConversation,
|
||||
loadMoreConversations
|
||||
}) {
|
||||
function ChatConversationListComponent({ conversationList, selectedConversation, setSelectedConversation }) {
|
||||
const renderConversation = (index) => {
|
||||
const item = conversationList[index];
|
||||
const cardContentRight = <TimeAgoFormatter>{item.updated_at}</TimeAgoFormatter>;
|
||||
@@ -69,13 +64,15 @@ function ChatConversationListComponent({
|
||||
);
|
||||
};
|
||||
|
||||
// TODO: Can go back into virtuoso for additional fetch
|
||||
// endReached={loadMoreConversations} // Calls loadMoreConversations when scrolled to the bottom
|
||||
|
||||
return (
|
||||
<div className="chat-list-container">
|
||||
<Virtuoso
|
||||
data={conversationList}
|
||||
itemContent={(index) => renderConversation(index)}
|
||||
style={{ height: "100%", width: "100%" }}
|
||||
endReached={loadMoreConversations} // Calls loadMoreConversations when scrolled to the bottom
|
||||
/>
|
||||
</div>
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user