From f7291d18164b201ae8a65e888c5b807aa70a5ab9 Mon Sep 17 00:00:00 2001 From: Maxim Shmakov Date: Thu, 2 Jul 2020 01:55:15 +0300 Subject: [PATCH] 1240: skipping hidden sidebar items (#1519) --- src/components/Community/Section/index.tsx | 4 +++- .../Layout/SidebarMenu/index.tsx | 22 ++++++++++--------- .../Home/UseCases/CollapsibleText/index.tsx | 4 +++- 3 files changed, 18 insertions(+), 12 deletions(-) diff --git a/src/components/Community/Section/index.tsx b/src/components/Community/Section/index.tsx index 04cc895392..52ae6c5d47 100644 --- a/src/components/Community/Section/index.tsx +++ b/src/components/Community/Section/index.tsx @@ -89,7 +89,9 @@ const Section: React.FC = ({ {background && } {isTablet ? ( - {children} + ) : ( children )} diff --git a/src/components/Documentation/Layout/SidebarMenu/index.tsx b/src/components/Documentation/Layout/SidebarMenu/index.tsx index 0a835e742a..a044f6467e 100644 --- a/src/components/Documentation/Layout/SidebarMenu/index.tsx +++ b/src/components/Documentation/Layout/SidebarMenu/index.tsx @@ -99,16 +99,18 @@ const SidebarMenuItem: React.FC = ({ <> {parentElement} {children && ( - - {children.map(item => ( - - ))} - + )} ) diff --git a/src/components/Home/UseCases/CollapsibleText/index.tsx b/src/components/Home/UseCases/CollapsibleText/index.tsx index 71091664e3..0e11146e9d 100644 --- a/src/components/Home/UseCases/CollapsibleText/index.tsx +++ b/src/components/Home/UseCases/CollapsibleText/index.tsx @@ -31,7 +31,9 @@ const CollapsibleText: React.FC = ({ tabIndex={0} > {header} - {children} + {!isOpened &&
More...
} )