From f08c9937bb1e9825c8b079d7b4d2240c3a55d4f0 Mon Sep 17 00:00:00 2001 From: gitstart Date: Fri, 11 Nov 2022 15:43:02 +0000 Subject: [PATCH] fix: showPanel false does not work on mobile view --- code/ui/manager/src/components/layout/mobile.stories.tsx | 3 +++ code/ui/manager/src/components/layout/mobile.tsx | 8 ++------ 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/code/ui/manager/src/components/layout/mobile.stories.tsx b/code/ui/manager/src/components/layout/mobile.stories.tsx index ff0eb280a4c6..1a9121a8cc91 100644 --- a/code/ui/manager/src/components/layout/mobile.stories.tsx +++ b/code/ui/manager/src/components/layout/mobile.stories.tsx @@ -33,6 +33,9 @@ export const InitialCanvas = ({ props }: { props: MobileProps }) => ( export const InitialAddons = ({ props }: { props: MobileProps }) => ( ); +export const NoPanel = ({ props }: { props: MobileProps }) => ( + +); export const Fullscreen = ({ props }: { props: MobileProps }) => ( ; Sidebar: ComponentType; Preview: ComponentType; Panel: ComponentType; @@ -204,7 +200,7 @@ class Mobile extends Component { {key} ))} - {viewMode ? ( + {viewMode && options.showPanel ? ( this.setState({ active: ADDONS })} active={active === ADDONS}