mirror of
https://github.com/danny-avila/LibreChat.git
synced 2026-02-13 13:04:24 +01:00
fix static flag bug
This commit is contained in:
parent
92b2109dc3
commit
779f142058
4 changed files with 50 additions and 39 deletions
17
src/App.jsx
17
src/App.jsx
|
|
@ -1,14 +1,17 @@
|
|||
import React from 'react';
|
||||
import Messages from './components/main/Messages';
|
||||
import Landing from './components/main/Landing';
|
||||
import TextChat from './components/main/TextChat';
|
||||
import Nav from './components/Nav';
|
||||
import MobileNav from './components/Nav/MobileNav';
|
||||
import useDocumentTitle from '~/hooks/useDocumentTitle';
|
||||
import { useSelector } from 'react-redux';
|
||||
|
||||
const App = () => {
|
||||
|
||||
const { messages } = useSelector((state) => state.messages);
|
||||
const convo = useSelector((state) => state.convo);
|
||||
const { title } = useSelector((state) => state.convo);
|
||||
|
||||
useDocumentTitle(title);
|
||||
|
||||
return (
|
||||
<div className="flex h-screen">
|
||||
|
|
@ -16,8 +19,14 @@ const App = () => {
|
|||
<div className="flex h-full w-full flex-1 flex-col bg-gray-50 md:pl-[260px]">
|
||||
<div className="transition-width relative flex h-full w-full flex-1 flex-col items-stretch overflow-hidden dark:bg-gray-800">
|
||||
<MobileNav />
|
||||
<Messages messages={messages} title={convo.title}/>
|
||||
<TextChat messages={messages}/>
|
||||
{messages.length === 0 ? (
|
||||
<Landing title={title} />
|
||||
) : (
|
||||
<Messages
|
||||
messages={messages}
|
||||
/>
|
||||
)}
|
||||
<TextChat messages={messages} />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue