@voyant-travel/bookings-react 0.138.8 → 0.138.9

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.
@@ -1 +1 @@
1
- {"version":3,"file":"booking-journey-host.d.ts","sourceRoot":"","sources":["../../src/admin/booking-journey-host.tsx"],"names":[],"mappings":"AAuDA,MAAM,WAAW,uBAAuB;IACtC,YAAY,EAAE,MAAM,CAAA;IACpB,QAAQ,EAAE,MAAM,CAAA;IAChB,4EAA4E;IAC5E,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,kBAAkB,CAAC,EAAE,MAAM,CAAA;IAC3B,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,2EAA2E;IAC3E,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,iFAAiF;IACjF,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd;oCACgC;IAChC,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,OAAO,EAAE,MAAM,CAAA;IACf,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAED,wBAAgB,kBAAkB,CAAC,EACjC,YAAY,EACZ,QAAQ,EACR,UAAU,EACV,kBAAkB,EAClB,SAAS,EACT,WAAW,EACX,aAAa,EACb,QAAQ,EACR,UAAU,EACV,UAAU,EACV,KAAK,EACL,UAAU,EACV,cAAc,EACd,OAAO,EACP,SAAS,GACV,EAAE,uBAAuB,GAAG,KAAK,CAAC,YAAY,CAqG9C"}
1
+ {"version":3,"file":"booking-journey-host.d.ts","sourceRoot":"","sources":["../../src/admin/booking-journey-host.tsx"],"names":[],"mappings":"AAuDA,MAAM,WAAW,uBAAuB;IACtC,YAAY,EAAE,MAAM,CAAA;IACpB,QAAQ,EAAE,MAAM,CAAA;IAChB,4EAA4E;IAC5E,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,kBAAkB,CAAC,EAAE,MAAM,CAAA;IAC3B,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,2EAA2E;IAC3E,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,iFAAiF;IACjF,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd;oCACgC;IAChC,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,OAAO,EAAE,MAAM,CAAA;IACf,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAED,wBAAgB,kBAAkB,CAAC,EACjC,YAAY,EACZ,QAAQ,EACR,UAAU,EACV,kBAAkB,EAClB,SAAS,EACT,WAAW,EACX,aAAa,EACb,QAAQ,EACR,UAAU,EACV,UAAU,EACV,KAAK,EACL,UAAU,EACV,cAAc,EACd,OAAO,EACP,SAAS,GACV,EAAE,uBAAuB,GAAG,KAAK,CAAC,YAAY,CAsG9C"}
@@ -92,14 +92,15 @@ export function BookingJourneyHost({ entityModule, entityId, sourceKind, sourceC
92
92
  ...(ratePlanId ? { ratePlanId } : {}),
93
93
  ...(board ? { board } : {}),
94
94
  }, defaultBuyerType: "B2B",
95
- // Operator payment options: hold (reserve, collect later), online payment
96
- // link (the customer pays via the hosted PSP page — we never charge a card
97
- // instantly here), bank transfer, and agency credit.
95
+ // The admin in-process commit route can reserve/hold bookings. Tokenized
96
+ // card charges, bank-transfer checkout instructions, and agency-credit
97
+ // account collection are separate flows that this packaged host does not
98
+ // wire yet, so do not advertise them here.
98
99
  paymentCapabilities: {
99
- acceptsCard: true,
100
+ acceptsCard: false,
100
101
  acceptsHold: true,
101
- acceptsBankTransfer: true,
102
- acceptsTicketOnCredit: true,
102
+ acceptsBankTransfer: false,
103
+ acceptsTicketOnCredit: false,
103
104
  }, entitySummary: entitySummary, className: className, ...slots }));
104
105
  }
