From ff15e7fb5352d764ec5974caec1144de43940dda Mon Sep 17 00:00:00 2001 From: Jordan Knott Date: Tue, 5 Jan 2021 17:00:31 -0600 Subject: [PATCH] feat: hide project finder after selecting project --- frontend/src/App/ProjectFinder.tsx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/frontend/src/App/ProjectFinder.tsx b/frontend/src/App/ProjectFinder.tsx index 060c39c..bca1134 100644 --- a/frontend/src/App/ProjectFinder.tsx +++ b/frontend/src/App/ProjectFinder.tsx @@ -7,6 +7,7 @@ import theme from './ThemeStyles'; import ControlledInput from 'shared/components/ControlledInput'; import { CaretDown, CaretRight } from 'shared/icons'; import useStickyState from 'shared/hooks/useStickyState'; +import { usePopup } from 'shared/components/PopupMenu'; const colors = [theme.colors.primary, theme.colors.secondary]; @@ -161,6 +162,7 @@ const ProjectFinder = () => { const { loading, data } = useGetProjectsQuery({ fetchPolicy: 'cache-and-network' }); const [search, setSearch] = useState(''); const [minified, setMinified] = useStickyState>([], 'project_finder_minified'); + const { hidePopup } = usePopup(); if (data) { const { teams } = data; const projects = data.projects.filter(p => { @@ -209,7 +211,7 @@ const ProjectFinder = () => { {team.projects.map((project, idx) => ( - + hidePopup()} to={`/projects/${project.id}`}>