Skip to content

harismanazir/FitIndia

Repository files navigation

FitIndia - Premium Fitness Center Website

A complete, modern, and responsive React.js website for FitIndia gym featuring multiple pages, professional dark theme design, and comprehensive fitness information. Built with TypeScript, Tailwind CSS, and modern web development best practices.

🏋️ Features

  • Multi-page Navigation: Home, About, Programs, Trainers, Membership, and Contact pages
  • Responsive Design: Optimized for mobile, tablet, and desktop devices
  • Modern UI/UX: Dark theme with orange accents, smooth animations, and hover effects
  • Professional Content: Comprehensive information about gym facilities, programs, and trainers
  • Interactive Elements: Contact forms with validation, membership plans, and program showcases
  • Clean Code: Well-structured React components with extensive TypeScript comments
  • SEO Optimized: Meta tags, Open Graph tags, and semantic HTML structure

🎨 Design System

  • Color Scheme: Dark grey/black backgrounds with orange (#FF4500) highlights and white text
  • Typography: Poppins font family from Google Fonts for modern, readable text
  • Layout: Clean, professional design with ample spacing and clear visual hierarchy
  • Images: High-quality fitness and gym-related photography from Unsplash
  • Icons: Font Awesome icons for consistent visual language
  • Animations: Custom CSS animations for scroll indicators and hover effects

🛠️ Tech Stack

  • Frontend Framework: React 18 with TypeScript for type safety
  • Routing: Wouter for lightweight client-side navigation
  • Styling: Tailwind CSS with custom design system and CSS variables
  • UI Components: shadcn/ui component library with custom styling
  • State Management: React hooks (useState, useEffect) for local state
  • Form Handling: Controlled components with client-side validation
  • Build Tool: Vite for fast development and optimized production builds
  • Development: Hot Module Replacement (HMR) for instant updates

📁 Project Structure

fitindia/
├── client/                          # Frontend React application
│   ├── src/
│   │   ├── components/              # Reusable UI components
│   │   │   ├── Layout.tsx          # Main layout wrapper with nav/footer
│   │   │   ├── Navigation.tsx      # Sticky navigation with mobile menu
│   │   │   └── Footer.tsx          # Site footer with links and info
│   │   ├── pages/                  # Individual page components
│   │   │   ├── Home.tsx           # Landing page with hero section
│   │   │   ├── About.tsx          # Company info and facilities
│   │   │   ├── Programs.tsx       # Fitness programs showcase
│   │   │   ├── Trainers.tsx       # Trainer profiles and expertise
│   │   │   ├── Membership.tsx     # Pricing plans and benefits
│   │   │   └── Contact.tsx        # Contact form and location info
│   │   ├── data/                   # Static data files
│   │   │   ├── programs.ts        # Fitness program information
│   │   │   ├── trainers.ts        # Trainer profiles and specialties
│   │   │   └── membership.ts      # Membership plans and pricing
│   │   ├── hooks/                  # Custom React hooks
│   │   ├── lib/                    # Utility functions and configs
│   │   ├── App.tsx                # Main app component with routing
│   │   ├── main.tsx               # React DOM rendering entry point
│   │   └── index.css              # Global styles and custom CSS
│   └── index.html                  # HTML template with meta tags
├── server/                         # Backend Express server (optional)
├── tailwind.config.ts              # Tailwind CSS configuration
├── package.json                    # Dependencies and scripts
└── README.md                       # This documentation file

🚀 Getting Started

Prerequisites

  • Node.js: Version 16 or higher
  • npm: Comes with Node.js (or you can use yarn/pnpm)

Installation Steps

  1. Clone or download the project

    # If you have the project files
    cd fitindia-gym-website
  2. Install dependencies

    npm install

    This will install all required packages including:

    • React 18 and React DOM

    • TypeScript for type safety

    • Tailwind CSS for styling

    • Vite for fast development

    • Wouter for routing

    • All other dependencies listed in package.json

  3. Start the development server

    npm run dev

    This will:

    • Start the Vite development server
    • Enable hot module replacement (HMR)
    • Open your default browser to view the site
    • The site will be available at http://localhost:5173
  4. View the website

    • Open your browser and navigate to the provided URL
    • The website should load with the FitIndia homepage
    • Navigate between pages using the top navigation menu

Development Commands

# Start development server with hot reload
npm run dev

# Build for production
npm run build

# Preview production build locally  
npm run preview

# Type check TypeScript files
npm run type-check

# Lint code for errors and style issues
npm run lint

📱 Pages Overview

1. Home Page (/)

  • Hero Section: Full-screen background image with inspiring call-to-action
  • Quick Stats: Member count, trainers, programs, and years of excellence
  • Featured Programs: Preview of most popular fitness programs
  • Scroll Indicator: Animated arrow encouraging users to explore

2. About Page (/about)

  • Company Overview: Mission, vision, and founding story
  • Facilities Showcase: High-quality images of gym equipment and spaces
  • Core Values: Community, excellence, and wellness pillars
  • History Timeline: Growth from single location to fitness community

3. Programs Page (/programs)

  • Program Cards: All 8+ fitness programs with images and descriptions
  • Benefits Lists: Specific health and fitness benefits for each program
  • Difficulty Levels: Beginner to Advanced level indicators
  • Duration Info: Session lengths and time commitments

4. Trainers Page (/trainers)

  • Trainer Profiles: Professional photos and detailed biographies
  • Expertise Areas: Specializations and certification credentials
  • Experience Levels: Years of experience and background information
  • Social Links: Instagram and LinkedIn profile connections

5. Membership Page (/membership)

  • Pricing Tiers: Monthly, Quarterly (Most Popular), and Yearly plans
  • Feature Comparison: Detailed breakdown of what's included
  • Money-Back Guarantee: 30-day satisfaction guarantee
  • FAQ Section: Common questions about memberships and policies

6. Contact Page (/contact)

  • Contact Form: Validated form with name, email, program interest, and message
  • Location Info: Complete address, phone numbers, email, and hours
  • Map Placeholder: Space for Google Maps integration
  • Free Services: Information about gym tours, consultations, and Q&A

🎯 Key Features Explained

Responsive Design

  • Mobile-First Approach: Designed for mobile devices, then enhanced for tablets and desktops
  • Breakpoint System: Uses Tailwind's responsive breakpoints (sm, md, lg, xl)
  • Mobile Navigation: Hamburger menu for mobile devices with smooth animations
  • Flexible Layouts: CSS Grid and Flexbox for adaptable content arrangement

Form Validation

  • Client-Side Validation: Real-time validation for required fields
  • User Feedback: Toast notifications for success and error states
  • Controlled Components: React state manages all form inputs
  • Accessibility: Proper labels, focus states, and keyboard navigation

Performance Optimizations

  • Image Optimization: Responsive images from Unsplash with appropriate sizing
  • Code Splitting: Vite automatically splits code for faster loading
  • CSS Optimization: Tailwind purges unused CSS in production builds
  • Font Loading: Google Fonts loaded efficiently with display=swap

🎨 Customization Guide

Colors

Edit the CSS variables in client/src/index.css:

:root {
  --primary: hsl(0, 0%, 6%);        /* Main background */
  --secondary: hsl(0, 0%, 10%);     /* Card backgrounds */
  --accent: hsl(16, 100%, 50%);     /* Orange highlights */
  --accent-light: hsl(16, 100%, 60%); /* Hover effects */
  --text-muted: hsl(0, 0%, 63%);    /* Secondary text */
}

Content

  • Programs: Edit client/src/data/programs.ts to add/modify fitness programs
  • Trainers: Update client/src/data/trainers.ts with new trainer profiles
  • Membership: Modify client/src/data/membership.ts for pricing changes
  • Images: Replace Unsplash URLs with your own professional gym photos

Styling

  • Global Styles: Modify client/src/index.css for site-wide changes
  • Component Styles: Each component uses Tailwind classes for styling
  • Custom Animations: Add new animations in the CSS file's animation section

🔧 Technical Notes

TypeScript

  • All components are fully typed for better development experience
  • Interface definitions in data files ensure type safety
  • Props and state are properly typed throughout the application

Accessibility

  • Semantic HTML: Proper heading hierarchy and landmark elements
  • ARIA Labels: Screen reader friendly labels and descriptions
  • Keyboard Navigation: All interactive elements are keyboard accessible
  • Color Contrast: High contrast ratios for readability

Browser Support

  • Modern Browsers: Chrome, Firefox, Safari, Edge (last 2 versions)
  • Mobile Browsers: iOS Safari, Chrome Mobile, Samsung Internet
  • Graceful Degradation: Core functionality works without JavaScript

🚀 Deployment Options

Vercel (Recommended)

  1. Push code to GitHub repository
  2. Connect GitHub repo to Vercel
  3. Vercel automatically detects Vite and deploys

Netlify

  1. Build the project: npm run build
  2. Upload the dist folder to Netlify
  3. Configure redirects for client-side routing

Traditional Hosting

  1. Run npm run build to create production files
  2. Upload contents of dist folder to web server
  3. Configure server to serve index.html for all routes

📞 Support

If you need help with the website:

  • Check the commented code - every component has detailed explanations
  • Review this README for setup and customization instructions
  • All components use consistent patterns for easy modification
  • Data files are clearly structured and documented

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors