From 502c367c12dde1809427dcb29f32da45b9055a4c Mon Sep 17 00:00:00 2001 From: Prateek Shourya Date: Tue, 25 Mar 2025 20:32:19 +0530 Subject: [PATCH] [RANTS-62] fix: remove button to change project cover for members and guests (#2797) --- .../main/info-section/hero-section.tsx | 28 ++++++++++--------- 1 file changed, 15 insertions(+), 13 deletions(-) diff --git a/web/ee/components/project-overview/details/main/info-section/hero-section.tsx b/web/ee/components/project-overview/details/main/info-section/hero-section.tsx index 64963dddaa..e87834604a 100644 --- a/web/ee/components/project-overview/details/main/info-section/hero-section.tsx +++ b/web/ee/components/project-overview/details/main/info-section/hero-section.tsx @@ -105,19 +105,21 @@ export const HeroSection = observer((props: THeroSection) => { alt={project.name} className="absolute left-0 top-0 h-full w-full object-cover" /> -
- { - if (data === project.cover_image) return; - handleCoverChange({ cover_image: data }); - }} - value={project.cover_image ?? DEFAULT_COVER_IMAGE} - disabled={!isAdmin} - projectId={project.id} - /> -
+ {isAdmin && ( +
+ { + if (data === project.cover_image) return; + handleCoverChange({ cover_image: data }); + }} + value={project.cover_image ?? DEFAULT_COVER_IMAGE} + disabled={!isAdmin} + projectId={project.id} + /> +
+ )}