# 200-ui/nepal-sky-watch-tracker architecture

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

- Interactive diagram: https://gitdiagram.com/200-ui/nepal-sky-watch-tracker
- Repository: https://github.com/200-ui/nepal-sky-watch-tracker

## Overview

This is a browser-based Nepal flight tracker. A user enters an origin, destination, date, and airline; the page passes the search criteria to a local service that generates and sorts synthetic flight data, then displays selectable results and a detail view. The detail view also presents status/timing information and notification controls. The repository shows no live flight API or persistent store. Component relationships are based on the supplied excerpts and SOURCE INDEX; other UI primitives are grouped rather than individually mapped.

Main entry points: [`src/pages/Index.tsx`](https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/pages/Index.tsx) (Tracker page/state), [`src/App.tsx`](https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/App.tsx) (App routing/providers), [`src/components/FlightSearch.tsx`](https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/components/FlightSearch.tsx) (Search form), [`src/components/FlightDetail.tsx`](https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/components/FlightDetail.tsx) (Flight details)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_app["Application shell"]
  node_app["App routing/providers<br/>[App.tsx]"]
  node_index["Tracker page/state<br/>[Index.tsx]"]
  node_notfound["Not found page<br/>[NotFound.tsx]"]
  node_splash["Splash screen<br/>[SplashScreen.tsx]"]
  node_theme["Theme provider<br/>[theme-provider.tsx]"]
  node_mode["Theme toggle<br/>[ModeToggle.tsx]"]
end

subgraph group_search["Flight search"]
  node_searchform["Search form<br/>[FlightSearch.tsx]"]
  node_service["Synthetic flight service<br/>[flightService.ts]"]
end

subgraph group_results["Flight results"]
  node_list["Flight list<br/>[FlightList.tsx]"]
  node_detail["Flight details<br/>[FlightDetail.tsx]"]
end

subgraph group_shared["Shared UI"]
  node_toastapi["Toast hook facade<br/>[use-toast.ts]"]
  node_toaststate["Toast state<br/>[use-toast.ts]"]
  node_toastview["Toast view<br/>[toast.tsx]"]
  node_ui["UI primitives"]
end

node_user(("Traveler"))

node_user -->|"opens"| node_app
node_app -->|"routes to"| node_index
node_app -->|"routes to"| node_notfound
node_index -->|"renders"| node_splash
node_index -->|"wraps"| node_theme
node_index -->|"renders"| node_mode
node_index -->|"renders"| node_searchform
node_searchform -->|"submits criteria"| node_index
node_index -->|"calls search"| node_service
node_index -->|"renders results"| node_list
node_list -->|"selects flight"| node_index
node_index -->|"renders selection"| node_detail
node_detail -->|"requests back"| node_index
node_searchform -->|"shows validation"| node_toastapi
node_detail -->|"shows notices"| node_toastapi
node_toastapi -->|"delegates to"| node_toaststate
node_toaststate -->|"uses types"| node_toastview
node_app -->|"configures tooltips"| node_ui
node_searchform -->|"uses controls"| node_ui
node_list -->|"uses cards/badges"| node_ui
node_detail -->|"uses detail controls"| node_ui

