import { useMemory } from "../providers/MemoryProvider/useMemory";

export enum ViewPanelsState {
    DIALOGS_PANEL_HIDE,
    DIALOGS_PANEL_SHOW,
    DIALOGS_PANEL_ONLY,
    DIALOGS_PANEL_HIDE_VIEW_RIGHT_PANEL
}

export function useViewPanelsState() : [ViewPanelsState, (state: ViewPanelsState) => void] {
    const [viewState, setViewState] = useMemory<ViewPanelsState>('view_panels_state', ViewPanelsState.DIALOGS_PANEL_SHOW, true);
    return [viewState, setViewState];
}