From 1b506744913f503f47e8380e48247ab69ace7ba5 Mon Sep 17 00:00:00 2001 From: JeffEmmett <20747463-JeffEmmett@users.noreply.replit.com> Date: Wed, 21 May 2025 11:09:29 +0000 Subject: [PATCH] Show available Pilates classes without booking options or pricing Removes booking functionality and price display from ClassCard and ClassesSection components. Replit-Commit-Author: Agent Replit-Commit-Session-Id: 88cd88e4-2dbe-4df6-8c8a-7e38f13ef1ec Replit-Commit-Screenshot-Url: https://storage.googleapis.com/screenshot-production-us-central1/af8dabca-e746-4e53-9c29-d8d4d9cf30f5/6dde4ef6-6ad6-4713-b98b-6bd86ff25b19.jpg --- client/src/components/classes/class-card.tsx | 43 +------------------ .../components/classes/classes-section.tsx | 35 --------------- 2 files changed, 2 insertions(+), 76 deletions(-) diff --git a/client/src/components/classes/class-card.tsx b/client/src/components/classes/class-card.tsx index 3bea44f..e5e501f 100644 --- a/client/src/components/classes/class-card.tsx +++ b/client/src/components/classes/class-card.tsx @@ -1,44 +1,17 @@ import { Class } from "@shared/schema"; -import { useAuth } from "@/hooks/use-auth"; -import { useState } from "react"; -import { useToast } from "@/hooks/use-toast"; -import { useLocation } from "wouter"; import FadiaGroupClassImage from "../../assets/Fadia-15.jpg"; import FadiaSmallGroupClassImage from "../../assets/Fadia-156.jpg"; import FadiaPrivateClassImage from "../../assets/Fadia-132.jpg"; interface ClassCardProps { classData: Class; - onBookClick: (classId: number) => void; } -export function ClassCard({ classData, onBookClick }: ClassCardProps) { - const { user } = useAuth(); - const { toast } = useToast(); - const [_, setLocation] = useLocation(); - - const formatPrice = (price: number) => { - return `$${(price / 100).toFixed(2)}`; - }; - +export function ClassCard({ classData }: ClassCardProps) { const formatDuration = (minutes: number) => { return `${minutes} minutes`; }; - const handleBookNow = () => { - if (!user) { - toast({ - title: "Authentication required", - description: "Please login or sign up to book a class", - variant: "destructive" - }); - setLocation("/auth"); - return; - } - - onBookClick(classData.id); - }; - // Determine badge color based on class type const badgeColor = () => { switch (classData.classType) { @@ -49,11 +22,6 @@ export function ClassCard({ classData, onBookClick }: ClassCardProps) { } }; - // All buttons use teal as the primary color - const buttonColor = () => { - return "bg-teal text-white"; - }; - // Format class type for display const formatClassType = (type: string) => { switch (type) { @@ -91,18 +59,11 @@ export function ClassCard({ classData, onBookClick }: ClassCardProps) {
{classData.description}
-