# karthik777-ap/rent-ledger architecture

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

- Interactive diagram: https://gitdiagram.com/karthik777-ap/rent-ledger
- Repository: https://github.com/karthik777-ap/rent-ledger

## Overview

Rent Ledger is a static rent-management web app for Indian landlords. The documented user workflow is to sign in, manage properties and tenants, track monthly rent and due dates, record payments, and generate receipts. The repository also includes PWA offline support, consent handling, and policy pages. The main application implementation is in index.html, but it was not sampled; domain capabilities and Supabase sign-in are therefore based on the README, not inspected application code.

Main entry points: [`index.html`](https://github.com/karthik777-ap/rent-ledger/blob/main/index.html) (Application), [`service-worker.js`](https://github.com/karthik777-ap/rent-ledger/blob/main/service-worker.js) (Offline Cache), [`cookie-consent.js`](https://github.com/karthik777-ap/rent-ledger/blob/main/cookie-consent.js) (Cookie Consent), [`offline.html`](https://github.com/karthik777-ap/rent-ledger/blob/main/offline.html) (Offline Page)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_app["Rent Management"]
  node_app_shell["Application<br/>[index.html]"]
  node_auth["Sign-in<br/>[index.html]"]
  node_properties["Properties and Tenants<br/>[index.html]"]
  node_rent["Rent and Due Dates<br/>[index.html]"]
  node_payments["Payments<br/>[index.html]"]
  node_receipts["Rent Receipts<br/>[index.html]"]
end

subgraph group_pwa["PWA Support"]
  node_service_worker["Offline Cache<br/>[service-worker.js]"]
  node_offline_page["Offline Page<br/>[offline.html]"]
  node_manifest["PWA Manifest<br/>[manifest.json]"]
end

subgraph group_privacy["Privacy and Policies"]
  node_consent["Cookie Consent<br/>[cookie-consent.js]"]
  node_privacy_policy["Privacy Policy"]
  node_security_page["Data Security<br/>[data-security.html]"]
  node_terms["Terms of Use<br/>[terms-of-use.html]"]
end

node_landlord(("Landlord"))
node_supabase["Supabase Auth"]
node_browser_storage[("Browser Storage")]

node_landlord -->|"uses"| node_app_shell
node_app_shell -->|"provides"| node_auth
node_auth -->|"authenticates with"| node_supabase
node_app_shell -->|"manages"| node_properties
node_app_shell -->|"tracks"| node_rent
node_app_shell -->|"records"| node_payments
node_app_shell -->|"generates"| node_receipts
node_service_worker -->|"falls back to"| node_offline_page
node_service_worker -->|"caches shell"| node_app_shell
node_service_worker -->|"caches"| node_manifest
node_consent -->|"stores choice"| node_browser_storage

click node_app_shell "https://github.com/karthik777-ap/rent-ledger/blob/main/index.html"
click node_auth "https://github.com/karthik777-ap/rent-ledger/blob/main/index.html"
click node_properties "https://github.com/karthik777-ap/rent-ledger/blob/main/index.html"
click node_rent "https://github.com/karthik777-ap/rent-ledger/blob/main/index.html"
click node_payments "https://github.com/karthik777-ap/rent-ledger/blob/main/index.html"
click node_receipts "https://github.com/karthik777-ap/rent-ledger/blob/main/index.html"
click node_service_worker "https://github.com/karthik777-ap/rent-ledger/blob/main/service-worker.js"
click node_offline_page "https://github.com/karthik777-ap/rent-ledger/blob/main/offline.html"
click node_manifest "https://github.com/karthik777-ap/rent-ledger/blob/main/manifest.json"
click node_consent "https://github.com/karthik777-ap/rent-ledger/blob/main/cookie-consent.js"
click node_privacy_policy "https://github.com/karthik777-ap/rent-ledger/blob/main/privacy-policy.html"
click node_security_page "https://github.com/karthik777-ap/rent-ledger/blob/main/data-security.html"
click node_terms "https://github.com/karthik777-ap/rent-ledger/blob/main/terms-of-use.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_app_shell,node_auth,node_properties,node_rent,node_payments,node_receipts toneBlue
class node_service_worker,node_offline_page,node_manifest,node_browser_storage toneAmber
class node_consent,node_privacy_policy,node_security_page,node_terms toneMint
class node_landlord,node_supabase toneIndigo
```

## Components

### Rent Management

- [Application](https://github.com/karthik777-ap/rent-ledger/blob/main/index.html): `index.html`
- [Sign-in](https://github.com/karthik777-ap/rent-ledger/blob/main/index.html): `index.html`
- [Properties and Tenants](https://github.com/karthik777-ap/rent-ledger/blob/main/index.html): `index.html`
- [Rent and Due Dates](https://github.com/karthik777-ap/rent-ledger/blob/main/index.html): `index.html`
- [Payments](https://github.com/karthik777-ap/rent-ledger/blob/main/index.html): `index.html`
- [Rent Receipts](https://github.com/karthik777-ap/rent-ledger/blob/main/index.html): `index.html`

### PWA Support

- [Offline Cache](https://github.com/karthik777-ap/rent-ledger/blob/main/service-worker.js): `service-worker.js`
- [Offline Page](https://github.com/karthik777-ap/rent-ledger/blob/main/offline.html): `offline.html`
- [PWA Manifest](https://github.com/karthik777-ap/rent-ledger/blob/main/manifest.json): `manifest.json`

### Privacy and Policies

- [Cookie Consent](https://github.com/karthik777-ap/rent-ledger/blob/main/cookie-consent.js): `cookie-consent.js`
- [Privacy Policy](https://github.com/karthik777-ap/rent-ledger/blob/main/privacy-policy.html): `privacy-policy.html`
- [Data Security](https://github.com/karthik777-ap/rent-ledger/blob/main/data-security.html): `data-security.html`
- [Terms of Use](https://github.com/karthik777-ap/rent-ledger/blob/main/terms-of-use.html): `terms-of-use.html`

### Other components

- **Landlord**
- **Supabase Auth**
- **Browser Storage**

## Connections

- Landlord → Application: uses (evidence: `README.md`)
- Application → Sign-in: provides (evidence: `README.md`)
- Sign-in → Supabase Auth: authenticates with (evidence: `README.md`)
- Application → Properties and Tenants: manages (evidence: `README.md`)
- Application → Rent and Due Dates: tracks (evidence: `README.md`)
- Application → Payments: records (evidence: `README.md`)
- Application → Rent Receipts: generates (evidence: `README.md`)
- Offline Cache → Offline Page: falls back to (evidence: `service-worker.js`)
- Offline Cache → Application: caches shell (evidence: `service-worker.js`)
- Offline Cache → PWA Manifest: caches (evidence: `service-worker.js`)
- Cookie Consent → Browser Storage: stores choice (evidence: `cookie-consent.js`)
