Commit Graph

5 Commits

Author SHA1 Message Date
Krao Hasanee 8034f15fb5 Full codebase cleanup and optimization pass
- Fix all hardcoded light colors breaking dark mode (FileAttachment, TaskDetail, RequestDetail)
- Parallelize sequential DB fetches in TaskDetail, CompanyDetail, MyProjects
- Add error handling: NewRequest project/file upload, MyCompany update, CompanyDetail prices, AuthContext profile fetch
- Fix currentUser.company_id → currentUser.company?.id in NewRequest
- Remove stale company.email references from InvoiceDetail, ProjectDetail, TaskDetail
- Clean up dead email field from Companies form reset

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-27 14:46:08 -04:00
Krao Hasanee 195c828f8b Improve auth performance: cache profile, remove double fetch, reduce timeout
- Seed currentUser from localStorage instantly on load (no loading flash)
- Remove getSession() duplicate — onAuthStateChange handles everything
- Fetch fresh profile in background while cached version shows immediately
- Reduce fallback timeout from 5s to 2s
- Explicit Supabase client auth options for reliability

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-27 10:41:42 -04:00
Krao Hasanee 5782f42712 Fix profile query: select phone/address instead of email from companies
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-27 00:00:49 -04:00
Krao Hasanee ee99465f8a Auto login after signup 2026-03-26 23:44:31 -04:00
Krao Hasanee 719209fa25 Refactor: clients → companies schema v2 2026-03-26 23:42:06 -04:00