diff --git a/src/routes/__root.tsx b/src/routes/__root.tsx index 666ca13..6b88bdb 100644 --- a/src/routes/__root.tsx +++ b/src/routes/__root.tsx @@ -157,6 +157,16 @@ function RootShell({ children }: { children: ReactNode }) { function RootComponent() { const { queryClient } = Route.useRouteContext(); + // `AppShell` legge la rosa da `giocatori_squadra` (useGiocatoreBase → DD-015): serve stare + // dentro il QueryClientProvider, quindi il provider avvolge tutto fin da qui. + return ( + + + + ); +} + +function AppShell() { const navigate = useNavigate(); const location = useLocation(); const giocatore = useGiocatoreBase(); @@ -183,7 +193,7 @@ function RootComponent() { } return ( - + <>
{/* Required: nested routes render here. Removing breaks all child routes. */} @@ -191,6 +201,6 @@ function RootComponent() { {!isBenvenuto && } {!isBenvenuto && } - + ); }