# thalisvn/agenda-electron architecture

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

- Interactive diagram: https://gitdiagram.com/thalisvn/agenda-electron
- Repository: https://github.com/thalisvn/agenda-electron

## Overview

Agenda Universitária is an Electron desktop calendar for managing academic commitments. The main workflow is month navigation and date selection, opening a day-specific window, then listing, creating, editing, or deleting commitments through the preload bridge and Electron IPC handlers backed by MongoDB. The README also describes day/month views and deadline notifications; the sampled implementation supports calendar views and CRUD, but does not show notification behavior. The map reflects only sampled source and documented capabilities.

Main entry points: [`src/script.js`](https://github.com/thalisvn/agenda-electron/blob/main/src/script.js) (Monthly calendar), [`src/main.js`](https://github.com/thalisvn/agenda-electron/blob/main/src/main.js) (Window and IPC handlers), [`src/preload.js`](https://github.com/thalisvn/agenda-electron/blob/main/src/preload.js) (API bridge), [`src/compromissoFrontend.js`](https://github.com/thalisvn/agenda-electron/blob/main/src/compromissoFrontend.js) (Day commitments)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_calendar["Calendar UI"]
  node_calendar_view["Monthly calendar<br/>[script.js]"]
end

subgraph group_commitments["Commitment UI"]
  node_day_view["Day commitments"]
  node_notification["Deadline notifications"]
end

subgraph group_electron["Electron Runtime"]
  node_preload["API bridge<br/>[preload.js]"]
  node_main["Window and IPC handlers<br/>[main.js]"]
end

subgraph group_storage["Persistence"]
  node_mongodb[("MongoDB")]
end

node_student(("Student"))

node_student -->|"uses"| node_calendar_view
node_calendar_view -->|"requests dates"| node_preload
node_preload -->|"invokes IPC"| node_main
node_main -->|"queries and writes"| node_mongodb
node_calendar_view -->|"opens selected day"| node_day_view
node_day_view -->|"requests CRUD"| node_preload
node_main -->|"signals refresh"| node_calendar_view
node_student -.->|"receives alerts"| node_notification

click node_calendar_view "https://github.com/thalisvn/agenda-electron/blob/main/src/script.js"
click node_day_view "https://github.com/thalisvn/agenda-electron/blob/main/src/compromissoFrontend.js"
click node_preload "https://github.com/thalisvn/agenda-electron/blob/main/src/preload.js"
click node_main "https://github.com/thalisvn/agenda-electron/blob/main/src/main.js"

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_calendar_view toneBlue
class node_day_view,node_notification toneAmber
class node_preload,node_main toneMint
class node_mongodb toneRose
class node_student toneIndigo
```

## Components

### Calendar UI

- [Monthly calendar](https://github.com/thalisvn/agenda-electron/blob/main/src/script.js): `src/script.js`

### Commitment UI

- [Day commitments](https://github.com/thalisvn/agenda-electron/blob/main/src/compromissoFrontend.js): `src/compromissoFrontend.js`
- **Deadline notifications**

### Electron Runtime

- [API bridge](https://github.com/thalisvn/agenda-electron/blob/main/src/preload.js): `src/preload.js`
- [Window and IPC handlers](https://github.com/thalisvn/agenda-electron/blob/main/src/main.js): `src/main.js`

### Persistence

- **MongoDB**

### Other components

- **Student**

## Connections

- Student → Monthly calendar: uses (evidence: `README.md`)
- Monthly calendar → API bridge: requests dates (evidence: `src/script.js`)
- API bridge → Window and IPC handlers: invokes IPC (evidence: `src/preload.js`)
- Window and IPC handlers → MongoDB: queries and writes (evidence: `src/main.js`)
- Monthly calendar → Day commitments: opens selected day
- Day commitments → API bridge: requests CRUD (evidence: `src/compromissoFrontend.js`)
- Window and IPC handlers → Monthly calendar: signals refresh (evidence: `src/main.js`)
- Student → Deadline notifications: receives alerts (evidence: `README.md`)
