# itsswayize/obsidian architecture

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

- Interactive diagram: https://gitdiagram.com/itsswayize/obsidian
- Repository: https://github.com/itsswayize/obsidian

## Overview

Obsidian Grooming Co. is an Angular barber-shop website. Customers discover the shop and its services, then book by choosing a service, barber, available date/time, and customer details; they can add a confirmed appointment to Google or Apple Calendar. The diagram includes the documented informational pages and shared navigation/promotion, plus local business data and availability. Source excerpts show the booking orchestration and several service calls; unsampled customer-form and calendar implementation details are not inferred.

Main entry points: [`src/app/app.routes.ts`](https://github.com/itsswayize/obsidian/blob/main/src/app/app.routes.ts) (Page Routes), [`src/app/features/booking/booking.ts`](https://github.com/itsswayize/obsidian/blob/main/src/app/features/booking/booking.ts) (Booking Flow), [`src/app/core/services/business-data.ts`](https://github.com/itsswayize/obsidian/blob/main/src/app/core/services/business-data.ts) (Shop Data), [`src/app/core/services/calendar.ts`](https://github.com/itsswayize/obsidian/blob/main/src/app/core/services/calendar.ts) (Calendar Export)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_site["Shop Website"]
  node_app["App Shell<br/>[app.ts]"]
  node_routes["Page Routes<br/>[app.routes.ts]"]
  node_home["Home<br/>[home.ts]"]
  node_services["Services Menu<br/>[services.ts]"]
  node_about["About &amp; Barbers<br/>[about.ts]"]
  node_contact["Contact &amp; Hours<br/>[contact.ts]"]
  node_terms["Terms<br/>[terms.ts]"]
  node_notfound["Not Found<br/>[not-found.ts]"]
end

subgraph group_booking["Appointment Booking"]
  node_booking["Booking Flow<br/>[booking.ts]"]
  node_state["Booking State<br/>[booking-state.ts]"]
  node_servicepick["Service Selector"]
  node_barberpick["Barber Selector<br/>[barber-selector.ts]"]
  node_datetime["Date &amp; Time"]
  node_customerform["Customer Details<br/>[customer-form.ts]"]
end

subgraph group_domain["Booking Domain"]
  node_availability["Slot Availability"]
  node_businessdata[("Shop Data<br/>[business-data.ts]")]
  node_models["Booking Models<br/>[booking.models.ts]"]
  node_calendar["Calendar Export<br/>[calendar.ts]"]
end

subgraph group_shared["Shared UI"]
  node_header["Navigation<br/>[header.ts]"]
  node_footer["Footer<br/>[footer.ts]"]
  node_promo["First-Visit Offer<br/>[promo-modal.ts]"]
end

node_visitor(("Customer"))
node_google(("Google Calendar"))
node_apple(("Apple Calendar"))

node_visitor -->|"opens pages"| node_routes
node_routes -->|"routes to"| node_home
node_routes -->|"routes to"| node_services
node_routes -->|"routes to"| node_about
node_routes -->|"routes to"| node_contact
node_routes -->|"routes to"| node_terms
node_routes -->|"routes to"| node_booking
node_routes -->|"routes to"| node_notfound
node_app -->|"hosts router"| node_routes
node_app -->|"renders"| node_header
node_app -->|"renders"| node_footer
node_home -->|"loads shop content"| node_businessdata
node_home -->|"renders"| node_promo
node_services -->|"loads services"| node_businessdata
node_about -->|"loads barbers"| node_businessdata
node_contact -->|"loads hours"| node_businessdata
node_booking -->|"renders"| node_servicepick
node_booking -->|"renders"| node_barberpick
node_booking -->|"renders"| node_datetime
node_booking -->|"renders"| node_customerform
node_booking -->|"updates steps"| node_state
node_servicepick -->|"loads services"| node_businessdata
node_barberpick -->|"loads barbers"| node_businessdata
node_datetime -->|"reads hours and bookings"| node_businessdata
node_datetime -->|"calculates slots"| node_availability
node_booking -->|"requests calendar export"| node_calendar
node_calendar -->|"opens event link"| node_google
node_calendar -->|"downloads ICS"| node_apple
node_businessdata -->|"uses domain types"| node_models
node_availability -->|"uses domain types"| node_models
node_calendar -->|"uses booking type"| node_models
node_state -->|"uses booking types"| node_models
node_visitor -->|"submits appointment"| node_booking

click node_app "https://github.com/itsswayize/obsidian/blob/main/src/app/app.ts"
click node_routes "https://github.com/itsswayize/obsidian/blob/main/src/app/app.routes.ts"
click node_home "https://github.com/itsswayize/obsidian/blob/main/src/app/features/home/home.ts"
click node_services "https://github.com/itsswayize/obsidian/blob/main/src/app/features/services/services.ts"
click node_about "https://github.com/itsswayize/obsidian/blob/main/src/app/features/about/about.ts"
click node_contact "https://github.com/itsswayize/obsidian/blob/main/src/app/features/contact/contact.ts"
click node_terms "https://github.com/itsswayize/obsidian/blob/main/src/app/features/terms/terms.ts"
click node_notfound "https://github.com/itsswayize/obsidian/blob/main/src/app/features/not-found/not-found.ts"
click node_booking "https://github.com/itsswayize/obsidian/blob/main/src/app/features/booking/booking.ts"
click node_state "https://github.com/itsswayize/obsidian/blob/main/src/app/features/booking/services/booking-state.ts"
click node_servicepick "https://github.com/itsswayize/obsidian/blob/main/src/app/features/booking/components/service-selector/service-selector.ts"
click node_barberpick "https://github.com/itsswayize/obsidian/blob/main/src/app/features/booking/components/barber-selector/barber-selector.ts"
click node_datetime "https://github.com/itsswayize/obsidian/blob/main/src/app/features/booking/components/date-time-selector/date-time-selector.ts"
click node_customerform "https://github.com/itsswayize/obsidian/blob/main/src/app/features/booking/components/customer-form/customer-form.ts"
click node_availability "https://github.com/itsswayize/obsidian/blob/main/src/app/core/services/booking-availability.ts"
click node_businessdata "https://github.com/itsswayize/obsidian/blob/main/src/app/core/services/business-data.ts"
click node_models "https://github.com/itsswayize/obsidian/blob/main/src/app/core/models/booking.models.ts"
click node_calendar "https://github.com/itsswayize/obsidian/blob/main/src/app/core/services/calendar.ts"
click node_header "https://github.com/itsswayize/obsidian/blob/main/src/app/shared/components/header/header.ts"
click node_footer "https://github.com/itsswayize/obsidian/blob/main/src/app/shared/components/footer/footer.ts"
click node_promo "https://github.com/itsswayize/obsidian/blob/main/src/app/shared/components/promo-modal/promo-modal.ts"

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_routes,node_home,node_services,node_about,node_contact,node_terms,node_notfound toneBlue
class node_booking,node_state,node_servicepick,node_barberpick,node_datetime,node_customerform toneAmber
class node_availability,node_businessdata,node_models,node_calendar toneMint
class node_header,node_footer,node_promo toneRose
class node_visitor,node_google,node_apple toneIndigo
```

## Components

### Shop Website

- [App Shell](https://github.com/itsswayize/obsidian/blob/main/src/app/app.ts): `src/app/app.ts`
- [Page Routes](https://github.com/itsswayize/obsidian/blob/main/src/app/app.routes.ts): `src/app/app.routes.ts`
- [Home](https://github.com/itsswayize/obsidian/blob/main/src/app/features/home/home.ts): `src/app/features/home/home.ts`
- [Services Menu](https://github.com/itsswayize/obsidian/blob/main/src/app/features/services/services.ts): `src/app/features/services/services.ts`
- [About & Barbers](https://github.com/itsswayize/obsidian/blob/main/src/app/features/about/about.ts): `src/app/features/about/about.ts`
- [Contact & Hours](https://github.com/itsswayize/obsidian/blob/main/src/app/features/contact/contact.ts): `src/app/features/contact/contact.ts`
- [Terms](https://github.com/itsswayize/obsidian/blob/main/src/app/features/terms/terms.ts): `src/app/features/terms/terms.ts`
- [Not Found](https://github.com/itsswayize/obsidian/blob/main/src/app/features/not-found/not-found.ts): `src/app/features/not-found/not-found.ts`

### Appointment Booking

- [Booking Flow](https://github.com/itsswayize/obsidian/blob/main/src/app/features/booking/booking.ts): `src/app/features/booking/booking.ts`
- [Booking State](https://github.com/itsswayize/obsidian/blob/main/src/app/features/booking/services/booking-state.ts): `src/app/features/booking/services/booking-state.ts`
- [Service Selector](https://github.com/itsswayize/obsidian/blob/main/src/app/features/booking/components/service-selector/service-selector.ts): `src/app/features/booking/components/service-selector/service-selector.ts`
- [Barber Selector](https://github.com/itsswayize/obsidian/blob/main/src/app/features/booking/components/barber-selector/barber-selector.ts): `src/app/features/booking/components/barber-selector/barber-selector.ts`
- [Date & Time](https://github.com/itsswayize/obsidian/blob/main/src/app/features/booking/components/date-time-selector/date-time-selector.ts): `src/app/features/booking/components/date-time-selector/date-time-selector.ts`
- [Customer Details](https://github.com/itsswayize/obsidian/blob/main/src/app/features/booking/components/customer-form/customer-form.ts): `src/app/features/booking/components/customer-form/customer-form.ts`

### Booking Domain

- [Slot Availability](https://github.com/itsswayize/obsidian/blob/main/src/app/core/services/booking-availability.ts): `src/app/core/services/booking-availability.ts`
- [Shop Data](https://github.com/itsswayize/obsidian/blob/main/src/app/core/services/business-data.ts): `src/app/core/services/business-data.ts`
- [Booking Models](https://github.com/itsswayize/obsidian/blob/main/src/app/core/models/booking.models.ts): `src/app/core/models/booking.models.ts`
- [Calendar Export](https://github.com/itsswayize/obsidian/blob/main/src/app/core/services/calendar.ts): `src/app/core/services/calendar.ts`

### Shared UI

- [Navigation](https://github.com/itsswayize/obsidian/blob/main/src/app/shared/components/header/header.ts): `src/app/shared/components/header/header.ts`
- [Footer](https://github.com/itsswayize/obsidian/blob/main/src/app/shared/components/footer/footer.ts): `src/app/shared/components/footer/footer.ts`
- [First-Visit Offer](https://github.com/itsswayize/obsidian/blob/main/src/app/shared/components/promo-modal/promo-modal.ts): `src/app/shared/components/promo-modal/promo-modal.ts`

### Other components

- **Customer**
- **Google Calendar**
- **Apple Calendar**

## Connections

- Customer → Page Routes: opens pages (evidence: `src/app/app.routes.ts`)
- Page Routes → Home: routes to (evidence: `src/app/app.routes.ts`)
- Page Routes → Services Menu: routes to (evidence: `src/app/app.routes.ts`)
- Page Routes → About & Barbers: routes to (evidence: `src/app/app.routes.ts`)
- Page Routes → Contact & Hours: routes to (evidence: `src/app/app.routes.ts`)
- Page Routes → Terms: routes to (evidence: `src/app/app.routes.ts`)
- Page Routes → Booking Flow: routes to (evidence: `src/app/app.routes.ts`)
- Page Routes → Not Found: routes to (evidence: `src/app/app.routes.ts`)
- App Shell → Page Routes: hosts router
- App Shell → Navigation: renders (evidence: `src/app/app.ts`)
- App Shell → Footer: renders (evidence: `src/app/app.ts`)
- Home → Shop Data: loads shop content (evidence: `src/app/features/home/home.ts`)
- Home → First-Visit Offer: renders (evidence: `src/app/features/home/home.ts`)
- Services Menu → Shop Data: loads services (evidence: `src/app/features/services/services.ts`)
- About & Barbers → Shop Data: loads barbers (evidence: `src/app/features/about/about.ts`)
- Contact & Hours → Shop Data: loads hours (evidence: `src/app/features/contact/contact.ts`)
- Booking Flow → Service Selector: renders (evidence: `src/app/features/booking/booking.ts`)
- Booking Flow → Barber Selector: renders (evidence: `src/app/features/booking/booking.ts`)
- Booking Flow → Date & Time: renders (evidence: `src/app/features/booking/booking.ts`)
- Booking Flow → Customer Details: renders (evidence: `src/app/features/booking/booking.ts`)
- Booking Flow → Booking State: updates steps (evidence: `src/app/features/booking/booking.ts`)
- Service Selector → Shop Data: loads services (evidence: `src/app/features/booking/components/service-selector/service-selector.ts`)
- Barber Selector → Shop Data: loads barbers (evidence: `src/app/features/booking/components/barber-selector/barber-selector.ts`)
- Date & Time → Shop Data: reads hours and bookings (evidence: `src/app/features/booking/components/date-time-selector/date-time-selector.ts`)
- Date & Time → Slot Availability: calculates slots (evidence: `src/app/features/booking/components/date-time-selector/date-time-selector.ts`)
- Booking Flow → Calendar Export: requests calendar export (evidence: `src/app/features/booking/booking.ts`)
- Calendar Export → Google Calendar: opens event link
- Calendar Export → Apple Calendar: downloads ICS
- Shop Data → Booking Models: uses domain types (evidence: `src/app/core/services/business-data.ts`)
- Slot Availability → Booking Models: uses domain types (evidence: `src/app/core/services/booking-availability.ts`)
- Calendar Export → Booking Models: uses booking type (evidence: `src/app/core/services/calendar.ts`)
- Booking State → Booking Models: uses booking types (evidence: `src/app/features/booking/services/booking-state.ts`)
- Customer → Booking Flow: submits appointment (evidence: `src/app/features/booking/booking.ts`)