click node_app "https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/App.tsx"
click node_index "https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/pages/Index.tsx"
click node_notfound "https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/pages/NotFound.tsx"
click node_splash "https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/components/SplashScreen.tsx"
click node_theme "https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/components/theme-provider.tsx"
click node_mode "https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/components/ModeToggle.tsx"
click node_searchform "https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/components/FlightSearch.tsx"
click node_service "https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/data/flightService.ts"
click node_list "https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/components/FlightList.tsx"
click node_detail "https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/components/FlightDetail.tsx"
click node_toastapi "https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/components/ui/use-toast.ts"
click node_toaststate "https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/hooks/use-toast.ts"
click node_toastview "https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/components/ui/toast.tsx"
click node_ui "https://github.com/200-ui/nepal-sky-watch-tracker/tree/main/src/components/ui"

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,node_index,node_notfound,node_splash,node_theme,node_mode toneBlue
class node_searchform,node_service toneAmber
class node_list,node_detail toneMint
class node_toastapi,node_toaststate,node_toastview,node_ui toneRose
class node_user toneIndigo
```

## Components

### Application shell

- [App routing/providers](https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/App.tsx): `src/App.tsx`
- [Tracker page/state](https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/pages/Index.tsx): `src/pages/Index.tsx`
- [Not found page](https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/pages/NotFound.tsx): `src/pages/NotFound.tsx`
- [Splash screen](https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/components/SplashScreen.tsx): `src/components/SplashScreen.tsx`
- [Theme provider](https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/components/theme-provider.tsx): `src/components/theme-provider.tsx`
- [Theme toggle](https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/components/ModeToggle.tsx): `src/components/ModeToggle.tsx`

### Flight search

- [Search form](https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/components/FlightSearch.tsx): `src/components/FlightSearch.tsx`
- [Synthetic flight service](https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/data/flightService.ts): `src/data/flightService.ts`

### Flight results

- [Flight list](https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/components/FlightList.tsx): `src/components/FlightList.tsx`
- [Flight details](https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/components/FlightDetail.tsx): `src/components/FlightDetail.tsx`

### Shared UI

- [Toast hook facade](https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/components/ui/use-toast.ts): `src/components/ui/use-toast.ts`
- [Toast state](https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/hooks/use-toast.ts): `src/hooks/use-toast.ts`
- [Toast view](https://github.com/200-ui/nepal-sky-watch-tracker/blob/main/src/components/ui/toast.tsx): `src/components/ui/toast.tsx`
- [UI primitives](https://github.com/200-ui/nepal-sky-watch-tracker/tree/main/src/components/ui): `src/components/ui`

### Other components

- **Traveler**

## Connections

- Traveler → App routing/providers: opens
- App routing/providers → Tracker page/state: routes to (evidence: `src/App.tsx`)
- App routing/providers → Not found page: routes to (evidence: `src/App.tsx`)
- Tracker page/state → Splash screen: renders (evidence: `src/pages/Index.tsx`)
- Tracker page/state → Theme provider: wraps (evidence: `src/pages/Index.tsx`)
- Tracker page/state → Theme toggle: renders (evidence: `src/pages/Index.tsx`)
- Tracker page/state → Search form: renders (evidence: `src/pages/Index.tsx`)
- Search form → Tracker page/state: submits criteria (evidence: `src/pages/Index.tsx`)
- Tracker page/state → Synthetic flight service: calls search (evidence: `src/pages/Index.tsx`)
- Tracker page/state → Flight list: renders results (evidence: `src/pages/Index.tsx`)
- Flight list → Tracker page/state: selects flight (evidence: `src/pages/Index.tsx`)
- Tracker page/state → Flight details: renders selection (evidence: `src/pages/Index.tsx`)
- Flight details → Tracker page/state: requests back (evidence: `src/pages/Index.tsx`)
- Search form → Toast hook facade: shows validation (evidence: `src/components/FlightSearch.tsx`)
- Flight details → Toast hook facade: shows notices (evidence: `src/components/FlightDetail.tsx`)
- Toast hook facade → Toast state: delegates to (evidence: `src/components/ui/use-toast.ts`)
- Toast state → Toast view: uses types (evidence: `src/hooks/use-toast.ts`)
- App routing/providers → UI primitives: configures tooltips (evidence: `src/App.tsx`)
- Search form → UI primitives: uses controls (evidence: `src/components/FlightSearch.tsx`)
- Flight list → UI primitives: uses cards/badges (evidence: `src/components/FlightList.tsx`)
- Flight details → UI primitives: uses detail controls (evidence: `src/components/FlightDetail.tsx`)