105
106
  /**
@@ -208,9 +209,10 @@ function CrmLeadPicker({ apply, buyerType, variant = "lead", linkedPersonId, })
208
209
  if (!org || appliedOrgId.current === org.id)
209
210
  return;
210
211
  appliedOrgId.current = org.id;
212
+ const companyName = org.legalName ?? org.name;
211
213
  apply({
212
214
  organizationId: org.id,
213
- companyName: org.legalName ?? org.name,
215
+ companyName,
214
216
  taxId: org.taxId ?? undefined,
215
217
  });
216
218
  }, [orgQuery.data]);
@@ -134,8 +134,8 @@ export declare const bookingDetailTabSchema: z.ZodEnum<{
134
134
  metadata: "metadata";
135
135
  items: "items";
136
136
  travelers: "travelers";
137
- activity: "activity";
138
137
  documents: "documents";
138
+ activity: "activity";
139
139
  finance: "finance";
140
140
  invoices: "invoices";
141
141
  suppliers: "suppliers";
@@ -152,8 +152,8 @@ export declare const bookingDetailSearchSchema: z.ZodObject<{
152
152
  metadata: "metadata";
153
153
  items: "items";
154
154
  travelers: "travelers";
155
- activity: "activity";
156
155
  documents: "documents";
156
+ activity: "activity";
157
157
  finance: "finance";
158
158
  invoices: "invoices";
159
159
  suppliers: "suppliers";
@@ -12,7 +12,7 @@ export declare function useSlotExtraManifestMutation(slotId: string): {
12
12
  productExtraId: string;
13
13
  optionExtraConfigId?: string | null | undefined;
14
14
  status?: "selected" | "cancelled" | "fulfilled" | "no_show" | undefined;
15
- collectionStatus?: "pending" | "not_required" | "collected" | "waived" | "refunded" | undefined;
15
+ collectionStatus?: "not_required" | "pending" | "collected" | "waived" | "refunded" | undefined;
16
16
  collectionCurrency?: string | null | undefined;
17
17
  collectionAmountCents?: number | null | undefined;
18
18
  notes?: string | null | undefined;
@@ -27,7 +27,7 @@ export declare function useSlotExtraManifestMutation(slotId: string): {
27
27
  productExtraId: string;
28
28
  optionExtraConfigId?: string | null | undefined;
29
29
  status?: "selected" | "cancelled" | "fulfilled" | "no_show" | undefined;
30
- collectionStatus?: "pending" | "not_required" | "collected" | "waived" | "refunded" | undefined;
30
+ collectionStatus?: "not_required" | "pending" | "collected" | "waived" | "refunded" | undefined;
31
31
  collectionCurrency?: string | null | undefined;
32
32
  collectionAmountCents?: number | null | undefined;
33
33
  notes?: string | null | undefined;
@@ -39,7 +39,7 @@ export declare function useSlotExtraManifestMutation(slotId: string): {
39
39
  }, Error, {
40
40
  productExtraId: string;
41
41
  travelerIds: string[];
42
- collectionStatus: "pending" | "not_required" | "collected" | "waived" | "refunded";
42
+ collectionStatus: "not_required" | "pending" | "collected" | "waived" | "refunded";
43
43
  collectionCurrency?: string | null | undefined;
44
44
  collectionAmountCents?: number | null | undefined;
45
45
  notes?: string | null | undefined;
@@ -55,7 +55,7 @@ export declare function useSlotExtraManifest(slotId: string | null | undefined,
55
55
  status: "selected" | "cancelled" | "fulfilled" | "no_show";
56
56
  selected: boolean;
57
57
  collectionMode: "cash_on_trip" | "external" | "included" | "none" | "booking_total";
58
- collectionStatus: "pending" | "not_required" | "collected" | "waived" | "refunded";
58
+ collectionStatus: "not_required" | "pending" | "collected" | "waived" | "refunded";
59
59
  collectionCurrency: string | null;
60
60
  collectionAmountCents: number | null;
61
61
  collectedAt: string | null;
@@ -243,7 +243,7 @@ export declare function getSlotExtraManifestQueryOptions(client: FetchWithValida
243
243
  status: "selected" | "cancelled" | "fulfilled" | "no_show";
244
244
  selected: boolean;
245
245
  collectionMode: "cash_on_trip" | "external" | "included" | "none" | "booking_total";
246
- collectionStatus: "pending" | "not_required" | "collected" | "waived" | "refunded";
246
+ collectionStatus: "not_required" | "pending" | "collected" | "waived" | "refunded";
247
247
  collectionCurrency: string | null;
248
248
  collectionAmountCents: number | null;
249
249
  collectedAt: string | null;
@@ -307,7 +307,7 @@ export declare function getSlotExtraManifestQueryOptions(client: FetchWithValida
307
307
  status: "selected" | "cancelled" | "fulfilled" | "no_show";
308
308
  selected: boolean;
309
309
  collectionMode: "cash_on_trip" | "external" | "included" | "none" | "booking_total";
310
- collectionStatus: "pending" | "not_required" | "collected" | "waived" | "refunded";
310
+ collectionStatus: "not_required" | "pending" | "collected" | "waived" | "refunded";
311
311
  collectionCurrency: string | null;
312
312
  collectionAmountCents: number | null;
313
313
  collectedAt: string | null;
@@ -372,7 +372,7 @@ export declare function getSlotExtraManifestQueryOptions(client: FetchWithValida
372
372
  status: "selected" | "cancelled" | "fulfilled" | "no_show";
373
373
  selected: boolean;
374
374
  collectionMode: "cash_on_trip" | "external" | "included" | "none" | "booking_total";
375
- collectionStatus: "pending" | "not_required" | "collected" | "waived" | "refunded";
375
+ collectionStatus: "not_required" | "pending" | "collected" | "waived" | "refunded";
376
376
  collectionCurrency: string | null;
377
377
  collectionAmountCents: number | null;
378
378
  collectedAt: string | null;
@@ -439,7 +439,7 @@ export declare function getSlotExtraManifestQueryOptions(client: FetchWithValida
439
439
  status: "selected" | "cancelled" | "fulfilled" | "no_show";
440
440
  selected: boolean;
441
441
  collectionMode: "cash_on_trip" | "external" | "included" | "none" | "booking_total";
442
- collectionStatus: "pending" | "not_required" | "collected" | "waived" | "refunded";
442
+ collectionStatus: "not_required" | "pending" | "collected" | "waived" | "refunded";
443
443
  collectionCurrency: string | null;
444
444
  collectionAmountCents: number | null;
445
445
  collectedAt: string | null;
@@ -175,8 +175,8 @@ export declare const slotExtraManifestSelectionSchema: z.ZodObject<{
175
175
  booking_total: "booking_total";
176
176
  }>;
177
177
  collectionStatus: z.ZodEnum<{
178
- pending: "pending";
179
178
  not_required: "not_required";
179
+ pending: "pending";
180
180
  collected: "collected";
181
181
  waived: "waived";
182
182
  refunded: "refunded";
@@ -278,8 +278,8 @@ export declare const slotExtraManifestSchema: z.ZodObject<{
278
278
  booking_total: "booking_total";
279
279
  }>;
280
280
  collectionStatus: z.ZodEnum<{
281
- pending: "pending";
282
281
  not_required: "not_required";
282
+ pending: "pending";
283
283
  collected: "collected";
284
284
  waived: "waived";
285
285
  refunded: "refunded";
@@ -383,8 +383,8 @@ export declare const slotExtraManifestResponse: z.ZodObject<{
383
383
  booking_total: "booking_total";
384
384
  }>;
385
385
  collectionStatus: z.ZodEnum<{
386
- pending: "pending";
387
386
  not_required: "not_required";
387
+ pending: "pending";
388
388
  collected: "collected";
389
389
  waived: "waived";
390
390
  refunded: "refunded";
@@ -18,7 +18,7 @@ export declare function useBookingActionLedger(bookingId: string | null | undefi
18
18
  actionVersion: string;
19
19
  actionKind: "reverse" | "read" | "create" | "update" | "delete" | "execute" | "approve" | "reject" | "compensate" | "duplicate";
20
20
  status: "cancelled" | "expired" | "requested" | "awaiting_approval" | "approved" | "denied" | "succeeded" | "failed" | "reversed" | "compensated" | "superseded";
21
- evaluatedRisk: "high" | "low" | "medium" | "critical";
21
+ evaluatedRisk: "low" | "medium" | "high" | "critical";
22
22
  actorType: string | null;
23
23
  principalType: "user" | "api_key" | "agent" | "workflow" | "system";
24
24
  principalId: string;
@@ -16,7 +16,7 @@ export declare function useSupplierStatusMutation(bookingId: string): {
16
16
  bookingId: string;
17
17
  supplierServiceId: string | null;
18
18
  serviceName: string;
19
- status: "pending" | "cancelled" | "confirmed" | "rejected";
19
+ status: "cancelled" | "pending" | "confirmed" | "rejected";
20
20
  supplierReference: string | null;
21
21
  costCurrency: string;
22
22
  costAmountCents: number;
@@ -30,7 +30,7 @@ export declare function useSupplierStatusMutation(bookingId: string): {
30
30
  bookingId: string;
31
31
  supplierServiceId: string | null;
32
32
  serviceName: string;
33
- status: "pending" | "cancelled" | "confirmed" | "rejected";
33
+ status: "cancelled" | "pending" | "confirmed" | "rejected";
34
34
  supplierReference: string | null;
35
35
  costCurrency: string;
36
36
  costAmountCents: number;
@@ -7,7 +7,7 @@ export declare function useSupplierStatuses(bookingId: string | null | undefined
7
7
  bookingId: string;
8
8
  supplierServiceId: string | null;
9
9
  serviceName: string;
10
- status: "pending" | "cancelled" | "confirmed" | "rejected";
10
+ status: "cancelled" | "pending" | "confirmed" | "rejected";
11
11
  supplierReference: string | null;
12
12
  costCurrency: string;
13
13
  costAmountCents: number;
@@ -15,6 +15,15 @@ export declare function buildCommitParty(draft: Draft): Record<string, unknown>;
15
15
  * otherwise awaiting payment.
16
16
  */
17
17
  export declare function resolveInitialStatus(draft: Draft): "draft" | "confirmed" | "awaiting_payment";
18
+ /**
19
+ * The packaged admin journey's in-process commit route can only create a held
20
+ * booking. Other payment intents need a dedicated checkout/provider flow
21
+ * because the route contract requires fields the generic draft does not carry
22
+ * (`tokenizedCard`, `agencyAccount`, bank-transfer instructions, etc.).
23
+ */
24
+ export declare function buildCommitPaymentIntent(draft: Draft): {
25
+ type: "hold";
26
+ };
18
27
  export declare function isStepVisible(step: JourneyStep, shape: BookingDraftShape): boolean;
