publish: fix new notebook on mobile screen sizes

This commit is contained in:
Liam Fitzgerald 2020-09-25 10:59:12 +10:00
parent 261b0f24a1
commit 898b3adeb5
2 changed files with 5 additions and 2 deletions

View File

@ -96,7 +96,7 @@ export function Sidebar(props: any) {
);
}
const display = props.path ? ['none', 'block'] : 'block';
const display = props.hidden ? ['none', 'block'] : 'block';
return (
<Col

View File

@ -89,7 +89,9 @@ export function Skeleton(props: SkeletonProps) {
}, 1500);
}, [noteId, notebook, ship, notebooks])
const panelDisplay = !path ? ["none", "block"] : "block";
const hideSidebar = path || props.location.pathname.endsWith('/new')
const panelDisplay = !hideSidebar ? ["none", "block"] : "block";
return (
<Box height="100%" width="100%" px={[0, 3]} pb={[0, 3]}>
<Box
@ -105,6 +107,7 @@ export function Skeleton(props: SkeletonProps) {
notebooks={props.notebooks}
contacts={props.contacts}
path={path}
hidden={hideSidebar}
invites={props.invites}
associations={props.associations}
api={props.api}