# abdullah4xx/orbit architecture

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

- Interactive diagram: https://gitdiagram.com/abdullah4xx/orbit
- Repository: https://github.com/abdullah4xx/orbit

## Overview

Orbit is an Electron browser with a Chromium-rendered web surface and a plain HTML/CSS browser interface. The main workflow runs from address-bar or tab actions in the chrome UI through the main-process navigation controller, which resolves input and operates web contents; page events then update browser state and history. Separate branches cover bookmarks, identity spoofing, extensions, settings and themes, and dedicated history, bookmark, identity, extension, and new-tab pages. Edges are limited to calls and integrations visible in the excerpts or README; some UI routes and main-process handlers are only partially sampled.

Main entry points: [`main.js`](https://github.com/abdullah4xx/orbit/blob/main/main.js) (Navigation controller), [`preload-tab.js`](https://github.com/abdullah4xx/orbit/blob/main/preload-tab.js) (Page preload), [`lib/identity.js`](https://github.com/abdullah4xx/orbit/blob/main/lib/identity.js) (Site identity), [`lib/extensions.js`](https://github.com/abdullah4xx/orbit/blob/main/lib/extensions.js) (Extension injection)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_control["Browser control"]
  node_chromeui["Browser chrome<br/>[chrome.js]"]
  node_main["Navigation controller<br/>[main.js]"]
  node_urls["Address resolver<br/>[urls.js]"]
  node_chromeinterface["Chrome preload API<br/>[preload-chrome.js]"]
end

subgraph group_records["Browser data"]
  node_settingsstore[("Settings store<br/>[store.js]")]
  node_bookmarkstore[("Bookmark store<br/>[store.js]")]
  node_historystore[("History store<br/>[store.js]")]
end

subgraph group_web["Web adaptation"]
  node_tabpreload["Page preload<br/>[preload-tab.js]"]
  node_identity["Site identity<br/>[identity.js]"]
  node_extensions["Extension injection<br/>[extensions.js]"]
  node_customextensions["Extension packages<br/>[manifest.json]"]
end

subgraph group_pages["Browser pages"]
  node_bookmarksui["Bookmark manager<br/>[bookmarks.js]"]
  node_settingsui["Settings page<br/>[settings.js]"]
  node_historyui["History page<br/>[history.js]"]
  node_identityui["Identity page<br/>[identity.js]"]
  node_extensionsui["Extensions page<br/>[extensions.js]"]
  node_newtabui["New-tab page<br/>[newtab.js]"]
  node_sharedpage["Page helpers<br/>[lib.js]"]
  node_themefiles["Theme styles<br/>[dark.css]"]
end

node_user(("Browser user"))
node_websites(("Websites"))

node_user -->|"uses"| node_chromeui
node_chromeui -->|"sends commands"| node_main
node_main -->|"resolves input"| node_urls
node_main -->|"loads interface"| node_chromeinterface
node_chromeinterface -->|"invokes IPC"| node_main
node_main -->|"configures pages"| node_tabpreload
node_tabpreload -->|"requests scripts"| node_main
node_main -->|"selects profile"| node_identity
node_tabpreload -->|"patches identity"| node_identity
node_main -->|"discovers extensions"| node_extensions
node_tabpreload -->|"requests injections"| node_extensions
node_customextensions -.->|"provides scripts"| node_extensions
node_websites -->|"receives identity"| node_identity
node_main -->|"reads settings"| node_settingsstore
node_main -->|"manages bookmarks"| node_bookmarkstore
node_main -.->|"records visits"| node_historystore
node_bookmarksui -->|"requests bookmark actions"| node_main
node_settingsui -->|"updates settings"| node_main
node_main -.->|"opens history"| node_historyui
node_main -.->|"opens identity"| node_identityui
node_main -.->|"opens extensions"| node_extensionsui
node_main -.->|"opens new tab"| node_newtabui
node_main -->|"loads theme"| node_themefiles
node_sharedpage -->|"receives theme events"| node_main

click node_chromeui "https://github.com/abdullah4xx/orbit/blob/main/ui/chrome.js"
click node_main "https://github.com/abdullah4xx/orbit/blob/main/main.js"
click node_urls "https://github.com/abdullah4xx/orbit/blob/main/lib/urls.js"
click node_tabpreload "https://github.com/abdullah4xx/orbit/blob/main/preload-tab.js"
click node_identity "https://github.com/abdullah4xx/orbit/blob/main/lib/identity.js"
click node_extensions "https://github.com/abdullah4xx/orbit/blob/main/lib/extensions.js"
click node_chromeinterface "https://github.com/abdullah4xx/orbit/blob/main/preload-chrome.js"
click node_settingsstore "https://github.com/abdullah4xx/orbit/blob/main/lib/store.js"
click node_bookmarkstore "https://github.com/abdullah4xx/orbit/blob/main/lib/store.js"
click node_historystore "https://github.com/abdullah4xx/orbit/blob/main/lib/store.js"
click node_bookmarksui "https://github.com/abdullah4xx/orbit/blob/main/ui/bookmarks.js"
click node_settingsui "https://github.com/abdullah4xx/orbit/blob/main/ui/settings.js"
click node_historyui "https://github.com/abdullah4xx/orbit/blob/main/ui/history.js"
click node_identityui "https://github.com/abdullah4xx/orbit/blob/main/ui/identity.js"
click node_extensionsui "https://github.com/abdullah4xx/orbit/blob/main/ui/extensions.js"
click node_newtabui "https://github.com/abdullah4xx/orbit/blob/main/ui/newtab.js"
click node_sharedpage "https://github.com/abdullah4xx/orbit/blob/main/ui/lib.js"
click node_themefiles "https://github.com/abdullah4xx/orbit/blob/main/themes/dark.css"
click node_customextensions "https://github.com/abdullah4xx/orbit/blob/main/extensions/night-pages/manifest.json"

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_chromeui,node_main,node_urls,node_chromeinterface,node_user toneBlue
class node_settingsstore,node_bookmarkstore,node_historystore toneAmber
class node_tabpreload,node_identity,node_extensions,node_customextensions toneMint
class node_bookmarksui,node_settingsui,node_historyui,node_identityui,node_extensionsui,node_newtabui,node_sharedpage,node_themefiles toneRose
class node_websites toneIndigo
```

## Components

### Browser control

- [Browser chrome](https://github.com/abdullah4xx/orbit/blob/main/ui/chrome.js): `ui/chrome.js`
- [Navigation controller](https://github.com/abdullah4xx/orbit/blob/main/main.js): `main.js`
- [Address resolver](https://github.com/abdullah4xx/orbit/blob/main/lib/urls.js): `lib/urls.js`
- [Chrome preload API](https://github.com/abdullah4xx/orbit/blob/main/preload-chrome.js): `preload-chrome.js`

### Browser data

- [Settings store](https://github.com/abdullah4xx/orbit/blob/main/lib/store.js): `lib/store.js`
- [Bookmark store](https://github.com/abdullah4xx/orbit/blob/main/lib/store.js): `lib/store.js`
- [History store](https://github.com/abdullah4xx/orbit/blob/main/lib/store.js): `lib/store.js`

### Web adaptation

- [Page preload](https://github.com/abdullah4xx/orbit/blob/main/preload-tab.js): `preload-tab.js`
- [Site identity](https://github.com/abdullah4xx/orbit/blob/main/lib/identity.js): `lib/identity.js`
- [Extension injection](https://github.com/abdullah4xx/orbit/blob/main/lib/extensions.js): `lib/extensions.js`
- [Extension packages](https://github.com/abdullah4xx/orbit/blob/main/extensions/night-pages/manifest.json): `extensions/night-pages/manifest.json`

### Browser pages

- [Bookmark manager](https://github.com/abdullah4xx/orbit/blob/main/ui/bookmarks.js): `ui/bookmarks.js`
- [Settings page](https://github.com/abdullah4xx/orbit/blob/main/ui/settings.js): `ui/settings.js`
- [History page](https://github.com/abdullah4xx/orbit/blob/main/ui/history.js): `ui/history.js`
- [Identity page](https://github.com/abdullah4xx/orbit/blob/main/ui/identity.js): `ui/identity.js`
- [Extensions page](https://github.com/abdullah4xx/orbit/blob/main/ui/extensions.js): `ui/extensions.js`
- [New-tab page](https://github.com/abdullah4xx/orbit/blob/main/ui/newtab.js): `ui/newtab.js`
- [Page helpers](https://github.com/abdullah4xx/orbit/blob/main/ui/lib.js): `ui/lib.js`
- [Theme styles](https://github.com/abdullah4xx/orbit/blob/main/themes/dark.css): `themes/dark.css`

### Other components

- **Browser user**
- **Websites**

## Connections

- Browser user → Browser chrome: uses (evidence: `README.md`)
- Browser chrome → Navigation controller: sends commands (evidence: `ui/chrome.js`)
- Navigation controller → Address resolver: resolves input (evidence: `main.js`)
- Navigation controller → Chrome preload API: loads interface (evidence: `main.js`)
- Chrome preload API → Navigation controller: invokes IPC (evidence: `preload-chrome.js`)
- Navigation controller → Page preload: configures pages (evidence: `main.js`)
- Page preload → Navigation controller: requests scripts (evidence: `preload-tab.js`)
- Navigation controller → Site identity: selects profile (evidence: `main.js`)
- Page preload → Site identity: patches identity (evidence: `preload-tab.js`)
- Navigation controller → Extension injection: discovers extensions (evidence: `main.js`)
- Page preload → Extension injection: requests injections (evidence: `preload-tab.js`)
- Extension packages → Extension injection: provides scripts (evidence: `README.md`)
- Websites → Site identity: receives identity (evidence: `README.md`)
- Navigation controller → Settings store: reads settings (evidence: `main.js`)
- Navigation controller → Bookmark store: manages bookmarks (evidence: `main.js`)
- Navigation controller → History store: records visits (evidence: `main.js`)
- Bookmark manager → Navigation controller: requests bookmark actions (evidence: `ui/bookmarks.js`)
- Settings page → Navigation controller: updates settings (evidence: `ui/settings.js`)
- Navigation controller → History page: opens history (evidence: `README.md`)
- Navigation controller → Identity page: opens identity (evidence: `README.md`)
- Navigation controller → Extensions page: opens extensions (evidence: `README.md`)
- Navigation controller → New-tab page: opens new tab (evidence: `README.md`)
- Navigation controller → Theme styles: loads theme (evidence: `main.js`)
- Page helpers → Navigation controller: receives theme events (evidence: `ui/lib.js`)
