BOD-14 Cleanup and re-org of some components for messaging.
This commit is contained in:
@@ -1,18 +1,9 @@
|
||||
import { useSubscription } from "@apollo/react-hooks";
|
||||
import React from "react";
|
||||
import { connect } from "react-redux";
|
||||
import { createStructuredSelector } from "reselect";
|
||||
import { MESSAGES_SUBSCRIPTION } from "../../graphql/messages.queries";
|
||||
import ChatConversationComponent from "./chat-conversation.component";
|
||||
|
||||
const mapStateToProps = createStructuredSelector({
|
||||
//currentUser: selectCurrentUser
|
||||
});
|
||||
const mapDispatchToProps = dispatch => ({
|
||||
//setUserLanguage: language => dispatch(setUserLanguage(language))
|
||||
});
|
||||
|
||||
export function ChatConversationContainer({ conversation }) {
|
||||
export default function ChatConversationContainer({ conversation }) {
|
||||
const { loading, error, data } = useSubscription(MESSAGES_SUBSCRIPTION, {
|
||||
variables: { conversationId: conversation.id }
|
||||
});
|
||||
@@ -26,7 +17,3 @@ export function ChatConversationContainer({ conversation }) {
|
||||
);
|
||||
}
|
||||
|
||||
export default connect(
|
||||
mapStateToProps,
|
||||
mapDispatchToProps
|
||||
)(ChatConversationContainer);
|
||||
|
||||
Reference in New Issue
Block a user