tf-checkout-react 2.0.0-beta.1 → 2.0.0-beta.3
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/index.d.mts +5 -0
- package/dist/index.d.ts +5 -0
- package/dist/index.esm.js +662 -341
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +662 -341
- package/dist/index.js.map +1 -1
- package/dist/styles/tickets.css +18 -1
- package/package.json +1 -1
- package/src/EmbeddedCheckout.tsx +9 -6
- package/src/auth/AuthModal.tsx +3 -3
- package/src/auth/ForgotPasswordForm.tsx +4 -6
- package/src/auth/LoginForm.tsx +2 -2
- package/src/auth/RegisterForm.tsx +2 -2
- package/src/auth/ResetPasswordForm.tsx +7 -7
- package/src/configure.ts +1 -5
- package/src/confirmer.ts +1 -5
- package/src/sections/AddOns.tsx +14 -7
- package/src/sections/BillingInfo.tsx +40 -33
- package/src/sections/Confirmation.tsx +10 -8
- package/src/sections/IDVerification.tsx +16 -9
- package/src/sections/OrderConfirmation.tsx +32 -23
- package/src/sections/OrderIDVerification.tsx +23 -11
- package/src/sections/OrderSummary.tsx +7 -5
- package/src/sections/Payment.tsx +18 -14
- package/src/sections/Tickets.tsx +48 -25
- package/src/sections/billing/BillingAddressFields.tsx +19 -13
- package/src/sections/billing/TicketHoldersCard.tsx +103 -94
- package/src/styles/tickets.css +18 -1
- package/src/ui/CheckoutProvider.tsx +5 -1
- package/src/ui/InstallmentPicker.tsx +8 -4
- package/src/ui/Loader.tsx +11 -7
- package/src/ui/PaymentMethods.tsx +82 -76
- package/src/ui/Stepper.tsx +27 -23
- package/src/ui/TimerBanner.tsx +7 -3
package/dist/index.js
CHANGED
|
@@ -1649,7 +1649,7 @@ var buildXenditCheckoutHtml = (options) => {
|
|
|
1649
1649
|
|
|
1650
1650
|
// ../tf-checkout-shared/src/engine/errors.ts
|
|
1651
1651
|
var errorMessage = (error) => toTtfError(error).message;
|
|
1652
|
-
var EXPIRED_WORDS = /expir|caduc|scadut|abgelaufen|verlopen|udløbet|löpt ut|utløpt|vypršel|wygasł|истек|expirou|kedaluwarsa|hết hạn|期限切れ|已过期|已過期|만료/i;
|
|
1652
|
+
var EXPIRED_WORDS = /expir|caduc|scadut|abgelaufen|verlopen|udløbet|löpt ut|utløpt|vypršel|wygasł|истек|expirou|kedaluwarsa|vanhentu|hết hạn|期限切れ|已过期|已過期|만료/i;
|
|
1653
1653
|
var isCartExpiredError = (error) => {
|
|
1654
1654
|
const e = toTtfError(error);
|
|
1655
1655
|
if (e.status !== 422) return false;
|
|
@@ -2051,8 +2051,12 @@ var removeReservedSeats = async (eventId, tierId, seatIds) => (
|
|
|
2051
2051
|
var refreshReservation = async (eventId, orderId) => patch(ENDPOINTS.seatmap.refreshReservation(eventId), { order_id: orderId });
|
|
2052
2052
|
|
|
2053
2053
|
// ../tf-checkout-shared/src/api/events.ts
|
|
2054
|
+
var badgeOf = (raw) => {
|
|
2055
|
+
const text = typeof raw === "string" ? raw.trim() : "";
|
|
2056
|
+
return text || null;
|
|
2057
|
+
};
|
|
2054
2058
|
var mapTicket = (t) => {
|
|
2055
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m;
|
|
2059
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n;
|
|
2056
2060
|
return {
|
|
2057
2061
|
id: String(t.id),
|
|
2058
2062
|
name: (_a = t.displayName) != null ? _a : "",
|
|
@@ -2080,7 +2084,8 @@ var mapTicket = (t) => {
|
|
|
2080
2084
|
allowDirectPurchase: Boolean(t.allowDirectPurchase),
|
|
2081
2085
|
waitingListEnabled: Boolean(t.waitingListEnabled),
|
|
2082
2086
|
waitingListMaxQuantity: t.waitingListMaxQuantity != null ? Number(t.waitingListMaxQuantity) : void 0,
|
|
2083
|
-
descriptionRich: (_m = t.descriptionRich) != null ? _m : null
|
|
2087
|
+
descriptionRich: (_m = t.descriptionRich) != null ? _m : null,
|
|
2088
|
+
badgeText: badgeOf((_n = t.badgeText) != null ? _n : t.badge_text)
|
|
2084
2089
|
};
|
|
2085
2090
|
};
|
|
2086
2091
|
var getEventTickets = async (eventId) => {
|
|
@@ -2134,7 +2139,7 @@ var getEventConditions = async (eventId) => {
|
|
|
2134
2139
|
}).filter((c) => c.content || c.name);
|
|
2135
2140
|
};
|
|
2136
2141
|
var getEventTimeSlotTickets = async (eventId, date, options) => {
|
|
2137
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t;
|
|
2142
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u;
|
|
2138
2143
|
const body = await get(ENDPOINTS.events.timeSlotByDate(eventId), {
|
|
2139
2144
|
params: {
|
|
2140
2145
|
date,
|
|
@@ -2171,6 +2176,7 @@ var getEventTimeSlotTickets = async (eventId, date, options) => {
|
|
|
2171
2176
|
isTable: Boolean(s.is_table),
|
|
2172
2177
|
allowDirectPurchase: true,
|
|
2173
2178
|
descriptionRich: (_t = s.description) != null ? _t : null,
|
|
2179
|
+
badgeText: badgeOf((_u = s.badge_text) != null ? _u : s.badgeText),
|
|
2174
2180
|
timeSlot: { date: slotDate, time: timeKey }
|
|
2175
2181
|
});
|
|
2176
2182
|
}
|
|
@@ -4285,7 +4291,137 @@ var en = {
|
|
|
4285
4291
|
"referral.inviteFriends": "Invite friends",
|
|
4286
4292
|
"referral.howToInvite": "How do you invite your friends?",
|
|
4287
4293
|
"referral.sendThisLink": "Send them this link:",
|
|
4288
|
-
"referral.howMuchCheaper": "How much cheaper?"
|
|
4294
|
+
"referral.howMuchCheaper": "How much cheaper?",
|
|
4295
|
+
// --- Checkout body (localization pass) ---------------------------------
|
|
4296
|
+
"common.submit": "Submit",
|
|
4297
|
+
"common.each": "each",
|
|
4298
|
+
"billing.heading": "Billing Information",
|
|
4299
|
+
"billing.continueToPayment": "Continue to payment",
|
|
4300
|
+
"billing.ttfOptIn": "Keep me updated about future events from The Ticket Fairy",
|
|
4301
|
+
"billing.fieldRequired": "This field is required.",
|
|
4302
|
+
"billing.firstNamePlaceholder": "First name *",
|
|
4303
|
+
"billing.lastNamePlaceholder": "Last name *",
|
|
4304
|
+
"billing.emailMustMatch": "Email addresses must match.",
|
|
4305
|
+
"billing.emailInvalid": "Enter a valid email address.",
|
|
4306
|
+
"billing.emailRegistered": "This email is already registered.",
|
|
4307
|
+
"billing.loginAutofill": "Log in to autofill your details",
|
|
4308
|
+
"billing.loginAutofillPlain": "Log in to autofill your details.",
|
|
4309
|
+
"billing.firstNameRequired": "First name is required.",
|
|
4310
|
+
"billing.lastNameRequired": "Last name is required.",
|
|
4311
|
+
"billing.streetRequired": "Street address is required.",
|
|
4312
|
+
"billing.cityRequired": "City is required.",
|
|
4313
|
+
"billing.postcodeRequired": "ZIP / postcode is required.",
|
|
4314
|
+
"billing.countryRequired": "Country is required.",
|
|
4315
|
+
"billing.stateRequired": "State / county is required.",
|
|
4316
|
+
"billing.countryEmpty": "\u2014 country * \u2014",
|
|
4317
|
+
"billing.stateEmpty": "\u2014 state / county \u2014",
|
|
4318
|
+
"billing.stateEmptyRequired": "\u2014 state / county * \u2014",
|
|
4319
|
+
"billing.holderTitle": "Ticket {{number}}",
|
|
4320
|
+
"billing.nationality": "Nationality",
|
|
4321
|
+
"billing.gender": "Gender",
|
|
4322
|
+
"billing.instagramHandle": "Instagram handle",
|
|
4323
|
+
"billing.phoneOptional": "Phone",
|
|
4324
|
+
"billing.phoneAria": "Phone",
|
|
4325
|
+
"billing.phoneInvalid": "Enter a valid phone number.",
|
|
4326
|
+
"billing.phonePlaceholder": "Phone number",
|
|
4327
|
+
"billing.dob": "Date of birth *",
|
|
4328
|
+
"billing.dobWithAge": "Date of birth * (must be {{age}}+)",
|
|
4329
|
+
"billing.dobRequired": "Date of birth is required.",
|
|
4330
|
+
"billing.ageMinimum": "You must be {{age}} or older.",
|
|
4331
|
+
"billing.privacyAgree": "I have read and agree to {{brand}}",
|
|
4332
|
+
"billing.privacyLink": "Privacy Policy.",
|
|
4333
|
+
"tickets.getTickets": "Get tickets",
|
|
4334
|
+
"tickets.selectOnMap": "Select on map",
|
|
4335
|
+
"tickets.selectSeats": "Select seats",
|
|
4336
|
+
"tickets.hideInfo": "Hide info",
|
|
4337
|
+
"tickets.viewInfo": "View info",
|
|
4338
|
+
"tickets.salesNotStarted": "Sales not started",
|
|
4339
|
+
"tickets.salesEnded": "Sales Ended",
|
|
4340
|
+
"tickets.accessCode": "Access code",
|
|
4341
|
+
"tickets.promoCode": "Promo code",
|
|
4342
|
+
"tickets.reserving": "Reserving\u2026",
|
|
4343
|
+
"addons.eyebrow": "Get Your Tickets",
|
|
4344
|
+
"addons.heading": "UPGRADES & ADD-ONS",
|
|
4345
|
+
"addons.confirmSelection": "CONFIRM SELECTION",
|
|
4346
|
+
"addons.updating": "Updating\u2026",
|
|
4347
|
+
"payment.title": "Payment",
|
|
4348
|
+
"payment.card": "Card",
|
|
4349
|
+
"payment.paymentPlan": "Payment plan",
|
|
4350
|
+
"payment.oxxo": "OXXO (pay in cash)",
|
|
4351
|
+
"payment.submitPayment": "Submit Payment",
|
|
4352
|
+
"payment.completeRegistration": "Complete Registration",
|
|
4353
|
+
"payment.placing": "Placing\u2026",
|
|
4354
|
+
"payment.testCard": "Test card: 4242 4242 4242 4242 \xB7 any future date \xB7 any CVC",
|
|
4355
|
+
"payment.testCardXendit": "Test card: 4000 0000 0000 0002 \xB7 any future date \xB7 any CVC",
|
|
4356
|
+
"confirmation.pending": "Payment pending",
|
|
4357
|
+
"confirmation.confirmed": "Your Tickets are Confirmed!",
|
|
4358
|
+
"confirmation.pendingBody": "We\u2019ll email your tickets as soon as the payment settles.",
|
|
4359
|
+
"confirmation.alreadyPaid": "This order was already paid \u2014 nothing was charged again.",
|
|
4360
|
+
"confirmation.available": "Your tickets are available in the My Tickets section \u2014 please bring them with you to the event.",
|
|
4361
|
+
"referral.copied": "Copied!",
|
|
4362
|
+
"referral.copyLink": "Copy link",
|
|
4363
|
+
"timer.completePurchase": "Please complete your purchase before the timer reaches zero.",
|
|
4364
|
+
"auth.logIn": "Log in",
|
|
4365
|
+
"auth.signUp": "Sign Up",
|
|
4366
|
+
"auth.passwordReset": "Password reset",
|
|
4367
|
+
"auth.backToLogin": "Back to log in",
|
|
4368
|
+
"auth.sendResetInstructions": "Send reset instructions",
|
|
4369
|
+
"auth.createAccount": "Create Account",
|
|
4370
|
+
"auth.forgotPassword": "Forgot password?",
|
|
4371
|
+
"auth.forgotIntro": "Enter your email and we\u2019ll send you instructions to reset your password.",
|
|
4372
|
+
"auth.missingToken": "This password-reset link is missing its token.",
|
|
4373
|
+
"auth.passwordTooShort": "Password must have at least 8 characters.",
|
|
4374
|
+
"auth.passwordNeedsSpecial": "Password must contain at least one special character.",
|
|
4375
|
+
"auth.passwordsMustMatch": "Passwords must match.",
|
|
4376
|
+
"auth.passwordChanged": "Your password has been changed. You can now log in.",
|
|
4377
|
+
"auth.selectState": "Select state / region",
|
|
4378
|
+
"auth.notRequired": "Not required",
|
|
4379
|
+
// --- Previously hardcoded in components ---------------------------------
|
|
4380
|
+
"tickets.waitingListJoined": "You\u2019re on the waiting list \u2014 we\u2019ll email you if a spot opens.",
|
|
4381
|
+
"tickets.firstName": "First name",
|
|
4382
|
+
"tickets.lastName": "Last name",
|
|
4383
|
+
"tickets.email": "Email",
|
|
4384
|
+
"tickets.joinWaitingList": "Join the waiting list",
|
|
4385
|
+
"tickets.free": "FREE",
|
|
4386
|
+
"tickets.withFees": "({{price}} with fees)",
|
|
4387
|
+
"tickets.deposit": "{{percent}}% DEPOSIT",
|
|
4388
|
+
"tickets.gotPromoCode": "Got a promo code? Click here",
|
|
4389
|
+
"payment.conditionRequired": "You must accept this condition to continue.",
|
|
4390
|
+
"payment.payInFull": "Pay in full instead",
|
|
4391
|
+
"payment.installmentTotal": "{{amount}} total",
|
|
4392
|
+
"confirmation.viewVoucher": "View payment voucher",
|
|
4393
|
+
"confirmation.viewTickets": "View my tickets",
|
|
4394
|
+
"confirmation.orderConfirmed": "Your order has been confirmed!",
|
|
4395
|
+
"confirmation.emailed": "Your tickets have been emailed to you",
|
|
4396
|
+
"confirmation.inMyTickets": "Your tickets are available in My Tickets.",
|
|
4397
|
+
"confirmation.bringThem": "Please bring them with you to the event",
|
|
4398
|
+
"confirmation.viewOrder": "View Order",
|
|
4399
|
+
"confirmation.missingReference": "The order reference is missing.",
|
|
4400
|
+
"referral.titleStart": "Your ticket can become",
|
|
4401
|
+
"referral.titleCheaper": "cheaper",
|
|
4402
|
+
"referral.titleOr": "or even",
|
|
4403
|
+
"referral.titleFree": "FREE!",
|
|
4404
|
+
"referral.inviteMiddle": "and we'll refund up to",
|
|
4405
|
+
"referral.inviteEnd": "of your ticket money, if they buy tickets as well!",
|
|
4406
|
+
"referral.copy": "Copy",
|
|
4407
|
+
"referral.currentPrice": "Your ticket is currently",
|
|
4408
|
+
"referral.ifFriendsBuy": "If your friends buy {{count}} tickets",
|
|
4409
|
+
"referral.becomes": "Your ticket becomes",
|
|
4410
|
+
"referral.goesDownTo": "Your ticket goes down to",
|
|
4411
|
+
"verification.title": "Account Verification",
|
|
4412
|
+
"verification.checking": "Checking your verification status\u2026",
|
|
4413
|
+
"verification.idle": "To complete the purchase, please verify your identity.",
|
|
4414
|
+
"verification.starting": "Opening the verification page\u2026",
|
|
4415
|
+
"verification.polling": "Waiting for verification to complete in the other tab\u2026",
|
|
4416
|
+
"verification.verified": "Identity verified \u2014 your tickets are on their way.",
|
|
4417
|
+
"verification.timeoutCheckAgain": "Still not confirmed. Finish in the other tab, then check again.",
|
|
4418
|
+
"verification.timeoutSafe": "Verification is taking longer than usual. Your payment is safe.",
|
|
4419
|
+
"verification.error": "We couldn\u2019t reach the verification service. Try again.",
|
|
4420
|
+
"verification.verify": "Verify",
|
|
4421
|
+
"verification.verifying": "Verifying\u2026",
|
|
4422
|
+
"verification.checkAgain": "Check again",
|
|
4423
|
+
"verification.tryAgain": "Try again",
|
|
4424
|
+
"auth.existingAccount": "This email already has an account. Log in to autofill your checkout details."
|
|
4289
4425
|
};
|
|
4290
4426
|
|
|
4291
4427
|
// ../tf-checkout-shared/src/i18n/resolve.ts
|
|
@@ -4417,7 +4553,137 @@ var esMX = {
|
|
|
4417
4553
|
"referral.inviteFriends": "Invita a tus amigos",
|
|
4418
4554
|
"referral.howToInvite": "\xBFC\xF3mo invitas a tus amigos?",
|
|
4419
4555
|
"referral.sendThisLink": "Env\xEDales este enlace:",
|
|
4420
|
-
"referral.howMuchCheaper": "\xBFCu\xE1nto m\xE1s barato?"
|
|
4556
|
+
"referral.howMuchCheaper": "\xBFCu\xE1nto m\xE1s barato?",
|
|
4557
|
+
// --- Checkout body (localization pass) ---------------------------------
|
|
4558
|
+
"common.submit": "Enviar",
|
|
4559
|
+
"common.each": "c/u",
|
|
4560
|
+
"billing.heading": "Informaci\xF3n de facturaci\xF3n",
|
|
4561
|
+
"billing.continueToPayment": "Continuar al pago",
|
|
4562
|
+
"billing.ttfOptIn": "Quiero recibir novedades sobre pr\xF3ximos eventos de The Ticket Fairy",
|
|
4563
|
+
"billing.fieldRequired": "Este campo es obligatorio.",
|
|
4564
|
+
"billing.firstNamePlaceholder": "Nombre *",
|
|
4565
|
+
"billing.lastNamePlaceholder": "Apellido *",
|
|
4566
|
+
"billing.emailMustMatch": "Los correos electr\xF3nicos deben coincidir.",
|
|
4567
|
+
"billing.emailInvalid": "Ingresa un correo electr\xF3nico v\xE1lido.",
|
|
4568
|
+
"billing.emailRegistered": "Este correo ya est\xE1 registrado.",
|
|
4569
|
+
"billing.loginAutofill": "Inicia sesi\xF3n para completar tus datos",
|
|
4570
|
+
"billing.loginAutofillPlain": "Inicia sesi\xF3n para completar tus datos.",
|
|
4571
|
+
"billing.firstNameRequired": "El nombre es obligatorio.",
|
|
4572
|
+
"billing.lastNameRequired": "El apellido es obligatorio.",
|
|
4573
|
+
"billing.streetRequired": "La calle y n\xFAmero son obligatorios.",
|
|
4574
|
+
"billing.cityRequired": "La ciudad es obligatoria.",
|
|
4575
|
+
"billing.postcodeRequired": "El c\xF3digo postal es obligatorio.",
|
|
4576
|
+
"billing.countryRequired": "El pa\xEDs es obligatorio.",
|
|
4577
|
+
"billing.stateRequired": "El estado es obligatorio.",
|
|
4578
|
+
"billing.countryEmpty": "\u2014 pa\xEDs * \u2014",
|
|
4579
|
+
"billing.stateEmpty": "\u2014 estado \u2014",
|
|
4580
|
+
"billing.stateEmptyRequired": "\u2014 estado * \u2014",
|
|
4581
|
+
"billing.holderTitle": "Boleto {{number}}",
|
|
4582
|
+
"billing.nationality": "Nacionalidad",
|
|
4583
|
+
"billing.gender": "G\xE9nero",
|
|
4584
|
+
"billing.instagramHandle": "Usuario de Instagram",
|
|
4585
|
+
"billing.phoneOptional": "Tel\xE9fono",
|
|
4586
|
+
"billing.phoneAria": "Tel\xE9fono",
|
|
4587
|
+
"billing.phoneInvalid": "Ingresa un n\xFAmero de tel\xE9fono v\xE1lido.",
|
|
4588
|
+
"billing.phonePlaceholder": "N\xFAmero de tel\xE9fono",
|
|
4589
|
+
"billing.dob": "Fecha de nacimiento *",
|
|
4590
|
+
"billing.dobWithAge": "Fecha de nacimiento * (debes tener {{age}}+)",
|
|
4591
|
+
"billing.dobRequired": "La fecha de nacimiento es obligatoria.",
|
|
4592
|
+
"billing.ageMinimum": "Debes tener {{age}} a\xF1os o m\xE1s.",
|
|
4593
|
+
"billing.privacyAgree": "He le\xEDdo y acepto el",
|
|
4594
|
+
"billing.privacyLink": "Aviso de Privacidad.",
|
|
4595
|
+
"tickets.getTickets": "Comprar boletos",
|
|
4596
|
+
"tickets.selectOnMap": "Seleccionar en el mapa",
|
|
4597
|
+
"tickets.selectSeats": "Seleccionar asientos",
|
|
4598
|
+
"tickets.hideInfo": "Ocultar informaci\xF3n",
|
|
4599
|
+
"tickets.viewInfo": "Ver informaci\xF3n",
|
|
4600
|
+
"tickets.salesNotStarted": "Venta no iniciada",
|
|
4601
|
+
"tickets.salesEnded": "Venta finalizada",
|
|
4602
|
+
"tickets.accessCode": "C\xF3digo de acceso",
|
|
4603
|
+
"tickets.promoCode": "C\xF3digo promocional",
|
|
4604
|
+
"tickets.reserving": "Reservando\u2026",
|
|
4605
|
+
"addons.eyebrow": "Obt\xE9n tus boletos",
|
|
4606
|
+
"addons.heading": "MEJORAS Y COMPLEMENTOS",
|
|
4607
|
+
"addons.confirmSelection": "CONFIRMAR SELECCI\xD3N",
|
|
4608
|
+
"addons.updating": "Actualizando\u2026",
|
|
4609
|
+
"payment.title": "Pago",
|
|
4610
|
+
"payment.card": "Tarjeta",
|
|
4611
|
+
"payment.paymentPlan": "Plan de pagos",
|
|
4612
|
+
"payment.oxxo": "OXXO (pago en efectivo)",
|
|
4613
|
+
"payment.submitPayment": "Pagar",
|
|
4614
|
+
"payment.completeRegistration": "Completar registro",
|
|
4615
|
+
"payment.placing": "Procesando\u2026",
|
|
4616
|
+
"payment.testCard": "Tarjeta de prueba: 4242 4242 4242 4242 \xB7 cualquier fecha futura \xB7 cualquier CVC",
|
|
4617
|
+
"payment.testCardXendit": "Tarjeta de prueba: 4000 0000 0000 0002 \xB7 cualquier fecha futura \xB7 cualquier CVC",
|
|
4618
|
+
"confirmation.pending": "Pago pendiente",
|
|
4619
|
+
"confirmation.confirmed": "\xA1Tus boletos est\xE1n confirmados!",
|
|
4620
|
+
"confirmation.pendingBody": "Te enviaremos tus boletos por correo en cuanto se acredite el pago.",
|
|
4621
|
+
"confirmation.alreadyPaid": "Esta orden ya estaba pagada: no se te cobr\xF3 de nuevo.",
|
|
4622
|
+
"confirmation.available": "Tus boletos est\xE1n disponibles en la secci\xF3n Mis boletos. Recuerda llevarlos contigo al evento.",
|
|
4623
|
+
"referral.copied": "\xA1Copiado!",
|
|
4624
|
+
"referral.copyLink": "Copiar enlace",
|
|
4625
|
+
"timer.completePurchase": "Completa tu compra antes de que el temporizador llegue a cero.",
|
|
4626
|
+
"auth.logIn": "Iniciar sesi\xF3n",
|
|
4627
|
+
"auth.signUp": "Crear cuenta",
|
|
4628
|
+
"auth.passwordReset": "Restablecer contrase\xF1a",
|
|
4629
|
+
"auth.backToLogin": "Volver a iniciar sesi\xF3n",
|
|
4630
|
+
"auth.sendResetInstructions": "Enviar instrucciones",
|
|
4631
|
+
"auth.createAccount": "Crear cuenta",
|
|
4632
|
+
"auth.forgotPassword": "\xBFOlvidaste tu contrase\xF1a?",
|
|
4633
|
+
"auth.forgotIntro": "Ingresa tu correo y te enviaremos instrucciones para restablecer tu contrase\xF1a.",
|
|
4634
|
+
"auth.missingToken": "A este enlace de restablecimiento le falta el token.",
|
|
4635
|
+
"auth.passwordTooShort": "La contrase\xF1a debe tener al menos 8 caracteres.",
|
|
4636
|
+
"auth.passwordNeedsSpecial": "La contrase\xF1a debe incluir al menos un car\xE1cter especial.",
|
|
4637
|
+
"auth.passwordsMustMatch": "Las contrase\xF1as deben coincidir.",
|
|
4638
|
+
"auth.passwordChanged": "Tu contrase\xF1a se cambi\xF3. Ya puedes iniciar sesi\xF3n.",
|
|
4639
|
+
"auth.selectState": "Selecciona estado / regi\xF3n",
|
|
4640
|
+
"auth.notRequired": "No requerido",
|
|
4641
|
+
// --- Previously hardcoded in components ---------------------------------
|
|
4642
|
+
"tickets.waitingListJoined": "Ya est\xE1s en la lista de espera \u2014 te escribiremos si se libera un lugar.",
|
|
4643
|
+
"tickets.firstName": "Nombre",
|
|
4644
|
+
"tickets.lastName": "Apellido",
|
|
4645
|
+
"tickets.email": "Correo electr\xF3nico",
|
|
4646
|
+
"tickets.joinWaitingList": "Unirme a la lista de espera",
|
|
4647
|
+
"tickets.free": "GRATIS",
|
|
4648
|
+
"tickets.withFees": "({{price}} con cargos)",
|
|
4649
|
+
"tickets.deposit": "{{percent}}% DE ANTICIPO",
|
|
4650
|
+
"tickets.gotPromoCode": "\xBFTienes un c\xF3digo promocional? Haz clic aqu\xED",
|
|
4651
|
+
"payment.conditionRequired": "Debes aceptar esta condici\xF3n para continuar.",
|
|
4652
|
+
"payment.payInFull": "Mejor pagar en una sola exhibici\xF3n",
|
|
4653
|
+
"payment.installmentTotal": "{{amount}} en total",
|
|
4654
|
+
"confirmation.viewVoucher": "Ver ficha de pago",
|
|
4655
|
+
"confirmation.viewTickets": "Ver mis boletos",
|
|
4656
|
+
"confirmation.orderConfirmed": "\xA1Tu pedido est\xE1 confirmado!",
|
|
4657
|
+
"confirmation.emailed": "Te enviamos tus boletos por correo",
|
|
4658
|
+
"confirmation.inMyTickets": "Tus boletos est\xE1n disponibles en Mis boletos.",
|
|
4659
|
+
"confirmation.bringThem": "Ll\xE9valos contigo al evento",
|
|
4660
|
+
"confirmation.viewOrder": "Ver pedido",
|
|
4661
|
+
"confirmation.missingReference": "Falta la referencia del pedido.",
|
|
4662
|
+
"referral.titleStart": "Tu boleto puede salirte",
|
|
4663
|
+
"referral.titleCheaper": "m\xE1s barato",
|
|
4664
|
+
"referral.titleOr": "o incluso",
|
|
4665
|
+
"referral.titleFree": "\xA1GRATIS!",
|
|
4666
|
+
"referral.inviteMiddle": "y te reembolsamos hasta el",
|
|
4667
|
+
"referral.inviteEnd": "de lo que pagaste por tu boleto si ellos tambi\xE9n compran.",
|
|
4668
|
+
"referral.copy": "Copiar",
|
|
4669
|
+
"referral.currentPrice": "Tu boleto cuesta ahora",
|
|
4670
|
+
"referral.ifFriendsBuy": "Si tus amigos compran {{count}} boletos",
|
|
4671
|
+
"referral.becomes": "Tu boleto queda",
|
|
4672
|
+
"referral.goesDownTo": "Tu boleto baja a",
|
|
4673
|
+
"verification.title": "Verificaci\xF3n de cuenta",
|
|
4674
|
+
"verification.checking": "Revisando el estado de tu verificaci\xF3n\u2026",
|
|
4675
|
+
"verification.idle": "Para completar la compra, verifica tu identidad.",
|
|
4676
|
+
"verification.starting": "Abriendo la p\xE1gina de verificaci\xF3n\u2026",
|
|
4677
|
+
"verification.polling": "Esperando a que termines la verificaci\xF3n en la otra pesta\xF1a\u2026",
|
|
4678
|
+
"verification.verified": "Identidad verificada \u2014 tus boletos van en camino.",
|
|
4679
|
+
"verification.timeoutCheckAgain": "A\xFAn no se confirma. Termina en la otra pesta\xF1a y vuelve a revisar.",
|
|
4680
|
+
"verification.timeoutSafe": "La verificaci\xF3n est\xE1 tardando m\xE1s de lo normal. Tu pago est\xE1 seguro.",
|
|
4681
|
+
"verification.error": "No pudimos conectar con el servicio de verificaci\xF3n. Int\xE9ntalo de nuevo.",
|
|
4682
|
+
"verification.verify": "Verificar",
|
|
4683
|
+
"verification.verifying": "Verificando\u2026",
|
|
4684
|
+
"verification.checkAgain": "Revisar de nuevo",
|
|
4685
|
+
"verification.tryAgain": "Intentar de nuevo",
|
|
4686
|
+
"auth.existingAccount": "Este correo ya tiene una cuenta. Inicia sesi\xF3n para autocompletar tus datos de compra."
|
|
4421
4687
|
};
|
|
4422
4688
|
|
|
4423
4689
|
// ../tf-checkout-shared/src/i18n/locales/index.ts
|
|
@@ -5274,14 +5540,17 @@ var import_react7 = __toESM(require("react"));
|
|
|
5274
5540
|
|
|
5275
5541
|
// src/ui/Loader.tsx
|
|
5276
5542
|
var import_react6 = __toESM(require("react"));
|
|
5277
|
-
var Loader = ({ className }) =>
|
|
5278
|
-
|
|
5279
|
-
|
|
5280
|
-
|
|
5281
|
-
|
|
5282
|
-
|
|
5283
|
-
|
|
5284
|
-
)
|
|
5543
|
+
var Loader = ({ className }) => {
|
|
5544
|
+
const t = useT();
|
|
5545
|
+
return /* @__PURE__ */ import_react6.default.createElement(
|
|
5546
|
+
"span",
|
|
5547
|
+
{
|
|
5548
|
+
className: cx("tf-checkout-loader", className),
|
|
5549
|
+
role: "status",
|
|
5550
|
+
"aria-label": t("common.loading")
|
|
5551
|
+
}
|
|
5552
|
+
);
|
|
5553
|
+
};
|
|
5285
5554
|
|
|
5286
5555
|
// src/ui/Button.tsx
|
|
5287
5556
|
var Button = (0, import_react7.forwardRef)(
|
|
@@ -5307,6 +5576,7 @@ Button.displayName = "Button";
|
|
|
5307
5576
|
|
|
5308
5577
|
// src/ui/InstallmentPicker.tsx
|
|
5309
5578
|
var useInstallmentPicker = () => {
|
|
5579
|
+
const t = useT();
|
|
5310
5580
|
const [pending, setPending] = (0, import_react8.useState)(null);
|
|
5311
5581
|
const onInstallmentOffers = (0, import_react8.useCallback)(
|
|
5312
5582
|
(offers) => new Promise((resolve) => setPending({ offers, resolve })),
|
|
@@ -5321,9 +5591,9 @@ var useInstallmentPicker = () => {
|
|
|
5321
5591
|
{
|
|
5322
5592
|
className: "tf-checkout-installments",
|
|
5323
5593
|
role: "dialog",
|
|
5324
|
-
"aria-label": "
|
|
5594
|
+
"aria-label": t("payment.chooseInstallments")
|
|
5325
5595
|
},
|
|
5326
|
-
/* @__PURE__ */ import_react8.default.createElement("div", { className: "tf-checkout-installments__box" }, /* @__PURE__ */ import_react8.default.createElement("strong", null, "
|
|
5596
|
+
/* @__PURE__ */ import_react8.default.createElement("div", { className: "tf-checkout-installments__box" }, /* @__PURE__ */ import_react8.default.createElement("strong", null, t("payment.payInInstallments")), /* @__PURE__ */ import_react8.default.createElement("div", { className: "tf-checkout-installments__list" }, pending.offers.map((o, i) => {
|
|
5327
5597
|
var _a;
|
|
5328
5598
|
return /* @__PURE__ */ import_react8.default.createElement(
|
|
5329
5599
|
"button",
|
|
@@ -5334,9 +5604,9 @@ var useInstallmentPicker = () => {
|
|
|
5334
5604
|
onClick: () => choose(o)
|
|
5335
5605
|
},
|
|
5336
5606
|
/* @__PURE__ */ import_react8.default.createElement("span", null, o.count, " \xD7 ", (_a = o.per_installment_formatted) != null ? _a : o.per_installment),
|
|
5337
|
-
/* @__PURE__ */ import_react8.default.createElement("span", { className: "tf-checkout-installments__meta" }, o.total_formatted ?
|
|
5607
|
+
/* @__PURE__ */ import_react8.default.createElement("span", { className: "tf-checkout-installments__meta" }, o.total_formatted ? t("payment.installmentTotal", { amount: o.total_formatted }) : "", o.diff_from_original_formatted ? ` \xB7 ${o.diff_from_original_formatted}` : "")
|
|
5338
5608
|
);
|
|
5339
|
-
})), /* @__PURE__ */ import_react8.default.createElement(Button, { variant: "ghost", block: true, onClick: () => choose(null) }, "
|
|
5609
|
+
})), /* @__PURE__ */ import_react8.default.createElement(Button, { variant: "ghost", block: true, onClick: () => choose(null) }, t("payment.payInFull")))
|
|
5340
5610
|
) : null;
|
|
5341
5611
|
return { onInstallmentOffers, picker };
|
|
5342
5612
|
};
|
|
@@ -5667,87 +5937,100 @@ var PaymentMethods = ({
|
|
|
5667
5937
|
children,
|
|
5668
5938
|
inputSlotFor,
|
|
5669
5939
|
className
|
|
5670
|
-
}) =>
|
|
5671
|
-
|
|
5672
|
-
|
|
5673
|
-
|
|
5674
|
-
|
|
5675
|
-
|
|
5676
|
-
|
|
5677
|
-
|
|
5678
|
-
|
|
5679
|
-
|
|
5680
|
-
|
|
5681
|
-
|
|
5682
|
-
|
|
5683
|
-
|
|
5684
|
-
|
|
5685
|
-
|
|
5686
|
-
className: cx(
|
|
5687
|
-
"tf-checkout-payment__method",
|
|
5688
|
-
isSelected && "tf-checkout-payment__method--selected"
|
|
5689
|
-
)
|
|
5690
|
-
},
|
|
5691
|
-
/* @__PURE__ */ import_react13.default.createElement("span", { className: "tf-checkout-payment__method-head" }, /* @__PURE__ */ import_react13.default.createElement(
|
|
5692
|
-
"input",
|
|
5693
|
-
{
|
|
5694
|
-
type: "radio",
|
|
5695
|
-
name: "tf-pay-method",
|
|
5696
|
-
className: "tf-checkout-payment__method-radio",
|
|
5697
|
-
checked: isSelected,
|
|
5698
|
-
onChange: () => onSelect(o.value)
|
|
5699
|
-
}
|
|
5700
|
-
), o.iconUrl && /* @__PURE__ */ import_react13.default.createElement("img", { className: "tf-checkout-payment__method-icon", src: o.iconUrl, alt: "" }), /* @__PURE__ */ import_react13.default.createElement("span", { className: "tf-checkout-payment__method-label" }, o.label)),
|
|
5701
|
-
isSelected && (o.value === inputSlotFor || o.extra) && /* @__PURE__ */ import_react13.default.createElement("div", { className: "tf-checkout-payment__method-body" }, o.value === inputSlotFor && children, o.extra && /* @__PURE__ */ import_react13.default.createElement(
|
|
5702
|
-
Field,
|
|
5940
|
+
}) => {
|
|
5941
|
+
const t = useT();
|
|
5942
|
+
return /* @__PURE__ */ import_react13.default.createElement(
|
|
5943
|
+
"div",
|
|
5944
|
+
{
|
|
5945
|
+
className: cx("tf-checkout-payment__methods", className),
|
|
5946
|
+
role: "radiogroup",
|
|
5947
|
+
"aria-label": t("payment.method")
|
|
5948
|
+
},
|
|
5949
|
+
options.map((o) => {
|
|
5950
|
+
var _a, _b, _c, _d, _e, _f;
|
|
5951
|
+
const isSelected = o.value === selected;
|
|
5952
|
+
const extraValue = o.extra === "phoneNumber" ? (_a = extraValues[o.value]) == null ? void 0 : _a.phoneNumber : (_b = extraValues[o.value]) == null ? void 0 : _b.cashtag;
|
|
5953
|
+
const extraInvalid = Boolean(isSelected && o.extra && showValidation) && !(extraValue == null ? void 0 : extraValue.trim());
|
|
5954
|
+
return /* @__PURE__ */ import_react13.default.createElement(
|
|
5955
|
+
"label",
|
|
5703
5956
|
{
|
|
5704
|
-
|
|
5705
|
-
|
|
5706
|
-
|
|
5957
|
+
key: o.value,
|
|
5958
|
+
className: cx(
|
|
5959
|
+
"tf-checkout-payment__method",
|
|
5960
|
+
isSelected && "tf-checkout-payment__method--selected"
|
|
5961
|
+
)
|
|
5707
5962
|
},
|
|
5708
|
-
/* @__PURE__ */ import_react13.default.createElement(
|
|
5709
|
-
|
|
5963
|
+
/* @__PURE__ */ import_react13.default.createElement("span", { className: "tf-checkout-payment__method-head" }, /* @__PURE__ */ import_react13.default.createElement(
|
|
5964
|
+
"input",
|
|
5710
5965
|
{
|
|
5711
|
-
|
|
5712
|
-
|
|
5713
|
-
|
|
5714
|
-
|
|
5715
|
-
|
|
5716
|
-
value: o.extra === "phoneNumber" ? (_d = (_c = extraValues[o.value]) == null ? void 0 : _c.phoneNumber) != null ? _d : "" : (_f = (_e = extraValues[o.value]) == null ? void 0 : _e.cashtag) != null ? _f : "",
|
|
5717
|
-
onChange: (e) => onExtraChange(
|
|
5718
|
-
o.value,
|
|
5719
|
-
o.extra === "phoneNumber" ? { phoneNumber: e.target.value } : { cashtag: e.target.value }
|
|
5720
|
-
)
|
|
5966
|
+
type: "radio",
|
|
5967
|
+
name: "tf-pay-method",
|
|
5968
|
+
className: "tf-checkout-payment__method-radio",
|
|
5969
|
+
checked: isSelected,
|
|
5970
|
+
onChange: () => onSelect(o.value)
|
|
5721
5971
|
}
|
|
5722
|
-
)
|
|
5723
|
-
|
|
5724
|
-
|
|
5725
|
-
|
|
5726
|
-
|
|
5972
|
+
), o.iconUrl && /* @__PURE__ */ import_react13.default.createElement(
|
|
5973
|
+
"img",
|
|
5974
|
+
{
|
|
5975
|
+
className: "tf-checkout-payment__method-icon",
|
|
5976
|
+
src: o.iconUrl,
|
|
5977
|
+
alt: ""
|
|
5978
|
+
}
|
|
5979
|
+
), /* @__PURE__ */ import_react13.default.createElement("span", { className: "tf-checkout-payment__method-label" }, o.label)),
|
|
5980
|
+
isSelected && (o.value === inputSlotFor || o.extra) && /* @__PURE__ */ import_react13.default.createElement("div", { className: "tf-checkout-payment__method-body" }, o.value === inputSlotFor && children, o.extra && /* @__PURE__ */ import_react13.default.createElement(
|
|
5981
|
+
Field,
|
|
5982
|
+
{
|
|
5983
|
+
label: `${EXTRA_LABEL[o.extra]} *`,
|
|
5984
|
+
error: extraInvalid ? t("billing.fieldRequired") : void 0,
|
|
5985
|
+
invalid: extraInvalid
|
|
5986
|
+
},
|
|
5987
|
+
/* @__PURE__ */ import_react13.default.createElement(
|
|
5988
|
+
Input,
|
|
5989
|
+
{
|
|
5990
|
+
inputMode: o.extra === "phoneNumber" ? "tel" : "text",
|
|
5991
|
+
required: true,
|
|
5992
|
+
invalid: extraInvalid,
|
|
5993
|
+
"aria-invalid": extraInvalid,
|
|
5994
|
+
placeholder: o.extra === "phoneNumber" ? "e.g. 081234567890" : "$cashtag",
|
|
5995
|
+
value: o.extra === "phoneNumber" ? (_d = (_c = extraValues[o.value]) == null ? void 0 : _c.phoneNumber) != null ? _d : "" : (_f = (_e = extraValues[o.value]) == null ? void 0 : _e.cashtag) != null ? _f : "",
|
|
5996
|
+
onChange: (e) => onExtraChange(
|
|
5997
|
+
o.value,
|
|
5998
|
+
o.extra === "phoneNumber" ? { phoneNumber: e.target.value } : { cashtag: e.target.value }
|
|
5999
|
+
)
|
|
6000
|
+
}
|
|
6001
|
+
)
|
|
6002
|
+
))
|
|
6003
|
+
);
|
|
6004
|
+
})
|
|
6005
|
+
);
|
|
6006
|
+
};
|
|
5727
6007
|
|
|
5728
6008
|
// src/ui/Stepper.tsx
|
|
5729
6009
|
var import_react14 = __toESM(require("react"));
|
|
5730
|
-
var Stepper = ({ value, onChange, min = 0, max = Infinity, step = 1, disabled, className }) =>
|
|
5731
|
-
|
|
5732
|
-
{
|
|
5733
|
-
|
|
5734
|
-
|
|
5735
|
-
|
|
5736
|
-
|
|
5737
|
-
|
|
5738
|
-
|
|
5739
|
-
|
|
5740
|
-
|
|
5741
|
-
|
|
5742
|
-
{
|
|
5743
|
-
|
|
5744
|
-
|
|
5745
|
-
|
|
5746
|
-
|
|
5747
|
-
|
|
5748
|
-
|
|
5749
|
-
|
|
5750
|
-
|
|
6010
|
+
var Stepper = ({ value, onChange, min = 0, max = Infinity, step = 1, disabled, className }) => {
|
|
6011
|
+
const t = useT();
|
|
6012
|
+
return /* @__PURE__ */ import_react14.default.createElement("div", { className: cx("tf-checkout-stepper", className) }, /* @__PURE__ */ import_react14.default.createElement(
|
|
6013
|
+
"button",
|
|
6014
|
+
{
|
|
6015
|
+
type: "button",
|
|
6016
|
+
className: "tf-checkout-stepper__btn",
|
|
6017
|
+
"aria-label": t("common.decrease"),
|
|
6018
|
+
disabled: disabled || value <= min,
|
|
6019
|
+
onClick: () => onChange(Math.max(min, value - step))
|
|
6020
|
+
},
|
|
6021
|
+
"\u2212"
|
|
6022
|
+
), /* @__PURE__ */ import_react14.default.createElement("span", { className: "tf-checkout-stepper__value" }, value), /* @__PURE__ */ import_react14.default.createElement(
|
|
6023
|
+
"button",
|
|
6024
|
+
{
|
|
6025
|
+
type: "button",
|
|
6026
|
+
className: "tf-checkout-stepper__btn",
|
|
6027
|
+
"aria-label": t("common.increase"),
|
|
6028
|
+
disabled: disabled || value >= max,
|
|
6029
|
+
onClick: () => onChange(Math.min(max, value + step))
|
|
6030
|
+
},
|
|
6031
|
+
"+"
|
|
6032
|
+
));
|
|
6033
|
+
};
|
|
5751
6034
|
|
|
5752
6035
|
// src/ui/QuantitySelect.tsx
|
|
5753
6036
|
var import_react15 = __toESM(require("react"));
|
|
@@ -5812,9 +6095,10 @@ var clock2 = (s) => {
|
|
|
5812
6095
|
var TimerBanner = ({
|
|
5813
6096
|
seconds,
|
|
5814
6097
|
urgentAt = 60,
|
|
5815
|
-
message
|
|
6098
|
+
message,
|
|
5816
6099
|
className
|
|
5817
6100
|
}) => {
|
|
6101
|
+
const t = useT();
|
|
5818
6102
|
const [dismissed, setDismissed] = (0, import_react18.useState)(false);
|
|
5819
6103
|
if (seconds === void 0 || seconds <= 0 || dismissed) return null;
|
|
5820
6104
|
const urgent = seconds <= urgentAt;
|
|
@@ -5828,14 +6112,14 @@ var TimerBanner = ({
|
|
|
5828
6112
|
className
|
|
5829
6113
|
)
|
|
5830
6114
|
},
|
|
5831
|
-
/* @__PURE__ */ import_react18.default.createElement("span", { className: "tf-checkout-timerbanner__msg" }, message),
|
|
6115
|
+
/* @__PURE__ */ import_react18.default.createElement("span", { className: "tf-checkout-timerbanner__msg" }, message != null ? message : t("timer.completePurchase")),
|
|
5832
6116
|
/* @__PURE__ */ import_react18.default.createElement("span", { className: "tf-checkout-timerbanner__clock" }, clock2(seconds)),
|
|
5833
6117
|
/* @__PURE__ */ import_react18.default.createElement(
|
|
5834
6118
|
"button",
|
|
5835
6119
|
{
|
|
5836
6120
|
type: "button",
|
|
5837
6121
|
className: "tf-checkout-timerbanner__close",
|
|
5838
|
-
"aria-label": "
|
|
6122
|
+
"aria-label": t("common.dismiss"),
|
|
5839
6123
|
onClick: () => setDismissed(true)
|
|
5840
6124
|
},
|
|
5841
6125
|
"\xD7"
|
|
@@ -5868,9 +6152,9 @@ var ForgotPasswordForm = ({
|
|
|
5868
6152
|
void onSubmit(email);
|
|
5869
6153
|
};
|
|
5870
6154
|
if (successMessage) {
|
|
5871
|
-
return /* @__PURE__ */ import_react19.default.createElement("div", { className: "tf-checkout-auth__form" }, /* @__PURE__ */ import_react19.default.createElement("div", { className: "tf-checkout-auth__success", role: "status" }, successMessage), /* @__PURE__ */ import_react19.default.createElement(Button, { type: "button", block: true, onClick: () => onBackToLogin(email) }, "
|
|
6155
|
+
return /* @__PURE__ */ import_react19.default.createElement("div", { className: "tf-checkout-auth__form" }, /* @__PURE__ */ import_react19.default.createElement("div", { className: "tf-checkout-auth__success", role: "status" }, successMessage), /* @__PURE__ */ import_react19.default.createElement(Button, { type: "button", block: true, onClick: () => onBackToLogin(email) }, t("auth.backToLogin")));
|
|
5872
6156
|
}
|
|
5873
|
-
return /* @__PURE__ */ import_react19.default.createElement("form", { className: "tf-checkout-auth__form", onSubmit: submit, noValidate: true }, /* @__PURE__ */ import_react19.default.createElement("p", { className: "tf-checkout-auth__intro" }, "
|
|
6157
|
+
return /* @__PURE__ */ import_react19.default.createElement("form", { className: "tf-checkout-auth__form", onSubmit: submit, noValidate: true }, /* @__PURE__ */ import_react19.default.createElement("p", { className: "tf-checkout-auth__intro" }, t("auth.forgotIntro")), error && /* @__PURE__ */ import_react19.default.createElement("div", { className: "tf-checkout-auth__alert", role: "alert" }, error), /* @__PURE__ */ import_react19.default.createElement(Field, { label: t("auth.email"), error: errors.email }, /* @__PURE__ */ import_react19.default.createElement(
|
|
5874
6158
|
Input,
|
|
5875
6159
|
{
|
|
5876
6160
|
type: "email",
|
|
@@ -5885,14 +6169,14 @@ var ForgotPasswordForm = ({
|
|
|
5885
6169
|
onFieldChange == null ? void 0 : onFieldChange();
|
|
5886
6170
|
}
|
|
5887
6171
|
}
|
|
5888
|
-
)), /* @__PURE__ */ import_react19.default.createElement(Button, { type: "submit", block: true, loading }, "
|
|
6172
|
+
)), /* @__PURE__ */ import_react19.default.createElement(Button, { type: "submit", block: true, loading }, t("auth.sendResetInstructions")), /* @__PURE__ */ import_react19.default.createElement(
|
|
5889
6173
|
"button",
|
|
5890
6174
|
{
|
|
5891
6175
|
type: "button",
|
|
5892
6176
|
className: "tf-checkout-auth__text-button tf-checkout-auth__back",
|
|
5893
6177
|
onClick: () => onBackToLogin(email)
|
|
5894
6178
|
},
|
|
5895
|
-
"
|
|
6179
|
+
t("auth.backToLogin")
|
|
5896
6180
|
));
|
|
5897
6181
|
};
|
|
5898
6182
|
|
|
@@ -5994,14 +6278,14 @@ var LoginForm = ({
|
|
|
5994
6278
|
}
|
|
5995
6279
|
}
|
|
5996
6280
|
)
|
|
5997
|
-
), /* @__PURE__ */ import_react21.default.createElement(Button, { type: "submit", block: true, loading }, "
|
|
6281
|
+
), /* @__PURE__ */ import_react21.default.createElement(Button, { type: "submit", block: true, loading }, t("auth.logIn")), allowPasswordReset && onForgotPassword && /* @__PURE__ */ import_react21.default.createElement(
|
|
5998
6282
|
"button",
|
|
5999
6283
|
{
|
|
6000
6284
|
type: "button",
|
|
6001
6285
|
className: "tf-checkout-auth__text-button tf-checkout-auth__forgot",
|
|
6002
6286
|
onClick: () => onForgotPassword(email)
|
|
6003
6287
|
},
|
|
6004
|
-
"
|
|
6288
|
+
t("auth.forgotPassword")
|
|
6005
6289
|
));
|
|
6006
6290
|
};
|
|
6007
6291
|
|
|
@@ -6228,7 +6512,7 @@ var RegisterForm = ({
|
|
|
6228
6512
|
invalid: Boolean(errors.stateId),
|
|
6229
6513
|
onChange: (event) => setField("stateId", event.target.value)
|
|
6230
6514
|
},
|
|
6231
|
-
/* @__PURE__ */ import_react22.default.createElement("option", { value: "" }, states.length > 0 ? "
|
|
6515
|
+
/* @__PURE__ */ import_react22.default.createElement("option", { value: "" }, states.length > 0 ? t("auth.selectState") : t("auth.notRequired")),
|
|
6232
6516
|
states.map((state) => /* @__PURE__ */ import_react22.default.createElement("option", { key: state.id, value: state.id }, state.name))
|
|
6233
6517
|
)
|
|
6234
6518
|
), /* @__PURE__ */ import_react22.default.createElement(
|
|
@@ -6322,7 +6606,7 @@ var RegisterForm = ({
|
|
|
6322
6606
|
}
|
|
6323
6607
|
)
|
|
6324
6608
|
)),
|
|
6325
|
-
/* @__PURE__ */ import_react22.default.createElement(Button, { type: "submit", block: true, loading }, "
|
|
6609
|
+
/* @__PURE__ */ import_react22.default.createElement(Button, { type: "submit", block: true, loading }, t("auth.createAccount"))
|
|
6326
6610
|
);
|
|
6327
6611
|
};
|
|
6328
6612
|
|
|
@@ -6414,7 +6698,7 @@ var AuthModal = ({
|
|
|
6414
6698
|
if (event.target === event.currentTarget && !auth.isSubmitting) onClose();
|
|
6415
6699
|
};
|
|
6416
6700
|
const isPasswordReset = auth.view === "forgot-password";
|
|
6417
|
-
const title = isPasswordReset ? "
|
|
6701
|
+
const title = isPasswordReset ? t("auth.passwordReset") : t("auth.title");
|
|
6418
6702
|
return /* @__PURE__ */ import_react23.default.createElement("div", { className: cx("tf-checkout-auth", className), onMouseDown: closeFromBackdrop }, /* @__PURE__ */ import_react23.default.createElement(
|
|
6419
6703
|
"div",
|
|
6420
6704
|
{
|
|
@@ -6456,7 +6740,7 @@ var AuthModal = ({
|
|
|
6456
6740
|
),
|
|
6457
6741
|
onClick: () => auth.showLogin(auth.suggestedEmail)
|
|
6458
6742
|
},
|
|
6459
|
-
"
|
|
6743
|
+
t("auth.logIn")
|
|
6460
6744
|
),
|
|
6461
6745
|
/* @__PURE__ */ import_react23.default.createElement(
|
|
6462
6746
|
"button",
|
|
@@ -6470,7 +6754,7 @@ var AuthModal = ({
|
|
|
6470
6754
|
),
|
|
6471
6755
|
onClick: () => auth.showRegister(auth.suggestedEmail)
|
|
6472
6756
|
},
|
|
6473
|
-
"
|
|
6757
|
+
t("auth.signUp")
|
|
6474
6758
|
)
|
|
6475
6759
|
),
|
|
6476
6760
|
logoUrl && /* @__PURE__ */ import_react23.default.createElement("div", { className: "tf-checkout-auth__logo-wrap" }, /* @__PURE__ */ import_react23.default.createElement(
|
|
@@ -6539,9 +6823,9 @@ var ResetPasswordForm = ({
|
|
|
6539
6823
|
const validation = (0, import_react24.useMemo)(() => {
|
|
6540
6824
|
if (!submitted) return {};
|
|
6541
6825
|
return {
|
|
6542
|
-
token: token ? "" : "
|
|
6543
|
-
password: password.length < 8 ? "
|
|
6544
|
-
confirmation: password !== confirmation ? "
|
|
6826
|
+
token: token ? "" : t("auth.missingToken"),
|
|
6827
|
+
password: password.length < 8 ? t("auth.passwordTooShort") : !/[@$!%*#?&]/.test(password) ? t("auth.passwordNeedsSpecial") : "",
|
|
6828
|
+
confirmation: password !== confirmation ? t("auth.passwordsMustMatch") : ""
|
|
6545
6829
|
};
|
|
6546
6830
|
}, [confirmation, password, submitted, token]);
|
|
6547
6831
|
const reset = hooks_exports.useResetPassword({
|
|
@@ -6558,7 +6842,7 @@ var ResetPasswordForm = ({
|
|
|
6558
6842
|
reset.mutate({ token, password, passwordConfirmation: confirmation });
|
|
6559
6843
|
};
|
|
6560
6844
|
if (success) {
|
|
6561
|
-
return /* @__PURE__ */ import_react24.default.createElement("div", { className: "tf-checkout-auth__form" }, /* @__PURE__ */ import_react24.default.createElement("div", { className: "tf-checkout-auth__success", role: "status" }, "
|
|
6845
|
+
return /* @__PURE__ */ import_react24.default.createElement("div", { className: "tf-checkout-auth__form" }, /* @__PURE__ */ import_react24.default.createElement("div", { className: "tf-checkout-auth__success", role: "status" }, t("auth.passwordChanged")), onBackToLogin && /* @__PURE__ */ import_react24.default.createElement(Button, { type: "button", block: true, onClick: onBackToLogin }, t("auth.logIn")));
|
|
6562
6846
|
}
|
|
6563
6847
|
return /* @__PURE__ */ import_react24.default.createElement("form", { className: "tf-checkout-auth__form", onSubmit: submit, noValidate: true }, /* @__PURE__ */ import_react24.default.createElement("h2", { className: "tf-checkout-auth__title" }, t("auth.changePassword")), validation.token && /* @__PURE__ */ import_react24.default.createElement("div", { className: "tf-checkout-auth__alert", role: "alert" }, validation.token), reset.error && /* @__PURE__ */ import_react24.default.createElement("div", { className: "tf-checkout-auth__alert", role: "alert" }, errorMessage(reset.error)), /* @__PURE__ */ import_react24.default.createElement(Field, { label: t("auth.newPassword"), error: validation.password }, /* @__PURE__ */ import_react24.default.createElement(
|
|
6564
6848
|
Input,
|
|
@@ -6582,36 +6866,37 @@ var ResetPasswordForm = ({
|
|
|
6582
6866
|
invalid: Boolean(validation.confirmation),
|
|
6583
6867
|
onChange: (event) => setConfirmation(event.target.value)
|
|
6584
6868
|
}
|
|
6585
|
-
)), /* @__PURE__ */ import_react24.default.createElement(Button, { type: "submit", block: true, loading: reset.isPending, disabled: !token }, "
|
|
6869
|
+
)), /* @__PURE__ */ import_react24.default.createElement(Button, { type: "submit", block: true, loading: reset.isPending, disabled: !token }, t("common.submit")));
|
|
6586
6870
|
};
|
|
6587
6871
|
|
|
6588
6872
|
// src/sections/Tickets.tsx
|
|
6589
6873
|
var import_react25 = __toESM(require("react"));
|
|
6590
6874
|
var WaitingListForm = ({ ticket, onJoin }) => {
|
|
6875
|
+
const tr = useT();
|
|
6591
6876
|
const [form, setForm] = (0, import_react25.useState)({ firstName: "", lastName: "", email: "" });
|
|
6592
6877
|
const [state, setState] = (0, import_react25.useState)("idle");
|
|
6593
6878
|
const [error, setError] = (0, import_react25.useState)("");
|
|
6594
6879
|
const ok = form.firstName.trim() && form.lastName.trim() && form.email.trim();
|
|
6595
6880
|
if (state === "done")
|
|
6596
|
-
return /* @__PURE__ */ import_react25.default.createElement("p", { className: "tf-checkout-note tf-checkout-tickets__wl-done" }, "
|
|
6881
|
+
return /* @__PURE__ */ import_react25.default.createElement("p", { className: "tf-checkout-note tf-checkout-tickets__wl-done" }, tr("tickets.waitingListJoined"));
|
|
6597
6882
|
return /* @__PURE__ */ import_react25.default.createElement("div", { className: "tf-checkout-tickets__wl" }, /* @__PURE__ */ import_react25.default.createElement(FieldRow, null, /* @__PURE__ */ import_react25.default.createElement(Field, null, /* @__PURE__ */ import_react25.default.createElement(
|
|
6598
6883
|
Input,
|
|
6599
6884
|
{
|
|
6600
|
-
placeholder: "
|
|
6885
|
+
placeholder: tr("tickets.firstName"),
|
|
6601
6886
|
value: form.firstName,
|
|
6602
6887
|
onChange: (e) => setForm((f) => ({ ...f, firstName: e.target.value }))
|
|
6603
6888
|
}
|
|
6604
6889
|
)), /* @__PURE__ */ import_react25.default.createElement(Field, null, /* @__PURE__ */ import_react25.default.createElement(
|
|
6605
6890
|
Input,
|
|
6606
6891
|
{
|
|
6607
|
-
placeholder: "
|
|
6892
|
+
placeholder: tr("tickets.lastName"),
|
|
6608
6893
|
value: form.lastName,
|
|
6609
6894
|
onChange: (e) => setForm((f) => ({ ...f, lastName: e.target.value }))
|
|
6610
6895
|
}
|
|
6611
6896
|
))), /* @__PURE__ */ import_react25.default.createElement(Field, null, /* @__PURE__ */ import_react25.default.createElement(
|
|
6612
6897
|
Input,
|
|
6613
6898
|
{
|
|
6614
|
-
placeholder: "
|
|
6899
|
+
placeholder: tr("tickets.email"),
|
|
6615
6900
|
value: form.email,
|
|
6616
6901
|
onChange: (e) => setForm((f) => ({ ...f, email: e.target.value }))
|
|
6617
6902
|
}
|
|
@@ -6630,14 +6915,14 @@ var WaitingListForm = ({ ticket, onJoin }) => {
|
|
|
6630
6915
|
disabled: !ok || state === "busy",
|
|
6631
6916
|
variant: "secondary"
|
|
6632
6917
|
},
|
|
6633
|
-
"
|
|
6918
|
+
tr("tickets.joinWaitingList")
|
|
6634
6919
|
), error && /* @__PURE__ */ import_react25.default.createElement("p", { className: "tf-checkout-error-text" }, error));
|
|
6635
6920
|
};
|
|
6636
6921
|
var Tickets = ({
|
|
6637
6922
|
eventId,
|
|
6638
6923
|
title = false,
|
|
6639
6924
|
onContinue,
|
|
6640
|
-
buttonLabel
|
|
6925
|
+
buttonLabel,
|
|
6641
6926
|
timeSlotDates,
|
|
6642
6927
|
step,
|
|
6643
6928
|
onSelectSeats,
|
|
@@ -6647,7 +6932,9 @@ var Tickets = ({
|
|
|
6647
6932
|
className
|
|
6648
6933
|
}) => {
|
|
6649
6934
|
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j;
|
|
6935
|
+
const tr = useT();
|
|
6650
6936
|
const checkout = useCheckoutContext();
|
|
6937
|
+
const buttonText = buttonLabel != null ? buttonLabel : tr("tickets.getTickets");
|
|
6651
6938
|
const ticketsQuery = hooks_exports.useTicketsWithMeta(eventId);
|
|
6652
6939
|
const promoMeta = (_a = ticketsQuery.data) == null ? void 0 : _a.promo;
|
|
6653
6940
|
const showWaitingList = (_c = (_b = ticketsQuery.data) == null ? void 0 : _b.showWaitingList) != null ? _c : false;
|
|
@@ -6733,7 +7020,7 @@ var Tickets = ({
|
|
|
6733
7020
|
const seatMapRow = (t) => isSeated && !t.allowDirectPurchase;
|
|
6734
7021
|
const hasSeatMapTickets = tickets.some(seatMapRow);
|
|
6735
7022
|
const directPurchasable = tickets.filter((t) => !seatMapRow(t));
|
|
6736
|
-
const seatCtaLabel = (eventInfo == null ? void 0 : eventInfo.tableMapEnabled) ? "
|
|
7023
|
+
const seatCtaLabel = (eventInfo == null ? void 0 : eventInfo.tableMapEnabled) ? tr("tickets.selectOnMap") : tr("tickets.selectSeats");
|
|
6737
7024
|
const firstTableIndex = tickets.findIndex((t) => t.isTable);
|
|
6738
7025
|
const firstTableId = firstTableIndex > 0 && tickets.slice(0, firstTableIndex).some((t) => !t.isTable) ? tickets[firstTableIndex].id : void 0;
|
|
6739
7026
|
const prime = () => {
|
|
@@ -6766,7 +7053,7 @@ var Tickets = ({
|
|
|
6766
7053
|
const ticketIndex = tickets.findIndex((candidate) => candidate.id === t.id);
|
|
6767
7054
|
const previousTicket = ticketIndex > 0 ? tickets[ticketIndex - 1] : void 0;
|
|
6768
7055
|
const startsNamedGroup = Boolean(t.groupName) && t.groupName !== (previousTicket == null ? void 0 : previousTicket.groupName);
|
|
6769
|
-
return /* @__PURE__ */ import_react25.default.createElement(import_react25.Fragment, { key: t.id }, startsNamedGroup ? /* @__PURE__ */ import_react25.default.createElement("div", { className: "tf-checkout-tickets__group" }, t.groupName) : t.id === firstTableId && /* @__PURE__ */ import_react25.default.createElement("div", { className: "tf-checkout-tickets__group" }, "
|
|
7056
|
+
return /* @__PURE__ */ import_react25.default.createElement(import_react25.Fragment, { key: t.id }, startsNamedGroup ? /* @__PURE__ */ import_react25.default.createElement("div", { className: "tf-checkout-tickets__group" }, t.groupName) : t.id === firstTableId && /* @__PURE__ */ import_react25.default.createElement("div", { className: "tf-checkout-tickets__group" }, tr("tickets.reserveTables")), /* @__PURE__ */ import_react25.default.createElement("div", { className: "tf-checkout-tickets__row-wrap" }, /* @__PURE__ */ import_react25.default.createElement("div", { className: "tf-checkout-tickets__row" }, /* @__PURE__ */ import_react25.default.createElement("div", { className: "tf-checkout-tickets__info" }, /* @__PURE__ */ import_react25.default.createElement("div", { className: "tf-checkout-tickets__name" }, /* @__PURE__ */ import_react25.default.createElement("span", null, t.name), t.descriptionRich && /* @__PURE__ */ import_react25.default.createElement(
|
|
6770
7057
|
"button",
|
|
6771
7058
|
{
|
|
6772
7059
|
type: "button",
|
|
@@ -6775,8 +7062,8 @@ var Tickets = ({
|
|
|
6775
7062
|
"aria-controls": `ticket-description-${t.id}`,
|
|
6776
7063
|
onClick: () => setVisibleDescription((current2) => current2 === t.id ? null : t.id)
|
|
6777
7064
|
},
|
|
6778
|
-
visibleDescription === t.id ? "
|
|
6779
|
-
)), /* @__PURE__ */ import_react25.default.createElement("div", { className: "tf-checkout-tickets__price" }, discounted && /* @__PURE__ */ import_react25.default.createElement("span", { className: "tf-checkout-tickets__old" }, money(sym, original)), /* @__PURE__ */ import_react25.default.createElement(
|
|
7065
|
+
visibleDescription === t.id ? tr("tickets.hideInfo") : tr("tickets.viewInfo")
|
|
7066
|
+
)), t.badgeText && !unavailable && /* @__PURE__ */ import_react25.default.createElement("span", { className: "tf-checkout-tickets__badge" }, t.badgeText), /* @__PURE__ */ import_react25.default.createElement("div", { className: "tf-checkout-tickets__price" }, discounted && /* @__PURE__ */ import_react25.default.createElement("span", { className: "tf-checkout-tickets__old" }, money(sym, original)), /* @__PURE__ */ import_react25.default.createElement(
|
|
6780
7067
|
"span",
|
|
6781
7068
|
{
|
|
6782
7069
|
className: cx(
|
|
@@ -6784,8 +7071,8 @@ var Tickets = ({
|
|
|
6784
7071
|
isFree && "tf-checkout-tickets__amount--free"
|
|
6785
7072
|
)
|
|
6786
7073
|
},
|
|
6787
|
-
isFree ? "
|
|
6788
|
-
), !isFree && !t.soldOut && /* @__PURE__ */ import_react25.default.createElement("span", { className: "tf-checkout-tickets__fees" },
|
|
7074
|
+
isFree ? tr("tickets.free") : money(sym, t.price)
|
|
7075
|
+
), !isFree && !t.soldOut && /* @__PURE__ */ import_react25.default.createElement("span", { className: "tf-checkout-tickets__fees" }, tr("tickets.withFees", { price: money(sym, t.priceWithFees) })), t.depositPercent != null && /* @__PURE__ */ import_react25.default.createElement("span", { className: "tf-checkout-tickets__deposit" }, tr("tickets.deposit", { percent: t.depositPercent.toFixed(2) })))), seatMapRow(t) ? null : unavailable ? /* @__PURE__ */ import_react25.default.createElement("span", { className: "tf-checkout-tickets__soldout" }, t.soldOut ? tr("tickets.soldOut") : notStarted ? tr("tickets.salesNotStarted") : tr("tickets.salesEnded")) : /* @__PURE__ */ import_react25.default.createElement("div", { className: "tf-checkout-tickets__qty" }, t.isTable && /* @__PURE__ */ import_react25.default.createElement("span", { className: "tf-checkout-tickets__guests" }, tr("tickets.guests")), /* @__PURE__ */ import_react25.default.createElement(
|
|
6789
7076
|
QuantitySelect,
|
|
6790
7077
|
{
|
|
6791
7078
|
value: (_a2 = qty[t.id]) != null ? _a2 : 0,
|
|
@@ -6814,7 +7101,7 @@ var Tickets = ({
|
|
|
6814
7101
|
className: "tf-checkout-tickets__wl-toggle",
|
|
6815
7102
|
onClick: () => setWlOpen((w) => ({ ...w, [t.id]: true }))
|
|
6816
7103
|
},
|
|
6817
|
-
"
|
|
7104
|
+
tr("tickets.joinWaitingList")
|
|
6818
7105
|
))));
|
|
6819
7106
|
};
|
|
6820
7107
|
const timeGroups = [];
|
|
@@ -6832,7 +7119,7 @@ var Tickets = ({
|
|
|
6832
7119
|
title: title || "",
|
|
6833
7120
|
pills: listQuery.isFetching && !listQuery.isLoading ? /* @__PURE__ */ import_react25.default.createElement(Loader, null) : void 0
|
|
6834
7121
|
}
|
|
6835
|
-
), listQuery.isLoading && /* @__PURE__ */ import_react25.default.createElement("div", { className: "tf-checkout-tickets__loading" }, /* @__PURE__ */ import_react25.default.createElement(Loader, { className: "tf-checkout-tickets__loading-spinner" })), listQuery.error && /* @__PURE__ */ import_react25.default.createElement("p", { className: "tf-checkout-error-text" }, listQuery.error.message), isTimeSlot && dates.length > 0 && /* @__PURE__ */ import_react25.default.createElement("div", { className: "tf-checkout-tickets__currency" }, /* @__PURE__ */ import_react25.default.createElement("span", { className: "tf-checkout-tickets__currency-label" }, "
|
|
7122
|
+
), listQuery.isLoading && /* @__PURE__ */ import_react25.default.createElement("div", { className: "tf-checkout-tickets__loading" }, /* @__PURE__ */ import_react25.default.createElement(Loader, { className: "tf-checkout-tickets__loading-spinner" })), listQuery.error && /* @__PURE__ */ import_react25.default.createElement("p", { className: "tf-checkout-error-text" }, listQuery.error.message), isTimeSlot && dates.length > 0 && /* @__PURE__ */ import_react25.default.createElement("div", { className: "tf-checkout-tickets__currency" }, /* @__PURE__ */ import_react25.default.createElement("span", { className: "tf-checkout-tickets__currency-label" }, tr("common.date")), /* @__PURE__ */ import_react25.default.createElement(
|
|
6836
7123
|
"select",
|
|
6837
7124
|
{
|
|
6838
7125
|
className: "tf-checkout-select",
|
|
@@ -6843,7 +7130,7 @@ var Tickets = ({
|
|
|
6843
7130
|
}
|
|
6844
7131
|
},
|
|
6845
7132
|
dates.map((d) => /* @__PURE__ */ import_react25.default.createElement("option", { key: d, value: d }, d))
|
|
6846
|
-
)), checkout.currency && checkout.currency.available.length > 1 && /* @__PURE__ */ import_react25.default.createElement("div", { className: "tf-checkout-tickets__currency" }, /* @__PURE__ */ import_react25.default.createElement("span", { className: "tf-checkout-tickets__currency-label" }, "
|
|
7133
|
+
)), checkout.currency && checkout.currency.available.length > 1 && /* @__PURE__ */ import_react25.default.createElement("div", { className: "tf-checkout-tickets__currency" }, /* @__PURE__ */ import_react25.default.createElement("span", { className: "tf-checkout-tickets__currency-label" }, tr("common.currency")), /* @__PURE__ */ import_react25.default.createElement(
|
|
6847
7134
|
"select",
|
|
6848
7135
|
{
|
|
6849
7136
|
className: "tf-checkout-select",
|
|
@@ -6851,18 +7138,18 @@ var Tickets = ({
|
|
|
6851
7138
|
onChange: (e) => changeCurrency(e.target.value)
|
|
6852
7139
|
},
|
|
6853
7140
|
checkout.currency.available.map((c) => /* @__PURE__ */ import_react25.default.createElement("option", { key: c.code, value: c.code }, c.name, " (", c.code, ")"))
|
|
6854
|
-
)), isTimeSlot && !slotQuery.isLoading && tickets.length === 0 && slotDate && /* @__PURE__ */ import_react25.default.createElement("p", { className: "tf-checkout-note" }, "
|
|
7141
|
+
)), isTimeSlot && !slotQuery.isLoading && tickets.length === 0 && slotDate && /* @__PURE__ */ import_react25.default.createElement("p", { className: "tf-checkout-note" }, tr("tickets.noSessions")), isTimeSlot ? timeGroups.map((g) => /* @__PURE__ */ import_react25.default.createElement(import_react25.Fragment, { key: g.time }, g.time && /* @__PURE__ */ import_react25.default.createElement("div", { className: "tf-checkout-tickets__slot-time" }, g.time), g.items.map(renderRow))) : tickets.map(renderRow), showCodeInput && /* @__PURE__ */ import_react25.default.createElement("div", { className: "tf-checkout-tickets__promo" }, !isAccess && !promoOpen ? /* @__PURE__ */ import_react25.default.createElement(
|
|
6855
7142
|
"button",
|
|
6856
7143
|
{
|
|
6857
7144
|
type: "button",
|
|
6858
7145
|
className: "tf-checkout-tickets__promo-toggle",
|
|
6859
7146
|
onClick: () => setPromoOpen(true)
|
|
6860
7147
|
},
|
|
6861
|
-
"
|
|
7148
|
+
tr("tickets.gotPromoCode")
|
|
6862
7149
|
) : /* @__PURE__ */ import_react25.default.createElement(import_react25.default.Fragment, null, /* @__PURE__ */ import_react25.default.createElement(FieldRow, null, /* @__PURE__ */ import_react25.default.createElement(Field, null, /* @__PURE__ */ import_react25.default.createElement(
|
|
6863
7150
|
Input,
|
|
6864
7151
|
{
|
|
6865
|
-
placeholder: isAccess ? "
|
|
7152
|
+
placeholder: isAccess ? tr("tickets.accessCode") : tr("tickets.promoCode"),
|
|
6866
7153
|
value: code,
|
|
6867
7154
|
onChange: (e) => setCode(e.target.value),
|
|
6868
7155
|
onKeyDown: (e) => e.key === "Enter" && applyCode()
|
|
@@ -6893,7 +7180,7 @@ var Tickets = ({
|
|
|
6893
7180
|
loading: checkout.isBusy,
|
|
6894
7181
|
disabled: checkout.isBusy || selected.length === 0
|
|
6895
7182
|
},
|
|
6896
|
-
checkout.isBusy ? "
|
|
7183
|
+
checkout.isBusy ? tr("tickets.reserving") : selectionIsTable ? tr("tickets.reserveTables") : buttonText
|
|
6897
7184
|
), hasSeatMapTickets && /* @__PURE__ */ import_react25.default.createElement(Button, { block: true, onClick: () => onSelectSeats == null ? void 0 : onSelectSeats() }, seatCtaLabel), (error || checkout.error) && /* @__PURE__ */ import_react25.default.createElement("p", { className: "tf-checkout-error-text" }, error || checkout.error));
|
|
6898
7185
|
};
|
|
6899
7186
|
|
|
@@ -7254,13 +7541,17 @@ var AddOns = ({
|
|
|
7254
7541
|
eventId,
|
|
7255
7542
|
onContinue,
|
|
7256
7543
|
onSkip,
|
|
7257
|
-
buttonLabel
|
|
7258
|
-
eyebrow
|
|
7259
|
-
heading
|
|
7544
|
+
buttonLabel,
|
|
7545
|
+
eyebrow,
|
|
7546
|
+
heading,
|
|
7260
7547
|
className
|
|
7261
7548
|
}) => {
|
|
7262
7549
|
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
7550
|
+
const t = useT();
|
|
7263
7551
|
const checkout = useCheckoutContext();
|
|
7552
|
+
const buttonText = buttonLabel != null ? buttonLabel : t("addons.confirmSelection");
|
|
7553
|
+
const eyebrowText = eyebrow != null ? eyebrow : t("addons.eyebrow");
|
|
7554
|
+
const headingText = heading != null ? heading : t("addons.heading");
|
|
7264
7555
|
const combined = !onContinue;
|
|
7265
7556
|
const addonsQuery = hooks_exports.useEventAddons(eventId);
|
|
7266
7557
|
const all = (_a = addonsQuery.data) != null ? _a : [];
|
|
@@ -7290,14 +7581,14 @@ var AddOns = ({
|
|
|
7290
7581
|
return ((_a3 = selection[id]) != null ? _a3 : 0) > 0;
|
|
7291
7582
|
})
|
|
7292
7583
|
);
|
|
7293
|
-
const
|
|
7584
|
+
const t2 = setTimeout(() => {
|
|
7294
7585
|
checkout.setAddonDataCapture(captureForSelected);
|
|
7295
7586
|
checkout.setAddons(selection).catch((e) => setError(errorMessage(e)));
|
|
7296
7587
|
}, 500);
|
|
7297
|
-
return () => clearTimeout(
|
|
7588
|
+
return () => clearTimeout(t2);
|
|
7298
7589
|
}, [combined, qty, capture]);
|
|
7299
7590
|
const hasRequired = ((_f = checkout.requiredAddOns) != null ? _f : []).some((a) => a.required);
|
|
7300
|
-
const head = /* @__PURE__ */ import_react27.default.createElement("div", { className: "tf-checkout-addons__head" },
|
|
7591
|
+
const head = /* @__PURE__ */ import_react27.default.createElement("div", { className: "tf-checkout-addons__head" }, eyebrowText && /* @__PURE__ */ import_react27.default.createElement("span", { className: "tf-checkout-addons__eyebrow" }, eyebrowText), /* @__PURE__ */ import_react27.default.createElement("span", { className: "tf-checkout-addons__heading" }, headingText), onSkip && !hasRequired && /* @__PURE__ */ import_react27.default.createElement("button", { type: "button", className: "tf-checkout-addons__skip", onClick: onSkip }, "Skip"));
|
|
7301
7592
|
if (addonsQuery.isLoading) {
|
|
7302
7593
|
return /* @__PURE__ */ import_react27.default.createElement(Card, { className }, head, /* @__PURE__ */ import_react27.default.createElement("div", { className: "tf-checkout-section-loader" }, /* @__PURE__ */ import_react27.default.createElement(Loader, null)));
|
|
7303
7594
|
}
|
|
@@ -7344,7 +7635,7 @@ var AddOns = ({
|
|
|
7344
7635
|
className: "tf-checkout-addons__desc",
|
|
7345
7636
|
dangerouslySetInnerHTML: { __html: a.description }
|
|
7346
7637
|
}
|
|
7347
|
-
)), soldOut(a) ? /* @__PURE__ */ import_react27.default.createElement("span", { className: "tf-checkout-tickets__soldout" }, "
|
|
7638
|
+
)), soldOut(a) ? /* @__PURE__ */ import_react27.default.createElement("span", { className: "tf-checkout-tickets__soldout" }, t("tickets.soldOut")) : /* @__PURE__ */ import_react27.default.createElement(
|
|
7348
7639
|
QuantitySelect,
|
|
7349
7640
|
{
|
|
7350
7641
|
value: n,
|
|
@@ -7375,7 +7666,7 @@ var AddOns = ({
|
|
|
7375
7666
|
loading: checkout.isBusy,
|
|
7376
7667
|
disabled: checkout.isBusy || selectedCount === 0
|
|
7377
7668
|
},
|
|
7378
|
-
checkout.isBusy ? "
|
|
7669
|
+
checkout.isBusy ? t("addons.updating") : buttonText
|
|
7379
7670
|
), missing.length > 0 && /* @__PURE__ */ import_react27.default.createElement("p", { className: "tf-checkout-note" }, "Required add-on: ", missing.join(", "), "."), (error || checkout.error) && /* @__PURE__ */ import_react27.default.createElement("p", { className: "tf-checkout-error-text" }, error || checkout.error));
|
|
7380
7671
|
};
|
|
7381
7672
|
|
|
@@ -7393,17 +7684,18 @@ var BillingAddressFields = ({
|
|
|
7393
7684
|
setBilling
|
|
7394
7685
|
}) => {
|
|
7395
7686
|
var _a, _b, _c, _d, _e;
|
|
7687
|
+
const t = useT();
|
|
7396
7688
|
const setValue = (key) => (event) => setBilling((current2) => ({ ...current2, [key]: event.target.value }));
|
|
7397
|
-
return /* @__PURE__ */ import_react28.default.createElement(import_react28.default.Fragment, null, /* @__PURE__ */ import_react28.default.createElement("div", { className: "tf-checkout-billing__section-label" }, "
|
|
7689
|
+
return /* @__PURE__ */ import_react28.default.createElement(import_react28.default.Fragment, null, /* @__PURE__ */ import_react28.default.createElement("div", { className: "tf-checkout-billing__section-label" }, t("billing.address")), /* @__PURE__ */ import_react28.default.createElement(
|
|
7398
7690
|
Field,
|
|
7399
7691
|
{
|
|
7400
|
-
error: fieldError("Street address", "
|
|
7692
|
+
error: fieldError("Street address", t("billing.streetRequired")),
|
|
7401
7693
|
invalid: Boolean(fieldError("Street address"))
|
|
7402
7694
|
},
|
|
7403
7695
|
/* @__PURE__ */ import_react28.default.createElement(
|
|
7404
7696
|
Input,
|
|
7405
7697
|
{
|
|
7406
|
-
placeholder: "
|
|
7698
|
+
placeholder: t("billing.streetPlaceholder"),
|
|
7407
7699
|
autoComplete: "street-address",
|
|
7408
7700
|
value: (_a = billing.streetAddress) != null ? _a : "",
|
|
7409
7701
|
required: true,
|
|
@@ -7415,13 +7707,13 @@ var BillingAddressFields = ({
|
|
|
7415
7707
|
), /* @__PURE__ */ import_react28.default.createElement(FieldRow, null, /* @__PURE__ */ import_react28.default.createElement(
|
|
7416
7708
|
Field,
|
|
7417
7709
|
{
|
|
7418
|
-
error: fieldError("City", "
|
|
7710
|
+
error: fieldError("City", t("billing.cityRequired")),
|
|
7419
7711
|
invalid: Boolean(fieldError("City"))
|
|
7420
7712
|
},
|
|
7421
7713
|
/* @__PURE__ */ import_react28.default.createElement(
|
|
7422
7714
|
Input,
|
|
7423
7715
|
{
|
|
7424
|
-
placeholder: "
|
|
7716
|
+
placeholder: t("billing.cityPlaceholder"),
|
|
7425
7717
|
autoComplete: "address-level2",
|
|
7426
7718
|
value: (_b = billing.city) != null ? _b : "",
|
|
7427
7719
|
required: true,
|
|
@@ -7433,13 +7725,13 @@ var BillingAddressFields = ({
|
|
|
7433
7725
|
), /* @__PURE__ */ import_react28.default.createElement(
|
|
7434
7726
|
Field,
|
|
7435
7727
|
{
|
|
7436
|
-
error: fieldError("ZIP / postcode", "
|
|
7728
|
+
error: fieldError("ZIP / postcode", t("billing.postcodeRequired")),
|
|
7437
7729
|
invalid: Boolean(fieldError("ZIP / postcode"))
|
|
7438
7730
|
},
|
|
7439
7731
|
/* @__PURE__ */ import_react28.default.createElement(
|
|
7440
7732
|
Input,
|
|
7441
7733
|
{
|
|
7442
|
-
placeholder: "
|
|
7734
|
+
placeholder: t("billing.postcodePlaceholder"),
|
|
7443
7735
|
autoComplete: "postal-code",
|
|
7444
7736
|
value: (_c = billing.zip) != null ? _c : "",
|
|
7445
7737
|
required: true,
|
|
@@ -7451,14 +7743,14 @@ var BillingAddressFields = ({
|
|
|
7451
7743
|
)), /* @__PURE__ */ import_react28.default.createElement(FieldRow, null, /* @__PURE__ */ import_react28.default.createElement(
|
|
7452
7744
|
Field,
|
|
7453
7745
|
{
|
|
7454
|
-
error: fieldError("Country", "
|
|
7746
|
+
error: fieldError("Country", t("billing.countryRequired")),
|
|
7455
7747
|
invalid: Boolean(fieldError("Country"))
|
|
7456
7748
|
},
|
|
7457
7749
|
/* @__PURE__ */ import_react28.default.createElement(
|
|
7458
7750
|
Select,
|
|
7459
7751
|
{
|
|
7460
7752
|
value: (_d = billing.countryId) != null ? _d : "",
|
|
7461
|
-
"aria-label": "
|
|
7753
|
+
"aria-label": t("billing.countryLabel"),
|
|
7462
7754
|
required: true,
|
|
7463
7755
|
invalid: Boolean(fieldError("Country")),
|
|
7464
7756
|
"aria-invalid": Boolean(fieldError("Country")),
|
|
@@ -7478,13 +7770,13 @@ var BillingAddressFields = ({
|
|
|
7478
7770
|
});
|
|
7479
7771
|
}
|
|
7480
7772
|
},
|
|
7481
|
-
/* @__PURE__ */ import_react28.default.createElement("option", { value: "" }, "
|
|
7773
|
+
/* @__PURE__ */ import_react28.default.createElement("option", { value: "" }, t("billing.countryEmpty")),
|
|
7482
7774
|
countries.map((country) => /* @__PURE__ */ import_react28.default.createElement("option", { key: country.id, value: country.id }, country.name))
|
|
7483
7775
|
)
|
|
7484
7776
|
), /* @__PURE__ */ import_react28.default.createElement(
|
|
7485
7777
|
Field,
|
|
7486
7778
|
{
|
|
7487
|
-
error: fieldError("State / county", "
|
|
7779
|
+
error: fieldError("State / county", t("billing.stateRequired")),
|
|
7488
7780
|
invalid: Boolean(fieldError("State / county"))
|
|
7489
7781
|
},
|
|
7490
7782
|
/* @__PURE__ */ import_react28.default.createElement(
|
|
@@ -7492,7 +7784,7 @@ var BillingAddressFields = ({
|
|
|
7492
7784
|
{
|
|
7493
7785
|
value: (_e = billing.stateId) != null ? _e : "",
|
|
7494
7786
|
disabled: !billing.countryId || states.length === 0,
|
|
7495
|
-
"aria-label": "
|
|
7787
|
+
"aria-label": t("billing.stateLabel"),
|
|
7496
7788
|
required: states.length > 0,
|
|
7497
7789
|
invalid: Boolean(fieldError("State / county")),
|
|
7498
7790
|
"aria-invalid": Boolean(fieldError("State / county")),
|
|
@@ -7507,7 +7799,7 @@ var BillingAddressFields = ({
|
|
|
7507
7799
|
}));
|
|
7508
7800
|
}
|
|
7509
7801
|
},
|
|
7510
|
-
/* @__PURE__ */ import_react28.default.createElement("option", { value: "" },
|
|
7802
|
+
/* @__PURE__ */ import_react28.default.createElement("option", { value: "" }, states.length > 0 ? t("billing.stateEmptyRequired") : t("billing.stateEmpty")),
|
|
7511
7803
|
states.map((state) => /* @__PURE__ */ import_react28.default.createElement("option", { key: state.id, value: state.id }, state.name))
|
|
7512
7804
|
)
|
|
7513
7805
|
)));
|
|
@@ -7587,114 +7879,121 @@ var TicketHoldersCard = ({
|
|
|
7587
7879
|
fieldError,
|
|
7588
7880
|
renderCustomFields,
|
|
7589
7881
|
patchHolder
|
|
7590
|
-
}) =>
|
|
7591
|
-
const
|
|
7592
|
-
|
|
7593
|
-
|
|
7594
|
-
|
|
7595
|
-
|
|
7596
|
-
|
|
7597
|
-
{
|
|
7598
|
-
|
|
7599
|
-
error: fieldError(firstNameKey, "First name is required."),
|
|
7600
|
-
invalid: Boolean(fieldError(firstNameKey))
|
|
7601
|
-
},
|
|
7602
|
-
/* @__PURE__ */ import_react30.default.createElement(
|
|
7603
|
-
Input,
|
|
7882
|
+
}) => {
|
|
7883
|
+
const t = useT();
|
|
7884
|
+
return /* @__PURE__ */ import_react30.default.createElement(Card, { className: "tf-checkout-billing__holders-card" }, /* @__PURE__ */ import_react30.default.createElement(SectionHeader, { title: t("billing.ticketHolders") }), holders.map((holder, index) => {
|
|
7885
|
+
const firstNameKey = `Ticket ${index + 1} holder first name`;
|
|
7886
|
+
const lastNameKey = `Ticket ${index + 1} holder last name`;
|
|
7887
|
+
const emailKey = `Ticket ${index + 1} holder email`;
|
|
7888
|
+
const phoneKey = `Ticket ${index + 1} holder phone`;
|
|
7889
|
+
return /* @__PURE__ */ import_react30.default.createElement("div", { key: index, className: "tf-checkout-billing__holder" }, /* @__PURE__ */ import_react30.default.createElement("div", { className: "tf-checkout-billing__holder-title" }, t("billing.holderTitle", { number: index + 1 })), holderNamesRequired && /* @__PURE__ */ import_react30.default.createElement(FieldRow, null, /* @__PURE__ */ import_react30.default.createElement(
|
|
7890
|
+
Field,
|
|
7604
7891
|
{
|
|
7605
|
-
|
|
7606
|
-
|
|
7607
|
-
invalid: Boolean(fieldError(firstNameKey))
|
|
7608
|
-
|
|
7609
|
-
|
|
7610
|
-
|
|
7611
|
-
|
|
7612
|
-
|
|
7613
|
-
|
|
7614
|
-
|
|
7615
|
-
|
|
7616
|
-
|
|
7617
|
-
|
|
7618
|
-
|
|
7619
|
-
/* @__PURE__ */ import_react30.default.createElement(
|
|
7620
|
-
|
|
7892
|
+
label: t("billing.holderFirstName"),
|
|
7893
|
+
error: fieldError(firstNameKey, t("billing.firstNameRequired")),
|
|
7894
|
+
invalid: Boolean(fieldError(firstNameKey))
|
|
7895
|
+
},
|
|
7896
|
+
/* @__PURE__ */ import_react30.default.createElement(
|
|
7897
|
+
Input,
|
|
7898
|
+
{
|
|
7899
|
+
value: holder.firstName,
|
|
7900
|
+
required: true,
|
|
7901
|
+
invalid: Boolean(fieldError(firstNameKey)),
|
|
7902
|
+
"aria-invalid": Boolean(fieldError(firstNameKey)),
|
|
7903
|
+
onChange: (event) => patchHolder(index, { firstName: event.target.value })
|
|
7904
|
+
}
|
|
7905
|
+
)
|
|
7906
|
+
), /* @__PURE__ */ import_react30.default.createElement(
|
|
7907
|
+
Field,
|
|
7621
7908
|
{
|
|
7622
|
-
|
|
7623
|
-
|
|
7624
|
-
invalid: Boolean(fieldError(lastNameKey))
|
|
7625
|
-
|
|
7626
|
-
|
|
7627
|
-
|
|
7628
|
-
|
|
7629
|
-
|
|
7630
|
-
|
|
7631
|
-
|
|
7632
|
-
|
|
7633
|
-
|
|
7634
|
-
|
|
7635
|
-
|
|
7636
|
-
/* @__PURE__ */ import_react30.default.createElement(
|
|
7637
|
-
|
|
7909
|
+
label: t("billing.holderLastName"),
|
|
7910
|
+
error: fieldError(lastNameKey, t("billing.lastNameRequired")),
|
|
7911
|
+
invalid: Boolean(fieldError(lastNameKey))
|
|
7912
|
+
},
|
|
7913
|
+
/* @__PURE__ */ import_react30.default.createElement(
|
|
7914
|
+
Input,
|
|
7915
|
+
{
|
|
7916
|
+
value: holder.lastName,
|
|
7917
|
+
required: true,
|
|
7918
|
+
invalid: Boolean(fieldError(lastNameKey)),
|
|
7919
|
+
"aria-invalid": Boolean(fieldError(lastNameKey)),
|
|
7920
|
+
onChange: (event) => patchHolder(index, { lastName: event.target.value })
|
|
7921
|
+
}
|
|
7922
|
+
)
|
|
7923
|
+
)), collectHolderContact && /* @__PURE__ */ import_react30.default.createElement(FieldRow, null, /* @__PURE__ */ import_react30.default.createElement(
|
|
7924
|
+
Field,
|
|
7638
7925
|
{
|
|
7639
|
-
|
|
7640
|
-
|
|
7641
|
-
|
|
7642
|
-
|
|
7643
|
-
|
|
7644
|
-
|
|
7645
|
-
|
|
7646
|
-
|
|
7647
|
-
|
|
7648
|
-
|
|
7649
|
-
|
|
7650
|
-
|
|
7651
|
-
|
|
7652
|
-
|
|
7653
|
-
|
|
7654
|
-
|
|
7655
|
-
/* @__PURE__ */ import_react30.default.createElement(
|
|
7656
|
-
|
|
7926
|
+
label: t("billing.email"),
|
|
7927
|
+
error: fieldError(emailKey, t("billing.emailInvalid")),
|
|
7928
|
+
invalid: Boolean(fieldError(emailKey))
|
|
7929
|
+
},
|
|
7930
|
+
/* @__PURE__ */ import_react30.default.createElement(
|
|
7931
|
+
Input,
|
|
7932
|
+
{
|
|
7933
|
+
type: "email",
|
|
7934
|
+
autoComplete: "email",
|
|
7935
|
+
value: holder.email,
|
|
7936
|
+
required: true,
|
|
7937
|
+
invalid: Boolean(fieldError(emailKey)),
|
|
7938
|
+
"aria-invalid": Boolean(fieldError(emailKey)),
|
|
7939
|
+
onChange: (event) => patchHolder(index, { email: event.target.value })
|
|
7940
|
+
}
|
|
7941
|
+
)
|
|
7942
|
+
), /* @__PURE__ */ import_react30.default.createElement(
|
|
7943
|
+
Field,
|
|
7657
7944
|
{
|
|
7658
|
-
|
|
7659
|
-
|
|
7660
|
-
|
|
7661
|
-
|
|
7662
|
-
|
|
7663
|
-
|
|
7664
|
-
|
|
7665
|
-
|
|
7666
|
-
|
|
7667
|
-
|
|
7668
|
-
|
|
7669
|
-
|
|
7670
|
-
|
|
7671
|
-
|
|
7672
|
-
|
|
7673
|
-
|
|
7674
|
-
|
|
7675
|
-
|
|
7945
|
+
label: t("billing.phone"),
|
|
7946
|
+
error: fieldError(phoneKey, t("billing.phoneInvalid")),
|
|
7947
|
+
invalid: Boolean(fieldError(phoneKey))
|
|
7948
|
+
},
|
|
7949
|
+
/* @__PURE__ */ import_react30.default.createElement(
|
|
7950
|
+
import_react_international_phone2.PhoneInput,
|
|
7951
|
+
{
|
|
7952
|
+
className: "tf-checkout-phone",
|
|
7953
|
+
inputClassName: `tf-checkout-input tf-checkout-phone__input${fieldError(phoneKey) ? " tf-checkout-input--invalid" : ""}`,
|
|
7954
|
+
defaultCountry: phoneCountry,
|
|
7955
|
+
disableDialCodeAndPrefix: true,
|
|
7956
|
+
showDisabledDialCodeAndPrefix: true,
|
|
7957
|
+
disableDialCodePrefill: true,
|
|
7958
|
+
value: holder.phone,
|
|
7959
|
+
required: true,
|
|
7960
|
+
inputProps: {
|
|
7961
|
+
autoComplete: "tel",
|
|
7962
|
+
"aria-label": phoneKey,
|
|
7963
|
+
"aria-invalid": Boolean(fieldError(phoneKey))
|
|
7964
|
+
},
|
|
7965
|
+
onChange: (phone) => patchHolder(index, { phone })
|
|
7966
|
+
}
|
|
7967
|
+
)
|
|
7968
|
+
)), renderCustomFields(holder, index));
|
|
7969
|
+
}));
|
|
7970
|
+
};
|
|
7676
7971
|
|
|
7677
7972
|
// src/sections/BillingInfo.tsx
|
|
7678
7973
|
var BillingInfo = ({
|
|
7679
7974
|
eventId,
|
|
7680
7975
|
onContinue,
|
|
7681
|
-
heading
|
|
7682
|
-
buttonLabel
|
|
7976
|
+
heading,
|
|
7977
|
+
buttonLabel,
|
|
7683
7978
|
onLogin,
|
|
7684
7979
|
skipWhenProfileComplete = false,
|
|
7685
7980
|
requireEmailConfirmation = false,
|
|
7686
7981
|
collectTicketHolders = false,
|
|
7687
7982
|
collectHolderContact = false,
|
|
7688
|
-
ttfOptInLabel
|
|
7983
|
+
ttfOptInLabel,
|
|
7689
7984
|
brandOptInLabel,
|
|
7690
7985
|
privacyPolicy,
|
|
7691
7986
|
showPrivacyError = false,
|
|
7692
7987
|
step,
|
|
7693
7988
|
className
|
|
7694
7989
|
}) => {
|
|
7695
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _A, _B, _C, _D;
|
|
7990
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _A, _B, _C, _D, _E;
|
|
7991
|
+
const t = useT();
|
|
7696
7992
|
const checkout = useCheckoutContext();
|
|
7697
7993
|
const validation = useCheckoutValidation();
|
|
7994
|
+
const headingText = heading != null ? heading : t("billing.heading");
|
|
7995
|
+
const buttonText = buttonLabel != null ? buttonLabel : t("billing.continueToPayment");
|
|
7996
|
+
const ttfOptInText = ttfOptInLabel != null ? ttfOptInLabel : t("billing.ttfOptIn");
|
|
7698
7997
|
const profile = hooks_exports.useProfile({ retry: false });
|
|
7699
7998
|
const event = hooks_exports.useEvent(eventId);
|
|
7700
7999
|
const combined = !onContinue;
|
|
@@ -7835,11 +8134,11 @@ var BillingInfo = ({
|
|
|
7835
8134
|
(0, import_react31.useEffect)(() => {
|
|
7836
8135
|
const email = billing.email.trim();
|
|
7837
8136
|
if (checkout.isLoggedIn || !isEmail(email)) return;
|
|
7838
|
-
const
|
|
8137
|
+
const t2 = setTimeout(
|
|
7839
8138
|
() => checkout.checkBuyerEmail(email).catch(() => void 0),
|
|
7840
8139
|
600
|
|
7841
8140
|
);
|
|
7842
|
-
return () => clearTimeout(
|
|
8141
|
+
return () => clearTimeout(t2);
|
|
7843
8142
|
}, [billing.email, checkout.isLoggedIn]);
|
|
7844
8143
|
const emailTaken = !checkout.isLoggedIn && checkout.existingAccountEmail === billing.email.trim();
|
|
7845
8144
|
const needsNationality = checkout.buyerFields.some((f) => f.kind === "nationality");
|
|
@@ -7963,7 +8262,7 @@ var BillingInfo = ({
|
|
|
7963
8262
|
const complete = missingDetails.length === 0;
|
|
7964
8263
|
const showValidation = validation.attempt > 0;
|
|
7965
8264
|
const missingSet = new Set(missingDetails);
|
|
7966
|
-
const fieldError = (key, message = "
|
|
8265
|
+
const fieldError = (key, message = t("billing.fieldRequired")) => showValidation && missingSet.has(key) ? message : void 0;
|
|
7967
8266
|
const dobError = showValidation ? missingDetails.find(
|
|
7968
8267
|
(detail) => detail === "Date of birth" || detail.startsWith("Age ")
|
|
7969
8268
|
) : void 0;
|
|
@@ -7971,7 +8270,7 @@ var BillingInfo = ({
|
|
|
7971
8270
|
const commit = () => {
|
|
7972
8271
|
checkout.setBilling(committedBilling);
|
|
7973
8272
|
checkout.setHolders(committedHolders);
|
|
7974
|
-
if (
|
|
8273
|
+
if (ttfOptInText || brandOptInLabel) checkout.setConsent(consent);
|
|
7975
8274
|
};
|
|
7976
8275
|
(0, import_react31.useEffect)(() => {
|
|
7977
8276
|
if (combined) commit();
|
|
@@ -7993,7 +8292,7 @@ var BillingInfo = ({
|
|
|
7993
8292
|
const hasEventSpecificDetails = checkout.buyerFields.length > 0 || checkout.customFields.some((group) => group.fields.length > 0) || showHolders || gates.showDob;
|
|
7994
8293
|
const skipBilling = skipWhenProfileComplete && checkout.isLoggedIn && profile.isSuccess && complete && !hasEventSpecificDetails;
|
|
7995
8294
|
if (skipBilling) return null;
|
|
7996
|
-
return /* @__PURE__ */ import_react31.default.createElement(import_react31.default.Fragment, null, /* @__PURE__ */ import_react31.default.createElement(Card, { className }, /* @__PURE__ */ import_react31.default.createElement(SectionHeader, { step, title:
|
|
8295
|
+
return /* @__PURE__ */ import_react31.default.createElement(import_react31.default.Fragment, null, /* @__PURE__ */ import_react31.default.createElement(Card, { className }, /* @__PURE__ */ import_react31.default.createElement(SectionHeader, { step, title: headingText }), onLogin && !checkout.isLoggedIn && /* @__PURE__ */ import_react31.default.createElement("div", { className: "tf-checkout-billing__login" }, /* @__PURE__ */ import_react31.default.createElement("span", null, "Login & skip ahead:"), /* @__PURE__ */ import_react31.default.createElement(
|
|
7997
8296
|
"button",
|
|
7998
8297
|
{
|
|
7999
8298
|
type: "button",
|
|
@@ -8010,7 +8309,7 @@ var BillingInfo = ({
|
|
|
8010
8309
|
/* @__PURE__ */ import_react31.default.createElement(
|
|
8011
8310
|
Input,
|
|
8012
8311
|
{
|
|
8013
|
-
placeholder: "
|
|
8312
|
+
placeholder: t("billing.firstNamePlaceholder"),
|
|
8014
8313
|
value: billing.firstName,
|
|
8015
8314
|
required: true,
|
|
8016
8315
|
invalid: Boolean(fieldError("First name")),
|
|
@@ -8027,7 +8326,7 @@ var BillingInfo = ({
|
|
|
8027
8326
|
/* @__PURE__ */ import_react31.default.createElement(
|
|
8028
8327
|
Input,
|
|
8029
8328
|
{
|
|
8030
|
-
placeholder: "
|
|
8329
|
+
placeholder: t("billing.lastNamePlaceholder"),
|
|
8031
8330
|
value: billing.lastName,
|
|
8032
8331
|
required: true,
|
|
8033
8332
|
invalid: Boolean(fieldError("Last name")),
|
|
@@ -8046,7 +8345,7 @@ var BillingInfo = ({
|
|
|
8046
8345
|
{
|
|
8047
8346
|
type: "email",
|
|
8048
8347
|
autoComplete: "email",
|
|
8049
|
-
placeholder: "
|
|
8348
|
+
placeholder: t("billing.emailPlaceholder"),
|
|
8050
8349
|
value: billing.email,
|
|
8051
8350
|
required: true,
|
|
8052
8351
|
invalid: Boolean(fieldError("Valid email address")),
|
|
@@ -8059,7 +8358,7 @@ var BillingInfo = ({
|
|
|
8059
8358
|
{
|
|
8060
8359
|
error: fieldError(
|
|
8061
8360
|
"Matching email confirmation",
|
|
8062
|
-
"
|
|
8361
|
+
t("billing.emailMustMatch")
|
|
8063
8362
|
),
|
|
8064
8363
|
invalid: Boolean(fieldError("Matching email confirmation"))
|
|
8065
8364
|
},
|
|
@@ -8068,7 +8367,7 @@ var BillingInfo = ({
|
|
|
8068
8367
|
{
|
|
8069
8368
|
type: "email",
|
|
8070
8369
|
autoComplete: "email",
|
|
8071
|
-
placeholder: "
|
|
8370
|
+
placeholder: t("billing.confirmEmailPlaceholder"),
|
|
8072
8371
|
value: (_C = billing.confirmEmail) != null ? _C : "",
|
|
8073
8372
|
required: true,
|
|
8074
8373
|
invalid: Boolean(fieldError("Matching email confirmation")),
|
|
@@ -8076,15 +8375,15 @@ var BillingInfo = ({
|
|
|
8076
8375
|
onChange: setB("confirmEmail")
|
|
8077
8376
|
}
|
|
8078
8377
|
)
|
|
8079
|
-
)), !showValidation && requireEmailConfirmation && billing.confirmEmail && billing.confirmEmail.trim().toLowerCase() !== billing.email.trim().toLowerCase() && /* @__PURE__ */ import_react31.default.createElement("p", { className: "tf-checkout-error-text" }, "
|
|
8378
|
+
)), !showValidation && requireEmailConfirmation && billing.confirmEmail && billing.confirmEmail.trim().toLowerCase() !== billing.email.trim().toLowerCase() && /* @__PURE__ */ import_react31.default.createElement("p", { className: "tf-checkout-error-text" }, t("billing.emailMismatch")), emailTaken && /* @__PURE__ */ import_react31.default.createElement("p", { className: "tf-checkout-note tf-checkout-billing__email-taken" }, t("billing.emailRegistered"), " ", onLogin ? /* @__PURE__ */ import_react31.default.createElement(
|
|
8080
8379
|
"button",
|
|
8081
8380
|
{
|
|
8082
8381
|
type: "button",
|
|
8083
8382
|
className: "tf-checkout-billing__login-link",
|
|
8084
8383
|
onClick: () => onLogin(billing.email)
|
|
8085
8384
|
},
|
|
8086
|
-
"
|
|
8087
|
-
) : "
|
|
8385
|
+
t("billing.loginAutofill")
|
|
8386
|
+
) : t("billing.loginAutofillPlain")), checkout.buyerFields.map((f) => {
|
|
8088
8387
|
var _a2;
|
|
8089
8388
|
return /* @__PURE__ */ import_react31.default.createElement(
|
|
8090
8389
|
BuyerField,
|
|
@@ -8095,15 +8394,15 @@ var BillingInfo = ({
|
|
|
8095
8394
|
onChange: (v) => setBilling((b) => ({ ...b, [f.key]: v })),
|
|
8096
8395
|
countries,
|
|
8097
8396
|
error: fieldError(
|
|
8098
|
-
f.kind === "nationality" ? "
|
|
8397
|
+
f.kind === "nationality" ? t("billing.nationality") : f.kind === "gender" ? t("billing.gender") : t("billing.instagramHandle")
|
|
8099
8398
|
)
|
|
8100
8399
|
}
|
|
8101
8400
|
);
|
|
8102
8401
|
}), gates.showPhone && /* @__PURE__ */ import_react31.default.createElement(
|
|
8103
8402
|
Field,
|
|
8104
8403
|
{
|
|
8105
|
-
label:
|
|
8106
|
-
error: fieldError("Valid phone number", "
|
|
8404
|
+
label: gates.phoneRequired ? t("billing.phone") : t("billing.phoneOptional"),
|
|
8405
|
+
error: fieldError("Valid phone number", t("billing.phoneInvalid")),
|
|
8107
8406
|
invalid: Boolean(fieldError("Valid phone number"))
|
|
8108
8407
|
},
|
|
8109
8408
|
/* @__PURE__ */ import_react31.default.createElement(
|
|
@@ -8117,10 +8416,10 @@ var BillingInfo = ({
|
|
|
8117
8416
|
disableDialCodePrefill: true,
|
|
8118
8417
|
value: (_D = billing.phone) != null ? _D : "",
|
|
8119
8418
|
required: gates.phoneRequired,
|
|
8120
|
-
placeholder: "
|
|
8419
|
+
placeholder: t("billing.phonePlaceholder"),
|
|
8121
8420
|
inputProps: {
|
|
8122
8421
|
autoComplete: "tel",
|
|
8123
|
-
"aria-label": "
|
|
8422
|
+
"aria-label": t("billing.phoneAria"),
|
|
8124
8423
|
"aria-invalid": Boolean(fieldError("Valid phone number"))
|
|
8125
8424
|
},
|
|
8126
8425
|
onChange: (phone) => setBilling((current2) => ({ ...current2, phone }))
|
|
@@ -8129,8 +8428,8 @@ var BillingInfo = ({
|
|
|
8129
8428
|
), gates.showDob && /* @__PURE__ */ import_react31.default.createElement(
|
|
8130
8429
|
Field,
|
|
8131
8430
|
{
|
|
8132
|
-
label:
|
|
8133
|
-
error: dobError === "Date of birth" ? "
|
|
8431
|
+
label: gates.minimumAge ? t("billing.dobWithAge", { age: gates.minimumAge }) : t("billing.dob"),
|
|
8432
|
+
error: dobError === "Date of birth" ? t("billing.dobRequired") : dobError ? t("billing.ageMinimum", { age: (_E = gates.minimumAge) != null ? _E : "" }) : void 0,
|
|
8134
8433
|
invalid: Boolean(dobError)
|
|
8135
8434
|
},
|
|
8136
8435
|
/* @__PURE__ */ import_react31.default.createElement(
|
|
@@ -8181,17 +8480,17 @@ var BillingInfo = ({
|
|
|
8181
8480
|
"aria-invalid": (showPrivacyError || showValidation) && !consent.ttfOptIn,
|
|
8182
8481
|
onChange: (e) => setConsent((c) => ({ ...c, ttfOptIn: e.target.checked })),
|
|
8183
8482
|
className: "tf-checkout-checkbox--consent",
|
|
8184
|
-
label: /* @__PURE__ */ import_react31.default.createElement(import_react31.default.Fragment, null, "
|
|
8483
|
+
label: /* @__PURE__ */ import_react31.default.createElement(import_react31.default.Fragment, null, t("billing.privacyAgree", { brand: privacyPolicy.brandName }), " ", /* @__PURE__ */ import_react31.default.createElement("a", { href: privacyPolicy.url, target: "_blank", rel: "noreferrer" }, privacyPolicy.linkLabel || t("billing.privacyLink")), " *")
|
|
8185
8484
|
}
|
|
8186
8485
|
),
|
|
8187
|
-
(showPrivacyError || showValidation) && !consent.ttfOptIn && /* @__PURE__ */ import_react31.default.createElement("div", { className: "tf-checkout-consent__error" }, "
|
|
8188
|
-
) :
|
|
8486
|
+
(showPrivacyError || showValidation) && !consent.ttfOptIn && /* @__PURE__ */ import_react31.default.createElement("div", { className: "tf-checkout-consent__error" }, t("common.required"))
|
|
8487
|
+
) : ttfOptInText ? /* @__PURE__ */ import_react31.default.createElement(
|
|
8189
8488
|
Checkbox,
|
|
8190
8489
|
{
|
|
8191
8490
|
checked: consent.ttfOptIn,
|
|
8192
8491
|
onChange: (e) => setConsent((c) => ({ ...c, ttfOptIn: e.target.checked })),
|
|
8193
8492
|
className: "tf-checkout-checkbox--consent",
|
|
8194
|
-
label:
|
|
8493
|
+
label: ttfOptInText
|
|
8195
8494
|
}
|
|
8196
8495
|
) : null, !combined && /* @__PURE__ */ import_react31.default.createElement(import_react31.default.Fragment, null, /* @__PURE__ */ import_react31.default.createElement(
|
|
8197
8496
|
Button,
|
|
@@ -8206,7 +8505,7 @@ var BillingInfo = ({
|
|
|
8206
8505
|
onContinue == null ? void 0 : onContinue();
|
|
8207
8506
|
}
|
|
8208
8507
|
},
|
|
8209
|
-
|
|
8508
|
+
buttonText
|
|
8210
8509
|
))), showHolders && /* @__PURE__ */ import_react31.default.createElement(
|
|
8211
8510
|
TicketHoldersCard,
|
|
8212
8511
|
{
|
|
@@ -8241,12 +8540,13 @@ var import_react33 = __toESM(require("react"));
|
|
|
8241
8540
|
var import_react32 = __toESM(require("react"));
|
|
8242
8541
|
var OrderSummary = ({ eventId, className }) => {
|
|
8243
8542
|
var _a, _b, _c;
|
|
8543
|
+
const t = useT();
|
|
8244
8544
|
const checkout = useCheckoutContext();
|
|
8245
8545
|
const event = hooks_exports.useEvent(eventId);
|
|
8246
8546
|
const breakdown = checkout.breakdown;
|
|
8247
8547
|
const detailed = checkout.priceBreakdown;
|
|
8248
8548
|
if (!breakdown || breakdown.tickets.length === 0) return null;
|
|
8249
|
-
return /* @__PURE__ */ import_react32.default.createElement(Card, { className: ["tf-checkout-order-summary", className].filter(Boolean).join(" ") }, ((_a = event.data) == null ? void 0 : _a.name) && /* @__PURE__ */ import_react32.default.createElement("div", { className: "tf-checkout-order-summary__group" }, /* @__PURE__ */ import_react32.default.createElement("div", { className: "tf-checkout-order-summary__label" }, "
|
|
8549
|
+
return /* @__PURE__ */ import_react32.default.createElement(Card, { className: ["tf-checkout-order-summary", className].filter(Boolean).join(" ") }, ((_a = event.data) == null ? void 0 : _a.name) && /* @__PURE__ */ import_react32.default.createElement("div", { className: "tf-checkout-order-summary__group" }, /* @__PURE__ */ import_react32.default.createElement("div", { className: "tf-checkout-order-summary__label" }, t("common.event")), /* @__PURE__ */ import_react32.default.createElement("div", { className: "tf-checkout-order-summary__event" }, event.data.name)), /* @__PURE__ */ import_react32.default.createElement("div", { className: "tf-checkout-order-summary__group" }, /* @__PURE__ */ import_react32.default.createElement("div", { className: "tf-checkout-order-summary__label" }, t("tickets.yourTickets")), breakdown.tickets.map((ticket, index) => {
|
|
8250
8550
|
var _a2;
|
|
8251
8551
|
const detail = detailed == null ? void 0 : detailed.tickets[index];
|
|
8252
8552
|
return /* @__PURE__ */ import_react32.default.createElement(
|
|
@@ -8255,7 +8555,7 @@ var OrderSummary = ({ eventId, className }) => {
|
|
|
8255
8555
|
key: `${ticket.ticketTypeId}-${index}`,
|
|
8256
8556
|
className: "tf-checkout-order-summary__item"
|
|
8257
8557
|
},
|
|
8258
|
-
/* @__PURE__ */ import_react32.default.createElement("div", { className: "tf-checkout-order-summary__ticket" }, ticket.quantity, " x ", ticket.name, " - ", (_a2 = detail == null ? void 0 : detail.unit_price) != null ? _a2 : ticket.unit, " ", "each"),
|
|
8558
|
+
/* @__PURE__ */ import_react32.default.createElement("div", { className: "tf-checkout-order-summary__ticket" }, ticket.quantity, " x ", ticket.name, " - ", (_a2 = detail == null ? void 0 : detail.unit_price) != null ? _a2 : ticket.unit, " ", t("common.each")),
|
|
8259
8559
|
(detail == null ? void 0 : detail.line_total) && detail.line_total !== detail.unit_price && /* @__PURE__ */ import_react32.default.createElement("div", { className: "tf-checkout-order-summary__fees" }, "(", detail.line_total, " with fees)")
|
|
8260
8560
|
);
|
|
8261
8561
|
})), ((_b = detailed == null ? void 0 : detailed.add_ons.length) != null ? _b : 0) > 0 && /* @__PURE__ */ import_react32.default.createElement("div", { className: "tf-checkout-order-summary__group" }, /* @__PURE__ */ import_react32.default.createElement("div", { className: "tf-checkout-order-summary__label" }, (detailed == null ? void 0 : detailed.add_ons_title) || "Add-ons"), detailed == null ? void 0 : detailed.add_ons.map((addOn, index) => /* @__PURE__ */ import_react32.default.createElement(
|
|
@@ -8264,8 +8564,8 @@ var OrderSummary = ({ eventId, className }) => {
|
|
|
8264
8564
|
key: `${addOn.name}-${index}`,
|
|
8265
8565
|
className: "tf-checkout-order-summary__item"
|
|
8266
8566
|
},
|
|
8267
|
-
/* @__PURE__ */ import_react32.default.createElement("div", { className: "tf-checkout-order-summary__ticket" }, addOn.quantity, " x ", addOn.name, addOn.show_price ? ` - ${addOn.unit_price} each` : "")
|
|
8268
|
-
))), /* @__PURE__ */ import_react32.default.createElement("div", { className: "tf-checkout-order-summary__total" }, /* @__PURE__ */ import_react32.default.createElement("div", { className: "tf-checkout-order-summary__label" }, "
|
|
8567
|
+
/* @__PURE__ */ import_react32.default.createElement("div", { className: "tf-checkout-order-summary__ticket" }, addOn.quantity, " x ", addOn.name, addOn.show_price ? ` - ${addOn.unit_price} ${t("common.each")}` : "")
|
|
8568
|
+
))), /* @__PURE__ */ import_react32.default.createElement("div", { className: "tf-checkout-order-summary__total" }, /* @__PURE__ */ import_react32.default.createElement("div", { className: "tf-checkout-order-summary__label" }, t("common.total")), /* @__PURE__ */ import_react32.default.createElement("div", { className: "tf-checkout-order-summary__amount" }, (_c = detailed == null ? void 0 : detailed.total) != null ? _c : `${breakdown.currencySymbol || `${breakdown.currencyCode} `}${Number(
|
|
8269
8569
|
breakdown.total
|
|
8270
8570
|
).toFixed(2)}`)));
|
|
8271
8571
|
};
|
|
@@ -8308,6 +8608,7 @@ var Payment = ({
|
|
|
8308
8608
|
className
|
|
8309
8609
|
}) => {
|
|
8310
8610
|
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m;
|
|
8611
|
+
const t = useT();
|
|
8311
8612
|
const checkout = useCheckoutContext();
|
|
8312
8613
|
const validation = useCheckoutValidation();
|
|
8313
8614
|
const [error, setError] = (0, import_react33.useState)("");
|
|
@@ -8337,7 +8638,11 @@ var Payment = ({
|
|
|
8337
8638
|
const out = [];
|
|
8338
8639
|
if (isXendit) {
|
|
8339
8640
|
if (methods.xenditCard)
|
|
8340
|
-
out.push({
|
|
8641
|
+
out.push({
|
|
8642
|
+
id: { kind: "xenditCard" },
|
|
8643
|
+
value: "xenditCard",
|
|
8644
|
+
label: t("payment.card")
|
|
8645
|
+
});
|
|
8341
8646
|
for (const w of methods.xenditEWallets)
|
|
8342
8647
|
out.push({
|
|
8343
8648
|
id: { kind: "xenditEWallet", walletKey: w.key },
|
|
@@ -8349,23 +8654,23 @@ var Payment = ({
|
|
|
8349
8654
|
} else if (checkout.gateway === "razorpay") {
|
|
8350
8655
|
out.push({ id: { kind: "razorpay" }, value: "razorpay", label: "Razorpay" });
|
|
8351
8656
|
} else {
|
|
8352
|
-
out.push({ id: { kind: "card" }, value: "card", label: "
|
|
8353
|
-
for (const
|
|
8354
|
-
if (
|
|
8657
|
+
out.push({ id: { kind: "card" }, value: "card", label: t("payment.card") });
|
|
8658
|
+
for (const t2 of (_b2 = checkout.redirectPaymentMethods) != null ? _b2 : []) {
|
|
8659
|
+
if (t2 === "paypal" && methods.paypal) continue;
|
|
8355
8660
|
out.push({
|
|
8356
|
-
id: { kind: "redirect", methodType:
|
|
8357
|
-
value: `rd:${
|
|
8358
|
-
label: redirectLabel(
|
|
8661
|
+
id: { kind: "redirect", methodType: t2 },
|
|
8662
|
+
value: `rd:${t2}`,
|
|
8663
|
+
label: redirectLabel(t2)
|
|
8359
8664
|
});
|
|
8360
8665
|
}
|
|
8361
8666
|
if ((_c2 = checkout.paymentPlan) == null ? void 0 : _c2.available)
|
|
8362
8667
|
out.push({
|
|
8363
8668
|
id: { kind: "paymentPlan" },
|
|
8364
8669
|
value: "paymentPlan",
|
|
8365
|
-
label: "
|
|
8670
|
+
label: t("payment.paymentPlan")
|
|
8366
8671
|
});
|
|
8367
8672
|
if (offersOxxo)
|
|
8368
|
-
out.push({ id: { kind: "oxxo" }, value: "oxxo", label: "
|
|
8673
|
+
out.push({ id: { kind: "oxxo" }, value: "oxxo", label: t("payment.oxxo") });
|
|
8369
8674
|
}
|
|
8370
8675
|
if (methods.paypal)
|
|
8371
8676
|
out.push({ id: { kind: "paypal" }, value: "paypal", label: "PayPal" });
|
|
@@ -8422,7 +8727,7 @@ var Payment = ({
|
|
|
8422
8727
|
const extra = selectedOption == null ? void 0 : selectedOption.extra;
|
|
8423
8728
|
const extrasOk = !extra || (extra === "cashtag" ? Boolean((_i = (_h = extras[selected]) == null ? void 0 : _h.cashtag) == null ? void 0 : _i.trim()) : Boolean((_k = (_j = extras[selected]) == null ? void 0 : _j.phoneNumber) == null ? void 0 : _k.trim()));
|
|
8424
8729
|
const privacyOk = !requirePrivacyPolicy || checkout.consent.ttfOptIn;
|
|
8425
|
-
const payLabel = isFree ? "
|
|
8730
|
+
const payLabel = isFree ? t("payment.completeRegistration") : isPlanSelected ? planConfirmLabel((_l = checkout.paymentPlan) == null ? void 0 : _l.configuration) : t("payment.submitPayment");
|
|
8426
8731
|
const planTerms = paymentPlanTerms((_m = checkout.paymentPlan) == null ? void 0 : _m.configuration);
|
|
8427
8732
|
const finalizing = checkout.status === "placing" || checkout.status === "succeeded";
|
|
8428
8733
|
const pay = () => {
|
|
@@ -8503,15 +8808,15 @@ var Payment = ({
|
|
|
8503
8808
|
}
|
|
8504
8809
|
}
|
|
8505
8810
|
) : /* @__PURE__ */ import_react33.default.createElement(CardInput, null)
|
|
8506
|
-
), isXendit && cardAreaError && /* @__PURE__ */ import_react33.default.createElement("p", { className: "tf-checkout-error-text" }, cardAreaError), showTestCardHint && /* @__PURE__ */ import_react33.default.createElement("p", { className: "tf-checkout-note" }, isXendit ? "
|
|
8811
|
+
), isXendit && cardAreaError && /* @__PURE__ */ import_react33.default.createElement("p", { className: "tf-checkout-error-text" }, cardAreaError), showTestCardHint && /* @__PURE__ */ import_react33.default.createElement("p", { className: "tf-checkout-note" }, isXendit ? t("payment.testCardXendit") : t("payment.testCard"))), isPlanSelected && planTerms.length > 0 && /* @__PURE__ */ import_react33.default.createElement("div", { className: "tf-checkout-payment__plan" }, /* @__PURE__ */ import_react33.default.createElement("strong", null, planTermsTitle(checkout.paymentPlan.configuration)), planTerms.map((part) => /* @__PURE__ */ import_react33.default.createElement("p", { key: part.id, className: "tf-checkout-note" }, part.text))), isPlanSelected && savedLast4 && /* @__PURE__ */ import_react33.default.createElement("div", { className: "tf-checkout-payment__plan-savedcard" }, /* @__PURE__ */ import_react33.default.createElement("p", { className: "tf-checkout-note" }, "Your payment will proceed with the card ending in", " ", /* @__PURE__ */ import_react33.default.createElement("strong", null, "**** ", savedLast4)), /* @__PURE__ */ import_react33.default.createElement(
|
|
8507
8812
|
Checkbox,
|
|
8508
8813
|
{
|
|
8509
8814
|
checked: useSavedCard,
|
|
8510
8815
|
onChange: (e) => setUseSavedCard(e.target.checked),
|
|
8511
|
-
label: "
|
|
8816
|
+
label: t("payment.useThisCard")
|
|
8512
8817
|
}
|
|
8513
8818
|
)));
|
|
8514
|
-
return /* @__PURE__ */ import_react33.default.createElement("div", { className: ["tf-checkout-payment-stack", className].filter(Boolean).join(" ") }, /* @__PURE__ */ import_react33.default.createElement(Card, null, /* @__PURE__ */ import_react33.default.createElement(SectionHeader, { title: "
|
|
8819
|
+
return /* @__PURE__ */ import_react33.default.createElement("div", { className: ["tf-checkout-payment-stack", className].filter(Boolean).join(" ") }, /* @__PURE__ */ import_react33.default.createElement(Card, null, /* @__PURE__ */ import_react33.default.createElement(SectionHeader, { title: t("payment.title") }), !isFree && /* @__PURE__ */ import_react33.default.createElement(import_react33.default.Fragment, null, !singleCard && /* @__PURE__ */ import_react33.default.createElement("div", { className: "tf-checkout-payment__label" }, t("payment.method")), !methods ? /* @__PURE__ */ import_react33.default.createElement("div", { className: "tf-checkout-payment__cardbox" }, /* @__PURE__ */ import_react33.default.createElement(Loader, null)) : singleCard ? paymentInput : /* @__PURE__ */ import_react33.default.createElement(
|
|
8515
8820
|
PaymentMethods,
|
|
8516
8821
|
{
|
|
8517
8822
|
options,
|
|
@@ -8543,7 +8848,7 @@ var Payment = ({
|
|
|
8543
8848
|
label: /* @__PURE__ */ import_react33.default.createElement(import_react33.default.Fragment, null, /* @__PURE__ */ import_react33.default.createElement("span", { dangerouslySetInnerHTML: { __html: c.content || c.name } }), c.isRequired && " *")
|
|
8544
8849
|
}
|
|
8545
8850
|
),
|
|
8546
|
-
invalid && /* @__PURE__ */ import_react33.default.createElement("div", { className: "tf-checkout-consent__error" }, "
|
|
8851
|
+
invalid && /* @__PURE__ */ import_react33.default.createElement("div", { className: "tf-checkout-consent__error" }, t("payment.conditionRequired"))
|
|
8547
8852
|
);
|
|
8548
8853
|
})), /* @__PURE__ */ import_react33.default.createElement(OrderSummary, { eventId }), /* @__PURE__ */ import_react33.default.createElement("div", { className: "tf-checkout-payment__cta" }, /* @__PURE__ */ import_react33.default.createElement(
|
|
8549
8854
|
Button,
|
|
@@ -8552,21 +8857,22 @@ var Payment = ({
|
|
|
8552
8857
|
loading: finalizing,
|
|
8553
8858
|
disabled: checkout.isBusy || finalizing || !isFree && !methods
|
|
8554
8859
|
},
|
|
8555
|
-
finalizing ? "
|
|
8860
|
+
finalizing ? t("payment.placing") : payLabel
|
|
8556
8861
|
)), bottomError && /* @__PURE__ */ import_react33.default.createElement("p", { className: "tf-checkout-error-text" }, bottomError));
|
|
8557
8862
|
};
|
|
8558
8863
|
|
|
8559
8864
|
// src/sections/IDVerification.tsx
|
|
8560
8865
|
var import_react34 = __toESM(require("react"));
|
|
8561
8866
|
var MESSAGE = {
|
|
8562
|
-
idle: "
|
|
8563
|
-
starting: "
|
|
8564
|
-
polling: "
|
|
8565
|
-
verified: "
|
|
8566
|
-
timeout: "
|
|
8567
|
-
error: "
|
|
8867
|
+
idle: "verification.idle",
|
|
8868
|
+
starting: "verification.starting",
|
|
8869
|
+
polling: "verification.polling",
|
|
8870
|
+
verified: "verification.verified",
|
|
8871
|
+
timeout: "verification.timeoutCheckAgain",
|
|
8872
|
+
error: "verification.error"
|
|
8568
8873
|
};
|
|
8569
8874
|
var IDVerification = ({ className }) => {
|
|
8875
|
+
const t = useT();
|
|
8570
8876
|
const checkout = useCheckoutContext();
|
|
8571
8877
|
const order = checkout.order;
|
|
8572
8878
|
const [phase, setPhase] = (0, import_react34.useState)("idle");
|
|
@@ -8587,7 +8893,7 @@ var IDVerification = ({ className }) => {
|
|
|
8587
8893
|
setError(errorMessage(e));
|
|
8588
8894
|
});
|
|
8589
8895
|
};
|
|
8590
|
-
return /* @__PURE__ */ import_react34.default.createElement(Card, { className: cx("tf-checkout-idverify", className) }, /* @__PURE__ */ import_react34.default.createElement(SectionHeader, { title: "
|
|
8896
|
+
return /* @__PURE__ */ import_react34.default.createElement(Card, { className: cx("tf-checkout-idverify", className) }, /* @__PURE__ */ import_react34.default.createElement(SectionHeader, { title: t("verification.title") }), /* @__PURE__ */ import_react34.default.createElement("p", { className: cx("tf-checkout-note", done && "tf-checkout-idverify__done") }, t(MESSAGE[phase])), !done && /* @__PURE__ */ import_react34.default.createElement(Button, { block: true, onClick: run, loading: running, disabled: running }, phase === "idle" ? t("verification.verify") : running ? t("verification.verifying") : t("verification.checkAgain")), error && /* @__PURE__ */ import_react34.default.createElement("p", { className: "tf-checkout-error-text" }, error));
|
|
8591
8897
|
};
|
|
8592
8898
|
|
|
8593
8899
|
// src/sections/Confirmation.tsx
|
|
@@ -8599,6 +8905,7 @@ var Confirmation = ({
|
|
|
8599
8905
|
children,
|
|
8600
8906
|
className
|
|
8601
8907
|
}) => {
|
|
8908
|
+
const t = useT();
|
|
8602
8909
|
const checkout = useCheckoutContext();
|
|
8603
8910
|
const order = checkout.order;
|
|
8604
8911
|
const [copied, setCopied] = (0, import_react35.useState)(false);
|
|
@@ -8632,7 +8939,7 @@ var Confirmation = ({
|
|
|
8632
8939
|
() => void 0
|
|
8633
8940
|
);
|
|
8634
8941
|
};
|
|
8635
|
-
return /* @__PURE__ */ import_react35.default.createElement(Card, { className: cx("tf-checkout-confirmation", className) }, /* @__PURE__ */ import_react35.default.createElement("span", { className: "tf-checkout-confirmation__check" }, pending ? "\u23F3" : "\u2713"), /* @__PURE__ */ import_react35.default.createElement("strong", { className: "tf-checkout-confirmation__title" }, pending ? "
|
|
8942
|
+
return /* @__PURE__ */ import_react35.default.createElement(Card, { className: cx("tf-checkout-confirmation", className) }, /* @__PURE__ */ import_react35.default.createElement("span", { className: "tf-checkout-confirmation__check" }, pending ? "\u23F3" : "\u2713"), /* @__PURE__ */ import_react35.default.createElement("strong", { className: "tf-checkout-confirmation__title" }, pending ? t("confirmation.pending") : t("confirmation.confirmed")), /* @__PURE__ */ import_react35.default.createElement("p", { className: "tf-checkout-note" }, pending ? t("confirmation.pendingBody") : order.alreadyPaid ? t("confirmation.alreadyPaid") : t("confirmation.available")), order.orderHash && /* @__PURE__ */ import_react35.default.createElement("p", { className: "tf-checkout-confirmation__ref" }, "Reference: ", order.orderHash), pending && order.pendingVoucherUrl && /* @__PURE__ */ import_react35.default.createElement(
|
|
8636
8943
|
"a",
|
|
8637
8944
|
{
|
|
8638
8945
|
className: "tf-checkout-button tf-checkout-button--secondary tf-checkout-button--block",
|
|
@@ -8640,15 +8947,15 @@ var Confirmation = ({
|
|
|
8640
8947
|
target: "_blank",
|
|
8641
8948
|
rel: "noopener noreferrer"
|
|
8642
8949
|
},
|
|
8643
|
-
"
|
|
8950
|
+
t("confirmation.viewVoucher")
|
|
8644
8951
|
), viewOrderUrl && /* @__PURE__ */ import_react35.default.createElement(
|
|
8645
8952
|
"a",
|
|
8646
8953
|
{
|
|
8647
8954
|
className: "tf-checkout-button tf-checkout-button--secondary tf-checkout-button--block",
|
|
8648
8955
|
href: viewOrderUrl
|
|
8649
8956
|
},
|
|
8650
|
-
"
|
|
8651
|
-
), children, !pending && url && /* @__PURE__ */ import_react35.default.createElement("div", { className: "tf-checkout-confirmation__share" }, /* @__PURE__ */ import_react35.default.createElement("strong", null, "
|
|
8957
|
+
t("confirmation.viewTickets")
|
|
8958
|
+
), children, !pending && url && /* @__PURE__ */ import_react35.default.createElement("div", { className: "tf-checkout-confirmation__share" }, /* @__PURE__ */ import_react35.default.createElement("strong", null, t("referral.cheaperOrFree")), /* @__PURE__ */ import_react35.default.createElement("p", { className: "tf-checkout-note" }, "Invite friends with your link. When they buy, you get rewarded."), /* @__PURE__ */ import_react35.default.createElement("div", { className: "tf-checkout-confirmation__share-link" }, /* @__PURE__ */ import_react35.default.createElement("input", { className: "tf-checkout-input", readOnly: true, value: url }), /* @__PURE__ */ import_react35.default.createElement(Button, { variant: "secondary", onClick: copy }, copied ? t("referral.copied") : t("referral.copyLink"))), /* @__PURE__ */ import_react35.default.createElement("div", { className: "tf-checkout-confirmation__socials" }, shares.map((s) => /* @__PURE__ */ import_react35.default.createElement(
|
|
8652
8959
|
"a",
|
|
8653
8960
|
{
|
|
8654
8961
|
key: s.label,
|
|
@@ -8670,9 +8977,10 @@ var attributesOf = (response) => {
|
|
|
8670
8977
|
if (data && typeof data === "object") return data;
|
|
8671
8978
|
return response;
|
|
8672
8979
|
};
|
|
8980
|
+
var MISSING_REFERENCE = "\0missing-reference";
|
|
8673
8981
|
var OrderConfirmation = ({
|
|
8674
8982
|
orderHash,
|
|
8675
|
-
title
|
|
8983
|
+
title,
|
|
8676
8984
|
message,
|
|
8677
8985
|
helper,
|
|
8678
8986
|
eventTitle,
|
|
@@ -8686,6 +8994,7 @@ var OrderConfirmation = ({
|
|
|
8686
8994
|
className
|
|
8687
8995
|
}) => {
|
|
8688
8996
|
var _a, _b, _c, _d;
|
|
8997
|
+
const t = useT();
|
|
8689
8998
|
const [data, setData] = (0, import_react36.useState)(null);
|
|
8690
8999
|
const [failure, setFailure] = (0, import_react36.useState)("");
|
|
8691
9000
|
const [copied, setCopied] = (0, import_react36.useState)(false);
|
|
@@ -8697,7 +9006,7 @@ var OrderConfirmation = ({
|
|
|
8697
9006
|
}, [onError, onLoaded]);
|
|
8698
9007
|
(0, import_react36.useEffect)(() => {
|
|
8699
9008
|
if (!orderHash) {
|
|
8700
|
-
setFailure(
|
|
9009
|
+
setFailure(MISSING_REFERENCE);
|
|
8701
9010
|
return;
|
|
8702
9011
|
}
|
|
8703
9012
|
let active = true;
|
|
@@ -8722,7 +9031,7 @@ var OrderConfirmation = ({
|
|
|
8722
9031
|
};
|
|
8723
9032
|
}, [orderHash]);
|
|
8724
9033
|
if (failure) {
|
|
8725
|
-
return /* @__PURE__ */ import_react36.default.createElement("div", { className: cx("confirmation-page tf-checkout-confirmation-page", className) }, /* @__PURE__ */ import_react36.default.createElement("div", { className: "tf-checkout-auth__alert", role: "alert" }, failure));
|
|
9034
|
+
return /* @__PURE__ */ import_react36.default.createElement("div", { className: cx("confirmation-page tf-checkout-confirmation-page", className) }, /* @__PURE__ */ import_react36.default.createElement("div", { className: "tf-checkout-auth__alert", role: "alert" }, failure === MISSING_REFERENCE ? t("confirmation.missingReference") : failure));
|
|
8726
9035
|
}
|
|
8727
9036
|
if (!data) {
|
|
8728
9037
|
return /* @__PURE__ */ import_react36.default.createElement("div", { className: "tf-checkout-confirmation-page__loading" }, /* @__PURE__ */ import_react36.default.createElement(Loader, { className: "tf-checkout-loader--page" }));
|
|
@@ -8738,14 +9047,14 @@ var OrderConfirmation = ({
|
|
|
8738
9047
|
const pricing = [
|
|
8739
9048
|
...Number.isFinite(currentPrice) ? [
|
|
8740
9049
|
{
|
|
8741
|
-
label: "
|
|
9050
|
+
label: t("referral.currentPrice"),
|
|
8742
9051
|
price: `${symbol}${currentPrice.toFixed(2)}`
|
|
8743
9052
|
}
|
|
8744
9053
|
] : [],
|
|
8745
9054
|
...sales.map((sale) => ({
|
|
8746
|
-
label:
|
|
8747
|
-
subLabel: Number(sale.price) === 0 ? "
|
|
8748
|
-
price: Number(sale.price) === 0 ? "
|
|
9055
|
+
label: t("referral.ifFriendsBuy", { count: sale.sales }),
|
|
9056
|
+
subLabel: Number(sale.price) === 0 ? t("referral.becomes") : t("referral.goesDownTo"),
|
|
9057
|
+
price: Number(sale.price) === 0 ? t("referral.titleFree") : `${symbol}${Number(sale.price).toFixed(2)}`
|
|
8749
9058
|
}))
|
|
8750
9059
|
];
|
|
8751
9060
|
const copy = () => {
|
|
@@ -8755,20 +9064,20 @@ var OrderConfirmation = ({
|
|
|
8755
9064
|
window.setTimeout(() => setCopied(false), 1500);
|
|
8756
9065
|
});
|
|
8757
9066
|
};
|
|
8758
|
-
return /* @__PURE__ */ import_react36.default.createElement("div", { className: cx("confirmation-page tf-checkout-confirmation-page", className) }, /* @__PURE__ */ import_react36.default.createElement("div", { className: "header-container" }, /* @__PURE__ */ import_react36.default.createElement("div", { className: "header-product-text" }, /* @__PURE__ */ import_react36.default.createElement("p", { className: "title" }, title), (eventTitle || eventDate || eventLocation) && /* @__PURE__ */ import_react36.default.createElement("div", { className: "event-details" }, eventTitle && /* @__PURE__ */ import_react36.default.createElement("div", { className: "event-title" }, eventTitle), eventDate && /* @__PURE__ */ import_react36.default.createElement("div", { className: "event-date" }, eventDate), eventLocation && /* @__PURE__ */ import_react36.default.createElement("div", { className: "event-location" }, eventLocation)), /* @__PURE__ */ import_react36.default.createElement("div", { className: "share-message-section" }, customReplacement ? /* @__PURE__ */ import_react36.default.createElement("div", { dangerouslySetInnerHTML: { __html: customText } }) : /* @__PURE__ */ import_react36.default.createElement(import_react36.default.Fragment, null, /* @__PURE__ */ import_react36.default.createElement("span", { className: "main" }, attachTickets ? "
|
|
9067
|
+
return /* @__PURE__ */ import_react36.default.createElement("div", { className: cx("confirmation-page tf-checkout-confirmation-page", className) }, /* @__PURE__ */ import_react36.default.createElement("div", { className: "header-container" }, /* @__PURE__ */ import_react36.default.createElement("div", { className: "header-product-text" }, /* @__PURE__ */ import_react36.default.createElement("p", { className: "title" }, title != null ? title : t("confirmation.orderConfirmed")), (eventTitle || eventDate || eventLocation) && /* @__PURE__ */ import_react36.default.createElement("div", { className: "event-details" }, eventTitle && /* @__PURE__ */ import_react36.default.createElement("div", { className: "event-title" }, eventTitle), eventDate && /* @__PURE__ */ import_react36.default.createElement("div", { className: "event-date" }, eventDate), eventLocation && /* @__PURE__ */ import_react36.default.createElement("div", { className: "event-location" }, eventLocation)), /* @__PURE__ */ import_react36.default.createElement("div", { className: "share-message-section" }, customReplacement ? /* @__PURE__ */ import_react36.default.createElement("div", { dangerouslySetInnerHTML: { __html: customText } }) : /* @__PURE__ */ import_react36.default.createElement(import_react36.default.Fragment, null, /* @__PURE__ */ import_react36.default.createElement("span", { className: "main" }, attachTickets ? t("confirmation.emailed") : message != null ? message : t("confirmation.inMyTickets")), /* @__PURE__ */ import_react36.default.createElement("span", { className: "helper" }, attachTickets ? t("confirmation.bringThem") : helper))))), customText && !customReplacement && /* @__PURE__ */ import_react36.default.createElement(
|
|
8759
9068
|
"div",
|
|
8760
9069
|
{
|
|
8761
9070
|
className: "custom-confirmation-page-text tf-checkout-confirmation-page__custom",
|
|
8762
9071
|
dangerouslySetInnerHTML: { __html: customText }
|
|
8763
9072
|
}
|
|
8764
|
-
), orderUrl && /* @__PURE__ */ import_react36.default.createElement("div", { className: "order-details-button-container" }, /* @__PURE__ */ import_react36.default.createElement("a", { className: "view-order-button", href: orderUrl }, "
|
|
9073
|
+
), orderUrl && /* @__PURE__ */ import_react36.default.createElement("div", { className: "order-details-button-container" }, /* @__PURE__ */ import_react36.default.createElement("a", { className: "view-order-button", href: orderUrl }, t("confirmation.viewOrder"))), showReferral && data.disable_referral === false && shareUrl && /* @__PURE__ */ import_react36.default.createElement(import_react36.default.Fragment, null, /* @__PURE__ */ import_react36.default.createElement("div", { className: "referral_text_image_section" }, /* @__PURE__ */ import_react36.default.createElement("div", { className: "referral_text_section" }, /* @__PURE__ */ import_react36.default.createElement("div", { className: "referral_title_text" }, t("referral.titleStart"), /* @__PURE__ */ import_react36.default.createElement("span", { className: "strong-text" }, " ", t("referral.titleCheaper"), " "), t("referral.titleOr"), /* @__PURE__ */ import_react36.default.createElement("span", { className: "strong-text" }, " ", t("referral.titleFree"))), /* @__PURE__ */ import_react36.default.createElement("div", { className: "referral_text" }, /* @__PURE__ */ import_react36.default.createElement("span", { className: "strong-text" }, t("referral.inviteFriends"), " "), t("referral.inviteMiddle"), /* @__PURE__ */ import_react36.default.createElement("span", { className: "strong-text" }, " 100% "), t("referral.inviteEnd")))), /* @__PURE__ */ import_react36.default.createElement("div", { className: "share_wrapper" }, /* @__PURE__ */ import_react36.default.createElement("div", { className: "share_section" }, /* @__PURE__ */ import_react36.default.createElement("div", { className: "invitation_section" }, /* @__PURE__ */ import_react36.default.createElement("div", { className: "invitation_title" }, t("referral.howToInvite")), /* @__PURE__ */ import_react36.default.createElement("div", { className: "share_buttons" }, /* @__PURE__ */ import_react36.default.createElement("div", { className: "share-by-link" }, /* @__PURE__ */ import_react36.default.createElement("h5", { className: "share-by-link label" }, t("referral.sendThisLink")), /* @__PURE__ */ import_react36.default.createElement("div", { className: "share-btn-inner" }, /* @__PURE__ */ import_react36.default.createElement("input", { className: "share-input", readOnly: true, value: shareUrl }), /* @__PURE__ */ import_react36.default.createElement(
|
|
8765
9074
|
"button",
|
|
8766
9075
|
{
|
|
8767
9076
|
className: "share-by-link-copy-icon",
|
|
8768
9077
|
type: "button",
|
|
8769
9078
|
onClick: copy
|
|
8770
9079
|
},
|
|
8771
|
-
/* @__PURE__ */ import_react36.default.createElement("span", { className: "copy-icon" }, copied ? "
|
|
9080
|
+
/* @__PURE__ */ import_react36.default.createElement("span", { className: "copy-icon" }, copied ? t("referral.copied") : t("referral.copy"))
|
|
8772
9081
|
))), showShareButtons && /* @__PURE__ */ import_react36.default.createElement("div", { className: "social-media-btns" }, /* @__PURE__ */ import_react36.default.createElement(
|
|
8773
9082
|
"a",
|
|
8774
9083
|
{
|
|
@@ -8789,31 +9098,33 @@ var OrderConfirmation = ({
|
|
|
8789
9098
|
rel: "noopener noreferrer"
|
|
8790
9099
|
},
|
|
8791
9100
|
"WhatsApp"
|
|
8792
|
-
))))), pricing.length > 0 && /* @__PURE__ */ import_react36.default.createElement("div", { className: "pricing-section" }, /* @__PURE__ */ import_react36.default.createElement("div", { className: "invitation_title" }, "
|
|
9101
|
+
))))), pricing.length > 0 && /* @__PURE__ */ import_react36.default.createElement("div", { className: "pricing-section" }, /* @__PURE__ */ import_react36.default.createElement("div", { className: "invitation_title" }, t("referral.howMuchCheaper")), pricing.map((item, index) => /* @__PURE__ */ import_react36.default.createElement("div", { className: "pricing-section_wrapper", key: `${item.label}-${index}` }, /* @__PURE__ */ import_react36.default.createElement("div", { className: "pricing-section_label" }, item.label, item.subLabel && /* @__PURE__ */ import_react36.default.createElement("div", { className: "pricing-section_sublabel" }, item.subLabel)), /* @__PURE__ */ import_react36.default.createElement("div", { className: "pricing-section_price" }, item.price)))))));
|
|
8793
9102
|
};
|
|
8794
9103
|
|
|
8795
9104
|
// src/sections/OrderIDVerification.tsx
|
|
8796
9105
|
var import_react37 = __toESM(require("react"));
|
|
8797
9106
|
var PHASE_MESSAGE = {
|
|
8798
|
-
checking: "
|
|
8799
|
-
idle: "
|
|
8800
|
-
starting: "
|
|
8801
|
-
polling: "
|
|
8802
|
-
verified: "
|
|
8803
|
-
timeout: "
|
|
8804
|
-
error: "
|
|
8805
|
-
};
|
|
9107
|
+
checking: "verification.checking",
|
|
9108
|
+
idle: "verification.idle",
|
|
9109
|
+
starting: "verification.starting",
|
|
9110
|
+
polling: "verification.polling",
|
|
9111
|
+
verified: "verification.verified",
|
|
9112
|
+
timeout: "verification.timeoutSafe",
|
|
9113
|
+
error: "verification.error"
|
|
9114
|
+
};
|
|
9115
|
+
var MISSING_REFERENCE2 = "\0missing-reference";
|
|
8806
9116
|
var OrderIDVerification = ({
|
|
8807
9117
|
orderHash,
|
|
8808
9118
|
onVerified,
|
|
8809
9119
|
className
|
|
8810
9120
|
}) => {
|
|
9121
|
+
const t = useT();
|
|
8811
9122
|
const [phase, setPhase] = (0, import_react37.useState)("checking");
|
|
8812
9123
|
const [failure, setFailure] = (0, import_react37.useState)("");
|
|
8813
9124
|
(0, import_react37.useEffect)(() => {
|
|
8814
9125
|
if (!orderHash) {
|
|
8815
9126
|
setPhase("error");
|
|
8816
|
-
setFailure(
|
|
9127
|
+
setFailure(MISSING_REFERENCE2);
|
|
8817
9128
|
return;
|
|
8818
9129
|
}
|
|
8819
9130
|
let active = true;
|
|
@@ -8866,7 +9177,7 @@ var OrderIDVerification = ({
|
|
|
8866
9177
|
}
|
|
8867
9178
|
);
|
|
8868
9179
|
};
|
|
8869
|
-
return /* @__PURE__ */ import_react37.default.createElement(Card, { className: cx("tf-checkout-idverify", className) }, /* @__PURE__ */ import_react37.default.createElement(SectionHeader, { title: "
|
|
9180
|
+
return /* @__PURE__ */ import_react37.default.createElement(Card, { className: cx("tf-checkout-idverify", className) }, /* @__PURE__ */ import_react37.default.createElement(SectionHeader, { title: t("verification.title") }), /* @__PURE__ */ import_react37.default.createElement(
|
|
8870
9181
|
"p",
|
|
8871
9182
|
{
|
|
8872
9183
|
className: cx(
|
|
@@ -8874,8 +9185,8 @@ var OrderIDVerification = ({
|
|
|
8874
9185
|
phase === "verified" && "tf-checkout-idverify__done"
|
|
8875
9186
|
)
|
|
8876
9187
|
},
|
|
8877
|
-
failure || PHASE_MESSAGE[phase]
|
|
8878
|
-
), phase !== "verified" && orderHash && /* @__PURE__ */ import_react37.default.createElement(Button, { block: true, onClick: run, loading: running, disabled: running || !orderHash }, phase === "idle" ? "
|
|
9188
|
+
failure === MISSING_REFERENCE2 ? t("confirmation.missingReference") : failure || t(PHASE_MESSAGE[phase])
|
|
9189
|
+
), phase !== "verified" && orderHash && /* @__PURE__ */ import_react37.default.createElement(Button, { block: true, onClick: run, loading: running, disabled: running || !orderHash }, phase === "idle" ? t("verification.verify") : running ? t("verification.verifying") : t("verification.tryAgain")));
|
|
8879
9190
|
};
|
|
8880
9191
|
|
|
8881
9192
|
// src/EmbeddedCheckout.tsx
|
|
@@ -8903,6 +9214,7 @@ var Flow = ({
|
|
|
8903
9214
|
showTestCardHint
|
|
8904
9215
|
}) => {
|
|
8905
9216
|
var _a;
|
|
9217
|
+
const t = useT();
|
|
8906
9218
|
const checkout = useCheckoutContext();
|
|
8907
9219
|
const [view, setView] = (0, import_react38.useState)(initialView);
|
|
8908
9220
|
const [selectionView, setSelectionView] = (0, import_react38.useState)(initialView);
|
|
@@ -9029,7 +9341,7 @@ var Flow = ({
|
|
|
9029
9341
|
key: authRequest.key,
|
|
9030
9342
|
open: true,
|
|
9031
9343
|
initialEmail: authRequest.email,
|
|
9032
|
-
message: authRequest.email ? "
|
|
9344
|
+
message: authRequest.email ? t("auth.existingAccount") : void 0,
|
|
9033
9345
|
allowRegistration: auth == null ? void 0 : auth.allowRegistration,
|
|
9034
9346
|
allowPasswordReset: auth == null ? void 0 : auth.allowPasswordReset,
|
|
9035
9347
|
requireRegistrationAddress: auth == null ? void 0 : auth.requireRegistrationAddress,
|
|
@@ -9064,32 +9376,41 @@ var EmbeddedCheckout = ({
|
|
|
9064
9376
|
locale,
|
|
9065
9377
|
messages,
|
|
9066
9378
|
className
|
|
9067
|
-
}) => /* @__PURE__ */ import_react38.default.createElement(
|
|
9068
|
-
|
|
9379
|
+
}) => /* @__PURE__ */ import_react38.default.createElement(
|
|
9380
|
+
CheckoutProvider,
|
|
9069
9381
|
{
|
|
9070
|
-
|
|
9071
|
-
|
|
9072
|
-
|
|
9073
|
-
|
|
9074
|
-
|
|
9075
|
-
|
|
9076
|
-
|
|
9077
|
-
|
|
9078
|
-
|
|
9079
|
-
|
|
9080
|
-
|
|
9081
|
-
|
|
9082
|
-
|
|
9083
|
-
|
|
9084
|
-
|
|
9085
|
-
|
|
9086
|
-
|
|
9087
|
-
|
|
9088
|
-
|
|
9089
|
-
|
|
9090
|
-
|
|
9091
|
-
|
|
9092
|
-
|
|
9382
|
+
theme,
|
|
9383
|
+
locale,
|
|
9384
|
+
messages,
|
|
9385
|
+
className
|
|
9386
|
+
},
|
|
9387
|
+
/* @__PURE__ */ import_react38.default.createElement(
|
|
9388
|
+
Flow,
|
|
9389
|
+
{
|
|
9390
|
+
key: eventId,
|
|
9391
|
+
eventId,
|
|
9392
|
+
onComplete,
|
|
9393
|
+
confirmationMode,
|
|
9394
|
+
initialView,
|
|
9395
|
+
onViewChange,
|
|
9396
|
+
autoScroll,
|
|
9397
|
+
requireEmailConfirmation,
|
|
9398
|
+
collectTicketHolders,
|
|
9399
|
+
collectHolderContact,
|
|
9400
|
+
onLogin,
|
|
9401
|
+
auth,
|
|
9402
|
+
skipBillingWhenProfileComplete,
|
|
9403
|
+
ttfOptInLabel,
|
|
9404
|
+
brandOptInLabel,
|
|
9405
|
+
privacyPolicy,
|
|
9406
|
+
additionalConditions,
|
|
9407
|
+
initialPromoCode,
|
|
9408
|
+
referrer,
|
|
9409
|
+
readAttributionFromUrl,
|
|
9410
|
+
showTestCardHint
|
|
9411
|
+
}
|
|
9412
|
+
)
|
|
9413
|
+
);
|
|
9093
9414
|
|
|
9094
9415
|
// src/ResumedCheckout.tsx
|
|
9095
9416
|
var import_react39 = __toESM(require("react"));
|