perf upgrade

This commit is contained in:
yohlo
2026-07-12 21:26:16 -07:00
parent ec334bbed4
commit 778f0f7994
74 changed files with 1522 additions and 1014 deletions
+3 -5
View File
@@ -1,5 +1,5 @@
import { AppShell } from '@mantine/core';
import { PropsWithChildren, useState } from 'react';
import { PropsWithChildren } from 'react';
import Header from './header';
import Navbar from './navbar';
import Pullable from './pullable';
@@ -8,10 +8,8 @@ import useRouterConfig from '../hooks/use-router-config';
import Page from '@/components/page';
const Layout: React.FC<PropsWithChildren> = ({ children }) => {
const { header } = useRouterConfig();
const { header, withPadding, fullWidth } = useRouterConfig();
const viewport = useVisualViewportSize();
const [scrollPosition, setScrollPosition] = useState({ x: 0, y: 0 });
const { withPadding, fullWidth } = useRouterConfig();
return (
<AppShell
@@ -47,7 +45,7 @@ const Layout: React.FC<PropsWithChildren> = ({ children }) => {
maw='100dvw'
style={{ transition: 'none', overflow: 'hidden' }}
>
<Pullable scrollPosition={scrollPosition} onScrollPositionChange={setScrollPosition}>
<Pullable>
<Page noPadding={!withPadding} fullWidth={fullWidth}>
{children}
</Page>