Phase 1 fixes
This commit is contained in:
@@ -11,8 +11,7 @@ import { useHeaderMetrics } from "../context/HeaderMetricsContext";
|
||||
import { useErrorHandler } from "../hooks/useErrorHandler";
|
||||
import { trackLoading } from "../components/common/LoadingStateMonitor";
|
||||
import PendingPaymentBanner from "../components/billing/PendingPaymentBanner";
|
||||
import { PageLoadingProvider, usePageLoadingContext } from "../context/PageLoadingContext";
|
||||
import PageLoader from "../components/common/PageLoader";
|
||||
import { PageLoadingProvider } from "../context/PageLoadingContext";
|
||||
|
||||
const LayoutContent: React.FC = () => {
|
||||
const { isExpanded, isHovered, isMobileOpen } = useSidebar();
|
||||
@@ -178,14 +177,8 @@ const LayoutContent: React.FC = () => {
|
||||
);
|
||||
};
|
||||
|
||||
// Wrapper component to conditionally render Outlet or PageLoader
|
||||
// Wrapper component - just renders children (global loading removed to avoid unmounting issues)
|
||||
const PageLoaderWrapper: React.FC<{ children: React.ReactNode }> = ({ children }) => {
|
||||
const { isLoading } = usePageLoadingContext();
|
||||
|
||||
if (isLoading) {
|
||||
return <PageLoader />;
|
||||
}
|
||||
|
||||
return <>{children}</>;
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user