19
28
  export declare function canAdvanceFromStep(step: JourneyStep, draft: Draft, shape: BookingDraftShape, available: boolean): boolean;
20
29
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"booking-journey-rules.d.ts","sourceRoot":"","sources":["../../../src/journey/components/booking-journey-rules.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,iBAAiB,EAOvB,MAAM,6DAA6D,CAAA;AACpE,OAAO,EAAE,KAAK,kBAAkB,EAAiB,MAAM,qBAAqB,CAAA;AAC5E,OAAO,EAAE,KAAK,KAAK,EAAY,MAAM,uBAAuB,CAAA;AAG5D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,aAAa,CAAA;AAE9C;;;;;GAKG;AACH,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,KAAK,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAqBtE;AAED;;;;GAIG;AACH,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,KAAK,GAAG,OAAO,GAAG,WAAW,GAAG,kBAAkB,CAK7F;AAED,wBAAgB,aAAa,CAAC,IAAI,EAAE,WAAW,EAAE,KAAK,EAAE,iBAAiB,GAAG,OAAO,CAgClF;AAED,wBAAgB,kBAAkB,CAChC,IAAI,EAAE,WAAW,EACjB,KAAK,EAAE,KAAK,EACZ,KAAK,EAAE,iBAAiB,EACxB,SAAS,EAAE,OAAO,GACjB,OAAO,CA2DT;AAED;;;;;;;;GAQG;AACH,wBAAgB,mBAAmB,CACjC,IAAI,EAAE,WAAW,EACjB,KAAK,EAAE,KAAK,EACZ,KAAK,EAAE,iBAAiB,EACxB,SAAS,EAAE,OAAO,GACjB,OAAO,CAeT;AAED;;;;;;;;GAQG;AACH,wBAAgB,eAAe,CAC7B,IAAI,EAAE,WAAW,EACjB,KAAK,EAAE,KAAK,EACZ,KAAK,EAAE,iBAAiB,EACxB,QAAQ,EAAE,kBAAkB,GAC3B,aAAa,CAAC,MAAM,CAAC,CA4DvB;AAMD;;;;;GAKG;AACH,wBAAgB,iBAAiB,CAC/B,KAAK,EAAE,KAAK,EACZ,YAAY,EAAE,MAAM,EACpB,QAAQ,EAAE,MAAM,GACf,MAAM,GAAG,IAAI,CAMf;AAED,wBAAgB,mBAAmB,IAAI,iBAAiB,CAavD"}
1
+ {"version":3,"file":"booking-journey-rules.d.ts","sourceRoot":"","sources":["../../../src/journey/components/booking-journey-rules.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,iBAAiB,EAOvB,MAAM,6DAA6D,CAAA;AACpE,OAAO,EAAE,KAAK,kBAAkB,EAAiB,MAAM,qBAAqB,CAAA;AAC5E,OAAO,EAAE,KAAK,KAAK,EAAY,MAAM,uBAAuB,CAAA;AAG5D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,aAAa,CAAA;AAE9C;;;;;GAKG;AACH,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,KAAK,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CA2BtE;AAED;;;;GAIG;AACH,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,KAAK,GAAG,OAAO,GAAG,WAAW,GAAG,kBAAkB,CAK7F;AAED;;;;;GAKG;AACH,wBAAgB,wBAAwB,CAAC,KAAK,EAAE,KAAK,GAAG;IAAE,IAAI,EAAE,MAAM,CAAA;CAAE,CAGvE;AAED,wBAAgB,aAAa,CAAC,IAAI,EAAE,WAAW,EAAE,KAAK,EAAE,iBAAiB,GAAG,OAAO,CAgClF;AAED,wBAAgB,kBAAkB,CAChC,IAAI,EAAE,WAAW,EACjB,KAAK,EAAE,KAAK,EACZ,KAAK,EAAE,iBAAiB,EACxB,SAAS,EAAE,OAAO,GACjB,OAAO,CA2DT;AAED;;;;;;;;GAQG;AACH,wBAAgB,mBAAmB,CACjC,IAAI,EAAE,WAAW,EACjB,KAAK,EAAE,KAAK,EACZ,KAAK,EAAE,iBAAiB,EACxB,SAAS,EAAE,OAAO,GACjB,OAAO,CAeT;AAED;;;;;;;;GAQG;AACH,wBAAgB,eAAe,CAC7B,IAAI,EAAE,WAAW,EACjB,KAAK,EAAE,KAAK,EACZ,KAAK,EAAE,iBAAiB,EACxB,QAAQ,EAAE,kBAAkB,GAC3B,aAAa,CAAC,MAAM,CAAC,CA4DvB;AAMD;;;;;GAKG;AACH,wBAAgB,iBAAiB,CAC/B,KAAK,EAAE,KAAK,EACZ,YAAY,EAAE,MAAM,EACpB,QAAQ,EAAE,MAAM,GACf,MAAM,GAAG,IAAI,CAMf;AAED,wBAAgB,mBAAmB,IAAI,iBAAiB,CAavD"}
@@ -11,18 +11,22 @@ import { findPaidScheduleRowsMissingPaymentDate } from "../lib/payment-schedule.
11
11
  */
12
12
  export function buildCommitParty(draft) {
13
13
  const c = draft.billing.contact;
14
+ const companyName = draft.billing.company?.name?.trim();
15
+ const contactFirstName = draft.billing.buyerType === "B2B" && companyName ? companyName : c.firstName;
16
+ const contactLastName = draft.billing.buyerType === "B2B" && contactFirstName === companyName ? "" : c.lastName;
17
+ const personId = draft.billing.buyerType === "B2B" ? undefined : c.personId;
14
18
  const organizationId = draft.billing.buyerType === "B2B" ? draft.billing.organizationId : undefined;
15
19
  return {
16
- personId: c.personId,
20
+ personId,
17
21
  organizationId,
18
22
  billing: {
19
- personId: c.personId,
23
+ personId,
20
24
  organizationId,
21
25
  contact: {
22
- firstName: c.firstName,
23
- lastName: c.lastName,
24
- email: c.email,
25
- phone: c.phone,
26
+ firstName: contactFirstName,
27
+ lastName: contactLastName,
28
+ email: draft.billing.buyerType === "B2B" && companyName ? "" : c.email,
29
+ phone: draft.billing.buyerType === "B2B" && companyName ? undefined : c.phone,
26
30
  },
27
31
  },
28
32
  travelerParty: {
@@ -42,6 +46,17 @@ export function resolveInitialStatus(draft) {
42
46
  const fullyPaid = schedules.length > 0 && schedules.every((s) => s.status === "paid");
43
47
  return fullyPaid ? "confirmed" : "awaiting_payment";
44
48
  }
49
+ /**
50
+ * The packaged admin journey's in-process commit route can only create a held
51
+ * booking. Other payment intents need a dedicated checkout/provider flow
52
+ * because the route contract requires fields the generic draft does not carry
53
+ * (`tokenizedCard`, `agencyAccount`, bank-transfer instructions, etc.).
54
+ */
55
+ export function buildCommitPaymentIntent(draft) {
56
+ if (draft.payment.intent === "hold")
57
+ return { type: "hold" };
58
+ throw new Error(`Unsupported booking payment intent: ${draft.payment.intent}`);
59
+ }
45
60
  export function isStepVisible(step, shape) {
46
61
  const subSteps = shape.configureSubSteps ?? [];
47
62
  switch (step) {
@@ -1 +1 @@
1
- {"version":3,"file":"booking-journey.d.ts","sourceRoot":"","sources":["../../../src/journey/components/booking-journey.tsx"],"names":[],"mappings":"AAgCA,OAAO,EACL,KAAK,mBAAmB,EAIzB,MAAM,aAAa,CAAA;AA6BpB,wBAAgB,cAAc,CAAC,KAAK,EAAE,mBAAmB,GAAG,KAAK,CAAC,YAAY,CAkwB7E"}
1
+ {"version":3,"file":"booking-journey.d.ts","sourceRoot":"","sources":["../../../src/journey/components/booking-journey.tsx"],"names":[],"mappings":"AAgCA,OAAO,EACL,KAAK,mBAAmB,EAIzB,MAAM,aAAa,CAAA;AA8BpB,wBAAgB,cAAc,CAAC,KAAK,EAAE,mBAAmB,GAAG,KAAK,CAAC,YAAY,CAkwB7E"}
@@ -8,7 +8,7 @@ import { useBookingsUiMessagesOrDefault } from "../../i18n/index.js";
8
8
  import { emptyDraft, totalPax } from "../lib/draft-state.js";
9
9
  import { findPaidScheduleRowsMissingPaymentDate } from "../lib/payment-schedule.js";
10
10
  import { JOURNEY_STEP_ORDER, } from "../types.js";
11
- import { buildCommitParty, canAdvanceFromStep, defaultMinimalShape, isStepVisible, makeHoldSignature, resolveInitialStatus, stackedStepComplete, warningsForStep, } from "./booking-journey-rules.js";
11
+ import { buildCommitParty, buildCommitPaymentIntent, canAdvanceFromStep, defaultMinimalShape, isStepVisible, makeHoldSignature, resolveInitialStatus, stackedStepComplete, warningsForStep, } from "./booking-journey-rules.js";
12
12
  import { ConfigureStepSkeleton } from "./configure-step-skeleton.js";
13
13
  import { ContractPreviewDialog } from "./contract-preview-dialog.js";
14
14
  import { AccommodationStep, AddonsStep, BillingStep, DepartureStep, DocumentsStep, FinalizeControls, OptionsStep, PaymentStep, ReviewStep, TravelersStep, } from "./journey-steps.js";
@@ -287,7 +287,7 @@ export function BookingJourney(props) {
287
287
  // draft — without this the create rejects with "no billing person/org".
288
288
  party: buildCommitParty(draft),
289
289
  initialStatus: resolveInitialStatus(draft),
290
- paymentIntent: { type: draft.payment.intent === "card" ? "card" : "hold" },
290
+ paymentIntent: buildCommitPaymentIntent(draft),
291
291
  });
292
292
  };
293
293
  const handleAccepted = async (acceptance) => {
@@ -1 +1 @@
1
- {"version":3,"file":"review-step.d.ts","sourceRoot":"","sources":["../../../../src/journey/components/journey-steps/review-step.tsx"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,0BAA0B,CAAA;AAOrD,wBAAgB,UAAU,CAAC,EACzB,KAAK,EACL,QAAQ,EACR,YAAY,EACZ,SAAS,EACT,UAAU,EACV,YAAY,EACZ,OAAO,EACP,QAAQ,GACT,EAAE;IACD,KAAK,EAAE,KAAK,CAAA;IACZ,QAAQ,EAAE,CAAC,IAAI,EAAE,KAAK,KAAK,IAAI,CAAA;IAC/B,YAAY,EAAE,OAAO,CAAA;IACrB,SAAS,EAAE,MAAM,IAAI,CAAA;IACrB,QAAQ,CAAC,EAAE,aAAa,CAAC,MAAM,CAAC,CAAA;IAChC;;;sCAGkC;IAClC,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB,YAAY,CAAC,EAAE,MAAM,KAAK,CAAC,SAAS,CAAA;IACpC;;;;;OAKG;IACH,OAAO,CAAC,EAAE,OAAO,GAAG,QAAQ,CAAA;IAC5B,uEAAuE;IACvE,OAAO,CAAC,EAAE;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,QAAQ,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI,CAAA;CACrD,GAAG,KAAK,CAAC,YAAY,CAiErB"}
1
+ {"version":3,"file":"review-step.d.ts","sourceRoot":"","sources":["../../../../src/journey/components/journey-steps/review-step.tsx"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,0BAA0B,CAAA;AAOrD,wBAAgB,UAAU,CAAC,EACzB,KAAK,EACL,QAAQ,EACR,YAAY,EACZ,SAAS,EACT,UAAU,EACV,YAAY,EACZ,OAAO,EACP,QAAQ,GACT,EAAE;IACD,KAAK,EAAE,KAAK,CAAA;IACZ,QAAQ,EAAE,CAAC,IAAI,EAAE,KAAK,KAAK,IAAI,CAAA;IAC/B,YAAY,EAAE,OAAO,CAAA;IACrB,SAAS,EAAE,MAAM,IAAI,CAAA;IACrB,QAAQ,CAAC,EAAE,aAAa,CAAC,MAAM,CAAC,CAAA;IAChC;;;sCAGkC;IAClC,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB,YAAY,CAAC,EAAE,MAAM,KAAK,CAAC,SAAS,CAAA;IACpC;;;;;OAKG;IACH,OAAO,CAAC,EAAE,OAAO,GAAG,QAAQ,CAAA;IAC5B,uEAAuE;IACvE,OAAO,CAAC,EAAE;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,QAAQ,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI,CAAA;CACrD,GAAG,KAAK,CAAC,YAAY,CAqErB"}
@@ -14,5 +14,9 @@ import { JourneyWarnings } from "./shared.js";
14
14
  export function ReviewStep({ draft, setDraft, isCommitting, onConfirm, canConfirm, renderExtras, surface, warnings, }) {
15
15
  const messages = useBookingsUiMessagesOrDefault();
16
16
  const isPublic = surface === "public";
17
- return (_jsxs(Card, { children: [_jsx(CardHeader, { children: _jsx(CardTitle, { children: messages.bookingJourney.review.title }) }), _jsx(Separator, {}), _jsxs(CardContent, { className: "space-y-4", children: [_jsxs("div", { children: [_jsx("div", { className: "font-medium", children: messages.bookingJourney.review.leadContact }), _jsxs("div", { className: "text-muted-foreground text-sm", children: [draft.billing.contact.firstName, " ", draft.billing.contact.lastName, " \u00B7", " ", draft.billing.contact.email] })] }), _jsxs("div", { children: [_jsx("div", { className: "font-medium", children: messages.bookingJourney.review.travelers }), _jsx("ul", { className: "text-muted-foreground text-sm", children: draft.travelers.map((t, i) => (_jsxs("li", { children: [t.firstName, " ", t.lastName, " (", t.band, ")"] }, t.rowId ?? i))) })] }), isPublic ? (_jsxs("div", { className: "space-y-1", children: [_jsx(Label, { htmlFor: "bj-customer-notes", children: messages.bookingJourney.review.customerNotes }), _jsx(Textarea, { id: "bj-customer-notes", placeholder: messages.bookingJourney.review.customerNotesPlaceholder, value: draft.customerNotes ?? "", onChange: (e) => setDraft({ ...draft, customerNotes: e.target.value }) })] })) : null, renderExtras ? _jsx("div", { children: renderExtras() }) : null, _jsx(JourneyWarnings, { warnings: warnings }), _jsxs("div", { className: "space-y-2", children: [_jsx(Button, { onClick: onConfirm, disabled: isCommitting || canConfirm === false, children: isCommitting ? (_jsxs(_Fragment, { children: [_jsx(Loader2, { className: "mr-2 h-4 w-4 animate-spin" }), messages.bookingJourney.review.confirming] })) : (messages.bookingJourney.review.confirmBooking) }), canConfirm === false ? (_jsx("p", { className: "text-muted-foreground text-sm", children: messages.bookingJourney.review.completeToConfirm })) : null] })] })] }));
17
+ const leadName = (draft.billing.buyerType === "B2B" ? draft.billing.company?.name : undefined) ||
18
+ [draft.billing.contact.firstName, draft.billing.contact.lastName].filter(Boolean).join(" ") ||
19
+ messages.bookingJourney.values.noValue;
20
+ const leadEmail = draft.billing.contact.email || messages.bookingJourney.values.noValue;
21
+ return (_jsxs(Card, { children: [_jsx(CardHeader, { children: _jsx(CardTitle, { children: messages.bookingJourney.review.title }) }), _jsx(Separator, {}), _jsxs(CardContent, { className: "space-y-4", children: [_jsxs("div", { children: [_jsx("div", { className: "font-medium", children: messages.bookingJourney.review.leadContact }), _jsxs("div", { className: "text-muted-foreground text-sm", children: [leadName, " \u00B7 ", leadEmail] })] }), _jsxs("div", { children: [_jsx("div", { className: "font-medium", children: messages.bookingJourney.review.travelers }), _jsx("ul", { className: "text-muted-foreground text-sm", children: draft.travelers.map((t, i) => (_jsxs("li", { children: [t.firstName, " ", t.lastName, " (", t.band, ")"] }, t.rowId ?? i))) })] }), isPublic ? (_jsxs("div", { className: "space-y-1", children: [_jsx(Label, { htmlFor: "bj-customer-notes", children: messages.bookingJourney.review.customerNotes }), _jsx(Textarea, { id: "bj-customer-notes", placeholder: messages.bookingJourney.review.customerNotesPlaceholder, value: draft.customerNotes ?? "", onChange: (e) => setDraft({ ...draft, customerNotes: e.target.value }) })] })) : null, renderExtras ? _jsx("div", { children: renderExtras() }) : null, _jsx(JourneyWarnings, { warnings: warnings }), _jsxs("div", { className: "space-y-2", children: [_jsx(Button, { onClick: onConfirm, disabled: isCommitting || canConfirm === false, children: isCommitting ? (_jsxs(_Fragment, { children: [_jsx(Loader2, { className: "mr-2 h-4 w-4 animate-spin" }), messages.bookingJourney.review.confirming] })) : (messages.bookingJourney.review.confirmBooking) }), canConfirm === false ? (_jsx("p", { className: "text-muted-foreground text-sm", children: messages.bookingJourney.review.completeToConfirm })) : null] })] })] }));
18
22
  }
@@ -1 +1 @@
1
- {"version":3,"file":"side-panel.d.ts","sourceRoot":"","sources":["../../../src/journey/components/side-panel.tsx"],"names":[],"mappings":"AAWA,OAAO,EAAiB,8BAA8B,EAAE,MAAM,qBAAqB,CAAA;AACnF,OAAO,KAAK,EAAwB,WAAW,EAAE,cAAc,EAAE,MAAM,aAAa,CAAA;AAEpF;;;;;;GAMG;AACH,wBAAgB,cAAc,CAAC,EAC7B,OAAO,EACP,SAAS,EACT,aAAa,EACb,aAAa,EACb,WAAW,EACX,KAAK,EACL,KAAK,EACL,KAAK,EACL,SAAS,EACT,aAAa,GACd,EAAE,cAAc,GAAG;IAClB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB;kDAC8C;IAC9C,aAAa,CAAC,EAAE,KAAK,CAAC,SAAS,CAAA;CAChC,GAAG,KAAK,CAAC,YAAY,CA2FrB;AAoFD,wBAAgB,YAAY,CAC1B,IAAI,EAAE,WAAW,EACjB,KAAK,EAAE,WAAW,CAAC,cAAc,CAAC,OAAO,CAAC,CAAC,EAC3C,QAAQ,EAAE,UAAU,CAAC,OAAO,8BAA8B,CAAC,GAC1D,MAAM,CAgER"}
1
+ {"version":3,"file":"side-panel.d.ts","sourceRoot":"","sources":["../../../src/journey/components/side-panel.tsx"],"names":[],"mappings":"AAWA,OAAO,EAAiB,8BAA8B,EAAE,MAAM,qBAAqB,CAAA;AACnF,OAAO,KAAK,EAAwB,WAAW,EAAE,cAAc,EAAE,MAAM,aAAa,CAAA;AAEpF;;;;;;GAMG;AACH,wBAAgB,cAAc,CAAC,EAC7B,OAAO,EACP,SAAS,EACT,aAAa,EACb,aAAa,EACb,WAAW,EACX,KAAK,EACL,KAAK,EACL,KAAK,EACL,SAAS,EACT,aAAa,GACd,EAAE,cAAc,GAAG;IAClB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB;kDAC8C;IAC9C,aAAa,CAAC,EAAE,KAAK,CAAC,SAAS,CAAA;CAChC,GAAG,KAAK,CAAC,YAAY,CA2FrB;AAoFD,wBAAgB,YAAY,CAC1B,IAAI,EAAE,WAAW,EACjB,KAAK,EAAE,WAAW,CAAC,cAAc,CAAC,OAAO,CAAC,CAAC,EAC3C,QAAQ,EAAE,UAAU,CAAC,OAAO,8BAA8B,CAAC,GAC1D,MAAM,CAkER"}
@@ -80,7 +80,8 @@ export function stepHeadline(step, draft, messages) {
80
80
  case "billing": {
81
81
  const c = draft.billing.contact;
82
82
  const name = [c.firstName, c.lastName].filter(Boolean).join(" ").trim();
83
- return name || c.email || messages.bookingJourney.values.notSet;
83
+ const companyName = draft.billing.buyerType === "B2B" ? draft.billing.company?.name?.trim() : undefined;
84
+ return companyName || name || c.email || messages.bookingJourney.values.notSet;
84
85
  }
85
86
  case "travelers": {
86
87
  const filled = draft.travelers.filter((t) => t.firstName && t.lastName).length;
@@ -161,8 +162,9 @@ function BillingDetails({ draft, }) {
161
162
  const c = draft.billing.contact;
162
163
  const a = draft.billing.address;
163
164
  const addressLine = [a.line1, a.line2, a.city, a.postal, a.country].filter(Boolean).join(", ");
164
- return (_jsxs("dl", { className: "space-y-1 text-xs", children: [_jsx(Row, { label: messages.bookingJourney.sidePanel.name, value: [c.firstName, c.lastName].filter(Boolean).join(" ") ||
165
- messages.bookingJourney.values.noValue }), _jsx(Row, { label: messages.bookingJourney.sidePanel.email, value: c.email || messages.bookingJourney.values.noValue }), c.phone ? _jsx(Row, { label: messages.bookingJourney.sidePanel.phone, value: c.phone }) : null, _jsx(Row, { label: messages.bookingJourney.sidePanel.buyer, value: draft.billing.buyerType === "B2B"
165
+ const contactName = (draft.billing.buyerType === "B2B" ? draft.billing.company?.name : undefined) ||
166
+ [c.firstName, c.lastName].filter(Boolean).join(" ");
167
+ return (_jsxs("dl", { className: "space-y-1 text-xs", children: [_jsx(Row, { label: messages.bookingJourney.sidePanel.name, value: contactName || messages.bookingJourney.values.noValue }), _jsx(Row, { label: messages.bookingJourney.sidePanel.email, value: c.email || messages.bookingJourney.values.noValue }), c.phone ? _jsx(Row, { label: messages.bookingJourney.sidePanel.phone, value: c.phone }) : null, _jsx(Row, { label: messages.bookingJourney.sidePanel.buyer, value: draft.billing.buyerType === "B2B"
166
168
  ? messages.bookingJourney.sidePanel.company
167
169
  : messages.bookingJourney.sidePanel.individual }), draft.billing.buyerType === "B2B" && draft.billing.company?.name ? (_jsx(Row, { label: messages.bookingJourney.sidePanel.company, value: draft.billing.company.name })) : null, draft.billing.buyerType === "B2B" && draft.billing.company?.vatId ? (_jsx(Row, { label: messages.bookingJourney.sidePanel.vat, value: draft.billing.company.vatId })) : null, addressLine ? (_jsx(Row, { label: messages.bookingJourney.sidePanel.address, value: addressLine })) : null] }));
168
170
  }
@@ -1 +1 @@
1
- {"version":3,"file":"draft-state.d.ts","sourceRoot":"","sources":["../../../src/journey/lib/draft-state.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,2DAA2D,CAAA;AAE/F,MAAM,MAAM,KAAK,GAAG,cAAc,CAAA;AAElC,MAAM,WAAW,mBAAmB;IAClC,MAAM,EAAE,MAAM,CAAA;IACd,EAAE,EAAE,MAAM,CAAA;IACV;;;;OAIG;IACH,UAAU,EAAE,MAAM,CAAA;IAClB,kBAAkB,CAAC,EAAE,MAAM,CAAA;IAC3B,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAED,wBAAgB,UAAU,CACxB,MAAM,EAAE,mBAAmB,EAC3B,QAAQ,GAAE;IAAE,SAAS,CAAC,EAAE,KAAK,GAAG,KAAK,CAAA;CAAO,GAC3C,KAAK,CAaP;AAED,wBAAgB,cAAc,CAAC,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,OAAO,CAAC,KAAK,CAAC,WAAW,CAAC,CAAC,GAAG,KAAK,CAEtF;AAED,wBAAgB,YAAY,CAAC,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,OAAO,CAAC,KAAK,CAAC,SAAS,CAAC,CAAC,GAAG,KAAK,CAElF;AAED,wBAAgB,mBAAmB,CAAC,KAAK,EAAE,KAAK,EAAE,SAAS,EAAE,KAAK,GAAG,KAAK,GAAG,KAAK,CAcjF;AAED,wBAAgB,+BAA+B,CAAC,OAAO,EAAE,KAAK,CAAC,SAAS,CAAC,CAAC,SAAS,CAAC,GAAG,OAAO,CAE7F;AAED,wBAAgB,aAAa,CAAC,KAAK,EAAE,KAAK,EAAE,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,KAAK,CAK9E;AAED,wBAAgB,YAAY,CAAC,KAAK,EAAE,KAAK,EAAE,SAAS,EAAE,KAAK,CAAC,WAAW,CAAC,GAAG,KAAK,CAE/E;AAED,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,KAAK,EAAE,aAAa,EAAE,KAAK,CAAC,eAAe,CAAC,GAAG,KAAK,CAE3F;AAED,wBAAgB,SAAS,CAAC,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,KAAK,CAAC,QAAQ,CAAC,GAAG,KAAK,CAEtE;AAED,wBAAgB,UAAU,CAAC,KAAK,EAAE,KAAK,EAAE,OAAO,EAAE,KAAK,CAAC,SAAS,CAAC,GAAG,KAAK,CAEzE;AAED,wBAAgB,QAAQ,CAAC,KAAK,EAAE,KAAK,GAAG,MAAM,CAM7C"}
1
+ {"version":3,"file":"draft-state.d.ts","sourceRoot":"","sources":["../../../src/journey/lib/draft-state.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,2DAA2D,CAAA;AAE/F,MAAM,MAAM,KAAK,GAAG,cAAc,CAAA;AAElC,MAAM,WAAW,mBAAmB;IAClC,MAAM,EAAE,MAAM,CAAA;IACd,EAAE,EAAE,MAAM,CAAA;IACV;;;;OAIG;IACH,UAAU,EAAE,MAAM,CAAA;IAClB,kBAAkB,CAAC,EAAE,MAAM,CAAA;IAC3B,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAED,wBAAgB,UAAU,CACxB,MAAM,EAAE,mBAAmB,EAC3B,QAAQ,GAAE;IAAE,SAAS,CAAC,EAAE,KAAK,GAAG,KAAK,CAAA;CAAO,GAC3C,KAAK,CAaP;AAED,wBAAgB,cAAc,CAAC,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,OAAO,CAAC,KAAK,CAAC,WAAW,CAAC,CAAC,GAAG,KAAK,CAEtF;AAED,wBAAgB,YAAY,CAAC,KAAK,EAAE,KAAK,EAAE,KAAK,EAAE,OAAO,CAAC,KAAK,CAAC,SAAS,CAAC,CAAC,GAAG,KAAK,CAElF;AAED,wBAAgB,mBAAmB,CAAC,KAAK,EAAE,KAAK,EAAE,SAAS,EAAE,KAAK,GAAG,KAAK,GAAG,KAAK,CAiBjF;AAED,wBAAgB,+BAA+B,CAAC,OAAO,EAAE,KAAK,CAAC,SAAS,CAAC,CAAC,SAAS,CAAC,GAAG,OAAO,CAE7F;AAED,wBAAgB,aAAa,CAAC,KAAK,EAAE,KAAK,EAAE,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,KAAK,CAK9E;AAED,wBAAgB,YAAY,CAAC,KAAK,EAAE,KAAK,EAAE,SAAS,EAAE,KAAK,CAAC,WAAW,CAAC,GAAG,KAAK,CAE/E;AAED,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,KAAK,EAAE,aAAa,EAAE,KAAK,CAAC,eAAe,CAAC,GAAG,KAAK,CAE3F;AAED,wBAAgB,SAAS,CAAC,KAAK,EAAE,KAAK,EAAE,MAAM,EAAE,KAAK,CAAC,QAAQ,CAAC,GAAG,KAAK,CAEtE;AAED,wBAAgB,UAAU,CAAC,KAAK,EAAE,KAAK,EAAE,OAAO,EAAE,KAAK,CAAC,SAAS,CAAC,GAAG,KAAK,CAEzE;AAED,wBAAgB,QAAQ,CAAC,KAAK,EAAE,KAAK,GAAG,MAAM,CAM7C"}
@@ -38,7 +38,10 @@ export function setBillingBuyerType(draft, buyerType) {
38
38
  },
39
39
  };
40
40
  }
41
- return patchBilling(draft, { buyerType });
41
+ return patchBilling(draft, {
42
+ buyerType,
43
+ contact: { firstName: "", lastName: "", email: "" },
44
+ });
42
45
  }
43
46
  export function canCopyBillingContactToTraveler(contact) {
44
47
  return Boolean(contact.firstName || contact.lastName || contact.email || contact.phone);
@@ -1505,7 +1505,7 @@ export declare function getSupplierStatusesQueryOptions(client: FetchWithValidat
1505
1505
  bookingId: string;
1506
1506
  supplierServiceId: string | null;
1507
1507
  serviceName: string;
1508
- status: "pending" | "cancelled" | "confirmed" | "rejected";
1508
+ status: "cancelled" | "pending" | "confirmed" | "rejected";
1509
1509
  supplierReference: string | null;
1510
1510
  costCurrency: string;
1511
1511
  costAmountCents: number;
@@ -1520,7 +1520,7 @@ export declare function getSupplierStatusesQueryOptions(client: FetchWithValidat
1520
1520
  bookingId: string;
1521
1521
  supplierServiceId: string | null;
1522
1522
  serviceName: string;
1523
- status: "pending" | "cancelled" | "confirmed" | "rejected";
1523
+ status: "cancelled" | "pending" | "confirmed" | "rejected";
1524
1524
  supplierReference: string | null;
1525
1525
  costCurrency: string;
1526
1526
  costAmountCents: number;
@@ -1536,7 +1536,7 @@ export declare function getSupplierStatusesQueryOptions(client: FetchWithValidat
1536
1536
  bookingId: string;
1537
1537
  supplierServiceId: string | null;
1538
1538
  serviceName: string;
1539
- status: "pending" | "cancelled" | "confirmed" | "rejected";
1539
+ status: "cancelled" | "pending" | "confirmed" | "rejected";
1540
1540
  supplierReference: string | null;
1541
1541
  costCurrency: string;
1542
1542
  costAmountCents: number;
@@ -1554,7 +1554,7 @@ export declare function getSupplierStatusesQueryOptions(client: FetchWithValidat
1554
1554
  bookingId: string;
1555
1555
  supplierServiceId: string | null;
1556
1556
  serviceName: string;
1557
- status: "pending" | "cancelled" | "confirmed" | "rejected";
1557
+ status: "cancelled" | "pending" | "confirmed" | "rejected";
1558
1558
  supplierReference: string | null;
1559
1559
  costCurrency: string;
1560
1560
  costAmountCents: number;
@@ -10,7 +10,7 @@ export declare function useBookingQuestions(options?: UseBookingQuestionsOptions
10
10
  label: string;
11
11
  description: string | null;
12
12
  target: "extra" | "service" | "traveler" | "booking" | "lead_traveler" | "booker";
13
- fieldType: "number" | "boolean" | "date" | "other" | "file" | "email" | "phone" | "textarea" | "text" | "single_select" | "multi_select" | "datetime" | "country";
13
+ fieldType: "number" | "boolean" | "date" | "other" | "file" | "email" | "phone" | "textarea" | "text" | "datetime" | "single_select" | "multi_select" | "country";
14
14
  placeholder: string | null;
15
15
  helpText: string | null;
16
16
  isRequired: boolean;
@@ -132,7 +132,7 @@ export declare function getBookingQuestionsQueryOptions(client: FetchWithValidat
132
132
  label: string;
133
133
  description: string | null;
134
134
  target: "extra" | "service" | "traveler" | "booking" | "lead_traveler" | "booker";
135
- fieldType: "number" | "boolean" | "date" | "other" | "file" | "email" | "phone" | "textarea" | "text" | "single_select" | "multi_select" | "datetime" | "country";
135
+ fieldType: "number" | "boolean" | "date" | "other" | "file" | "email" | "phone" | "textarea" | "text" | "datetime" | "single_select" | "multi_select" | "country";
136
136
  placeholder: string | null;
137
137
  helpText: string | null;
138
138
  isRequired: boolean;
@@ -150,7 +150,7 @@ export declare function getBookingQuestionsQueryOptions(client: FetchWithValidat
150
150
  label: string;
151
151
  description: string | null;
152
152
  target: "extra" | "service" | "traveler" | "booking" | "lead_traveler" | "booker";
153
- fieldType: "number" | "boolean" | "date" | "other" | "file" | "email" | "phone" | "textarea" | "text" | "single_select" | "multi_select" | "datetime" | "country";
153
+ fieldType: "number" | "boolean" | "date" | "other" | "file" | "email" | "phone" | "textarea" | "text" | "datetime" | "single_select" | "multi_select" | "country";
154
154
  placeholder: string | null;
155
155
  helpText: string | null;
156
156
  isRequired: boolean;
@@ -169,7 +169,7 @@ export declare function getBookingQuestionsQueryOptions(client: FetchWithValidat
169
169
  label: string;
170
170
  description: string | null;
171
171
  target: "extra" | "service" | "traveler" | "booking" | "lead_traveler" | "booker";
172
- fieldType: "number" | "boolean" | "date" | "other" | "file" | "email" | "phone" | "textarea" | "text" | "single_select" | "multi_select" | "datetime" | "country";
172
+ fieldType: "number" | "boolean" | "date" | "other" | "file" | "email" | "phone" | "textarea" | "text" | "datetime" | "single_select" | "multi_select" | "country";
173
173
  placeholder: string | null;
174
174
  helpText: string | null;
175
175
  isRequired: boolean;
@@ -190,7 +190,7 @@ export declare function getBookingQuestionsQueryOptions(client: FetchWithValidat
190
190
  label: string;
191
191
  description: string | null;
192
192
  target: "extra" | "service" | "traveler" | "booking" | "lead_traveler" | "booker";
193
- fieldType: "number" | "boolean" | "date" | "other" | "file" | "email" | "phone" | "textarea" | "text" | "single_select" | "multi_select" | "datetime" | "country";
193
+ fieldType: "number" | "boolean" | "date" | "other" | "file" | "email" | "phone" | "textarea" | "text" | "datetime" | "single_select" | "multi_select" | "country";
194
194
  placeholder: string | null;
195
195
  helpText: string | null;
196
196
  isRequired: boolean;
@@ -26,9 +26,9 @@ export declare const questionFieldTypeSchema: z.ZodEnum<{
26
26
  phone: "phone";
27
27
  textarea: "textarea";
28
28
  text: "text";
29
+ datetime: "datetime";
29
30
  single_select: "single_select";
30
31
  multi_select: "multi_select";
31
- datetime: "datetime";
32
32
  country: "country";
33
33
  }>;
34
34
  export declare const bookingQuestionSchema: z.ZodObject<{
@@ -55,9 +55,9 @@ export declare const bookingQuestionSchema: z.ZodObject<{
55
55
  phone: "phone";
56
56
  textarea: "textarea";
57
57
  text: "text";
58
+ datetime: "datetime";
58
59
  single_select: "single_select";
59
60
  multi_select: "multi_select";
60
- datetime: "datetime";
61
61
  country: "country";
62
62
  }>;
63
63
  placeholder: z.ZodNullable<z.ZodString>;
@@ -166,9 +166,9 @@ export declare const bookingQuestionListResponse: z.ZodObject<{
166
166
  phone: "phone";
167
167
  textarea: "textarea";
168
168
  text: "text";
169
+ datetime: "datetime";
169
170
  single_select: "single_select";
170
171
  multi_select: "multi_select";
171
- datetime: "datetime";
172
172
  country: "country";
173
173
  }>;
174
174
  placeholder: z.ZodNullable<z.ZodString>;
package/dist/schemas.d.ts CHANGED
@@ -22,8 +22,8 @@ export declare const bookingStatusSchema: z.ZodEnum<{
22
22
  }>;
23
23
  export type BookingStatus = z.infer<typeof bookingStatusSchema>;
24
24
  export declare const supplierConfirmationStatusSchema: z.ZodEnum<{
25
- pending: "pending";
26
25
  cancelled: "cancelled";
26
+ pending: "pending";
27
27
  confirmed: "confirmed";
28
28
  rejected: "rejected";
29
29
  }>;
@@ -277,8 +277,8 @@ export declare const bookingSupplierStatusRecordSchema: z.ZodObject<{
277
277
  supplierServiceId: z.ZodNullable<z.ZodString>;
278
278
  serviceName: z.ZodString;
279
279
  status: z.ZodEnum<{
280
- pending: "pending";
281
280
  cancelled: "cancelled";
281
+ pending: "pending";
282
282
  confirmed: "confirmed";
283
283
  rejected: "rejected";
284
284
  }>;
@@ -1699,8 +1699,8 @@ export declare const bookingSupplierStatusesResponse: z.ZodObject<{
1699
1699
  supplierServiceId: z.ZodNullable<z.ZodString>;
1700
1700
  serviceName: z.ZodString;
1701
1701
  status: z.ZodEnum<{
1702
- pending: "pending";
1703
1702
  cancelled: "cancelled";
1703
+ pending: "pending";
1704
1704
  confirmed: "confirmed";
1705
1705
  rejected: "rejected";
1706
1706
  }>;
@@ -2244,9 +2244,9 @@ export declare const bookingActionLedgerStatusSchema: z.ZodEnum<{
2244
2244
  superseded: "superseded";
2245
2245
  }>;
2246
2246
  export declare const bookingActionLedgerRiskSchema: z.ZodEnum<{
2247
- high: "high";
2248
2247
  low: "low";
2249
2248
  medium: "medium";
2249
+ high: "high";
2250
2250
  critical: "critical";
2251
2251
  }>;
2252
2252
  export declare const bookingActionLedgerPrincipalTypeSchema: z.ZodEnum<{
@@ -2287,9 +2287,9 @@ export declare const bookingActionLedgerEntrySchema: z.ZodObject<{
2287
2287
  superseded: "superseded";
2288
2288
  }>;
2289
2289
  evaluatedRisk: z.ZodEnum<{
2290
- high: "high";
2291
2290
  low: "low";
2292
2291
  medium: "medium";
2292
+ high: "high";
2293
2293
  critical: "critical";
2294
2294
  }>;
2295
2295
  actorType: z.ZodNullable<z.ZodString>;
@@ -2377,9 +2377,9 @@ export declare const bookingActionLedgerListResponse: z.ZodObject<{
2377
2377
  superseded: "superseded";
2378
2378
  }>;
2379
2379
  evaluatedRisk: z.ZodEnum<{
2380
- high: "high";
2381
2380
  low: "low";
2382
2381
  medium: "medium";
2382
+ high: "high";
2383
2383
  critical: "critical";
2384
2384
  }>;
2385
2385
  actorType: z.ZodNullable<z.ZodString>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@voyant-travel/bookings-react",
3
- "version": "0.138.8",
3
+ "version": "0.138.9",
4
4
  "license": "Apache-2.0",
5
5
  "repository": {
6
6
  "type": "git",
@@ -145,17 +145,17 @@
145
145
  "react-dom": "^19.0.0",
146
146
  "react-hook-form": "^7.80.0",
147
147
  "zod": "^4.0.0",
148
- "@voyant-travel/admin": "^0.115.3",
149
- "@voyant-travel/bookings": "^0.138.8",
150
- "@voyant-travel/catalog-react": "^0.136.3",
148
+ "@voyant-travel/bookings": "^0.138.9",
151
149
  "@voyant-travel/distribution-react": "^0.128.4",
150
+ "@voyant-travel/catalog-react": "^0.136.3",
152
151
  "@voyant-travel/relationships-react": "^0.138.1",
153
152
  "@voyant-travel/finance-react": "^0.138.9",
153
+ "@voyant-travel/admin": "^0.115.3",
154
+ "@voyant-travel/commerce-react": "^0.20.0",
154
155
  "@voyant-travel/identity-react": "^0.138.3",
155
156
  "@voyant-travel/legal-react": "^0.138.2",
156
- "@voyant-travel/commerce-react": "^0.20.0",
157
- "@voyant-travel/inventory-react": "^0.20.0",
158
157
  "@voyant-travel/ui": "^0.108.10",
158
+ "@voyant-travel/inventory-react": "^0.20.0",
159
159
  "@voyant-travel/operations-react": "^0.19.2"
160
160
  },
161
161
  "peerDependenciesMeta": {
@@ -205,9 +205,9 @@
205
205
  "dependencies": {
206
206
  "sonner": "^2.0.7",
207
207
  "@voyant-travel/catalog-contracts": "^0.108.1",
208
+ "@voyant-travel/types": "^0.106.1",
208
209
  "@voyant-travel/i18n": "^0.109.8",
209
- "@voyant-travel/react": "^0.104.1",
210
- "@voyant-travel/types": "^0.106.1"
210
+ "@voyant-travel/react": "^0.104.1"
211
211
  },
212
212
  "devDependencies": {
213
213
  "@tanstack/react-query": "^5.101.2",
@@ -223,18 +223,18 @@
223
223
  "vitest": "^4.1.9",
224
224
  "zod": "^4.4.3",
225
225
  "@voyant-travel/admin": "^0.115.3",
226
- "@voyant-travel/bookings": "^0.138.8",
227
226
  "@voyant-travel/catalog-react": "^0.136.3",
228
227
  "@voyant-travel/distribution-react": "^0.128.4",
229
228
  "@voyant-travel/relationships-react": "^0.138.1",
230
229
  "@voyant-travel/finance-react": "^0.138.9",
231
230
  "@voyant-travel/identity-react": "^0.138.3",
231
+ "@voyant-travel/bookings": "^0.138.9",
232
232
  "@voyant-travel/legal-react": "^0.138.2",
233
233
  "@voyant-travel/commerce-react": "^0.20.0",
234
234
  "@voyant-travel/inventory-react": "^0.20.0",
235
235
  "@voyant-travel/react": "^0.104.1",
236
- "@voyant-travel/ui": "^0.108.10",
237
236
  "@voyant-travel/voyant-typescript-config": "^0.1.0",
237
+ "@voyant-travel/ui": "^0.108.10",
238
238
  "@voyant-travel/operations-react": "^0.19.2"
239
239
  },
240
240
  "files": [