'use client' import type { ChatProps } from './index' import { createContext, useContext } from 'use-context-selector' export type ChatContextValue = Pick & { readonly?: boolean } export const ChatContext = createContext({ chatList: [], readonly: false, }) export const useChatContext = () => useContext(ChatContext) export default ChatContext