feat: add configurable web native notifications for assistant completion (#123)
This commit is contained in:
@@ -53,6 +53,7 @@ interface UIStore {
|
||||
diffFileLayout: Record<string, 'inline' | 'side-by-side'>;
|
||||
diffWrapLines: boolean;
|
||||
isTimelineDialogOpen: boolean;
|
||||
nativeNotificationsEnabled: boolean;
|
||||
|
||||
setTheme: (theme: 'light' | 'dark' | 'system') => void;
|
||||
toggleSidebar: () => void;
|
||||
@@ -95,6 +96,7 @@ interface UIStore {
|
||||
setDiffWrapLines: (wrap: boolean) => void;
|
||||
setMultiRunLauncherOpen: (open: boolean) => void;
|
||||
setTimelineDialogOpen: (open: boolean) => void;
|
||||
setNativeNotificationsEnabled: (value: boolean) => void;
|
||||
openMultiRunLauncher: () => void;
|
||||
openMultiRunLauncherWithPrompt: (prompt: string) => void;
|
||||
}
|
||||
@@ -138,6 +140,7 @@ export const useUIStore = create<UIStore>()(
|
||||
diffFileLayout: {},
|
||||
diffWrapLines: false,
|
||||
isTimelineDialogOpen: false,
|
||||
nativeNotificationsEnabled: false,
|
||||
|
||||
setTheme: (theme) => {
|
||||
set({ theme });
|
||||
@@ -465,6 +468,10 @@ export const useUIStore = create<UIStore>()(
|
||||
setTimelineDialogOpen: (open) => {
|
||||
set({ isTimelineDialogOpen: open });
|
||||
},
|
||||
|
||||
setNativeNotificationsEnabled: (value) => {
|
||||
set({ nativeNotificationsEnabled: value });
|
||||
},
|
||||
}),
|
||||
{
|
||||
name: 'ui-store',
|
||||
@@ -489,6 +496,7 @@ export const useUIStore = create<UIStore>()(
|
||||
recentModels: state.recentModels,
|
||||
diffLayoutPreference: state.diffLayoutPreference,
|
||||
diffWrapLines: state.diffWrapLines,
|
||||
nativeNotificationsEnabled: state.nativeNotificationsEnabled,
|
||||
})
|
||||
}
|
||||
),
|
||||
|
||||
Reference in New Issue
Block a user