# regianleopoldo/lembrai-frontend architecture

> Architecture diagram of the GitHub repository regianleopoldo/lembrai-frontend, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-30). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/regianleopoldo/lembrai-frontend
- Repository: https://github.com/regianleopoldo/lembrai-frontend

## Overview

Agenda Fácil is a Next.js frontend for personal scheduling. The main user flow is Google sign-in, then browsing the dashboard and commitment lists, creating or editing commitments, and viewing their status; the UI exchanges data with a REST backend. Separate areas cover calendar, categories, disciplines, goals, reports, settings, and notifications. The graph reflects documented capabilities and source-index references; several feature pages are only partially sampled, so their backend calls and detailed interactions are not inferred.

Main entry points: [`src/app/inicio/page.tsx`](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/app/inicio/page.tsx) (Dashboard), [`src/components/CardCompromisso.tsx`](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/components/CardCompromisso.tsx) (Commitment actions), [`src/components/notificacoes/SinoNotificacoes.tsx`](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/components/notificacoes/SinoNotificacoes.tsx) (Notification bell), [`src/components/LoginGoogle.tsx`](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/components/LoginGoogle.tsx) (Google login)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_access["Access and navigation"]
  node_login["Google login<br/>[LoginGoogle.tsx]"]
  node_home["Entry routes<br/>[page.tsx]"]
  node_guard["Access guard<br/>[AuthGuard.tsx]"]
  node_navigation["App navigation<br/>[Sidebar.tsx]"]
  node_header["App header<br/>[Header.tsx]"]
end

subgraph group_commitments["Commitment workflow"]
  node_dashboard["Dashboard<br/>[page.tsx]"]
  node_dashboard_view["Dashboard indicators<br/>[Dashboard.tsx]"]
  node_commitment_list["Commitment list"]
  node_commitment_card["Commitment actions"]
  node_commitment_form["Create and edit"]
  node_commitment_detail["Commitment details<br/>[page.tsx]"]
  node_status["Status formatting<br/>[statusVisual.ts]"]
  node_date_format["Date formatting<br/>[formatarData.ts]"]
end

subgraph group_planning["Planning and insights"]
  node_calendar["Calendar"]
  node_categories["Categories"]
  node_disciplines["Disciplines"]
  node_goals["Goals<br/>[MetasClient.tsx]"]
  node_reports["Reports"]
  node_settings["Settings"]
end

subgraph group_support["Notifications and API"]
  node_notification_bell["Notification bell"]
  node_notification_hook["Notification state<br/>[useNotificacoes.ts]"]
  node_notification_item["Notification item"]
  node_api_client["API client<br/>[api.ts]"]
  node_backend[("REST backend")]
end

node_user(("User"))
node_google(("Google OAuth"))

node_user -->|"opens app"| node_home
node_home -->|"presents login"| node_login
node_login -->|"authenticates with"| node_google
node_user -->|"uses"| node_dashboard
node_dashboard -->|"renders"| node_dashboard_view
node_dashboard -->|"renders"| node_commitment_card
node_dashboard -->|"loads commitments"| node_backend
node_commitment_list -->|"loads commitments"| node_backend
node_commitment_card -->|"formats status"| node_status
node_commitment_card -->|"formats dates"| node_date_format
node_commitment_card -.->|"updates commitment"| node_backend
node_commitment_form -.->|"saves commitment"| node_backend
node_commitment_detail -->|"formats status"| node_status
node_user -->|"creates or edits"| node_commitment_form
node_user -->|"views details"| node_commitment_detail
node_calendar -.->|"loads commitments"| node_backend
node_categories -.->|"manages categories"| node_backend
node_disciplines -.->|"manages disciplines"| node_backend
node_goals -->|"requests goals"| node_api_client
node_api_client -->|"sends API requests"| node_backend
node_reports -.->|"loads report data"| node_backend
node_settings -->|"uses login UI"| node_login
node_user -->|"navigates"| node_navigation
node_header -->|"renders"| node_notification_bell
node_notification_bell -->|"uses state hook"| node_notification_hook
node_notification_bell -->|"renders items"| node_notification_item
node_notification_hook -->|"fetches and updates"| node_backend

