import { create } from 'zustand';
import { devtools } from 'zustand/middleware';
export const useCatalogStore = create()(devtools((set) => ({
    currentApiCatalogId: '',
    setCurrentApiCatalogId: (apiCatalogId) => {
        sessionStorage.setItem('current-api-catalog-id', apiCatalogId);
        set((state) => ({ currentApiCatalogId: apiCatalogId }));
    },
    catalogsMap: {},
    setCatalogsMap: (catalogsMap) => set((state) => ({
        catalogsMap: Object.assign(Object.assign({}, state.catalogsMap), catalogsMap)
    })),
    promotedEntityMap: {},
    setPromotedEntityMap: (promotedEntityMap) => set((state) => ({
        promotedEntityMap: Object.assign(Object.assign({}, state.promotedEntityMap), promotedEntityMap)
    })),
    promotedMethodEntitiesMap: {},
    setPromotedMethodEntitiesMap: (promotedMethodEntitiesMap) => set((state) => ({
        promotedMethodEntitiesMap: Object.assign(Object.assign({}, state.promotedMethodEntitiesMap), promotedMethodEntitiesMap)
    }))
})));
//# sourceMappingURL=catalogStore.js.map