From 0c8a8675659838ec239bea5278c3fe5bd04c9dde Mon Sep 17 00:00:00 2001 From: guru_sainath Date: Mon, 6 Nov 2023 13:52:33 +0530 Subject: [PATCH] fix: handled drag and drop issue, gantt hover issue for issue peek overview (#2660) --- .../issues/issue-peek-overview/root.tsx | 55 ++++++++++--------- .../issues/issue-peek-overview/view.tsx | 4 +- .../cycle/cycle_issue_kanban_view.store.ts | 1 + web/store/issue/issue_kanban_view.store.ts | 1 + .../module/module_issue_kanban_view.store.ts | 1 + 5 files changed, 34 insertions(+), 28 deletions(-) diff --git a/web/components/issues/issue-peek-overview/root.tsx b/web/components/issues/issue-peek-overview/root.tsx index 255e22929..6c8631b5b 100644 --- a/web/components/issues/issue-peek-overview/root.tsx +++ b/web/components/issues/issue-peek-overview/root.tsx @@ -1,4 +1,4 @@ -import { FC, ReactNode } from "react"; +import { FC, Fragment, ReactNode } from "react"; import { useRouter } from "next/router"; import useSWR from "swr"; import { observer } from "mobx-react-lite"; @@ -112,6 +112,7 @@ export const IssuePeekOverview: FC = observer((props) => { else await issueStore.deleteIssue(workspaceSlug, projectId, issue!); const { query } = router; if (query.peekIssueId) { + issueDetailStore.setPeekId(null); delete query.peekIssueId; router.push({ pathname: router.pathname, @@ -123,30 +124,32 @@ export const IssuePeekOverview: FC = observer((props) => { const userRole = userStore.currentProjectRole ?? 5; return ( - - {children} - + + + {children} + + ); }); diff --git a/web/components/issues/issue-peek-overview/view.tsx b/web/components/issues/issue-peek-overview/view.tsx index 509fe593a..a44fbedaf 100644 --- a/web/components/issues/issue-peek-overview/view.tsx +++ b/web/components/issues/issue-peek-overview/view.tsx @@ -97,6 +97,7 @@ export const IssueView: FC = observer((props) => { const updateRoutePeekId = () => { if (issueId != peekIssueId) { + issueDetailStore.setPeekId(issueId); const { query } = router; router.push({ pathname: router.pathname, @@ -107,6 +108,7 @@ export const IssueView: FC = observer((props) => { const removeRoutePeekId = () => { const { query } = router; if (query.peekIssueId) { + issueDetailStore.setPeekId(null); delete query.peekIssueId; router.push({ pathname: router.pathname, @@ -292,8 +294,6 @@ export const IssueView: FC = observer((props) => { issueReactionRemove={issueReactionRemove} /> -
-