feat: implement booking feature with service and time slot selection

This commit is contained in:
Danel Kungla
2025-09-03 10:04:00 +03:00
parent a587b222b9
commit f7514c698e
11 changed files with 306 additions and 14 deletions

View File

@@ -0,0 +1,18 @@
import { createContext } from 'react';
import { StoreProduct } from '@medusajs/types';
import { noop } from 'lodash';
const BookingContext = createContext<{
timeSlots: string[];
selectedService: StoreProduct | null;
setSelectedService: (selectedService: any) => void;
updateTimeSlots: (serviceId: number) => Promise<void>;
}>({
timeSlots: [],
selectedService: null,
setSelectedService: (_) => _,
updateTimeSlots: async (_) => noop(),
});
export { BookingContext };