click node_login "https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/components/LoginGoogle.tsx"
click node_home "https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/app/page.tsx"
click node_guard "https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/components/AuthGuard.tsx"
click node_navigation "https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/components/Sidebar.tsx"
click node_dashboard "https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/app/inicio/page.tsx"
click node_dashboard_view "https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/components/Dashboard.tsx"
click node_commitment_list "https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/app/compromissos/CompromissosClient.tsx"
click node_commitment_card "https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/components/CardCompromisso.tsx"
click node_commitment_form "https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/components/FormCompromisso.tsx"
click node_commitment_detail "https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/app/compromisso/%5Bid%5D/page.tsx"
click node_calendar "https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/app/calendario/CalendarioClient.tsx"
click node_categories "https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/app/categorias/CategoriasClient.tsx"
click node_disciplines "https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/app/disciplinas/DisciplinasClient.tsx"
click node_goals "https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/app/metas/MetasClient.tsx"
click node_reports "https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/app/relatorios/RelatoriosClient.tsx"
click node_settings "https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/app/configuracoes/ConfiguracoesClient.tsx"
click node_header "https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/components/Header.tsx"
click node_status "https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/utils/statusVisual.ts"
click node_date_format "https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/utils/formatarData.ts"
click node_notification_bell "https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/components/notificacoes/SinoNotificacoes.tsx"
click node_notification_hook "https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/hooks/useNotificacoes.ts"
click node_notification_item "https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/components/notificacoes/ItemNotificacao.tsx"
click node_api_client "https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/lib/api.ts"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_login,node_home,node_guard,node_navigation,node_header,node_user toneBlue
class node_dashboard,node_dashboard_view,node_commitment_list,node_commitment_card,node_commitment_form,node_commitment_detail,node_status,node_date_format toneAmber
class node_calendar,node_categories,node_disciplines,node_goals,node_reports,node_settings toneMint
class node_notification_bell,node_notification_hook,node_notification_item,node_api_client,node_backend toneRose
class node_google toneIndigo
```

## Components

### Access and navigation

- [Google login](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/components/LoginGoogle.tsx): `src/components/LoginGoogle.tsx`
- [Entry routes](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/app/page.tsx): `src/app/page.tsx`
- [Access guard](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/components/AuthGuard.tsx): `src/components/AuthGuard.tsx`
- [App navigation](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/components/Sidebar.tsx): `src/components/Sidebar.tsx`
- [App header](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/components/Header.tsx): `src/components/Header.tsx`

### Commitment workflow

- [Dashboard](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/app/inicio/page.tsx): `src/app/inicio/page.tsx`
- [Dashboard indicators](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/components/Dashboard.tsx): `src/components/Dashboard.tsx`
- [Commitment list](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/app/compromissos/CompromissosClient.tsx): `src/app/compromissos/CompromissosClient.tsx`
- [Commitment actions](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/components/CardCompromisso.tsx): `src/components/CardCompromisso.tsx`
- [Create and edit](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/components/FormCompromisso.tsx): `src/components/FormCompromisso.tsx`
- [Commitment details](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/app/compromisso/%5Bid%5D/page.tsx): `src/app/compromisso/[id]/page.tsx`
- [Status formatting](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/utils/statusVisual.ts): `src/utils/statusVisual.ts`
- [Date formatting](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/utils/formatarData.ts): `src/utils/formatarData.ts`

### Planning and insights

- [Calendar](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/app/calendario/CalendarioClient.tsx): `src/app/calendario/CalendarioClient.tsx`
- [Categories](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/app/categorias/CategoriasClient.tsx): `src/app/categorias/CategoriasClient.tsx`
- [Disciplines](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/app/disciplinas/DisciplinasClient.tsx): `src/app/disciplinas/DisciplinasClient.tsx`
- [Goals](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/app/metas/MetasClient.tsx): `src/app/metas/MetasClient.tsx`
- [Reports](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/app/relatorios/RelatoriosClient.tsx): `src/app/relatorios/RelatoriosClient.tsx`
- [Settings](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/app/configuracoes/ConfiguracoesClient.tsx): `src/app/configuracoes/ConfiguracoesClient.tsx`

### Notifications and API

- [Notification bell](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/components/notificacoes/SinoNotificacoes.tsx): `src/components/notificacoes/SinoNotificacoes.tsx`
- [Notification state](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/hooks/useNotificacoes.ts): `src/hooks/useNotificacoes.ts`
- [Notification item](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/components/notificacoes/ItemNotificacao.tsx): `src/components/notificacoes/ItemNotificacao.tsx`
- [API client](https://github.com/regianleopoldo/lembrai-frontend/blob/main/src/lib/api.ts): `src/lib/api.ts`
- **REST backend**

### Other components

- **User**
- **Google OAuth**

## Connections

- User → Entry routes: opens app (evidence: `README.md`)
- Entry routes → Google login: presents login (evidence: `src/app/page.tsx`)
- Google login → Google OAuth: authenticates with (evidence: `README.md`)
- User → Dashboard: uses (evidence: `README.md`)
- Dashboard → Dashboard indicators: renders (evidence: `src/app/inicio/page.tsx`)
- Dashboard → Commitment actions: renders (evidence: `src/app/inicio/page.tsx`)
- Dashboard → REST backend: loads commitments (evidence: `src/app/inicio/page.tsx`)
- Commitment list → REST backend: loads commitments (evidence: `src/app/compromissos/CompromissosClient.tsx`)
- Commitment actions → Status formatting: formats status (evidence: `src/components/CardCompromisso.tsx`)
- Commitment actions → Date formatting: formats dates (evidence: `src/components/CardCompromisso.tsx`)
- Commitment actions → REST backend: updates commitment
- Create and edit → REST backend: saves commitment
- Commitment details → Status formatting: formats status (evidence: `src/app/compromisso/[id]/page.tsx`)
- User → Create and edit: creates or edits (evidence: `README.md`)
- User → Commitment details: views details (evidence: `README.md`)
- Calendar → REST backend: loads commitments
- Categories → REST backend: manages categories
- Disciplines → REST backend: manages disciplines
- Goals → API client: requests goals (evidence: `src/app/metas/MetasClient.tsx`)
- API client → REST backend: sends API requests (evidence: `README.md`)
- Reports → REST backend: loads report data
- Settings → Google login: uses login UI (evidence: `src/app/configuracoes/ConfiguracoesClient.tsx`)
- User → App navigation: navigates (evidence: `README.md`)
- App header → Notification bell: renders (evidence: `src/components/Header.tsx`)
- Notification bell → Notification state: uses state hook (evidence: `src/components/notificacoes/SinoNotificacoes.tsx`)
- Notification bell → Notification item: renders items (evidence: `src/components/notificacoes/SinoNotificacoes.tsx`)
- Notification state → REST backend: fetches and updates (evidence: `src/hooks/useNotificacoes.ts`)
