How ekthar/manjal works
1. This repository is a Vite-based React + TypeScript single-page marketing site, likely for a medical/wellness brand. It is entirely frontend-focused: there is no backend, API layer, or database code in the repo.
2. The application entry path is the standard Vite flow: index.html loads src/main.tsx, which mounts the React app from src/index.tsx and applies the global stylesheet from src/index.css. This is the root of the runtime architecture.
3. The UI is assembled from a set of feature-oriented components in src/components. The main page appears to be composed of themed sections such as Hero, Doctors, AllServices, Therapies, Consultation, HospitalDetails, AboutGallery, and ChakraList, plus shared navigation/utility pieces like Navbar, FloatingDock, ScrollReveal, SectionDivider, LoadingIntro, FloatingParticles, and MeditatingSilhouette.
4. The page structure is likely one long scroll experience with anchored sections rather than route-based navigation. The presence of Navbar, FloatingDock, and ScrollReveal suggests the main interactions are section jumping, animated reveals on scroll, and persistent quick-navigation controls.
5. Content and configuration are separated from presentation. src/constants.ts likely holds copy, section labels, and shared data used by multiple components, while src/types.ts defines the shared TypeScript shapes for that content. This keeps the section components mostly presentational.
6. Visual styling is split across Tailwind and targeted CSS. Tailwind is configured in tailwind.config.cjs, PostCSS in postcss.config.cjs, and global styling lives in src/index.css. A dedicated src/styles/gallery.css indicates the gallery has custom layout/animation rules beyond the general site styles.
7. The assets are heavily static and prebuilt. public/ contains the custom font (Priestacy.otf), treatment assets, and a large responsive gallery in AVIF formats at multiple sizes (-400, -800, -1200). That implies the site is optimized for fast asset delivery and image-responsive presentation without server-side processing.
8. Media preparation is handled by repo scripts rather than runtime code. scripts/prepare-gallery-images.mjs and scripts/optimize-svgs.mjs suggest a build-time content pipeline that converts/optimizes gallery media and SVG assets before they are served from public/.
9. The public/gallery-src and public/gallery split shows a source/derived asset boundary. The source directory appears to hold original media, while public/gallery contains the generated web-ready variants consumed by the gallery UI.
10. The build/tooling layer is standard modern frontend tooling: Vite for bundling/dev server, TypeScript for type safety, Tailwind/PostCSS for styling, and ESLint for code quality. The architecture is optimized for local static development and production asset bundling, not for server orchestration.
11. metadata.json and the asset-heavy public structure suggest the site likely includes SEO/social metadata and image-driven sections, but those are still delivered as static files from the frontend build.
12. Overall architecture: a static, componentized React presentation site with a strong content/asset pipeline. The main data flow is from constants/types and preprocessed public assets into section components, then into a single scrollable UI with animation and navigation helpers.
Main entry points: index.tsx index.tsx · AboutGallery.tsx About Gallery · main.tsx main.tsx · constants.ts constants.ts
Components 31
Runtime
Vite entry and React app composition
- index.html · Vite entry document that loads the React bundle
index.html - main.tsx · Browser entry that mounts the application
src/main.tsx - index.tsx · Top-level React composition for the single-page experience
src/index.tsx
UI
Section components and shared presentation pieces
- Hero · Landing section and first visual impression
src/components/Hero.tsx - All Services · Overview of available offerings
src/components/AllServices.tsx - Doctors · Provider and team presentation
src/components/Doctors.tsx - Therapies · Therapy and treatment content block
src/components/Therapies.tsx - Consultation · Appointment and consultation call to action
src/components/Consultation.tsx - Hospital Details · Facility and location information
src/components/HospitalDetails.tsx - About Gallery · Image-driven gallery and brand storytelling
src/components/AboutGallery.tsx - Chakra List · Specialized content list for the site narrative
src/components/ChakraList.tsx - Navbar · Primary section navigation
src/components/Navbar.tsx - Floating Dock · Persistent shortcut navigation for the long scroll page
src/components/FloatingDock.tsx - Scroll Reveal · Scroll-triggered reveal wrapper for sections
src/components/ScrollReveal.tsx - Loading Intro · Initial loading or entrance sequence
src/components/LoadingIntro.tsx - Floating Particles · Ambient background motion layer
src/components/FloatingParticles.tsx - Silhouette · Hero-area decorative illustration element
src/components/MeditatingSilhouette.tsx
Content
Static data, types, and styling
- constants.ts · Shared copy and section data consumed by the UI
src/constants.ts - types.ts · TypeScript shapes for structured site content
src/types.ts - index.css · Site-wide stylesheet layered with Tailwind
src/index.css - gallery.css · Custom styles for gallery layout and motion
src/styles/gallery.css
Assets
Prebuilt public media and source gallery inputs
- public/gallery · Responsive AVIF gallery variants served to the UI
public/gallery - gallery-src · Original gallery media used to generate public variants
public/gallery-src - treatments · Treatment imagery and supporting public media
public/assets/treatments - Priestacy.otf · Custom brand font shipped from public assets
public/Priestacy.otf
Tooling
Build, lint, and media preparation scripts
- prepare-gallery · Build-time gallery image preparation script
scripts/prepare-gallery-images.mjs - optimize-svgs · Build-time SVG optimization script
scripts/optimize-svgs.mjs - vite.config.ts · Vite bundling and dev-server configuration
vite.config.ts - tailwind.config.cjs · Tailwind theme and content configuration
tailwind.config.cjs - postcss.config.cjs · PostCSS pipeline configuration
postcss.config.cjs - eslint.config.js · Linting rules for the frontend codebase
eslint.config.js
Connections 31
- index.html → main.tsx: loads · HTML bootstraps the Vite React entry
- main.tsx → index.tsx: mounts · Main entry renders the app root
- index.tsx → Hero: composes · Root page includes the hero section
- index.tsx → All Services: composes · Root page includes the services section
- index.tsx → Doctors: composes · Root page includes the doctors section
- index.tsx → Therapies: composes · Root page includes the therapies section
- index.tsx → Consultation: composes · Root page includes the consultation section
- index.tsx → Hospital Details: composes · Root page includes facility details
- index.tsx → About Gallery: composes · Root page includes the gallery section
- index.tsx → Chakra List: composes · Root page includes the chakra content block
- index.tsx → Navbar: uses · Root page includes primary navigation
- index.tsx → Floating Dock: uses · Root page includes floating quick navigation
- index.tsx → Loading Intro: uses · Root page includes the loading intro
- index.tsx → Floating Particles: decorates · Background motion layer enhances the page
- index.tsx → Silhouette: decorates · Decorative art supports the hero section
- index.tsx → Scroll Reveal: wraps · Sections animate through scroll reveal
- index.tsx → constants.ts: reads · Page content is driven by shared constants
- index.tsx → index.css: styles · Application uses the global stylesheet
- About Gallery → public/gallery: renders · Gallery UI consumes generated responsive images
- About Gallery → gallery.css: styles · Gallery section uses dedicated CSS rules
- About Gallery → constants.ts: reads · Gallery content is sourced from shared data
- constants.ts → types.ts: typed by · Structured content follows shared TypeScript types
- public/gallery → gallery-src: generated from · Web-ready gallery assets are derived from source media
- prepare-gallery → gallery-src: processes · Script prepares original gallery inputs
- prepare-gallery → public/gallery: outputs · Script generates the responsive gallery variants
- optimize-svgs → treatments: processes · Script optimizes shipped asset files
- index.tsx → Priestacy.otf: loads · Application uses the bundled custom font
- vite.config.ts → main.tsx: bundles · Vite config targets the React entry
- tailwind.config.cjs → index.css: configures · Tailwind works with the global stylesheet
- postcss.config.cjs → index.css: processes · PostCSS transforms site styles
- eslint.config.js → index.tsx: checks · Linting covers the application source