File tree Expand file tree Collapse file tree 1 file changed +10
-2
lines changed
Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change 11'use client' ;
22
3- import { useState , useEffect } from 'react' ;
3+ import { useState , useEffect , Suspense } from 'react' ;
44import { useRouter , useSearchParams } from 'next/navigation' ;
55import Link from 'next/link' ;
66import { authFetch } from '@/lib/auth/client' ;
@@ -346,7 +346,7 @@ function ClientsTab() {
346346}
347347
348348// ─── Main Page with Tabs ─────────────────────────────────────────
349- export default function InvoicesPage ( ) {
349+ function InvoicesPageContent ( ) {
350350 const searchParams = useSearchParams ( ) ;
351351 const router = useRouter ( ) ;
352352 const initialTab = searchParams . get ( 'tab' ) === 'clients' ? 'clients' : 'invoices' ;
@@ -400,3 +400,11 @@ export default function InvoicesPage() {
400400 </ div >
401401 ) ;
402402}
403+
404+ export default function InvoicesPage ( ) {
405+ return (
406+ < Suspense fallback = { < div className = "min-h-screen bg-gray-900 flex items-center justify-center" > < div className = "animate-spin rounded-full h-12 w-12 border-b-2 border-purple-400" /> </ div > } >
407+ < InvoicesPageContent />
408+ </ Suspense >
409+ ) ;
410+ }
You can’t perform that action at this time.
0 commit comments