How bisensagar/expnslptr works
expnspltr is a shared-trip expense-splitting app with admin and regular-user views. Users sign in, then role-based routing takes admins to trip and account management or regular users to their assigned trips. Admins create trips, add members and expenses, and can settle a trip; both views show expense shares and settlement breakdowns. The sampled detail pages call the settlement algorithm and query Supabase directly. Edges reflect shown calls or README-documented behavior; unsampled page internals are not inferred.
Main entry points: App.jsx Routes and guards · AuthContext.jsx Session and profile · UserTripDetail.jsx Trip overview · supabase.js Supabase client
Components 13
App and access
- Routes and guards
src/App.jsx - Sign in
src/pages/LoginPage.jsx - Session and profile
src/context/AuthContext.jsx
Admin management
- Admin shell
src/pages/AdminLayout.jsx - Trips and users
src/pages/Dashboard.jsx - Trip management
src/pages/TripDetail.jsx
Member experience
- Assigned trips
src/pages/UserTrips.jsx - Trip overview
src/pages/UserTripDetail.jsx
Services and calculations
- Settlement algorithm
src/lib/settlement.js - Supabase client
src/lib/supabase.js - Supabase Auth
- Supabase database
supabase_schema.sql
Other components
- Trip participants
Connections 26
- Trip participants → Sign in: signs in
README.md - Routes and guards → Session and profile: provides auth
src/App.jsx - Routes and guards → Sign in: routes to
src/App.jsx - Routes and guards → Admin shell: guards admin
src/App.jsx - Routes and guards → Trips and users: routes to
src/App.jsx - Routes and guards → Trip management: routes to
src/App.jsx - Routes and guards → Assigned trips: routes to
src/App.jsx - Routes and guards → Trip overview: routes to
src/App.jsx - Sign in → Session and profile: signs in via
src/pages/LoginPage.jsx - Session and profile → Supabase client: checks session
src/context/AuthContext.jsx - Admin shell → Session and profile: reads profile
src/pages/AdminLayout.jsx - Admin shell → Trip participants: offers sign-out
README.md - Trips and users → Supabase client: queries data
src/pages/Dashboard.jsx - Trips and users → Supabase database: manages trips and users
src/pages/Dashboard.jsx - Trips and users → Supabase Auth: creates accounts
src/pages/Dashboard.jsx - Trip management → Supabase client: queries data
src/pages/TripDetail.jsx - Trip management → Supabase database: manages trip records
src/pages/TripDetail.jsx - Trip management → Settlement algorithm: calculates settlement
src/pages/TripDetail.jsx - Assigned trips → Session and profile: reads profile
src/pages/UserTrips.jsx - Assigned trips → Supabase client: loads assigned trips
src/pages/UserTrips.jsx - Assigned trips → Supabase database: queries memberships
src/pages/UserTrips.jsx - Trip overview → Session and profile: reads profile
src/pages/UserTripDetail.jsx - Trip overview → Supabase client: loads trip data
src/pages/UserTripDetail.jsx - Trip overview → Supabase database: queries trip records
src/pages/UserTripDetail.jsx - Trip overview → Settlement algorithm: calculates settlement
src/pages/UserTripDetail.jsx - Supabase Auth → Supabase database: stores profiles
README.md