How cpmacatangay/expense works
Salo is a shared group-meal ledger delivered as a PWA; the Android app is explicitly archived. Members sign in, join or create a group, record an outing with attendance and item shares, then the owner finalizes it. Finalization writes shares and activity; the shared ledger derives balances and transfers, while members record and confirm settlements. History, activity, exports, recaps, and payment QR images are supporting capabilities. Edges use excerpts or README statements as evidence; several feature implementations were not sampled, so some documented links remain dashed.
Main entry points: App.tsx PWA routes · OutingEditorPage.tsx Outing editor · client.ts Supabase services · index.ts Outing finalization
Components 21
App and identity
- PWA routes
src/app/App.tsx - Authentication
src/features/auth/authContext.ts
Groups and outings
- Group management
src/features/groups/SettingsPage.tsx - Outing editor
src/features/outings/OutingEditorPage.tsx - Outing data
src/features/outings/api.ts - Outing finalization
supabase/functions/finalize-outing/index.ts
Money and settlement
- Share calculation
src/domain/money/computeShares.ts - Money rules
src/domain/money/validate.ts - Ledger view
src/pages/LedgerPage.tsx - Ledger loading
src/features/ledger/useLedger.ts - Balance calculation
src/domain/ledger/computeLedger.ts - Settlement operations
src/features/ledger/api.ts
History and sharing
- Activity feed
src/pages/ActivityPage.tsx - Filtered history
src/pages/HistoryPage.tsx - Group exports
src/features/export/load.ts - Meal recaps
src/features/recap/RecapPanel.tsx - Payment QR
src/features/payments/qr.ts
Platform and services
- Platform shells
src/platform/PlatformShell.tsx - Supabase services
src/data/supabase/client.ts - Supabase Edge Function
supabase/functions/finalize-outing/index.ts
Other components
- Group member
Connections 24
- Group member → PWA routes: uses
README.md - PWA routes → Authentication: gates routes
src/app/App.tsx - PWA routes → Group management: routes to
src/app/App.tsx - PWA routes → Outing editor: routes to
src/app/App.tsx - PWA routes → Platform shells: wraps pages
src/app/App.tsx - Group member → Group management: creates or joins
README.md - Group member → Outing editor: records meal
README.md - Outing editor → Outing data: reads and writes
src/features/outings/OutingEditorPage.tsx - Outing editor → Share calculation: previews shares
src/features/outings/OutingEditorPage.tsx - Outing editor → Outing finalization: requests finalization
README.md - Outing finalization → Share calculation: computes shares
supabase/functions/finalize-outing/index.ts - Outing finalization → Supabase services: writes finalized data
README.md - Ledger view → Ledger loading: loads ledger
src/pages/LedgerPage.tsx - Ledger loading → Supabase services: loads records
- Ledger loading → Balance calculation: computes balances
src/features/ledger/useLedger.ts - Ledger view → Settlement operations: records decisions
src/pages/LedgerPage.tsx - Settlement operations → Supabase services: persists settlements
src/features/ledger/api.ts - Group member → Activity feed: reviews changes
README.md - Group member → Filtered history: filters outings
README.md - Group member → Group exports: exports records
README.md - Group member → Meal recaps: shares recap
README.md - Group member → Payment QR: views payment QR
README.md - Authentication → Supabase services: authenticates
src/features/auth/AuthProvider.tsx - Group member → Platform shells: chooses platform
README.md