diff --git a/app/(app)/comms/comms-client.tsx b/app/(app)/comms/comms-client.tsx index a090d17..f57d184 100644 --- a/app/(app)/comms/comms-client.tsx +++ b/app/(app)/comms/comms-client.tsx @@ -2,7 +2,7 @@ import { useState, useEffect, useRef } from 'react' import { createClient } from '@/lib/supabase/client' -import { Hash, Users2, Send } from 'lucide-react' +import { Hash, Users2, Send, ChevronLeft } from 'lucide-react' interface Props { member: any @@ -15,6 +15,7 @@ export default function CommsClient({ member, space, channels }: Props) { const [messages, setMessages] = useState([]) const [newMessage, setNewMessage] = useState('') const [sending, setSending] = useState(false) + const [showChannelList, setShowChannelList] = useState(true) const messagesEndRef = useRef(null) useEffect(() => { @@ -140,26 +141,32 @@ export default function CommsClient({ member, space, channels }: Props) { const projectChannels = channels.filter(c => c.channel_type === 'project') return ( -
-
+
+
-

Comms

+ {/* Mobile back to channels */} + {!showChannelList && selectedChannel && ( + + )} +

+ {!showChannelList && selectedChannel ? `#${selectedChannel.name}` : 'Comms'} +

-
- {/* Channels sidebar */} -