change color textarea to white and hide history chat after chat
This commit is contained in:
parent
4b85b6ee39
commit
8e8a1d3e6b
3 changed files with 10 additions and 3 deletions
|
|
@ -31,7 +31,7 @@
|
|||
gap: 40px;
|
||||
textarea {
|
||||
font-size: 14px;
|
||||
color: #606060;
|
||||
color: white;
|
||||
width: 100%;
|
||||
border: none;
|
||||
outline: none;
|
||||
|
|
|
|||
|
|
@ -24,6 +24,7 @@ import AppUnavailable from '@/components/app-unavailable';
|
|||
import { API_KEY, APP_ID, APP_INFO, isShowPrompt, promptTemplate } from '@/config';
|
||||
import type { Annotation as AnnotationType } from '@/types/log';
|
||||
import { addFileInfos, sortAgentSorts } from '@/utils/tools';
|
||||
import { useAuthStore } from '@/stores/useAuthStore';
|
||||
|
||||
export type IMainProps = {
|
||||
params: any;
|
||||
|
|
@ -34,6 +35,7 @@ import HistoryChat from '@/components/layouts/history-chat/history-chat';
|
|||
import Chat from '@/components/layouts/chat/chat';
|
||||
|
||||
const Main: FC = () => {
|
||||
const { hideHistoryChat, setHideHistoryCHat } = useAuthStore();
|
||||
const { t } = useTranslation();
|
||||
const media = useBreakpoints();
|
||||
const isMobile = media === MediaType.mobile;
|
||||
|
|
@ -654,6 +656,7 @@ const Main: FC = () => {
|
|||
}
|
||||
});
|
||||
getHistoryChat(currConversationId);
|
||||
setHideHistoryCHat(true);
|
||||
};
|
||||
|
||||
const handleFeedback = async (messageId: string, feedback: Feedbacktype) => {
|
||||
|
|
@ -694,7 +697,7 @@ const Main: FC = () => {
|
|||
checkCanSend={checkCanSend}
|
||||
visionConfig={visionConfig}
|
||||
/>
|
||||
<HistoryChat data={historyChatList} />
|
||||
{!hideHistoryChat && <HistoryChat data={historyChatList} />}
|
||||
</main>
|
||||
</>
|
||||
);
|
||||
|
|
|
|||
|
|
@ -2,10 +2,14 @@ import { create } from 'zustand';
|
|||
|
||||
interface State {
|
||||
isLogin: boolean;
|
||||
hideHistoryChat: boolean;
|
||||
setLogin: (val: boolean) => void;
|
||||
setHideHistoryCHat: (val: boolean) => void;
|
||||
}
|
||||
|
||||
export const useAuthStore = create<State>((set) => ({
|
||||
isLogin: false,
|
||||
setLogin: (val) => set({ isLogin: val })
|
||||
hideHistoryChat: false,
|
||||
setLogin: (val) => set({ isLogin: val }),
|
||||
setHideHistoryCHat: (val) => set({ hideHistoryChat: val })
|
||||
}));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue