From 2830cb19feb47f3a52467ec715546375292c3c69 Mon Sep 17 00:00:00 2001 From: Peng Xiao Date: Tue, 15 Aug 2023 12:01:46 +0800 Subject: [PATCH] fix: show recursive items (#3750) --- .../workspace-slider-bar/components/reference-page.tsx | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/apps/core/src/components/pure/workspace-slider-bar/components/reference-page.tsx b/apps/core/src/components/pure/workspace-slider-bar/components/reference-page.tsx index a92763347a..872943a329 100644 --- a/apps/core/src/components/pure/workspace-slider-bar/components/reference-page.tsx +++ b/apps/core/src/components/pure/workspace-slider-bar/components/reference-page.tsx @@ -29,14 +29,8 @@ export const ReferencePage = ({ const icon = setting?.mode === 'edgeless' ? : ; const references = useBlockSuitePageReferences(workspace, pageId); const referencesToShow = useMemo(() => { - return [ - ...new Set( - references.filter( - ref => !parentIds.has(ref) && !metaMapping[ref]?.trash - ) - ), - ]; - }, [references, parentIds, metaMapping]); + return [...new Set(references.filter(ref => !metaMapping[ref]?.trash))]; + }, [references, metaMapping]); const [collapsed, setCollapsed] = useState(true); const collapsible = referencesToShow.length > 0; const nestedItem = parentIds.size > 0;