mirror of
https://github.com/IRBorisov/ConceptPortal.git
synced 2025-06-26 13:00:39 +03:00
Hide footer when navigation is hidden
This commit is contained in:
parent
2deeee756c
commit
162191040c
|
@ -22,14 +22,14 @@ function App () {
|
|||
const scrollWindowSize = useMemo(
|
||||
() => {
|
||||
return !noNavigation ?
|
||||
'max-h-[calc(100vh-4.5rem)]'
|
||||
: 'max-h-[100vh]';
|
||||
'calc(100vh - 4.5rem)'
|
||||
: '100vh';
|
||||
}, [noNavigation]);
|
||||
const mainSize = useMemo(
|
||||
() => {
|
||||
return !noNavigation ?
|
||||
'min-h-[calc(100vh-12rem)]'
|
||||
: 'min-h-[calc(100vh-8rem)] ';
|
||||
'calc(100vh - 12rem)'
|
||||
: '100vh';
|
||||
}, [noNavigation]);
|
||||
|
||||
return (
|
||||
|
@ -42,8 +42,8 @@ function App () {
|
|||
pauseOnFocusLoss={false}
|
||||
/>
|
||||
|
||||
<div className={`${scrollWindowSize} overflow-auto`}>
|
||||
<main className={`${mainSize} px-2`}>
|
||||
<div className='overflow-auto' style={{maxHeight: scrollWindowSize}}>
|
||||
<main className='px-2' style={{minHeight: mainSize}}>
|
||||
<Routes>
|
||||
<Route path='/' element={ <HomePage/>} />
|
||||
|
||||
|
@ -60,7 +60,7 @@ function App () {
|
|||
<Route path='*' element={ <NotFoundPage/>} />
|
||||
</Routes>
|
||||
</main>
|
||||
<Footer />
|
||||
{!noNavigation && <Footer />}
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
|
|
|
@ -189,7 +189,7 @@ function EditorTermGraph({ onOpenEdit }: EditorTermGraphProps) {
|
|||
() => {
|
||||
return !noNavigation ?
|
||||
'calc(100vh - 13rem)'
|
||||
: 'calc(100vh - 8.5rem)';
|
||||
: 'calc(100vh - 2rem)';
|
||||
}, [noNavigation]);
|
||||
|
||||
const dismissedStyle = useCallback(
|
||||
|
@ -281,7 +281,7 @@ function EditorTermGraph({ onOpenEdit }: EditorTermGraphProps) {
|
|||
<div className='flex-wrap w-full h-full overflow-auto'>
|
||||
<div
|
||||
className='relative border-t border-r'
|
||||
style={{width: canvasWidth, height: canvasHeight}}
|
||||
style={{width: canvasWidth, height: canvasHeight, borderBottomWidth: noNavigation ? '1px': ''}}
|
||||
>
|
||||
<div id='items-graph-help' className='relative top-0 right-0 z-10 m-2'>
|
||||
<HelpIcon color='text-primary' size={6} />
|
||||
|
|
Loading…
Reference in New Issue
Block a user