Replace entire repo content with code from /root/shahikitchen-google/

This commit is contained in:
root
2026-07-03 02:51:15 +00:00
parent c8b7dc95e4
commit 8ccf033329
79 changed files with 7611 additions and 439 deletions
+4
View File
@@ -1,8 +1,12 @@
import type { OrderLine } from '../shared/order-line';
import type { BookingMode, EventTypeId } from './event-types';
export type BranchLocation = 'askim' | 'backaplan' | '';
export interface BookingDetails {
bookingMode: BookingMode;
eventType: EventTypeId | '';
eventTypeOther: string;
location: BranchLocation;
date: string;
time: string;
+76
View File
@@ -0,0 +1,76 @@
export type BookingMode = 'table' | 'event';
export type EventTypeId =
| 'birthday'
| 'wedding'
| 'engagement'
| 'anniversary'
| 'baby-shower'
| 'graduation'
| 'office-party'
| 'corporate-lunch'
| 'family-gathering'
| 'religious-celebration'
| 'farewell'
| 'retirement'
| 'bridal-shower'
| 'holiday-party'
| 'other';
export interface BookingEventType {
id: EventTypeId;
icon:
| 'cake'
| 'heart'
| 'gem'
| 'sparkles'
| 'baby'
| 'graduation-cap'
| 'briefcase'
| 'users'
| 'party-popper'
| 'plane'
| 'award'
| 'gift'
| 'tree-pine'
| 'more-horizontal';
}
export const BOOKING_EVENT_TYPES: readonly BookingEventType[] = [
{ id: 'birthday', icon: 'cake' },
{ id: 'wedding', icon: 'heart' },
{ id: 'engagement', icon: 'gem' },
{ id: 'anniversary', icon: 'sparkles' },
{ id: 'baby-shower', icon: 'baby' },
{ id: 'graduation', icon: 'graduation-cap' },
{ id: 'office-party', icon: 'briefcase' },
{ id: 'corporate-lunch', icon: 'users' },
{ id: 'family-gathering', icon: 'users' },
{ id: 'religious-celebration', icon: 'sparkles' },
{ id: 'farewell', icon: 'plane' },
{ id: 'retirement', icon: 'award' },
{ id: 'bridal-shower', icon: 'gift' },
{ id: 'holiday-party', icon: 'tree-pine' },
{ id: 'other', icon: 'more-horizontal' },
] as const;
export const TABLE_GUEST_OPTIONS = ['1', '2', '3', '4', '5', '6', '7', '8', '9', '10'] as const;
export const EVENT_GUEST_OPTIONS = [
'2',
'3',
'4',
'5',
'6',
'7',
'8',
'9',
'10',
'10-15',
'16-25',
'26-40',
'41-60',
'61-80',
'81-100',
'100+',
] as const;
+7 -1
View File
@@ -1,12 +1,18 @@
import type { BookingDetails } from './entities';
export function isBookingComplete(booking: BookingDetails): boolean {
const hasEventType =
booking.bookingMode === 'table' ||
(booking.eventType !== '' &&
(booking.eventType !== 'other' || booking.eventTypeOther.trim().length > 0));
return !!(
booking.location &&
booking.date &&
booking.time &&
booking.guests &&
booking.name &&
booking.phone
booking.phone &&
hasEventType
);
}