# prathampatel79/habbit-tracker architecture

> Architecture diagram of the GitHub repository prathampatel79/habbit-tracker, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-06). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/prathampatel79/habbit-tracker
- Repository: https://github.com/prathampatel79/habbit-tracker

## Overview

This small habit-tracker page lets a user click Add, then displays the entered habit. The handler’s event registration and DOM reads/writes are visible in script.js; index.html and style.css were not sampled, so UI details are limited to the elements named by the handler.

Main entry points: [`script.js`](https://github.com/prathampatel79/habbit-tracker/blob/main/script.js) (Add handler), [`index.html`](https://github.com/prathampatel79/habbit-tracker/blob/main/index.html) (Add button)

## Diagram (Mermaid)

```mermaid
flowchart TD

node_user(("User"))
node_add_button["Add button<br/>[index.html]"]
node_handler["Add handler<br/>[script.js]"]
node_habit_input["Habit input<br/>[index.html]"]
node_habit_display["Habit display<br/>[index.html]"]

node_user -.->|"clicks"| node_add_button
node_add_button -->|"triggers"| node_handler
node_handler -->|"reads"| node_habit_input
node_handler -->|"writes"| node_habit_display

click node_add_button "https://github.com/prathampatel79/habbit-tracker/blob/main/index.html"
click node_handler "https://github.com/prathampatel79/habbit-tracker/blob/main/script.js"
click node_habit_input "https://github.com/prathampatel79/habbit-tracker/blob/main/index.html"
click node_habit_display "https://github.com/prathampatel79/habbit-tracker/blob/main/index.html"

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_user toneBlue
class node_add_button,node_habit_input,node_habit_display toneTeal
class node_handler toneMint
```

## Components

### Other components

- **User**
- [Add button](https://github.com/prathampatel79/habbit-tracker/blob/main/index.html): `index.html`
- [Add handler](https://github.com/prathampatel79/habbit-tracker/blob/main/script.js): `script.js`
- [Habit input](https://github.com/prathampatel79/habbit-tracker/blob/main/index.html): `index.html`
- [Habit display](https://github.com/prathampatel79/habbit-tracker/blob/main/index.html): `index.html`

## Connections

- User → Add button: clicks
- Add button → Add handler: triggers (evidence: `script.js`)
- Add handler → Habit input: reads (evidence: `script.js`)
- Add handler → Habit display: writes (evidence: `script.js`)
