@jay-framework/wix-bookings 0.26.1 → 0.26.4
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.
|
@@ -115,6 +115,8 @@ The plugin reports **what happened** through enum variants; the string tags are
|
|
|
115
115
|
|
|
116
116
|
- **No available times** is not a failure: `!hasSlots` with `slotsFailure === NONE` (and `!slotsLoading`).
|
|
117
117
|
- `VALIDATION`: the participant form failed a check; `bookingError` names the field (English template, Wix label).
|
|
118
|
+
|
|
119
|
+
> **Participant validation is not the `wixForm` pipeline.** The booking flow checks each participant field with `validateFormSummaryField` from `@jay-framework/wix-forms`: required, plus simple email / URL / phone / number patterns on the trimmed value. The `wixForm` phone pipeline (international `+972…` numbers, `defaultPhoneCountry`, `PHONE_COUNTRY`) and the submit hook (`HOOK` errors, `onSubmitStart`) do **not** apply here: phones go to `createBooking` as typed. There is no per-field `errorRule`; branch on `bookingFailure`. For comparison, see `rich-forms.md` §3 in the wix-forms guides.
|
|
118
120
|
- `CHECKOUT_PERMISSION`, `CHECKOUT_REDIRECT_REJECTED`, `SITE_NOT_PUBLISHED` are **setup** problems (see the troubleshooting guide). Show visitors a neutral line; the default text is a hint for the site owner.
|
|
119
121
|
|
|
120
122
|
```html
|
|
@@ -55,6 +55,10 @@ Bookings loads participant fields via `getFormSummary` from `@jay-framework/wix-
|
|
|
55
55
|
required. Wix checkout does not ask for them either, so the booking is confirmed without them.
|
|
56
56
|
Do not put address or other non-text fields on a booking form until this is fixed
|
|
57
57
|
|
|
58
|
+
## Phone / validation behaves differently from a `wixForm` page
|
|
59
|
+
|
|
60
|
+
Expected, not a bug. Booking participant fields are checked with `validateFormSummaryField` (required + simple patterns on the trimmed value). The `wixForm` phone rules (international numbers, `defaultPhoneCountry`, `PHONE_COUNTRY`), `HOOK` errors and `onSubmitStart` do not apply to the booking flow, and phones are sent to `createBooking` as typed. Failures surface as `bookingFailure === VALIDATION`, not per-field `errorRule`.
|
|
61
|
+
|
|
58
62
|
## Do not assume success from redirect alone
|
|
59
63
|
|
|
60
64
|
`postFlowUrl` fires when the user **finishes or abandons** checkout. For production, look up booking/order status rather than showing confirmation solely on page return.
|