@wix/bookings 1.0.1796 → 1.0.1798
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/build/cjs/context-booking-checkout.d.ts +3 -37
- package/build/cjs/context-booking-checkout.js +1350 -1340
- package/build/cjs/context-booking-checkout.js.map +1 -1
- package/build/cjs/context-categories.d.ts +1 -3
- package/build/cjs/context-categories.js +20 -43
- package/build/cjs/context-categories.js.map +1 -1
- package/build/cjs/context-locations.d.ts +1 -1
- package/build/cjs/context-locations.js +20 -43
- package/build/cjs/context-locations.js.map +1 -1
- package/build/cjs/context-service-addons.d.ts +1 -15
- package/build/cjs/context-service-addons.js +20 -43
- package/build/cjs/context-service-addons.js.map +1 -1
- package/build/cjs/context-service.d.ts +1 -65
- package/build/cjs/context-service.js +363 -386
- package/build/cjs/context-service.js.map +1 -1
- package/build/cjs/context-services.d.ts +1 -23
- package/build/cjs/context-services.js +542 -566
- package/build/cjs/context-services.js.map +1 -1
- package/build/cjs/context-time-slots.d.ts +1 -21
- package/build/cjs/context-time-slots.js +588 -615
- package/build/cjs/context-time-slots.js.map +1 -1
- package/build/es/context-booking-checkout.d.mts +3 -37
- package/build/es/context-booking-checkout.mjs +1350 -1340
- package/build/es/context-booking-checkout.mjs.map +1 -1
- package/build/es/context-categories.d.mts +1 -3
- package/build/es/context-categories.mjs +20 -43
- package/build/es/context-categories.mjs.map +1 -1
- package/build/es/context-locations.d.mts +1 -1
- package/build/es/context-locations.mjs +20 -43
- package/build/es/context-locations.mjs.map +1 -1
- package/build/es/context-service-addons.d.mts +1 -15
- package/build/es/context-service-addons.mjs +20 -43
- package/build/es/context-service-addons.mjs.map +1 -1
- package/build/es/context-service.d.mts +1 -65
- package/build/es/context-service.mjs +363 -386
- package/build/es/context-service.mjs.map +1 -1
- package/build/es/context-services.d.mts +1 -23
- package/build/es/context-services.mjs +542 -566
- package/build/es/context-services.mjs.map +1 -1
- package/build/es/context-time-slots.d.mts +1 -21
- package/build/es/context-time-slots.mjs +588 -615
- package/build/es/context-time-slots.mjs.map +1 -1
- package/build/internal/cjs/context-booking-checkout.d.ts +3 -37
- package/build/internal/cjs/context-categories.d.ts +1 -3
- package/build/internal/cjs/context-locations.d.ts +1 -1
- package/build/internal/cjs/context-service-addons.d.ts +1 -15
- package/build/internal/cjs/context-service.d.ts +1 -65
- package/build/internal/cjs/context-services.d.ts +1 -23
- package/build/internal/cjs/context-time-slots.d.ts +1 -21
- package/build/internal/es/context-booking-checkout.d.mts +3 -37
- package/build/internal/es/context-categories.d.mts +1 -3
- package/build/internal/es/context-locations.d.mts +1 -1
- package/build/internal/es/context-service-addons.d.mts +1 -15
- package/build/internal/es/context-service.d.mts +1 -65
- package/build/internal/es/context-services.d.mts +1 -23
- package/build/internal/es/context-time-slots.d.mts +1 -21
- package/context-runtime/context-booking-checkout/runtime.d.ts +3 -38
- package/context-runtime/context-booking-checkout/runtime.js +3 -3
- package/context-runtime/context-categories/runtime.d.ts +1 -4
- package/context-runtime/context-categories/runtime.js +2 -2
- package/context-runtime/context-locations/runtime.d.ts +1 -2
- package/context-runtime/context-locations/runtime.js +2 -2
- package/context-runtime/context-service/runtime.d.ts +1 -66
- package/context-runtime/context-service/runtime.js +3 -3
- package/context-runtime/context-service-addons/runtime.d.ts +1 -16
- package/context-runtime/context-service-addons/runtime.js +2 -2
- package/context-runtime/context-services/runtime.d.ts +1 -24
- package/context-runtime/context-services/runtime.js +3 -3
- package/context-runtime/context-time-slots/runtime.d.ts +1 -22
- package/context-runtime/context-time-slots/runtime.js +3 -3
- package/package.json +4 -4
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React, { ReactNode } from 'react';
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
// ../../node_modules/type-fest/source/observable-like.d.ts
|
|
4
4
|
declare global {
|
|
5
5
|
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
6
6
|
interface SymbolConstructor {
|
|
@@ -17,8 +17,6 @@ As well, some guidance on making an `Observable` to not include `closed` propert
|
|
|
17
17
|
|
|
18
18
|
@category Observable
|
|
19
19
|
*/
|
|
20
|
-
//#endregion
|
|
21
|
-
//#region ../../node_modules/@wix/sdk-types/internal/build/index.d.ts
|
|
22
20
|
declare global {
|
|
23
21
|
interface ContextualClient {}
|
|
24
22
|
}
|
|
@@ -64,8 +62,6 @@ declare global {
|
|
|
64
62
|
*/
|
|
65
63
|
interface SDKTypeMode {}
|
|
66
64
|
}
|
|
67
|
-
//#endregion
|
|
68
|
-
//#region ../../node_modules/@wix/auto_sdk_bookings_availability-time-slots/build/es/index.typings.d.mts
|
|
69
65
|
/**
|
|
70
66
|
* A time slot represents a specific time period when a service is available for booking.
|
|
71
67
|
* It provides all the information needed to display availability to customers, including whether customers can actually book it, the remaining capacity, and which staff members or resources are available.
|
|
@@ -353,14 +349,10 @@ interface NonBookableReasons {
|
|
|
353
349
|
/** Whether the related event is cancelled. */
|
|
354
350
|
eventCancelled?: boolean | null;
|
|
355
351
|
}
|
|
356
|
-
//#endregion
|
|
357
|
-
//#region ../bookings-flow-data/dist/types.d.ts
|
|
358
352
|
/** Genders a visitor can narrow "any staff member" to, in display order. Same literals as the
|
|
359
353
|
* availability API's `requestedGender.gender`, single- and multi-service alike. */
|
|
360
354
|
declare const REQUESTED_GENDERS: readonly ["ANY_FEMALE", "ANY_MALE"];
|
|
361
355
|
type RequestedGender = (typeof REQUESTED_GENDERS)[number];
|
|
362
|
-
//#endregion
|
|
363
|
-
//#region ../../node_modules/@wix/editor-react-types/dist/image.d.ts
|
|
364
356
|
type Point = {
|
|
365
357
|
x: number;
|
|
366
358
|
y: number;
|
|
@@ -396,8 +388,6 @@ type Image = {
|
|
|
396
388
|
quality?: number; /** The image alt text for accessibility. */
|
|
397
389
|
alt?: string;
|
|
398
390
|
};
|
|
399
|
-
//#endregion
|
|
400
|
-
//#region src/api/adapters/staff-member/staff-member.d.ts
|
|
401
391
|
/**
|
|
402
392
|
* Where a staff member has working hours, derived server-side from their WORKING_HOURS
|
|
403
393
|
* calendar events. Returned only when `STAFF_WORKING_HOURS_LOCATIONS` is requested (see
|
|
@@ -415,8 +405,6 @@ interface StaffMemberItem {
|
|
|
415
405
|
/** Absent when the coverage wasn't returned — callers treat that as "works everywhere". */
|
|
416
406
|
locationCoverage?: StaffLocationCoverage;
|
|
417
407
|
}
|
|
418
|
-
//#endregion
|
|
419
|
-
//#region src/mappers/date-time.d.ts
|
|
420
408
|
/** Inclusive. */
|
|
421
409
|
interface LocalDateRange {
|
|
422
410
|
/** First date of the range, as a local date in `YYYY-MM-DD` format. The range includes it. */
|
|
@@ -424,16 +412,12 @@ interface LocalDateRange {
|
|
|
424
412
|
/** Last date of the range, as a local date in `YYYY-MM-DD` format. The range includes it. */
|
|
425
413
|
readonly endDate: string;
|
|
426
414
|
}
|
|
427
|
-
//#endregion
|
|
428
|
-
//#region src/api/adapters/time-slots/days-availability.d.ts
|
|
429
415
|
/** `unavailable`: has slots, none bookable. */
|
|
430
416
|
type DayAvailability = 'none' | 'unavailable' | 'available';
|
|
431
417
|
interface DayAvailabilityItem {
|
|
432
418
|
readonly date: string;
|
|
433
419
|
readonly availability: DayAvailability;
|
|
434
420
|
}
|
|
435
|
-
//#endregion
|
|
436
|
-
//#region src/extensions/contexts/time-slots-context/time-slots-context.types.d.ts
|
|
437
421
|
/** A local date in `YYYY-MM-DD` format. */
|
|
438
422
|
type LocalDate = string;
|
|
439
423
|
/** How a `goToNextAvailableDate()` search ended. */
|
|
@@ -602,8 +586,6 @@ interface NextAvailability {
|
|
|
602
586
|
/**
|
|
603
587
|
* The availability of the current service or multi-service appointment: its time slots, day
|
|
604
588
|
* availability, upcoming slots, filters, and the actions to browse and pick them.
|
|
605
|
-
*
|
|
606
|
-
* @beta
|
|
607
589
|
*/
|
|
608
590
|
interface TimeSlotsContextValue extends TimeSlotsContextFields {
|
|
609
591
|
/**
|
|
@@ -1402,8 +1384,6 @@ interface TimeSlotsContextProviderProps {
|
|
|
1402
1384
|
interface TimeSlotsContextAuthoringProps {
|
|
1403
1385
|
readonly loadNextAvailabilityInitially?: boolean;
|
|
1404
1386
|
}
|
|
1405
|
-
//#endregion
|
|
1406
|
-
//#region src/extensions/contexts/time-slots-context/time-slots-context.d.ts
|
|
1407
1387
|
declare const timeSlotsContext: React.Context<TimeSlotsContextValue | null>;
|
|
1408
1388
|
/**
|
|
1409
1389
|
* The `useTimeSlotsContext()` hook provides access to the available dates and time slots of a
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React, { ReactNode } from 'react';
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
// ../../node_modules/type-fest/source/observable-like.d.ts
|
|
4
4
|
declare global {
|
|
5
5
|
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
6
6
|
interface SymbolConstructor {
|
|
@@ -17,8 +17,6 @@ As well, some guidance on making an `Observable` to not include `closed` propert
|
|
|
17
17
|
|
|
18
18
|
@category Observable
|
|
19
19
|
*/
|
|
20
|
-
//#endregion
|
|
21
|
-
//#region ../../node_modules/@wix/sdk-types/internal/build/index.d.ts
|
|
22
20
|
declare global {
|
|
23
21
|
interface ContextualClient {}
|
|
24
22
|
}
|
|
@@ -64,8 +62,6 @@ declare global {
|
|
|
64
62
|
*/
|
|
65
63
|
interface SDKTypeMode {}
|
|
66
64
|
}
|
|
67
|
-
//#endregion
|
|
68
|
-
//#region ../../node_modules/@wix/auto_sdk_bookings_service-options-and-variants/build/es/index.typings.d.mts
|
|
69
65
|
/**
|
|
70
66
|
* The `serviceOptionsAndVariants` object links a [service](https://dev.wix.com/docs/api-reference/business-solutions/bookings/services/services-v2/introduction)
|
|
71
67
|
* to its variants.
|
|
@@ -523,8 +519,6 @@ interface ExtendedFields$1 {
|
|
|
523
519
|
*/
|
|
524
520
|
namespaces?: Record<string, Record<string, any>>;
|
|
525
521
|
}
|
|
526
|
-
//#endregion
|
|
527
|
-
//#region ../../node_modules/@wix/auto_sdk_bookings_services/build/es/bookings-services-v2-service-services.universal-p5eQUd5f.d.mts
|
|
528
522
|
/** The `service` object represents an offering that a business provides to its customers. */
|
|
529
523
|
interface Service {
|
|
530
524
|
/**
|
|
@@ -2319,8 +2313,6 @@ interface BookedAddOn {
|
|
|
2319
2313
|
nameTranslated?: string | null;
|
|
2320
2314
|
}
|
|
2321
2315
|
/** Server-computed datetime adjusted to a requested timezone. */
|
|
2322
|
-
//#endregion
|
|
2323
|
-
//#region ../../node_modules/@wix/auto_sdk_bookings_bookings/build/es/index.typings.d.mts
|
|
2324
2316
|
declare enum ResourceTransparency {
|
|
2325
2317
|
OPAQUE = "OPAQUE",
|
|
2326
2318
|
TRANSPARENT = "TRANSPARENT"
|
|
@@ -2467,8 +2459,6 @@ interface SlotLocation {
|
|
|
2467
2459
|
locationType?: LocationLocationTypeWithLiterals;
|
|
2468
2460
|
}
|
|
2469
2461
|
/** Response for RescheduleBookingAnonymously */
|
|
2470
|
-
//#endregion
|
|
2471
|
-
//#region ../bookings-flow-data/dist/types.d.ts
|
|
2472
2462
|
/**
|
|
2473
2463
|
* Whether the selection holds 1 service or several services booked together. Supported values:
|
|
2474
2464
|
* - `'single'`: 1 service.
|
|
@@ -2559,11 +2549,7 @@ interface BookingPreferences {
|
|
|
2559
2549
|
*/
|
|
2560
2550
|
wantsPromoCode?: boolean;
|
|
2561
2551
|
}
|
|
2562
|
-
//#endregion
|
|
2563
|
-
//#region src/api/adapters/service/service.d.ts
|
|
2564
2552
|
type Service$1 = Service;
|
|
2565
|
-
//#endregion
|
|
2566
|
-
//#region src/domains/payment-options/consts.d.ts
|
|
2567
2553
|
/**
|
|
2568
2554
|
* No MEMBERSHIP on purpose: the data panel would let the owner preselect it and the
|
|
2569
2555
|
* filter would reduce the list to plan rows. Plan rows carry `paymentMethod: null`.
|
|
@@ -2595,8 +2581,6 @@ declare const PAYMENT_OPTION_KIND: {
|
|
|
2595
2581
|
readonly SUBSCRIPTION: "SUBSCRIPTION";
|
|
2596
2582
|
};
|
|
2597
2583
|
type PaymentOptionKind = (typeof PAYMENT_OPTION_KIND)[keyof typeof PAYMENT_OPTION_KIND];
|
|
2598
|
-
//#endregion
|
|
2599
|
-
//#region ../../node_modules/@wix/auto_sdk_pricing-plans_plans-v-3/build/es/pricing-plans-v3-plan-plans-v-3.universal-CED5HgCd.d.mts
|
|
2600
2584
|
/**
|
|
2601
2585
|
* The choices a buyer makes about a plan, carried in the `options` field of an eCommerce line item's
|
|
2602
2586
|
* `catalogReference`.
|
|
@@ -2671,8 +2655,6 @@ declare enum PurchaseFlow {
|
|
|
2671
2655
|
}
|
|
2672
2656
|
/** @enumType */
|
|
2673
2657
|
type PurchaseFlowWithLiterals = PurchaseFlow | 'MANUAL' | 'ONLINE';
|
|
2674
|
-
//#endregion
|
|
2675
|
-
//#region src/domains/payment-options/from-plans.d.ts
|
|
2676
2658
|
/** A plan in the eCommerce catalog: the plan's `options` carry the pricing variant. */
|
|
2677
2659
|
interface PlanCatalogReference {
|
|
2678
2660
|
/** ID of the app that sells the plan. */
|
|
@@ -2705,8 +2687,6 @@ interface PlanBenefit {
|
|
|
2705
2687
|
*/
|
|
2706
2688
|
redemptionCost: number | null;
|
|
2707
2689
|
}
|
|
2708
|
-
//#endregion
|
|
2709
|
-
//#region src/domains/payment-options/from-service.d.ts
|
|
2710
2690
|
type Payment = NonNullable<Service['payment']>;
|
|
2711
2691
|
type Money = NonNullable<NonNullable<Payment['fixed']>['price']>;
|
|
2712
2692
|
interface MembershipRowData {
|
|
@@ -2823,8 +2803,6 @@ interface PaymentOption {
|
|
|
2823
2803
|
* booking summary to show the option's price and how it's paid.
|
|
2824
2804
|
*/
|
|
2825
2805
|
type CheckoutPaymentOption = Pick<PaymentOption, 'membership' | 'purchasablePlan'> & Partial<Omit<PaymentOption, 'membership' | 'purchasablePlan'>>;
|
|
2826
|
-
//#endregion
|
|
2827
|
-
//#region src/domains/payment-options/to-booking.d.ts
|
|
2828
2806
|
interface SelectedMembership {
|
|
2829
2807
|
/** ID of the visitor's membership. */
|
|
2830
2808
|
membershipId: string;
|
|
@@ -2835,8 +2813,6 @@ interface SelectedMembership {
|
|
|
2835
2813
|
*/
|
|
2836
2814
|
serviceId: string;
|
|
2837
2815
|
}
|
|
2838
|
-
//#endregion
|
|
2839
|
-
//#region src/api/adapters/pricing/preview-price.d.ts
|
|
2840
2816
|
/** Participants to book with 1 price choice. */
|
|
2841
2817
|
interface ParticipantsServiceChoice {
|
|
2842
2818
|
/** Number of participants to book with the price choice. */
|
|
@@ -2861,8 +2837,6 @@ interface ParticipantsPrice {
|
|
|
2861
2837
|
/** Price per participant. Absent unless a single price choice prices all the participants. */
|
|
2862
2838
|
perParticipant?: number;
|
|
2863
2839
|
}
|
|
2864
|
-
//#endregion
|
|
2865
|
-
//#region src/domains/booking-checkout/to-booking-entity.d.ts
|
|
2866
2840
|
interface ContactDetailsInput {
|
|
2867
2841
|
/** Visitor's first name. */
|
|
2868
2842
|
firstName: string;
|
|
@@ -2896,6 +2870,7 @@ interface BookingPayment {
|
|
|
2896
2870
|
subscription?: boolean;
|
|
2897
2871
|
}
|
|
2898
2872
|
interface CreateBookingInput {
|
|
2873
|
+
useCartPaymentConfig?: boolean;
|
|
2899
2874
|
/**
|
|
2900
2875
|
* Visitor's contact details, for the cart and the order.
|
|
2901
2876
|
*
|
|
@@ -2959,14 +2934,10 @@ interface CreateBookingInput {
|
|
|
2959
2934
|
*/
|
|
2960
2935
|
requiresCheckoutPage?: boolean;
|
|
2961
2936
|
}
|
|
2962
|
-
//#endregion
|
|
2963
|
-
//#region src/lib/navigation.d.ts
|
|
2964
2937
|
type OwnerLink = {
|
|
2965
2938
|
/** URL to go to. */href: string; /** Where the link opens. */
|
|
2966
2939
|
target?: /** In the current tab. */'_self' /** In a new tab. The visitor stays on the page in the current tab. */ | '_blank';
|
|
2967
2940
|
};
|
|
2968
|
-
//#endregion
|
|
2969
|
-
//#region src/domains/plan-and-book/flow.d.ts
|
|
2970
2941
|
declare const PLAN_AND_BOOK_CTA: {
|
|
2971
2942
|
readonly BOOK: "BOOK";
|
|
2972
2943
|
readonly BUY_PLAN_AND_BOOK: "BUY_PLAN_AND_BOOK";
|
|
@@ -2998,8 +2969,6 @@ interface PlanAndBookFlow {
|
|
|
2998
2969
|
*/
|
|
2999
2970
|
route: PlanAndBookRoute;
|
|
3000
2971
|
}
|
|
3001
|
-
//#endregion
|
|
3002
|
-
//#region src/domains/booking-checkout/checkout-error.d.ts
|
|
3003
2972
|
/** Why a `createBooking()` or `addToCart()` call failed. */
|
|
3004
2973
|
interface CheckoutError {
|
|
3005
2974
|
/**
|
|
@@ -3025,8 +2994,6 @@ interface CheckoutError {
|
|
|
3025
2994
|
/** Text of the first rule the booking breaks, when the server sends one. */
|
|
3026
2995
|
violation?: string;
|
|
3027
2996
|
}
|
|
3028
|
-
//#endregion
|
|
3029
|
-
//#region src/extensions/contexts/booking-checkout-context/use-booking-checkout.d.ts
|
|
3030
2997
|
interface BookingFormHandle {
|
|
3031
2998
|
/**
|
|
3032
2999
|
* Whether the selection can't join the visitor's cart: the cart holds an appointment with the
|
|
@@ -3095,6 +3062,7 @@ interface FormFacts {
|
|
|
3095
3062
|
*/
|
|
3096
3063
|
paymentOption: BookingPaymentOption; /** Whether the service has a price above 0. */
|
|
3097
3064
|
hasPrice: boolean;
|
|
3065
|
+
skipsStoredPaymentMethod?: boolean;
|
|
3098
3066
|
}[];
|
|
3099
3067
|
/** Whether the visitor's cart holds bookings. Other items in the cart don't count. */
|
|
3100
3068
|
hasBookingsInCart: boolean;
|
|
@@ -3580,8 +3548,6 @@ interface BookingCheckoutState {
|
|
|
3580
3548
|
*/
|
|
3581
3549
|
setWantsPromoCode: (wanted: boolean) => void;
|
|
3582
3550
|
}
|
|
3583
|
-
//#endregion
|
|
3584
|
-
//#region src/extensions/contexts/booking-checkout-context/booking-checkout-context.d.ts
|
|
3585
3551
|
/** The booking in progress: the selection decoded from the page URL, its payment options and participant count, and the actions to create the booking or add it to the cart. */
|
|
3586
3552
|
type BookingCheckoutContextValue = BookingCheckoutState;
|
|
3587
3553
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React, { ReactNode } from 'react';
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
// src/lib/picker-filter.d.ts
|
|
4
4
|
/** One field of a panel filter backed by an Items Selection provider (`$in`, or `$eq` after an operator switch). */
|
|
5
5
|
interface PickerRule {
|
|
6
6
|
$in?: string[];
|
|
@@ -9,8 +9,6 @@ interface PickerRule {
|
|
|
9
9
|
interface CategoriesPickerFilter {
|
|
10
10
|
categoryId?: PickerRule;
|
|
11
11
|
}
|
|
12
|
-
//#endregion
|
|
13
|
-
//#region src/extensions/contexts/categories-context/categories-context.d.ts
|
|
14
12
|
/** A service category as shown in a category list, with its selected state. */
|
|
15
13
|
interface CategoryItem {
|
|
16
14
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React, { ReactNode } from 'react';
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
// src/extensions/contexts/locations-context/locations-context.d.ts
|
|
4
4
|
/** A business location as shown in a location list, with its selected state. */
|
|
5
5
|
interface LocationItem {
|
|
6
6
|
/**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React, { ReactNode } from 'react';
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
// ../../node_modules/type-fest/source/observable-like.d.ts
|
|
4
4
|
declare global {
|
|
5
5
|
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
6
6
|
interface SymbolConstructor {
|
|
@@ -17,8 +17,6 @@ As well, some guidance on making an `Observable` to not include `closed` propert
|
|
|
17
17
|
|
|
18
18
|
@category Observable
|
|
19
19
|
*/
|
|
20
|
-
//#endregion
|
|
21
|
-
//#region ../../node_modules/@wix/sdk-types/internal/build/index.d.ts
|
|
22
20
|
declare global {
|
|
23
21
|
interface ContextualClient {}
|
|
24
22
|
}
|
|
@@ -64,8 +62,6 @@ declare global {
|
|
|
64
62
|
*/
|
|
65
63
|
interface SDKTypeMode {}
|
|
66
64
|
}
|
|
67
|
-
//#endregion
|
|
68
|
-
//#region ../../node_modules/@wix/auto_sdk_bookings_services/build/es/bookings-services-v2-service-services.universal-p5eQUd5f.d.mts
|
|
69
65
|
/**
|
|
70
66
|
* Money.
|
|
71
67
|
* Default format to use. Sufficiently compliant with majority of standards: w3c, ISO 4217, ISO 20022, ISO 8583:2003.
|
|
@@ -199,15 +195,11 @@ interface AddOnGroupDetail$1 {
|
|
|
199
195
|
*/
|
|
200
196
|
promptTranslated?: string | null;
|
|
201
197
|
}
|
|
202
|
-
//#endregion
|
|
203
|
-
//#region ../bookings-flow-data/dist/types.d.ts
|
|
204
198
|
/** An add-on the visitor chose, with its quantity. */
|
|
205
199
|
type AddOn$1 = {
|
|
206
200
|
/** ID of the add-on. */id: NonNullable<BookedAddOn['_id']>; /** Number of the add-on to book. */
|
|
207
201
|
quantity: NonNullable<BookedAddOn['quantity']>;
|
|
208
202
|
};
|
|
209
|
-
//#endregion
|
|
210
|
-
//#region ../../node_modules/@wix/editor-react-types/dist/image.d.ts
|
|
211
203
|
type Point = {
|
|
212
204
|
x: number;
|
|
213
205
|
y: number;
|
|
@@ -243,8 +235,6 @@ type Image = {
|
|
|
243
235
|
quality?: number; /** The image alt text for accessibility. */
|
|
244
236
|
alt?: string;
|
|
245
237
|
};
|
|
246
|
-
//#endregion
|
|
247
|
-
//#region src/api/adapters/service-addons/service-addons.d.ts
|
|
248
238
|
type AddOn = AddOn$2 & {
|
|
249
239
|
mainMedia?: {
|
|
250
240
|
image?: string | null;
|
|
@@ -353,8 +343,6 @@ interface AddOnGroupItem {
|
|
|
353
343
|
*/
|
|
354
344
|
canSelectMore: boolean;
|
|
355
345
|
}
|
|
356
|
-
//#endregion
|
|
357
|
-
//#region src/extensions/contexts/service-addons-context/service-addons-context.types.d.ts
|
|
358
346
|
/** The add-ons offered for the current service, the visitor's picks, and the actions to change them. */
|
|
359
347
|
interface ServiceAddOnsContextValue {
|
|
360
348
|
/**
|
|
@@ -498,8 +486,6 @@ interface ServiceAddOnsContextValue {
|
|
|
498
486
|
interface ServiceAddOnsContextProviderProps {
|
|
499
487
|
children: ReactNode;
|
|
500
488
|
}
|
|
501
|
-
//#endregion
|
|
502
|
-
//#region src/extensions/contexts/service-addons-context/service-addons-context.d.ts
|
|
503
489
|
declare const serviceAddOnsContext: React.Context<ServiceAddOnsContextValue | null>;
|
|
504
490
|
/**
|
|
505
491
|
* The `useServiceAddOnsContext()` hook provides access to the add-ons a Wix Bookings service offers
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React, { ReactNode } from 'react';
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
// ../../node_modules/@wix/editor-react-types/dist/links.d.ts
|
|
4
4
|
type LinkTarget = '_self' | '_blank';
|
|
5
5
|
/**
|
|
6
6
|
* A link to a URL, used for navigation within components.
|
|
@@ -35,8 +35,6 @@ type Link = {
|
|
|
35
35
|
*/
|
|
36
36
|
pageRole?: string;
|
|
37
37
|
};
|
|
38
|
-
//#endregion
|
|
39
|
-
//#region ../../node_modules/@wix/editor-react-types/dist/image.d.ts
|
|
40
38
|
type Point = {
|
|
41
39
|
x: number;
|
|
42
40
|
y: number;
|
|
@@ -72,8 +70,6 @@ type Image = {
|
|
|
72
70
|
quality?: number; /** The image alt text for accessibility. */
|
|
73
71
|
alt?: string;
|
|
74
72
|
};
|
|
75
|
-
//#endregion
|
|
76
|
-
//#region ../../node_modules/@wix/editor-react-types/dist/base.d.ts
|
|
77
73
|
/**
|
|
78
74
|
* A standard email address according to RFC 5321, section 4.1.2.
|
|
79
75
|
*
|
|
@@ -100,8 +96,6 @@ type Email = string;
|
|
|
100
96
|
* ```
|
|
101
97
|
*/
|
|
102
98
|
type Phone = string;
|
|
103
|
-
//#endregion
|
|
104
|
-
//#region ../../node_modules/@wix/editor-react-types/dist/visualMedia.d.ts
|
|
105
99
|
interface VisualMediaBase {
|
|
106
100
|
/** The URL of the media file */
|
|
107
101
|
src: string;
|
|
@@ -136,8 +130,6 @@ type ImageParameters = {
|
|
|
136
130
|
/** The focal point for the image */focalPoint?: [number, number]; /** The alt text for the image */
|
|
137
131
|
alt?: string;
|
|
138
132
|
};
|
|
139
|
-
//#endregion
|
|
140
|
-
//#region ../../node_modules/type-fest/source/observable-like.d.ts
|
|
141
133
|
declare global {
|
|
142
134
|
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
143
135
|
interface SymbolConstructor {
|
|
@@ -154,8 +146,6 @@ As well, some guidance on making an `Observable` to not include `closed` propert
|
|
|
154
146
|
|
|
155
147
|
@category Observable
|
|
156
148
|
*/
|
|
157
|
-
//#endregion
|
|
158
|
-
//#region ../../node_modules/@wix/sdk-types/internal/build/index.d.ts
|
|
159
149
|
declare global {
|
|
160
150
|
interface ContextualClient {}
|
|
161
151
|
}
|
|
@@ -201,8 +191,6 @@ declare global {
|
|
|
201
191
|
*/
|
|
202
192
|
interface SDKTypeMode {}
|
|
203
193
|
}
|
|
204
|
-
//#endregion
|
|
205
|
-
//#region ../../node_modules/@wix/auto_sdk_bookings_multi-service-availability-time-slots/build/es/index.typings.d.mts
|
|
206
194
|
interface AvailableResources {
|
|
207
195
|
/**
|
|
208
196
|
* [Resource type ID](https://dev.wix.com/docs/api-reference/business-solutions/bookings/resources/resource-types-v2/introduction).
|
|
@@ -271,8 +259,6 @@ interface NestedTimeSlot {
|
|
|
271
259
|
*/
|
|
272
260
|
scheduleId?: string | null;
|
|
273
261
|
}
|
|
274
|
-
//#endregion
|
|
275
|
-
//#region ../../node_modules/@wix/auto_sdk_bookings_service-options-and-variants/build/es/index.typings.d.mts
|
|
276
262
|
/**
|
|
277
263
|
* The `serviceOptionsAndVariants` object links a [service](https://dev.wix.com/docs/api-reference/business-solutions/bookings/services/services-v2/introduction)
|
|
278
264
|
* to its variants.
|
|
@@ -730,8 +716,6 @@ interface ExtendedFields$2 {
|
|
|
730
716
|
*/
|
|
731
717
|
namespaces?: Record<string, Record<string, any>>;
|
|
732
718
|
}
|
|
733
|
-
//#endregion
|
|
734
|
-
//#region ../../node_modules/@wix/auto_sdk_bookings_services/build/es/bookings-services-v2-service-services.universal-p5eQUd5f.d.mts
|
|
735
719
|
/** The `service` object represents an offering that a business provides to its customers. */
|
|
736
720
|
interface Service {
|
|
737
721
|
/**
|
|
@@ -2526,8 +2510,6 @@ interface BookedAddOn {
|
|
|
2526
2510
|
nameTranslated?: string | null;
|
|
2527
2511
|
}
|
|
2528
2512
|
/** Server-computed datetime adjusted to a requested timezone. */
|
|
2529
|
-
//#endregion
|
|
2530
|
-
//#region ../../node_modules/@wix/auto_sdk_bookings_bookings/build/es/index.typings.d.mts
|
|
2531
2513
|
declare enum ResourceTransparency {
|
|
2532
2514
|
OPAQUE = "OPAQUE",
|
|
2533
2515
|
TRANSPARENT = "TRANSPARENT"
|
|
@@ -2674,8 +2656,6 @@ interface SlotLocation {
|
|
|
2674
2656
|
locationType?: LocationLocationTypeWithLiterals;
|
|
2675
2657
|
}
|
|
2676
2658
|
/** Response for RescheduleBookingAnonymously */
|
|
2677
|
-
//#endregion
|
|
2678
|
-
//#region ../../node_modules/@wix/auto_sdk_bookings_bookings-settings/build/es/index.typings.d.mts
|
|
2679
2659
|
declare enum BasedOn {
|
|
2680
2660
|
/** Times are displayed in the business's time zone. */
|
|
2681
2661
|
BUSINESS_TIME_ZONE = "BUSINESS_TIME_ZONE",
|
|
@@ -2684,18 +2664,12 @@ declare enum BasedOn {
|
|
|
2684
2664
|
}
|
|
2685
2665
|
/** @enumType */
|
|
2686
2666
|
type BasedOnWithLiterals = BasedOn | 'BUSINESS_TIME_ZONE' | 'CUSTOMER_TIME_ZONE';
|
|
2687
|
-
//#endregion
|
|
2688
|
-
//#region src/api/adapters/service/service.d.ts
|
|
2689
|
-
//#endregion
|
|
2690
|
-
//#region src/domains/states/service-cta-states.d.ts
|
|
2691
2667
|
declare const SERVICE_CTA_STATES: {
|
|
2692
2668
|
readonly BOOK: "book";
|
|
2693
2669
|
readonly REQUEST_TO_BOOK: "requestToBook";
|
|
2694
2670
|
readonly VIEW_COURSE: "viewCourse";
|
|
2695
2671
|
};
|
|
2696
2672
|
type ServiceCtaState = (typeof SERVICE_CTA_STATES)[keyof typeof SERVICE_CTA_STATES];
|
|
2697
|
-
//#endregion
|
|
2698
|
-
//#region ../bookings-flow-data/dist/types.d.ts
|
|
2699
2673
|
/**
|
|
2700
2674
|
* Whether the selection holds 1 service or several services booked together. Supported values:
|
|
2701
2675
|
* - `'single'`: 1 service.
|
|
@@ -2786,8 +2760,6 @@ interface BookingPreferences {
|
|
|
2786
2760
|
*/
|
|
2787
2761
|
wantsPromoCode?: boolean;
|
|
2788
2762
|
}
|
|
2789
|
-
//#endregion
|
|
2790
|
-
//#region src/domains/url-builder/service-selection-url.d.ts
|
|
2791
2763
|
/** Page a course's booking button goes to. */
|
|
2792
2764
|
type CourseNavigationTarget = /** The service page. */'servicePage' /** The booking form, to book the whole course. */ | 'bookingForm';
|
|
2793
2765
|
/** Page a class's or an appointment's booking button goes to. */
|
|
@@ -2804,8 +2776,6 @@ interface ServiceSelectionNavigationConfig {
|
|
|
2804
2776
|
/** Page to go to for a class or an appointment. */
|
|
2805
2777
|
classAppointmentNavigationTarget: ClassAppointmentNavigationTarget;
|
|
2806
2778
|
}
|
|
2807
|
-
//#endregion
|
|
2808
|
-
//#region src/hooks/use-bi-logger/bi-consts.d.ts
|
|
2809
2779
|
declare const BI_WIDGET_NAME: {
|
|
2810
2780
|
readonly SERVICES: "services_context";
|
|
2811
2781
|
readonly SERVICE: "service_context";
|
|
@@ -2823,8 +2793,6 @@ declare const BI_REFERRAL_INFO: {
|
|
|
2823
2793
|
readonly EXPLORE_PLANS: "explore_plans";
|
|
2824
2794
|
};
|
|
2825
2795
|
type BiReferralInfo = (typeof BI_REFERRAL_INFO)[keyof typeof BI_REFERRAL_INFO];
|
|
2826
|
-
//#endregion
|
|
2827
|
-
//#region src/hooks/use-bi-logger/use-bi-logger.d.ts
|
|
2828
2796
|
/** Analytics event to report. */
|
|
2829
2797
|
interface BiEvent {
|
|
2830
2798
|
/** ID of the event's source. */
|
|
@@ -2837,10 +2805,6 @@ interface BiEvent {
|
|
|
2837
2805
|
params: Record<string, unknown>;
|
|
2838
2806
|
}
|
|
2839
2807
|
declare const useBiLogger: (widgetName: BiWidgetName) => (event: BiEvent) => void;
|
|
2840
|
-
//#endregion
|
|
2841
|
-
//#region src/api/adapters/service-options-and-variants/service-options-and-variants.d.ts
|
|
2842
|
-
//#endregion
|
|
2843
|
-
//#region ../../node_modules/@wix/auto_sdk_calendar_events/build/es/index.typings.d.mts
|
|
2844
2808
|
/**
|
|
2845
2809
|
* An event is a scheduled entry on a calendar that includes details like timing,
|
|
2846
2810
|
* location, and participants. Each event is associated with
|
|
@@ -3505,15 +3469,11 @@ interface ExtendedFields {
|
|
|
3505
3469
|
*/
|
|
3506
3470
|
namespaces?: Record<string, Record<string, any>>;
|
|
3507
3471
|
}
|
|
3508
|
-
//#endregion
|
|
3509
|
-
//#region src/domains/offered-days/offered-days.d.ts
|
|
3510
3472
|
/** Day of the week that a service's sessions recur on. */
|
|
3511
3473
|
interface OfferedDay {
|
|
3512
3474
|
/** Day of the week, in uppercase English. For example, `MONDAY`. */
|
|
3513
3475
|
day: string;
|
|
3514
3476
|
}
|
|
3515
|
-
//#endregion
|
|
3516
|
-
//#region src/domains/pricing-options/pricing-options.d.ts
|
|
3517
3477
|
type ServiceOptionType = ServiceOptionTypeWithLiterals;
|
|
3518
3478
|
interface PricingOptionChoice {
|
|
3519
3479
|
/**
|
|
@@ -3597,8 +3557,6 @@ interface PricingOption {
|
|
|
3597
3557
|
/** Choices that the visitor selects from, one for each of the service's variants. */
|
|
3598
3558
|
choices: PricingOptionChoice[];
|
|
3599
3559
|
}
|
|
3600
|
-
//#endregion
|
|
3601
|
-
//#region src/domains/service-price/format-service-price.d.ts
|
|
3602
3560
|
/** Service's price details. Amounts are formatted for the site's locale. */
|
|
3603
3561
|
interface ServicePriceData {
|
|
3604
3562
|
/**
|
|
@@ -3661,8 +3619,6 @@ interface ServicePriceData {
|
|
|
3661
3619
|
*/
|
|
3662
3620
|
isFree: boolean;
|
|
3663
3621
|
}
|
|
3664
|
-
//#endregion
|
|
3665
|
-
//#region src/domains/service-locations/service-locations.d.ts
|
|
3666
3622
|
/** Where a service takes place. */
|
|
3667
3623
|
interface ServiceLocationItem {
|
|
3668
3624
|
/** Kind of location. */
|
|
@@ -3670,8 +3626,6 @@ interface ServiceLocationItem {
|
|
|
3670
3626
|
/** The business location's name or the address. Null for the customer's place: label it in your own words. */
|
|
3671
3627
|
text: string | null;
|
|
3672
3628
|
}
|
|
3673
|
-
//#endregion
|
|
3674
|
-
//#region src/domains/service-bookability/service-bookability.d.ts
|
|
3675
3629
|
declare const AVAILABILITY_STATES: {
|
|
3676
3630
|
readonly AVAILABLE: "available";
|
|
3677
3631
|
readonly FULLY_BOOKED: "fullyBooked";
|
|
@@ -3711,8 +3665,6 @@ interface ServiceBookability {
|
|
|
3711
3665
|
*/
|
|
3712
3666
|
bookingOpensAt: Date | null;
|
|
3713
3667
|
}
|
|
3714
|
-
//#endregion
|
|
3715
|
-
//#region src/api/adapters/staff-member/staff-member.d.ts
|
|
3716
3668
|
/**
|
|
3717
3669
|
* Where a staff member has working hours, derived server-side from their WORKING_HOURS
|
|
3718
3670
|
* calendar events. Returned only when `STAFF_WORKING_HOURS_LOCATIONS` is requested (see
|
|
@@ -3730,8 +3682,6 @@ interface StaffMemberItem {
|
|
|
3730
3682
|
/** Absent when the coverage wasn't returned — callers treat that as "works everywhere". */
|
|
3731
3683
|
locationCoverage?: StaffLocationCoverage;
|
|
3732
3684
|
}
|
|
3733
|
-
//#endregion
|
|
3734
|
-
//#region src/domains/course-availability/course-availability.d.ts
|
|
3735
3685
|
/** Capacity of a course. */
|
|
3736
3686
|
interface CourseAvailability {
|
|
3737
3687
|
/**
|
|
@@ -3747,11 +3697,7 @@ interface CourseAvailability {
|
|
|
3747
3697
|
*/
|
|
3748
3698
|
remainingCapacity: number | null;
|
|
3749
3699
|
}
|
|
3750
|
-
//#endregion
|
|
3751
|
-
//#region src/domains/service-item-fields/service-item-fields.d.ts
|
|
3752
3700
|
type ServiceItemStaffMember = Omit<StaffMemberItem, 'isSelected'>;
|
|
3753
|
-
//#endregion
|
|
3754
|
-
//#region src/domains/url-builder/booking-preferences-blob.types.d.ts
|
|
3755
3701
|
type SelectStaffMember = (staffMemberId: string) => void;
|
|
3756
3702
|
/** Sets an explicit "any available staff", of `requestedGender` when given, else of any gender. */
|
|
3757
3703
|
type ClearSelection = (requestedGender?: RequestedGender) => void;
|
|
@@ -3830,8 +3776,6 @@ type NestedSlotPart = Pick<NestedTimeSlot, 'serviceId' | 'localStartDate' | 'loc
|
|
|
3830
3776
|
type SetMultiServiceSlot = (nestedTimeSlots: ReadonlyArray<NestedSlotPart>, timezone?: string) => boolean;
|
|
3831
3777
|
/** Drops a Multi-Service Appointment's picked time from every entry; locations stay. */
|
|
3832
3778
|
type ClearMultiServiceSlot = () => void;
|
|
3833
|
-
//#endregion
|
|
3834
|
-
//#region src/api/adapters/bookings-settings/bookings-settings.d.ts
|
|
3835
3779
|
/** A policy, not an IANA zone: the real zone needs the business zone from site properties. */
|
|
3836
3780
|
type DisplayTimeZonePolicy = {
|
|
3837
3781
|
/**
|
|
@@ -3860,8 +3804,6 @@ interface ExposedBookingsSettings {
|
|
|
3860
3804
|
/** Whether visitors can book more than 1 service in a single appointment. */
|
|
3861
3805
|
multiServiceAppointmentsEnabled: boolean;
|
|
3862
3806
|
}
|
|
3863
|
-
//#endregion
|
|
3864
|
-
//#region src/extensions/contexts/services-context/services-context.d.ts
|
|
3865
3807
|
/** Raw data only; the nested service-context derives display values. Not for direct binding. */
|
|
3866
3808
|
interface ServiceItem {
|
|
3867
3809
|
/**
|
|
@@ -3917,8 +3859,6 @@ interface ServiceItem {
|
|
|
3917
3859
|
*/
|
|
3918
3860
|
servicePageLink: Link | null;
|
|
3919
3861
|
}
|
|
3920
|
-
//#endregion
|
|
3921
|
-
//#region src/domains/reschedule/reschedule.d.ts
|
|
3922
3862
|
/** The booking being moved, as the calendar needs it. */
|
|
3923
3863
|
interface RescheduledBooking {
|
|
3924
3864
|
/** Booking ID. */
|
|
@@ -3991,8 +3931,6 @@ interface Reschedule {
|
|
|
3991
3931
|
*/
|
|
3992
3932
|
planName: string | null;
|
|
3993
3933
|
}
|
|
3994
|
-
//#endregion
|
|
3995
|
-
//#region src/api/adapters/booking/reschedule-booking.d.ts
|
|
3996
3934
|
/** Who and where the moved booking is with, as the server assigned them. */
|
|
3997
3935
|
interface RescheduledSlot {
|
|
3998
3936
|
/**
|
|
@@ -4008,8 +3946,6 @@ interface RescheduledSlot {
|
|
|
4008
3946
|
*/
|
|
4009
3947
|
locationName: string | null;
|
|
4010
3948
|
}
|
|
4011
|
-
//#endregion
|
|
4012
|
-
//#region src/extensions/contexts/service-context/service-context.d.ts
|
|
4013
3949
|
/** A bookable service with its display values, the visitor's booking selection and the actions to change it, plus multi-service appointment and reschedule state. */
|
|
4014
3950
|
interface ServiceContextValue {
|
|
4015
3951
|
/**
|