feat: add toggle for showing draft starters on new sessions
Persists draft starter visibility across desktop and web settings Adds a new OpenChamber visual setting with localization and search support Hides the draft starter chips when the setting is off
This commit is contained in:
@@ -591,6 +591,7 @@ interface UIStore {
|
||||
fontSize: number;
|
||||
// Global draft welcome starters; null = unset (use the default built-in set).
|
||||
globalDraftStarters: DraftStarterRef[] | null;
|
||||
draftStartersVisible: boolean;
|
||||
terminalFontSize: number;
|
||||
terminalShell: TerminalShell;
|
||||
terminalLoginShells: TerminalShell[];
|
||||
@@ -751,6 +752,7 @@ interface UIStore {
|
||||
setMessageLimit: (value: number) => void;
|
||||
setFontSize: (size: number) => void;
|
||||
setGlobalDraftStarters: (refs: DraftStarterRef[]) => void;
|
||||
setDraftStartersVisible: (value: boolean) => void;
|
||||
setTerminalFontSize: (size: number) => void;
|
||||
setTerminalShell: (shell: TerminalShell) => void;
|
||||
setTerminalLoginShells: (shells: TerminalShell[]) => void;
|
||||
@@ -978,6 +980,7 @@ export const useUIStore = create<UIStore>()(
|
||||
expandedEditorToolbar: false,
|
||||
showSplitAssistantMessageActions: false,
|
||||
allowPromptingSubagentSessions: false,
|
||||
draftStartersVisible: true,
|
||||
isMobileSessionStatusBarCollapsed: false,
|
||||
mobileSessionPanelOpen: false,
|
||||
mobileSessionFilterProjectId: null,
|
||||
@@ -1675,6 +1678,10 @@ export const useUIStore = create<UIStore>()(
|
||||
set({ globalDraftStarters: refs });
|
||||
},
|
||||
|
||||
setDraftStartersVisible: (value) => {
|
||||
set({ draftStartersVisible: value });
|
||||
},
|
||||
|
||||
setTerminalFontSize: (size) => {
|
||||
const rounded = Math.round(size);
|
||||
const clamped = Math.max(9, Math.min(52, rounded));
|
||||
@@ -2420,6 +2427,7 @@ export const useUIStore = create<UIStore>()(
|
||||
expandedEditorToolbar: state.expandedEditorToolbar,
|
||||
showSplitAssistantMessageActions: state.showSplitAssistantMessageActions,
|
||||
allowPromptingSubagentSessions: state.allowPromptingSubagentSessions,
|
||||
draftStartersVisible: state.draftStartersVisible,
|
||||
isMobileSessionStatusBarCollapsed: state.isMobileSessionStatusBarCollapsed,
|
||||
mobileSessionFilterProjectId: state.mobileSessionFilterProjectId,
|
||||
shortcutOverrides: state.shortcutOverrides,
|
||||
|
||||
Reference in New Issue
Block a user