Booking Block
Display available booking types (time blocks) for customers to browse and book.
Data BlockPreview
Grid Layout
Booking types in a responsive grid
Book a Session
List Layout
Compact list view
Selected Bookings
Only showing specific booking types
Properties
| Property | Type | Default | Description |
|---|---|---|---|
title | string | - | Optional heading above booking list |
source | 'all' | 'selected' | 'all' | Show all booking types or selected ones |
selectedTimeBlockIds | string[] | - | IDs of booking types to show |
layout | 'grid' | 'list' | 'grid' | Display layout style |
Data Dependencies
This block pulls booking type data from your space:
interface TimeBlock {
id: string
title: string
description: string
slug: string | null
coverImageSrc: string | null
shortDescription: string | null
}
Usage
// Grid layout showing all booking types
<BookingBlock
content={{
title: 'Book a Class',
source: 'all',
layout: 'grid',
}}
timeBlocks={bookingData}
/>
// List layout with selected items
<BookingBlock
content={{
source: 'selected',
selectedTimeBlockIds: ['class-1', 'class-2'],
layout: 'list',
}}
timeBlocks={bookingData}
/>
Best Practices
- Use cover images - Visual thumbnails increase engagement
- Write clear descriptions - Help customers choose the right option
- Grid for browsing - Use grid layout when you have 3+ options
- List for quick selection - Use list layout for simpler choices