mirror of
https://github.com/prowler-cloud/prowler.git
synced 2026-07-24 21:11:53 +00:00
17 lines
607 B
TypeScript
17 lines
607 B
TypeScript
import { create } from "zustand";
|
|
|
|
interface ScansStoreState {
|
|
isLaunchScanModalOpen: boolean;
|
|
setLaunchScanModalOpen: (open: boolean) => void;
|
|
openLaunchScanModal: () => void;
|
|
closeLaunchScanModal: () => void;
|
|
}
|
|
|
|
// Modal state is ephemeral; intentionally not persisted across reloads.
|
|
export const useScansStore = create<ScansStoreState>((set) => ({
|
|
isLaunchScanModalOpen: false,
|
|
setLaunchScanModalOpen: (open) => set({ isLaunchScanModalOpen: open }),
|
|
openLaunchScanModal: () => set({ isLaunchScanModalOpen: true }),
|
|
closeLaunchScanModal: () => set({ isLaunchScanModalOpen: false }),
|
|
}));
|