UNPKG

@lobehub/chat

Version:

Lobe Chat - an open-source, high-performance chatbot framework that supports speech synthesis, multimodal, and extensible Function Call plugin system. Supports one-click free deployment of your private ChatGPT/LLM web application.

17 lines (12 loc) 458 B
import { ElectronState } from '@/store/electron/initialState'; const userPath = (s: ElectronState) => s.appState.userPath; const userHomePath = (s: ElectronState) => userPath(s)?.home || ''; const displayRelativePath = (path: string) => (s: ElectronState) => { const basePath = userHomePath(s); return !!basePath ? path.replaceAll(basePath, '~') : path; }; export const desktopStateSelectors = { displayRelativePath, userHomePath, userPath, };