import { Suspense } from 'react'; import { ErrorBoundary } from 'react-error-boundary'; import { Outlet } from 'react-router'; import ConceptToaster from '@/app/ConceptToaster'; import Footer from '@/app/Footer'; import Navigation from '@/app/Navigation'; import Loader from '@/components/ui/Loader'; import { useAppLayoutStore, useMainHeight, useViewportHeight } from '@/stores/appLayout'; import { globals } from '@/utils/constants'; import ErrorFallback from './ErrorFallback'; import { GlobalDialogs } from './GlobalDialogs'; import { GlobalTooltips } from './GlobalTooltips'; import { NavigationState } from './Navigation/NavigationContext'; const resetState = () => { console.log('Resetting state after error fallback'); }; const logError = (error: Error, info: { componentStack?: string | null | undefined }) => { console.log('Error fallback: ' + error.message); if (info.componentStack) { console.log('Component stack: ' + info.componentStack); } }; function ApplicationLayout() { const mainHeight = useMainHeight(); const viewportHeight = useViewportHeight(); const showScroll = useAppLayoutStore(state => !state.noScroll); const noNavigationAnimation = useAppLayoutStore(state => state.noNavigationAnimation); const noNavigation = useAppLayoutStore(state => state.noNavigation); const noFooter = useAppLayoutStore(state => state.noFooter); return (
}>
{!noNavigation && !noFooter ?
); } export default ApplicationLayout;