# pardhavkrishna21/park_spheree architecture

> Architecture diagram of the GitHub repository pardhavkrishna21/park_spheree, 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/pardhavkrishna21/park_spheree
- Repository: https://github.com/pardhavkrishna21/park_spheree

## Overview

This is a React parking marketplace UI: drivers find a space, check availability, configure a timed reservation and add-ons, then manage the booking; hosts list spaces and review occupancy and earnings. The app also exposes subscriptions, valet, services, account, help, and authentication views. The sampled code and README describe a Vite template rather than product behavior; the product map is inferred from source names and the available imports. Data appears to be local mock data, with no backend or persistent store evidenced.

Main entry points: [`src/App.jsx`](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/App.jsx) (App state and routing), [`src/utils/bookingTime.js`](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/utils/bookingTime.js) (Booking time rules), [`src/components/BookingModal/index.jsx`](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/BookingModal/index.jsx) (Reservation and add-ons), [`src/utils/availability.js`](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/utils/availability.js) (Availability calculation)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_app["Application shell"]
  node_app["App state and routing<br/>[App.jsx]"]
  node_nav["Navigation<br/>[index.jsx]"]
  node_mock["Sample marketplace data<br/>[mockData.js]"]
  node_auth["Authentication UI<br/>[index.jsx]"]
end

subgraph group_driver["Driver experience"]
  node_find["Find parking<br/>[index.jsx]"]
  node_spot["Parking spot cards<br/>[index.jsx]"]
  node_booking["Reservation and add-ons<br/>[index.jsx]"]
  node_bookings["Booking management<br/>[index.jsx]"]
  node_datetime["Date and time selection<br/>[index.jsx]"]
  node_subscriptions["Plans and subscriptions<br/>[index.jsx]"]
  node_services["EV and wash services<br/>[index.jsx]"]
  node_valet["Captain valet service<br/>[index.jsx]"]
  node_valetpicker["Valet selection<br/>[index.jsx]"]
  node_account["Account view<br/>[index.jsx]"]
  node_help["Help and feedback<br/>[index.jsx]"]
end

subgraph group_host["Host experience"]
  node_hostlist["Create space listing<br/>[index.jsx]"]
  node_hostdash["Host earnings dashboard<br/>[index.jsx]"]
end

subgraph group_logic["Domain logic"]
  node_availability["Availability calculation<br/>[availability.js]"]
  node_time["Booking time rules<br/>[bookingTime.js]"]
  node_plans["Plan and add-on pricing<br/>[plans.js]"]
  node_geo["Valet distance calculation<br/>[geo.js]"]
  node_violations["Violation rules<br/>[violations.js]"]
end

node_driver_actor(("Driver"))
node_host_actor(("Space host"))

node_driver_actor -->|"uses"| node_app
node_host_actor -->|"uses"| node_app
node_app -->|"renders"| node_nav
node_app -->|"loads sample data"| node_mock
node_app -->|"renders"| node_auth
node_app -->|"renders"| node_find
node_app -->|"opens reservation"| node_booking
node_app -->|"renders"| node_bookings
node_app -->|"renders"| node_subscriptions
node_app -->|"renders"| node_valet
node_app -->|"renders"| node_services
node_app -->|"renders"| node_hostlist
node_app -->|"renders"| node_hostdash
node_app -->|"renders"| node_account
node_app -->|"renders"| node_help
node_find -->|"renders"| node_spot
node_find -->|"uses"| node_datetime
node_find -->|"checks availability"| node_availability
node_booking -->|"checks availability"| node_availability
node_booking -->|"checks time conflicts"| node_time
node_booking -->|"prices add-ons"| node_plans
node_booking -->|"offers valet selection"| node_valetpicker
node_bookings -->|"checks availability"| node_availability
node_bookings -->|"formats booking times"| node_time
node_bookings -->|"uses plan pricing"| node_plans
node_valetpicker -->|"prices valet"| node_plans
node_valetpicker -->|"calculates distance"| node_geo
node_services -->|"checks availability"| node_availability
node_services -->|"checks plan perks"| node_plans
node_services -->|"uses booking windows"| node_time
node_availability -->|"uses time ranges"| node_time
node_account -->|"formats booking times"| node_time
node_app -->|"checks booking conflicts"| node_time

