From cc2648a1a98eafe3fb6bd1c8744083c8535f1c9e Mon Sep 17 00:00:00 2001 From: Maksym Yezhov Date: Mon, 15 Dec 2025 22:05:49 -0800 Subject: [PATCH] refactor: remove unsused props from componentLibraryProvider --- .../shared/Dialogs/ComponentDuplicateDialog.test.tsx | 2 -- .../ComponentLibraryProvider/ComponentLibraryProvider.tsx | 7 ------- 2 files changed, 9 deletions(-) diff --git a/src/components/shared/Dialogs/ComponentDuplicateDialog.test.tsx b/src/components/shared/Dialogs/ComponentDuplicateDialog.test.tsx index 4d46a90e3..38891bea9 100644 --- a/src/components/shared/Dialogs/ComponentDuplicateDialog.test.tsx +++ b/src/components/shared/Dialogs/ComponentDuplicateDialog.test.tsx @@ -48,8 +48,6 @@ const createMockComponentLibraryContext = ( searchComponentLibrary: vi.fn(), addToComponentLibrary: vi.fn(), removeFromComponentLibrary: vi.fn(), - refetchLibrary: vi.fn(), - refetchUserComponents: vi.fn(), setComponentFavorite: vi.fn(), checkIfUserComponent: vi.fn().mockReturnValue(false), checkLibraryContainsComponent: vi.fn().mockReturnValue(false), diff --git a/src/providers/ComponentLibraryProvider/ComponentLibraryProvider.tsx b/src/providers/ComponentLibraryProvider/ComponentLibraryProvider.tsx index 8f6f37d43..4200c05af 100644 --- a/src/providers/ComponentLibraryProvider/ComponentLibraryProvider.tsx +++ b/src/providers/ComponentLibraryProvider/ComponentLibraryProvider.tsx @@ -84,9 +84,6 @@ type ComponentLibraryContextType = { component: HydratedComponentReference, ) => Promise; removeFromComponentLibrary: (component: ComponentReference) => void; - refetchLibrary: () => void; - refetchUserComponents: () => void; - setComponentFavorite: ( component: ComponentReference, favorited: boolean, @@ -593,8 +590,6 @@ export const ComponentLibraryProvider = ({ getComponentLibrary, addToComponentLibrary, removeFromComponentLibrary, - refetchLibrary, - refetchUserComponents, setComponentFavorite, checkIfUserComponent, checkLibraryContainsComponent, @@ -612,8 +607,6 @@ export const ComponentLibraryProvider = ({ getComponentLibrary, addToComponentLibrary, removeFromComponentLibrary, - refetchLibrary, - refetchUserComponents, setComponentFavorite, checkIfUserComponent, checkLibraryContainsComponent,