2022-04-28 18:54:33 +02:00
|
|
|
import Sider from 'antd/lib/layout/Sider';
|
|
|
|
import { useRecoilValue } from 'recoil';
|
2022-04-28 14:36:05 -07:00
|
|
|
import { ChatMessage } from '../../../interfaces/chat-message.model';
|
|
|
|
import ChatContainer from '../../chat/ChatContainer';
|
|
|
|
import { chatMessages } from '../../stores/ClientConfigStore';
|
2022-04-28 18:54:33 +02:00
|
|
|
|
|
|
|
export default function Sidebar() {
|
2022-04-28 14:36:05 -07:00
|
|
|
const messages = useRecoilValue<ChatMessage[]>(chatMessages);
|
|
|
|
|
2022-04-28 18:54:33 +02:00
|
|
|
return (
|
|
|
|
<Sider
|
2022-04-28 14:36:05 -07:00
|
|
|
collapsed={false}
|
2022-04-28 18:54:33 +02:00
|
|
|
width={300}
|
|
|
|
style={{
|
|
|
|
position: 'fixed',
|
|
|
|
right: 0,
|
|
|
|
top: 0,
|
|
|
|
bottom: 0,
|
|
|
|
}}
|
2022-04-28 14:36:05 -07:00
|
|
|
>
|
|
|
|
<ChatContainer messages={messages} />
|
|
|
|
</Sider>
|
2022-04-28 18:54:33 +02:00
|
|
|
);
|
|
|
|
}
|