click node_app "https://github.com/pardhavkrishna21/park_spheree/blob/main/src/App.jsx"
click node_nav "https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/Navbar/index.jsx"
click node_mock "https://github.com/pardhavkrishna21/park_spheree/blob/main/src/data/mockData.js"
click node_auth "https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/AuthPortal/index.jsx"
click node_find "https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/FindParking/index.jsx"
click node_spot "https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/SpotCard/index.jsx"
click node_booking "https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/BookingModal/index.jsx"
click node_bookings "https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/BookingsView/index.jsx"
click node_datetime "https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/DateTimePicker/index.jsx"
click node_subscriptions "https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/Subscriptions/index.jsx"
click node_services "https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/ServicesView/index.jsx"
click node_valet "https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/CaptainValet/index.jsx"
click node_valetpicker "https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/ValetPicker/index.jsx"
click node_account "https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/AccountView/index.jsx"
click node_help "https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/HelpFeedback/index.jsx"
click node_hostlist "https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/HostListings/index.jsx"
click node_hostdash "https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/HostDashboard/index.jsx"
click node_availability "https://github.com/pardhavkrishna21/park_spheree/blob/main/src/utils/availability.js"
click node_time "https://github.com/pardhavkrishna21/park_spheree/blob/main/src/utils/bookingTime.js"
click node_plans "https://github.com/pardhavkrishna21/park_spheree/blob/main/src/utils/plans.js"
click node_geo "https://github.com/pardhavkrishna21/park_spheree/blob/main/src/utils/geo.js"
click node_violations "https://github.com/pardhavkrishna21/park_spheree/blob/main/src/utils/violations.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_app,node_nav,node_mock,node_auth toneBlue
class node_find,node_spot,node_booking,node_bookings,node_datetime,node_subscriptions,node_services,node_valet,node_valetpicker,node_account,node_help toneAmber
class node_hostlist,node_hostdash toneMint
class node_availability,node_time,node_plans,node_geo,node_violations toneRose
class node_driver_actor,node_host_actor toneIndigo
```

## Components

### Application shell

- [App state and routing](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/App.jsx): `src/App.jsx`
- [Navigation](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/Navbar/index.jsx): `src/components/Navbar/index.jsx`
- [Sample marketplace data](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/data/mockData.js): `src/data/mockData.js`
- [Authentication UI](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/AuthPortal/index.jsx): `src/components/AuthPortal/index.jsx`

### Driver experience

- [Find parking](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/FindParking/index.jsx): `src/components/FindParking/index.jsx`
- [Parking spot cards](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/SpotCard/index.jsx): `src/components/SpotCard/index.jsx`
- [Reservation and add-ons](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/BookingModal/index.jsx): `src/components/BookingModal/index.jsx`
- [Booking management](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/BookingsView/index.jsx): `src/components/BookingsView/index.jsx`
- [Date and time selection](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/DateTimePicker/index.jsx): `src/components/DateTimePicker/index.jsx`
- [Plans and subscriptions](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/Subscriptions/index.jsx): `src/components/Subscriptions/index.jsx`
- [EV and wash services](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/ServicesView/index.jsx): `src/components/ServicesView/index.jsx`
- [Captain valet service](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/CaptainValet/index.jsx): `src/components/CaptainValet/index.jsx`
- [Valet selection](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/ValetPicker/index.jsx): `src/components/ValetPicker/index.jsx`
- [Account view](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/AccountView/index.jsx): `src/components/AccountView/index.jsx`
- [Help and feedback](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/HelpFeedback/index.jsx): `src/components/HelpFeedback/index.jsx`

### Host experience

- [Create space listing](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/HostListings/index.jsx): `src/components/HostListings/index.jsx`
- [Host earnings dashboard](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/components/HostDashboard/index.jsx): `src/components/HostDashboard/index.jsx`

### Domain logic

- [Availability calculation](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/utils/availability.js): `src/utils/availability.js`
- [Booking time rules](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/utils/bookingTime.js): `src/utils/bookingTime.js`
- [Plan and add-on pricing](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/utils/plans.js): `src/utils/plans.js`
- [Valet distance calculation](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/utils/geo.js): `src/utils/geo.js`
- [Violation rules](https://github.com/pardhavkrishna21/park_spheree/blob/main/src/utils/violations.js): `src/utils/violations.js`

### Other components

- **Driver**
- **Space host**

## Connections

- Driver → App state and routing: uses
- Space host → App state and routing: uses
- App state and routing → Navigation: renders (evidence: `src/App.jsx`)
- App state and routing → Sample marketplace data: loads sample data (evidence: `src/App.jsx`)
- App state and routing → Authentication UI: renders (evidence: `src/App.jsx`)
- App state and routing → Find parking: renders (evidence: `src/App.jsx`)
- App state and routing → Reservation and add-ons: opens reservation (evidence: `src/App.jsx`)
- App state and routing → Booking management: renders (evidence: `src/App.jsx`)
- App state and routing → Plans and subscriptions: renders (evidence: `src/App.jsx`)
- App state and routing → Captain valet service: renders (evidence: `src/App.jsx`)
- App state and routing → EV and wash services: renders (evidence: `src/App.jsx`)
- App state and routing → Create space listing: renders (evidence: `src/App.jsx`)
- App state and routing → Host earnings dashboard: renders (evidence: `src/App.jsx`)
- App state and routing → Account view: renders (evidence: `src/App.jsx`)
- App state and routing → Help and feedback: renders (evidence: `src/App.jsx`)
- Find parking → Parking spot cards: renders (evidence: `src/components/FindParking/index.jsx`)
- Find parking → Date and time selection: uses (evidence: `src/components/FindParking/index.jsx`)
- Find parking → Availability calculation: checks availability (evidence: `src/components/FindParking/index.jsx`)
- Reservation and add-ons → Availability calculation: checks availability (evidence: `src/components/BookingModal/index.jsx`)
- Reservation and add-ons → Booking time rules: checks time conflicts (evidence: `src/components/BookingModal/index.jsx`)
- Reservation and add-ons → Plan and add-on pricing: prices add-ons (evidence: `src/components/BookingModal/index.jsx`)
- Reservation and add-ons → Valet selection: offers valet selection (evidence: `src/components/BookingModal/index.jsx`)
- Booking management → Availability calculation: checks availability (evidence: `src/components/BookingsView/index.jsx`)
- Booking management → Booking time rules: formats booking times (evidence: `src/components/BookingsView/index.jsx`)
- Booking management → Plan and add-on pricing: uses plan pricing (evidence: `src/components/BookingsView/index.jsx`)
- Valet selection → Plan and add-on pricing: prices valet (evidence: `src/components/ValetPicker/index.jsx`)
- Valet selection → Valet distance calculation: calculates distance (evidence: `src/components/ValetPicker/index.jsx`)
- EV and wash services → Availability calculation: checks availability (evidence: `src/components/ServicesView/index.jsx`)
- EV and wash services → Plan and add-on pricing: checks plan perks (evidence: `src/components/ServicesView/index.jsx`)
- EV and wash services → Booking time rules: uses booking windows (evidence: `src/components/ServicesView/index.jsx`)
- Availability calculation → Booking time rules: uses time ranges (evidence: `src/utils/availability.js`)
- Account view → Booking time rules: formats booking times (evidence: `src/components/AccountView/index.jsx`)
- App state and routing → Booking time rules: checks booking conflicts (evidence: `src/App.jsx`)
