@cimplify/sdk 0.21.0 → 0.22.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/advanced.d.mts +2 -2
- package/dist/advanced.d.ts +2 -2
- package/dist/{client-B8PO4NKN.d.mts → client-uvCOGdBp.d.ts} +14 -2
- package/dist/{client-DjrlvxW7.d.ts → client-v1NFqZFG.d.mts} +14 -2
- package/dist/index.d.mts +4 -4
- package/dist/index.d.ts +4 -4
- package/dist/{payment-CKqMU4xT.d.mts → payment-DazihbCY.d.mts} +1 -0
- package/dist/{payment-CKqMU4xT.d.ts → payment-DazihbCY.d.ts} +1 -0
- package/dist/{price-e4beObLZ.d.ts → price-5_L8WK6Q.d.ts} +1 -1
- package/dist/{price-BqV_DjjQ.d.mts → price-BcHVTqqu.d.mts} +1 -1
- package/dist/react.d.mts +83 -95
- package/dist/react.d.ts +83 -95
- package/dist/react.js +1035 -2489
- package/dist/react.mjs +1035 -2491
- package/dist/styles.css +1 -1
- package/dist/utils.d.mts +2 -2
- package/dist/utils.d.ts +2 -2
- package/package.json +1 -1
- package/registry/booking-card.json +1 -1
- package/registry/booking-page.json +1 -1
- package/registry/product-card.json +1 -1
- package/registry/service-card.json +1 -1
package/dist/react.d.mts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import React, { ReactNode } from 'react';
|
|
2
2
|
import { A as AdSlot, a as AdPosition, e as AdContextValue } from './ads-BxbWrwqp.mjs';
|
|
3
3
|
export { c as AdConfig, g as getVariantDisplayName } from './ads-BxbWrwqp.mjs';
|
|
4
|
-
import { C as CimplifyClient, a8 as ProcessCheckoutResult, aa as CheckoutStatus, ab as CheckoutStatusContext, bK as Location, bH as Business, k as ReorderResult, aR as OrderStatus, b2 as Order, d as QuoteBundleSelectionInput, Q as QuoteCompositeSelectionInput, P as PriceQuote, g as QuoteUiMessage, bX as Service,
|
|
5
|
-
import { J as Product, d as Pagination, h as CimplifyError, L as ProductWithDetails, a5 as Category, M as Money, b0 as BundleSelectionInput, av as ComponentSelectionInput, b3 as BundleSelectionData, b6 as CompositeSelectionData, a7 as Collection, aD as ProductTaxonomy, aE as TaxonomyWithChildren, aC as ProductTimeProfile, aH as Deal, aI as ProductDealInfo, aJ as DiscountValidation, ac as BundleSummary, aw as CompositePriceResult, y as CustomAttributeDefinition, G as PropertyFacet, bI as ProductBillingPlan, N as VariantView, W as VariantAxisWithValues, a as CurrencyCode, a1 as AddOnWithOptions, ah as BundleComponentView, aa as BundlePriceType, as as CompositeGroupView, bb as DisplayCart } from './payment-
|
|
6
|
-
import { P as ProductWithPrice } from './price-
|
|
4
|
+
import { C as CimplifyClient, a8 as ProcessCheckoutResult, aa as CheckoutStatus, ab as CheckoutStatusContext, bK as Location, bH as Business, k as ReorderResult, aR as OrderStatus, b2 as Order, d as QuoteBundleSelectionInput, Q as QuoteCompositeSelectionInput, P as PriceQuote, g as QuoteUiMessage, bX as Service, c0 as AvailableSlot, c1 as DayAvailability, c6 as CustomerBooking, cc as CancelBookingResult, w as ActivityStateResponse, u as SessionMessage, x as ActivityRecommendation, E as DeliveryFeeResponse, cO as FxRateResponse, bR as StorefrontBootstrap, Y as ElementsOptions, d0 as AuthenticatedData, cY as AddressInfo, cZ as PaymentMethodInfo, K as CimplifyElements, d2 as ElementsCheckoutResult, a7 as ProcessCheckoutOptions, b1 as LineItem, bY as Staff, bP as Room } from './client-v1NFqZFG.mjs';
|
|
5
|
+
import { J as Product, d as Pagination, h as CimplifyError, L as ProductWithDetails, a5 as Category, M as Money, b0 as BundleSelectionInput, av as ComponentSelectionInput, b3 as BundleSelectionData, b6 as CompositeSelectionData, a7 as Collection, aD as ProductTaxonomy, aE as TaxonomyWithChildren, aC as ProductTimeProfile, aH as Deal, aI as ProductDealInfo, aJ as DiscountValidation, ac as BundleSummary, aw as CompositePriceResult, y as CustomAttributeDefinition, G as PropertyFacet, bI as ProductBillingPlan, N as VariantView, W as VariantAxisWithValues, a as CurrencyCode, a1 as AddOnWithOptions, ah as BundleComponentView, aa as BundlePriceType, as as CompositeGroupView, bb as DisplayCart } from './payment-DazihbCY.mjs';
|
|
6
|
+
import { P as ProductWithPrice } from './price-BcHVTqqu.mjs';
|
|
7
7
|
import { ClassValue } from 'clsx';
|
|
8
8
|
|
|
9
9
|
interface UserIdentity {
|
|
@@ -132,7 +132,12 @@ declare function useCimplify(): CimplifyContextValue;
|
|
|
132
132
|
declare function useOptionalCimplify(): CimplifyContextValue | null;
|
|
133
133
|
declare function useCimplifyClient(): CimplifyClientContextValue;
|
|
134
134
|
|
|
135
|
-
interface
|
|
135
|
+
interface CachedQueryBaseOptions {
|
|
136
|
+
enabled?: boolean;
|
|
137
|
+
client?: CimplifyClient;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
interface UseProductsOptions extends CachedQueryBaseOptions {
|
|
136
141
|
category?: string;
|
|
137
142
|
taxonomy?: string;
|
|
138
143
|
search?: string;
|
|
@@ -146,8 +151,6 @@ interface UseProductsOptions {
|
|
|
146
151
|
max_price?: number;
|
|
147
152
|
page?: number;
|
|
148
153
|
properties?: Record<string, string>;
|
|
149
|
-
enabled?: boolean;
|
|
150
|
-
client?: CimplifyClient;
|
|
151
154
|
}
|
|
152
155
|
interface UseProductsResult {
|
|
153
156
|
products: Product[];
|
|
@@ -160,9 +163,7 @@ interface UseProductsResult {
|
|
|
160
163
|
}
|
|
161
164
|
declare function useProducts(options?: UseProductsOptions): UseProductsResult;
|
|
162
165
|
|
|
163
|
-
interface UseProductOptions {
|
|
164
|
-
enabled?: boolean;
|
|
165
|
-
client?: CimplifyClient;
|
|
166
|
+
interface UseProductOptions extends CachedQueryBaseOptions {
|
|
166
167
|
}
|
|
167
168
|
interface UseProductResult {
|
|
168
169
|
product: ProductWithDetails | null;
|
|
@@ -172,9 +173,7 @@ interface UseProductResult {
|
|
|
172
173
|
}
|
|
173
174
|
declare function useProduct(slugOrId: string | null | undefined, options?: UseProductOptions): UseProductResult;
|
|
174
175
|
|
|
175
|
-
interface UseCategoriesOptions {
|
|
176
|
-
enabled?: boolean;
|
|
177
|
-
client?: CimplifyClient;
|
|
176
|
+
interface UseCategoriesOptions extends CachedQueryBaseOptions {
|
|
178
177
|
}
|
|
179
178
|
interface UseCategoriesResult {
|
|
180
179
|
categories: Category[];
|
|
@@ -230,6 +229,7 @@ interface AddToCartOptions {
|
|
|
230
229
|
scheduledStart?: string;
|
|
231
230
|
scheduledEnd?: string;
|
|
232
231
|
staffId?: string;
|
|
232
|
+
resourceId?: string;
|
|
233
233
|
}
|
|
234
234
|
interface UseCartOptions {
|
|
235
235
|
client?: CimplifyClient;
|
|
@@ -282,9 +282,7 @@ interface UseLocationsResult {
|
|
|
282
282
|
}
|
|
283
283
|
declare function useLocations(options?: UseLocationsOptions): UseLocationsResult;
|
|
284
284
|
|
|
285
|
-
interface UseCollectionsOptions {
|
|
286
|
-
client?: CimplifyClient;
|
|
287
|
-
enabled?: boolean;
|
|
285
|
+
interface UseCollectionsOptions extends CachedQueryBaseOptions {
|
|
288
286
|
}
|
|
289
287
|
interface UseCollectionsResult {
|
|
290
288
|
collections: Collection[];
|
|
@@ -294,9 +292,7 @@ interface UseCollectionsResult {
|
|
|
294
292
|
}
|
|
295
293
|
declare function useCollections(options?: UseCollectionsOptions): UseCollectionsResult;
|
|
296
294
|
|
|
297
|
-
interface UseCollectionOptions {
|
|
298
|
-
client?: CimplifyClient;
|
|
299
|
-
enabled?: boolean;
|
|
295
|
+
interface UseCollectionOptions extends CachedQueryBaseOptions {
|
|
300
296
|
}
|
|
301
297
|
interface UseCollectionResult {
|
|
302
298
|
collection: Collection | null;
|
|
@@ -357,10 +353,8 @@ interface UseQuoteResult {
|
|
|
357
353
|
}
|
|
358
354
|
declare function useQuote(input: UseQuoteInput | null | undefined, options?: UseQuoteOptions): UseQuoteResult;
|
|
359
355
|
|
|
360
|
-
interface UseTaxonomiesOptions {
|
|
356
|
+
interface UseTaxonomiesOptions extends CachedQueryBaseOptions {
|
|
361
357
|
parentId?: string;
|
|
362
|
-
enabled?: boolean;
|
|
363
|
-
client?: CimplifyClient;
|
|
364
358
|
}
|
|
365
359
|
interface UseTaxonomiesResult {
|
|
366
360
|
taxonomies: ProductTaxonomy[];
|
|
@@ -370,9 +364,7 @@ interface UseTaxonomiesResult {
|
|
|
370
364
|
}
|
|
371
365
|
declare function useTaxonomies(options?: UseTaxonomiesOptions): UseTaxonomiesResult;
|
|
372
366
|
|
|
373
|
-
interface UseTaxonomyOptions {
|
|
374
|
-
enabled?: boolean;
|
|
375
|
-
client?: CimplifyClient;
|
|
367
|
+
interface UseTaxonomyOptions extends CachedQueryBaseOptions {
|
|
376
368
|
}
|
|
377
369
|
interface UseTaxonomyResult {
|
|
378
370
|
taxonomy: TaxonomyWithChildren | null;
|
|
@@ -382,9 +374,7 @@ interface UseTaxonomyResult {
|
|
|
382
374
|
}
|
|
383
375
|
declare function useTaxonomy(id: string, options?: UseTaxonomyOptions): UseTaxonomyResult;
|
|
384
376
|
|
|
385
|
-
interface UseTaxonomyPathOptions {
|
|
386
|
-
enabled?: boolean;
|
|
387
|
-
client?: CimplifyClient;
|
|
377
|
+
interface UseTaxonomyPathOptions extends CachedQueryBaseOptions {
|
|
388
378
|
}
|
|
389
379
|
interface UseTaxonomyPathResult {
|
|
390
380
|
path: ProductTaxonomy[];
|
|
@@ -394,9 +384,7 @@ interface UseTaxonomyPathResult {
|
|
|
394
384
|
}
|
|
395
385
|
declare function useTaxonomyPath(id: string, options?: UseTaxonomyPathOptions): UseTaxonomyPathResult;
|
|
396
386
|
|
|
397
|
-
interface UseProductSchedulesOptions {
|
|
398
|
-
enabled?: boolean;
|
|
399
|
-
client?: CimplifyClient;
|
|
387
|
+
interface UseProductSchedulesOptions extends CachedQueryBaseOptions {
|
|
400
388
|
}
|
|
401
389
|
interface UseProductSchedulesResult {
|
|
402
390
|
schedules: ProductTimeProfile[];
|
|
@@ -406,10 +394,8 @@ interface UseProductSchedulesResult {
|
|
|
406
394
|
}
|
|
407
395
|
declare function useProductSchedules(productId: string, options?: UseProductSchedulesOptions): UseProductSchedulesResult;
|
|
408
396
|
|
|
409
|
-
interface UseProductAvailabilityOptions {
|
|
397
|
+
interface UseProductAvailabilityOptions extends CachedQueryBaseOptions {
|
|
410
398
|
locationId?: string;
|
|
411
|
-
enabled?: boolean;
|
|
412
|
-
client?: CimplifyClient;
|
|
413
399
|
}
|
|
414
400
|
interface UseProductAvailabilityResult {
|
|
415
401
|
isAvailable: boolean | null;
|
|
@@ -420,10 +406,8 @@ interface UseProductAvailabilityResult {
|
|
|
420
406
|
}
|
|
421
407
|
declare function useProductAvailability(productId: string, options?: UseProductAvailabilityOptions): UseProductAvailabilityResult;
|
|
422
408
|
|
|
423
|
-
interface UseDealsOptions {
|
|
409
|
+
interface UseDealsOptions extends CachedQueryBaseOptions {
|
|
424
410
|
locationId?: string;
|
|
425
|
-
enabled?: boolean;
|
|
426
|
-
client?: CimplifyClient;
|
|
427
411
|
}
|
|
428
412
|
interface UseDealsResult {
|
|
429
413
|
deals: Deal[];
|
|
@@ -433,9 +417,7 @@ interface UseDealsResult {
|
|
|
433
417
|
}
|
|
434
418
|
declare function useDeals(options?: UseDealsOptions): UseDealsResult;
|
|
435
419
|
|
|
436
|
-
interface UseProductsOnSaleOptions {
|
|
437
|
-
enabled?: boolean;
|
|
438
|
-
client?: CimplifyClient;
|
|
420
|
+
interface UseProductsOnSaleOptions extends CachedQueryBaseOptions {
|
|
439
421
|
}
|
|
440
422
|
interface UseProductsOnSaleResult {
|
|
441
423
|
products: ProductDealInfo[];
|
|
@@ -445,9 +427,7 @@ interface UseProductsOnSaleResult {
|
|
|
445
427
|
}
|
|
446
428
|
declare function useProductsOnSale(options?: UseProductsOnSaleOptions): UseProductsOnSaleResult;
|
|
447
429
|
|
|
448
|
-
interface UseProductDealsOptions {
|
|
449
|
-
enabled?: boolean;
|
|
450
|
-
client?: CimplifyClient;
|
|
430
|
+
interface UseProductDealsOptions extends CachedQueryBaseOptions {
|
|
451
431
|
}
|
|
452
432
|
interface UseProductDealsResult {
|
|
453
433
|
deals: Deal[];
|
|
@@ -467,9 +447,7 @@ interface UseValidateDiscountResult {
|
|
|
467
447
|
}
|
|
468
448
|
declare function useValidateDiscount(options?: UseValidateDiscountOptions): UseValidateDiscountResult;
|
|
469
449
|
|
|
470
|
-
interface UseBundlesOptions {
|
|
471
|
-
enabled?: boolean;
|
|
472
|
-
client?: CimplifyClient;
|
|
450
|
+
interface UseBundlesOptions extends CachedQueryBaseOptions {
|
|
473
451
|
}
|
|
474
452
|
interface UseBundlesResult {
|
|
475
453
|
bundles: BundleSummary[];
|
|
@@ -498,11 +476,9 @@ interface UseProductPriceResult {
|
|
|
498
476
|
}
|
|
499
477
|
declare function useProductPrice(input: UseProductPriceInput): UseProductPriceResult;
|
|
500
478
|
|
|
501
|
-
interface UseOrdersOptions {
|
|
479
|
+
interface UseOrdersOptions extends CachedQueryBaseOptions {
|
|
502
480
|
status?: OrderStatus;
|
|
503
481
|
limit?: number;
|
|
504
|
-
enabled?: boolean;
|
|
505
|
-
client?: CimplifyClient;
|
|
506
482
|
}
|
|
507
483
|
interface UseOrdersResult {
|
|
508
484
|
orders: Order[];
|
|
@@ -512,9 +488,7 @@ interface UseOrdersResult {
|
|
|
512
488
|
}
|
|
513
489
|
declare function useOrders(options?: UseOrdersOptions): UseOrdersResult;
|
|
514
490
|
|
|
515
|
-
interface UseServicesOptions {
|
|
516
|
-
enabled?: boolean;
|
|
517
|
-
client?: CimplifyClient;
|
|
491
|
+
interface UseServicesOptions extends CachedQueryBaseOptions {
|
|
518
492
|
}
|
|
519
493
|
interface UseServicesResult {
|
|
520
494
|
services: Service[];
|
|
@@ -524,10 +498,8 @@ interface UseServicesResult {
|
|
|
524
498
|
}
|
|
525
499
|
declare function useServices(options?: UseServicesOptions): UseServicesResult;
|
|
526
500
|
|
|
527
|
-
interface UseAvailableSlotsOptions {
|
|
501
|
+
interface UseAvailableSlotsOptions extends CachedQueryBaseOptions {
|
|
528
502
|
participantCount?: number;
|
|
529
|
-
enabled?: boolean;
|
|
530
|
-
client?: CimplifyClient;
|
|
531
503
|
}
|
|
532
504
|
interface UseAvailableSlotsResult {
|
|
533
505
|
slots: AvailableSlot[];
|
|
@@ -537,11 +509,9 @@ interface UseAvailableSlotsResult {
|
|
|
537
509
|
}
|
|
538
510
|
declare function useAvailableSlots(serviceId: string | null, date: string | null, options?: UseAvailableSlotsOptions): UseAvailableSlotsResult;
|
|
539
511
|
|
|
540
|
-
interface UseServiceAvailabilityOptions {
|
|
512
|
+
interface UseServiceAvailabilityOptions extends CachedQueryBaseOptions {
|
|
541
513
|
participantCount?: number;
|
|
542
514
|
locationId?: string;
|
|
543
|
-
enabled?: boolean;
|
|
544
|
-
client?: CimplifyClient;
|
|
545
515
|
}
|
|
546
516
|
interface UseServiceAvailabilityResult {
|
|
547
517
|
days: DayAvailability[];
|
|
@@ -551,10 +521,8 @@ interface UseServiceAvailabilityResult {
|
|
|
551
521
|
}
|
|
552
522
|
declare function useServiceAvailability(serviceId: string | null, startDate: string | null, endDate: string | null, options?: UseServiceAvailabilityOptions): UseServiceAvailabilityResult;
|
|
553
523
|
|
|
554
|
-
interface UseBookingsOptions {
|
|
524
|
+
interface UseBookingsOptions extends CachedQueryBaseOptions {
|
|
555
525
|
filter?: "all" | "upcoming" | "past";
|
|
556
|
-
enabled?: boolean;
|
|
557
|
-
client?: CimplifyClient;
|
|
558
526
|
}
|
|
559
527
|
interface UseBookingsResult {
|
|
560
528
|
bookings: CustomerBooking[];
|
|
@@ -565,10 +533,8 @@ interface UseBookingsResult {
|
|
|
565
533
|
}
|
|
566
534
|
declare function useBookings(options?: UseBookingsOptions): UseBookingsResult;
|
|
567
535
|
|
|
568
|
-
interface UseAttributeDefinitionsOptions {
|
|
569
|
-
enabled?: boolean;
|
|
536
|
+
interface UseAttributeDefinitionsOptions extends CachedQueryBaseOptions {
|
|
570
537
|
namespace?: string;
|
|
571
|
-
client?: CimplifyClient;
|
|
572
538
|
}
|
|
573
539
|
interface UseAttributeDefinitionsResult {
|
|
574
540
|
definitions: CustomAttributeDefinition[];
|
|
@@ -578,9 +544,7 @@ interface UseAttributeDefinitionsResult {
|
|
|
578
544
|
}
|
|
579
545
|
declare function useAttributeDefinitions(options?: UseAttributeDefinitionsOptions): UseAttributeDefinitionsResult;
|
|
580
546
|
|
|
581
|
-
interface UsePropertyFacetsOptions {
|
|
582
|
-
enabled?: boolean;
|
|
583
|
-
client?: CimplifyClient;
|
|
547
|
+
interface UsePropertyFacetsOptions extends CachedQueryBaseOptions {
|
|
584
548
|
category_id?: string;
|
|
585
549
|
product_type?: string;
|
|
586
550
|
}
|
|
@@ -647,9 +611,7 @@ interface UseVariantSelectorResult {
|
|
|
647
611
|
*/
|
|
648
612
|
declare function useVariantSelector(options: UseVariantSelectorOptions): UseVariantSelectorResult;
|
|
649
613
|
|
|
650
|
-
interface UseActivityStateOptions {
|
|
651
|
-
enabled?: boolean;
|
|
652
|
-
client?: CimplifyClient;
|
|
614
|
+
interface UseActivityStateOptions extends CachedQueryBaseOptions {
|
|
653
615
|
}
|
|
654
616
|
interface UseActivityStateResult {
|
|
655
617
|
state: ActivityStateResponse | null;
|
|
@@ -660,19 +622,11 @@ interface UseActivityStateResult {
|
|
|
660
622
|
refetch: () => Promise<void>;
|
|
661
623
|
dismissMessage: (code: string) => Promise<void>;
|
|
662
624
|
}
|
|
663
|
-
/**
|
|
664
|
-
* useActivityState — fetches the current session activity state including messages and intent.
|
|
665
|
-
*
|
|
666
|
-
* Wraps `client.activity.getState()` with global caching and in-flight dedup.
|
|
667
|
-
* Provides a `dismissMessage` action to dismiss individual messages and refetch.
|
|
668
|
-
*/
|
|
669
625
|
declare function useActivityState(options?: UseActivityStateOptions): UseActivityStateResult;
|
|
670
626
|
|
|
671
|
-
interface UseRecommendationsOptions {
|
|
627
|
+
interface UseRecommendationsOptions extends CachedQueryBaseOptions {
|
|
672
628
|
locationId?: string;
|
|
673
629
|
limit?: number;
|
|
674
|
-
enabled?: boolean;
|
|
675
|
-
client?: CimplifyClient;
|
|
676
630
|
}
|
|
677
631
|
interface UseRecommendationsResult {
|
|
678
632
|
recommendations: ActivityRecommendation[];
|
|
@@ -681,20 +635,12 @@ interface UseRecommendationsResult {
|
|
|
681
635
|
error: CimplifyError | null;
|
|
682
636
|
refetch: () => Promise<void>;
|
|
683
637
|
}
|
|
684
|
-
/**
|
|
685
|
-
* useRecommendations — fetches personalized product recommendations based on session activity.
|
|
686
|
-
*
|
|
687
|
-
* Wraps `client.activity.getRecommendations()` with global caching and in-flight dedup.
|
|
688
|
-
* Cache key includes locationId and limit.
|
|
689
|
-
*/
|
|
690
638
|
declare function useRecommendations(options?: UseRecommendationsOptions): UseRecommendationsResult;
|
|
691
639
|
|
|
692
|
-
interface UseDeliveryFeeOptions {
|
|
640
|
+
interface UseDeliveryFeeOptions extends CachedQueryBaseOptions {
|
|
693
641
|
latitude: number;
|
|
694
642
|
longitude: number;
|
|
695
643
|
country?: string;
|
|
696
|
-
enabled?: boolean;
|
|
697
|
-
client?: CimplifyClient;
|
|
698
644
|
}
|
|
699
645
|
interface UseDeliveryFeeResult {
|
|
700
646
|
fee: DeliveryFeeResponse | null;
|
|
@@ -704,11 +650,9 @@ interface UseDeliveryFeeResult {
|
|
|
704
650
|
}
|
|
705
651
|
declare function useDeliveryFee(options: UseDeliveryFeeOptions): UseDeliveryFeeResult;
|
|
706
652
|
|
|
707
|
-
interface UseFxRateOptions {
|
|
653
|
+
interface UseFxRateOptions extends CachedQueryBaseOptions {
|
|
708
654
|
from: CurrencyCode;
|
|
709
655
|
to: CurrencyCode;
|
|
710
|
-
enabled?: boolean;
|
|
711
|
-
client?: CimplifyClient;
|
|
712
656
|
}
|
|
713
657
|
interface UseFxRateResult {
|
|
714
658
|
rate: FxRateResponse | null;
|
|
@@ -718,9 +662,7 @@ interface UseFxRateResult {
|
|
|
718
662
|
}
|
|
719
663
|
declare function useFxRate(options: UseFxRateOptions): UseFxRateResult;
|
|
720
664
|
|
|
721
|
-
interface UseBootstrapOptions {
|
|
722
|
-
enabled?: boolean;
|
|
723
|
-
client?: CimplifyClient;
|
|
665
|
+
interface UseBootstrapOptions extends CachedQueryBaseOptions {
|
|
724
666
|
}
|
|
725
667
|
interface UseBootstrapResult {
|
|
726
668
|
bootstrap: StorefrontBootstrap | null;
|
|
@@ -2048,6 +1990,49 @@ interface DealsPageProps {
|
|
|
2048
1990
|
*/
|
|
2049
1991
|
declare function DealsPage({ title, deals: dealsProp, productsOnSale: productsOnSaleProp, products: productsProp, locationId, renderImage, columns, className, classNames, }: DealsPageProps): React.ReactElement;
|
|
2050
1992
|
|
|
1993
|
+
interface Resource {
|
|
1994
|
+
id: string;
|
|
1995
|
+
name: string;
|
|
1996
|
+
description?: string;
|
|
1997
|
+
capacity?: number;
|
|
1998
|
+
floor?: string;
|
|
1999
|
+
image_url?: string;
|
|
2000
|
+
is_available?: boolean;
|
|
2001
|
+
}
|
|
2002
|
+
interface ResourcePickerClassNames {
|
|
2003
|
+
root?: string;
|
|
2004
|
+
option?: string;
|
|
2005
|
+
image?: string;
|
|
2006
|
+
name?: string;
|
|
2007
|
+
description?: string;
|
|
2008
|
+
meta?: string;
|
|
2009
|
+
capacity?: string;
|
|
2010
|
+
floor?: string;
|
|
2011
|
+
unavailable?: string;
|
|
2012
|
+
}
|
|
2013
|
+
interface ResourcePickerProps {
|
|
2014
|
+
/** List of available resources (rooms, equipment, etc.). */
|
|
2015
|
+
resources: Resource[];
|
|
2016
|
+
/** Currently selected resource ID, or null for "Any available". */
|
|
2017
|
+
selectedResourceId?: string | null;
|
|
2018
|
+
/** Called when a resource is selected. Passes null for "Any available". */
|
|
2019
|
+
onResourceSelect?: (resourceId: string | null) => void;
|
|
2020
|
+
/** Show "Any available" option. Default: true. */
|
|
2021
|
+
showAnyOption?: boolean;
|
|
2022
|
+
/** Label for the "Any available" option. */
|
|
2023
|
+
anyLabel?: string;
|
|
2024
|
+
/** Custom image renderer (e.g. Next.js Image). */
|
|
2025
|
+
renderImage?: (props: {
|
|
2026
|
+
src: string;
|
|
2027
|
+
alt: string;
|
|
2028
|
+
className?: string;
|
|
2029
|
+
}) => React.ReactNode;
|
|
2030
|
+
className?: string;
|
|
2031
|
+
classNames?: ResourcePickerClassNames;
|
|
2032
|
+
}
|
|
2033
|
+
declare function roomToResource(room: Room): Resource;
|
|
2034
|
+
declare function ResourcePicker({ resources, selectedResourceId, onResourceSelect, showAnyOption, anyLabel, renderImage, className, classNames, }: ResourcePickerProps): React.ReactElement;
|
|
2035
|
+
|
|
2051
2036
|
interface BookingPageClassNames {
|
|
2052
2037
|
root?: string;
|
|
2053
2038
|
header?: string;
|
|
@@ -2063,6 +2048,7 @@ interface BookingPageClassNames {
|
|
|
2063
2048
|
rescheduleInfo?: string;
|
|
2064
2049
|
depositInfo?: string;
|
|
2065
2050
|
cancellationPolicy?: string;
|
|
2051
|
+
resourceStep?: string;
|
|
2066
2052
|
}
|
|
2067
2053
|
interface BookingPageProps {
|
|
2068
2054
|
/** The service being booked. */
|
|
@@ -2071,6 +2057,8 @@ interface BookingPageProps {
|
|
|
2071
2057
|
product?: Product;
|
|
2072
2058
|
/** Optional staff list for staff selection step. */
|
|
2073
2059
|
staff?: Staff[];
|
|
2060
|
+
/** Optional resources for resource selection step (rooms, equipment, etc.). */
|
|
2061
|
+
resources?: Resource[];
|
|
2074
2062
|
/** Number of participants. */
|
|
2075
2063
|
participantCount?: number;
|
|
2076
2064
|
/** Page title. */
|
|
@@ -2088,7 +2076,7 @@ interface BookingPageProps {
|
|
|
2088
2076
|
className?: string;
|
|
2089
2077
|
classNames?: BookingPageClassNames;
|
|
2090
2078
|
}
|
|
2091
|
-
declare function BookingPage({ service, product, staff, participantCount, title, onBooked, onBack, existingBooking, onRescheduled, showPrice, className, classNames, }: BookingPageProps): React.ReactElement;
|
|
2079
|
+
declare function BookingPage({ service, product, staff, resources, participantCount, title, onBooked, onBack, existingBooking, onRescheduled, showPrice, className, classNames, }: BookingPageProps): React.ReactElement;
|
|
2092
2080
|
|
|
2093
2081
|
interface BookingsPageClassNames {
|
|
2094
2082
|
root?: string;
|
|
@@ -2333,4 +2321,4 @@ interface CurrencySelectorProps {
|
|
|
2333
2321
|
*/
|
|
2334
2322
|
declare function CurrencySelector({ currencies, currentCurrency, onCurrencyChange, showRate, baseCurrency, renderCurrency, className, classNames, }: CurrencySelectorProps): React.ReactElement | null;
|
|
2335
2323
|
|
|
2336
|
-
export { Ad, AdPosition, type AdProps, AdProvider, AdSlot, AddOnSelector, type AddOnSelectorClassNames, type AddOnSelectorProps, type AddToCartOptions, AddressElement, AuthElement, AvailabilityBadge, type AvailabilityBadgeClassNames, type AvailabilityBadgeProps, BillingPlanSelector, type BillingPlanSelectorClassNames, type BillingPlanSelectorProps, BookingCard, type BookingCardClassNames, type BookingCardProps, BookingList, type BookingListClassNames, type BookingListProps, BookingPage, type BookingPageClassNames, type BookingPageProps, BookingsPage, type BookingsPageClassNames, type BookingsPageProps, BundleSelector, type BundleSelectorClassNames, type BundleSelectorProps, type CartAddOnOptionSelection, CartPage, type CartPageClassNames, type CartPageProps, CartSummary, type CartSummaryClassNames, type CartSummaryProps, type CartVariantSelection, CataloguePage, type CataloguePageClassNames, type CataloguePageProps, CategoryFilter, type CategoryFilterClassNames, type CategoryFilterProps, CategoryGrid, type CategoryGridClassNames, type CategoryGridProps, CheckoutPage, type CheckoutPageClassNames, type CheckoutPageProps, CimplifyCheckout, type CimplifyCheckoutProps, type CimplifyClientContextValue, type CimplifyContextValue, CimplifyProvider, type CimplifyProviderProps, CollectionPage, type CollectionPageClassNames, type CollectionPageProps, CompositeSelector, type CompositeSelectorClassNames, type CompositeSelectorProps, CurrencySelector, type CurrencySelectorClassNames, type CurrencySelectorProps, DateSlotPicker, type DateSlotPickerClassNames, type DateSlotPickerProps, DealBanner, type DealBannerClassNames, type DealBannerProps, DealsPage, type DealsPageClassNames, type DealsPageProps, DeliveryEstimate, type DeliveryEstimateClassNames, type DeliveryEstimateProps, DiscountInput, type DiscountInputClassNames, type DiscountInputProps, ElementsProvider, LocationPicker, type LocationPickerClassNames, type LocationPickerProps, OrderDetailPage, type OrderDetailPageClassNames, type OrderDetailPageProps, OrderHistory, type OrderHistoryClassNames, OrderHistoryPage, type OrderHistoryPageClassNames, type OrderHistoryPageProps, type OrderHistoryProps, OrderSummary, type OrderSummaryClassNames, type OrderSummaryProps, PaymentElement, Price, type PriceProps, ProductCard, type ProductCardClassNames, type ProductCardProps, ProductCustomizer, type ProductCustomizerClassNames, type ProductCustomizerProps, ProductGrid, type ProductGridClassNames, type ProductGridProps, ProductImageGallery, type ProductImageGalleryProps, ProductPage, type ProductPageClassNames, type ProductPageProps, ProductSheet, type ProductSheetClassNames, type ProductSheetProps, QuantitySelector, type QuantitySelectorClassNames, type QuantitySelectorProps, RecentlyViewed, type RecentlyViewedClassNames, type RecentlyViewedProps, RecommendationCarousel, type RecommendationCarouselClassNames, type RecommendationCarouselProps, SaleBadge, type SaleBadgeClassNames, type SaleBadgeProps, SearchInput, type SearchInputClassNames, type SearchInputProps, SearchPage, type SearchPageClassNames, type SearchPageProps, ServiceCard, type ServiceCardClassNames, type ServiceCardProps, ServiceGrid, type ServiceGridClassNames, type ServiceGridProps, SessionMessageBanner, type SessionMessageBannerClassNames, type SessionMessageBannerProps, SlotPicker, type SlotPickerClassNames, type SlotPickerProps, StaffPicker, type StaffPickerClassNames, type StaffPickerProps, StoreNav, type StoreNavClassNames, type StoreNavProps, type UseActivityStateOptions, type UseActivityStateResult, type UseAttributeDefinitionsOptions, type UseAttributeDefinitionsResult, type UseAvailableSlotsOptions, type UseAvailableSlotsResult, type UseBillingPlansOptions, type UseBillingPlansResult, type UseBookingsOptions, type UseBookingsResult, type UseBootstrapOptions, type UseBootstrapResult, type UseBundlesOptions, type UseBundlesResult, type UseCartItem, type UseCartOptions, type UseCartResult, type UseCategoriesOptions, type UseCategoriesResult, type UseCollectionOptions, type UseCollectionResult, type UseCollectionsOptions, type UseCollectionsResult, type UseDealsOptions, type UseDealsResult, type UseDeliveryFeeOptions, type UseDeliveryFeeResult, type UseFxRateOptions, type UseFxRateResult, type UseLocationsOptions, type UseLocationsResult, type UseOrderOptions, type UseOrderResult, type UseOrdersOptions, type UseOrdersResult, type UseProductAvailabilityOptions, type UseProductAvailabilityResult, type UseProductDealsOptions, type UseProductDealsResult, type UseProductOptions, type UseProductPriceInput, type UseProductPriceResult, type UseProductResult, type UseProductSchedulesOptions, type UseProductSchedulesResult, type UseProductsOnSaleOptions, type UseProductsOnSaleResult, type UseProductsOptions, type UseProductsResult, type UsePropertyFacetsOptions, type UsePropertyFacetsResult, type UseQuoteInput, type UseQuoteOptions, type UseQuoteResult, type UseRecommendationsOptions, type UseRecommendationsResult, type UseSearchOptions, type UseSearchResult, type UseServiceAvailabilityOptions, type UseServiceAvailabilityResult, type UseServicesOptions, type UseServicesResult, type UseTaxonomiesOptions, type UseTaxonomiesResult, type UseTaxonomyOptions, type UseTaxonomyPathOptions, type UseTaxonomyPathResult, type UseTaxonomyResult, type UseValidateDiscountOptions, type UseValidateDiscountResult, type UseVariantSelectorOptions, type UseVariantSelectorResult, VariantSelector, type VariantSelectorClassNames, type VariantSelectorProps, cn, useActivityState, useAds, useAttributeDefinitions, useAvailableSlots, useBillingPlans, useBookings, useBootstrap, useBundles, useCart, useCategories, useCheckout, useCimplify, useCimplifyClient, useCollection, useCollections, useDeals, useDeliveryFee, useElements, useElementsReady, useFxRate, useLocations, useOptionalCimplify, useOrder, useOrders, useProduct, useProductAvailability, useProductDeals, useProductPrice, useProductSchedules, useProducts, useProductsOnSale, usePropertyFacets, useQuote, useRecommendations, useSearch, useServiceAvailability, useServices, useTaxonomies, useTaxonomy, useTaxonomyPath, useValidateDiscount, useVariantSelector };
|
|
2324
|
+
export { Ad, AdPosition, type AdProps, AdProvider, AdSlot, AddOnSelector, type AddOnSelectorClassNames, type AddOnSelectorProps, type AddToCartOptions, AddressElement, AuthElement, AvailabilityBadge, type AvailabilityBadgeClassNames, type AvailabilityBadgeProps, BillingPlanSelector, type BillingPlanSelectorClassNames, type BillingPlanSelectorProps, BookingCard, type BookingCardClassNames, type BookingCardProps, BookingList, type BookingListClassNames, type BookingListProps, BookingPage, type BookingPageClassNames, type BookingPageProps, BookingsPage, type BookingsPageClassNames, type BookingsPageProps, BundleSelector, type BundleSelectorClassNames, type BundleSelectorProps, type CartAddOnOptionSelection, CartPage, type CartPageClassNames, type CartPageProps, CartSummary, type CartSummaryClassNames, type CartSummaryProps, type CartVariantSelection, CataloguePage, type CataloguePageClassNames, type CataloguePageProps, CategoryFilter, type CategoryFilterClassNames, type CategoryFilterProps, CategoryGrid, type CategoryGridClassNames, type CategoryGridProps, CheckoutPage, type CheckoutPageClassNames, type CheckoutPageProps, CimplifyCheckout, type CimplifyCheckoutProps, type CimplifyClientContextValue, type CimplifyContextValue, CimplifyProvider, type CimplifyProviderProps, CollectionPage, type CollectionPageClassNames, type CollectionPageProps, CompositeSelector, type CompositeSelectorClassNames, type CompositeSelectorProps, CurrencySelector, type CurrencySelectorClassNames, type CurrencySelectorProps, DateSlotPicker, type DateSlotPickerClassNames, type DateSlotPickerProps, DealBanner, type DealBannerClassNames, type DealBannerProps, DealsPage, type DealsPageClassNames, type DealsPageProps, DeliveryEstimate, type DeliveryEstimateClassNames, type DeliveryEstimateProps, DiscountInput, type DiscountInputClassNames, type DiscountInputProps, ElementsProvider, LocationPicker, type LocationPickerClassNames, type LocationPickerProps, OrderDetailPage, type OrderDetailPageClassNames, type OrderDetailPageProps, OrderHistory, type OrderHistoryClassNames, OrderHistoryPage, type OrderHistoryPageClassNames, type OrderHistoryPageProps, type OrderHistoryProps, OrderSummary, type OrderSummaryClassNames, type OrderSummaryProps, PaymentElement, Price, type PriceProps, ProductCard, type ProductCardClassNames, type ProductCardProps, ProductCustomizer, type ProductCustomizerClassNames, type ProductCustomizerProps, ProductGrid, type ProductGridClassNames, type ProductGridProps, ProductImageGallery, type ProductImageGalleryProps, ProductPage, type ProductPageClassNames, type ProductPageProps, ProductSheet, type ProductSheetClassNames, type ProductSheetProps, QuantitySelector, type QuantitySelectorClassNames, type QuantitySelectorProps, RecentlyViewed, type RecentlyViewedClassNames, type RecentlyViewedProps, RecommendationCarousel, type RecommendationCarouselClassNames, type RecommendationCarouselProps, type Resource, ResourcePicker, type ResourcePickerClassNames, type ResourcePickerProps, SaleBadge, type SaleBadgeClassNames, type SaleBadgeProps, SearchInput, type SearchInputClassNames, type SearchInputProps, SearchPage, type SearchPageClassNames, type SearchPageProps, ServiceCard, type ServiceCardClassNames, type ServiceCardProps, ServiceGrid, type ServiceGridClassNames, type ServiceGridProps, SessionMessageBanner, type SessionMessageBannerClassNames, type SessionMessageBannerProps, SlotPicker, type SlotPickerClassNames, type SlotPickerProps, StaffPicker, type StaffPickerClassNames, type StaffPickerProps, StoreNav, type StoreNavClassNames, type StoreNavProps, type UseActivityStateOptions, type UseActivityStateResult, type UseAttributeDefinitionsOptions, type UseAttributeDefinitionsResult, type UseAvailableSlotsOptions, type UseAvailableSlotsResult, type UseBillingPlansOptions, type UseBillingPlansResult, type UseBookingsOptions, type UseBookingsResult, type UseBootstrapOptions, type UseBootstrapResult, type UseBundlesOptions, type UseBundlesResult, type UseCartItem, type UseCartOptions, type UseCartResult, type UseCategoriesOptions, type UseCategoriesResult, type UseCollectionOptions, type UseCollectionResult, type UseCollectionsOptions, type UseCollectionsResult, type UseDealsOptions, type UseDealsResult, type UseDeliveryFeeOptions, type UseDeliveryFeeResult, type UseFxRateOptions, type UseFxRateResult, type UseLocationsOptions, type UseLocationsResult, type UseOrderOptions, type UseOrderResult, type UseOrdersOptions, type UseOrdersResult, type UseProductAvailabilityOptions, type UseProductAvailabilityResult, type UseProductDealsOptions, type UseProductDealsResult, type UseProductOptions, type UseProductPriceInput, type UseProductPriceResult, type UseProductResult, type UseProductSchedulesOptions, type UseProductSchedulesResult, type UseProductsOnSaleOptions, type UseProductsOnSaleResult, type UseProductsOptions, type UseProductsResult, type UsePropertyFacetsOptions, type UsePropertyFacetsResult, type UseQuoteInput, type UseQuoteOptions, type UseQuoteResult, type UseRecommendationsOptions, type UseRecommendationsResult, type UseSearchOptions, type UseSearchResult, type UseServiceAvailabilityOptions, type UseServiceAvailabilityResult, type UseServicesOptions, type UseServicesResult, type UseTaxonomiesOptions, type UseTaxonomiesResult, type UseTaxonomyOptions, type UseTaxonomyPathOptions, type UseTaxonomyPathResult, type UseTaxonomyResult, type UseValidateDiscountOptions, type UseValidateDiscountResult, type UseVariantSelectorOptions, type UseVariantSelectorResult, VariantSelector, type VariantSelectorClassNames, type VariantSelectorProps, cn, roomToResource, useActivityState, useAds, useAttributeDefinitions, useAvailableSlots, useBillingPlans, useBookings, useBootstrap, useBundles, useCart, useCategories, useCheckout, useCimplify, useCimplifyClient, useCollection, useCollections, useDeals, useDeliveryFee, useElements, useElementsReady, useFxRate, useLocations, useOptionalCimplify, useOrder, useOrders, useProduct, useProductAvailability, useProductDeals, useProductPrice, useProductSchedules, useProducts, useProductsOnSale, usePropertyFacets, useQuote, useRecommendations, useSearch, useServiceAvailability, useServices, useTaxonomies, useTaxonomy, useTaxonomyPath, useValidateDiscount, useVariantSelector };
|