Skip to content

Commit

Permalink
fixup! feat(#141): [wip] render direct message room
Browse files Browse the repository at this point in the history
  • Loading branch information
jeremyckahn committed Dec 2, 2024
1 parent 6b587e1 commit bc65e30
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/components/Room/Room.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ export function Room({
const { showActiveTypingStatus, publicKey } =
settingsContext.getUserSettings()
const {
isDirectMessageRoom,
isMessageSending,
handleInlineMediaUpload,
handleMessageChange,
Expand Down Expand Up @@ -78,8 +79,6 @@ export function Room({
}
)

const isDirectMessageRoom = typeof targetPeerId === 'string'

const handleMessageSubmit = async (message: string) => {
await sendMessage(message)
}
Expand Down Expand Up @@ -167,7 +166,7 @@ export function Room({
<ChatTranscript
messageLog={messageLog}
userId={userId}
sx={{ pt: 1 }}
sx={{ ...(isDirectMessageRoom && { pt: 1 }) }}
/>
<Divider />
<Box>
Expand Down
1 change: 1 addition & 0 deletions src/components/Room/useRoom.ts
Original file line number Diff line number Diff line change
Expand Up @@ -538,6 +538,7 @@ export function useRoom(
}, [peerList, peerRoom, setPeerConnectionTypes])

return {
isDirectMessageRoom,
isPrivate,
handleInlineMediaUpload,
handleMessageChange,
Expand Down

0 comments on commit bc65e30

Please sign in to comment.