SurfSense/surfsense_web/atoms/chats/ui.atoms.ts

18 lines
423 B
TypeScript
Raw Normal View History

2025-11-15 02:07:20 +02:00
import { atom } from "jotai";
2025-11-18 22:12:47 +02:00
import type { GetChatsRequest } from "@/contracts/types/chat.types";
2025-11-15 02:07:20 +02:00
type ActiveChathatUIState = {
isChatPannelOpen: boolean;
};
export const activeChathatUIAtom = atom<ActiveChathatUIState>({
isChatPannelOpen: false,
});
2025-11-18 22:12:47 +02:00
2025-11-18 18:57:41 +02:00
export const activeChatIdAtom = atom<string | null>(null);
2025-11-18 22:12:47 +02:00
export const globalChatsQueryParamsAtom = atom<GetChatsRequest["queryParams"]>({
limit: 5,
skip: 0,
});