From 099bc9e054da4ad143661987fde95958233e41a2 Mon Sep 17 00:00:00 2001 From: daniel31x13 Date: Tue, 30 Jul 2024 23:23:58 -0400 Subject: [PATCH] remove old code --- store/modals.ts | 64 ------------------------------------------------- 1 file changed, 64 deletions(-) delete mode 100644 store/modals.ts diff --git a/store/modals.ts b/store/modals.ts deleted file mode 100644 index f709d70f..00000000 --- a/store/modals.ts +++ /dev/null @@ -1,64 +0,0 @@ -import { - CollectionIncludingMembersAndLinkCount, - LinkIncludingShortenedCollectionAndTags, -} from "@/types/global"; -import { create } from "zustand"; - -type Modal = - | { - modal: "LINK"; - state: boolean; - method: "CREATE"; - active?: LinkIncludingShortenedCollectionAndTags; - } - | { - modal: "LINK"; - state: boolean; - method: "UPDATE"; - active: LinkIncludingShortenedCollectionAndTags; - } - | { - modal: "LINK"; - state: boolean; - method: "FORMATS"; - active: LinkIncludingShortenedCollectionAndTags; - } - | { - modal: "COLLECTION"; - state: boolean; - method: "UPDATE"; - isOwner: boolean; - active: CollectionIncludingMembersAndLinkCount; - defaultIndex?: number; - } - | { - modal: "COLLECTION"; - state: boolean; - method: "CREATE"; - isOwner?: boolean; - active?: CollectionIncludingMembersAndLinkCount; - defaultIndex?: number; - } - | { - modal: "COLLECTION"; - state: boolean; - method: "VIEW_TEAM"; - isOwner?: boolean; - active?: CollectionIncludingMembersAndLinkCount; - defaultIndex?: number; - } - | null; - -type ModalsStore = { - modal: Modal; - setModal: (modal: Modal) => void; -}; - -const useModalStore = create((set) => ({ - modal: null, - setModal: (modal: Modal) => { - set({ modal }); - }, -})); - -export default useModalStore;