p-stream/src/stores/interface/overlayStack.ts
2025-06-05 12:10:30 -06:00

13 lines
378 B
TypeScript

import { create } from "zustand";
type OverlayType = "volume" | "subtitle" | "speed" | null;
interface OverlayStackStore {
currentOverlay: OverlayType;
setCurrentOverlay: (overlay: OverlayType) => void;
}
export const useOverlayStack = create<OverlayStackStore>((set) => ({
currentOverlay: null,
setCurrentOverlay: (overlay) => set({ currentOverlay: overlay }),
}));