How lele97/pagatu-frontend works
PagaTu is a React SPA for teams sharing coffee-buying turns. A signed-in member opens Home to review groups, payments, statistics and awards, then enters a group to view its turn and record, skip or share a payment; invitation handling and account flows are separate branches. The README documents the route shell and two-layer HTTP client, but source excerpts are incomplete, so unshown component-to-service links are omitted rather than inferred.
Main entry points: main.jsx Router · group.jsx Group page · root.jsx App root · Oauth2LoginButton.jsx OAuth login
Components 26
App shell
- Router
app/main.jsx - App root
app/routes/root.jsx - Footer
app/components/footer/footer.jsx - Error page
app/components/error/error-page.jsx - Settings state
app/context/SettingsContext.jsx - Group navigation state
app/context/GroupContext.jsx
Accounts
- Welcome and auth
app/components/auth/AuthLanding.jsx - OAuth login
app/components/buttons/Oauth2LoginButton.jsx - Provider icons
app/components/buttons/OAuthIcons.jsx - Registration
app/components/signup/signup-form.jsx - Birth date picker
app/components/signup/modal/datePickerModal.jsx - Auth guard
app/components/auth/RequireAuth.jsx - OAuth config
app/config/oauth.js
Groups and coffee
- Home dashboard
app/components/home/home.jsx - Group page
app/components/group/group.jsx - Group page state
app/hooks/useGroupPage.js - Group header
app/components/group/groupHeader.jsx - Register payment
app/components/group/modals/RegisterPaymentModal.jsx - Payment actions
app/components/group/paymentActions.jsx - Payment cards
app/components/group/paymentCards.jsx - Invitation response
app/components/invitation/invitation.jsx
HTTP client
- Endpoint methods
app/utils/apiService.js - HTTP requests and cache
app/utils/api.js
Other components
- Member
- Spring gateway
- OAuth providers
Connections 27
- Member → Router: opens app
README.md - Router → App root: routes through
app/main.jsx - App root → Settings state: provides state
app/routes/root.jsx - App root → Group navigation state: provides state
app/routes/root.jsx - App root → Footer: renders
app/routes/root.jsx - Router → Welcome and auth: routes to
app/main.jsx - Router → Home dashboard: routes to
app/main.jsx - Router → Group page: routes to
app/main.jsx - Router → Invitation response: routes to
README.md - Router → Error page: routes errors to
app/main.jsx - Router → Auth guard: guards pages with
app/main.jsx - Welcome and auth → OAuth login: offers login
- Welcome and auth → Registration: offers registration
- Registration → Birth date picker: renders
app/components/signup/signup-form.jsx - OAuth login → Provider icons: renders icons
app/components/buttons/Oauth2LoginButton.jsx - OAuth login → OAuth config: uses provider config
app/components/buttons/Oauth2LoginButton.jsx - OAuth login → OAuth providers: starts sign-in
- Home dashboard → Endpoint methods: requests dashboard data
README.md - Group page → Group page state: uses page state
README.md - Group page → Group header: renders
app/components/group/group.jsx - Group page → Register payment: renders
app/components/group/group.jsx - Group page → Payment actions: renders
app/components/group/group.jsx - Group page → Payment cards: renders
app/components/group/group.jsx - Group page state → Endpoint methods: requests group data
- Invitation response → Endpoint methods: accepts or rejects
app/components/invitation/invitation.jsx - Endpoint methods → HTTP requests and cache: calls request layer
README.md - HTTP requests and cache → Spring gateway: sends REST and JWT
README.md