@ticketboothapp/booking 0.1.22 → 1.2.24
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/package.json +2 -29
- package/src/index.ts +0 -79
- package/tsconfig.json +2 -8
- package/src/assets/icons/minus.svg +0 -7
- package/src/assets/icons/partner-logos/getyourguide.svg +0 -8
- package/src/assets/icons/plus.svg +0 -3
- package/src/colours.css +0 -23
- package/src/components/BookingDetails.module.css +0 -1591
- package/src/components/BookingDetails.tsx +0 -2264
- package/src/components/BookingWidget.tsx +0 -302
- package/src/components/ManageBookingView.tsx +0 -437
- package/src/components/PhoneInputWithCountry.module.css +0 -131
- package/src/components/PhoneInputWithCountry.tsx +0 -44
- package/src/components/PickupLocationDialog.module.css +0 -360
- package/src/components/PickupLocationDialog.tsx +0 -357
- package/src/components/PostBookingDependentAddOnUpsell.module.css +0 -174
- package/src/components/PostBookingDependentAddOnUpsell.tsx +0 -407
- package/src/components/booking/AddOnsSection.module.css +0 -10
- package/src/components/booking/AddOnsSection.tsx +0 -184
- package/src/components/booking/AdminPaymentChoiceModal.tsx +0 -98
- package/src/components/booking/BookingDialog.module.css +0 -643
- package/src/components/booking/BookingDialog.tsx +0 -356
- package/src/components/booking/BookingFlow.tsx +0 -4385
- package/src/components/booking/BookingFlowCollage.module.css +0 -148
- package/src/components/booking/BookingFlowCollage.tsx +0 -184
- package/src/components/booking/BookingFlowPlaceholder.module.css +0 -27
- package/src/components/booking/BookingFlowPlaceholder.tsx +0 -25
- package/src/components/booking/BookingFlowPreview.tsx +0 -51
- package/src/components/booking/BookingProductGrid.module.css +0 -359
- package/src/components/booking/BookingProductGrid.tsx +0 -497
- package/src/components/booking/Calendar.module.css +0 -616
- package/src/components/booking/Calendar.tsx +0 -1123
- package/src/components/booking/CancellationPolicySelector.module.css +0 -124
- package/src/components/booking/CancellationPolicySelector.tsx +0 -142
- package/src/components/booking/ChangeBookingDialog.tsx +0 -562
- package/src/components/booking/CheckoutForm.module.css +0 -244
- package/src/components/booking/CheckoutForm.tsx +0 -364
- package/src/components/booking/CheckoutModal.tsx +0 -451
- package/src/components/booking/CurrencySwitcher.tsx +0 -81
- package/src/components/booking/DapFlowCollage.tsx +0 -88
- package/src/components/booking/DapTourDescription.tsx +0 -35
- package/src/components/booking/DependentAddOnBookingDialog.tsx +0 -1350
- package/src/components/booking/DependentAddOnPaymentForm.tsx +0 -124
- package/src/components/booking/ErrorBoundary.tsx +0 -63
- package/src/components/booking/InfoTooltip.tsx +0 -108
- package/src/components/booking/ItineraryBox.module.css +0 -258
- package/src/components/booking/ItineraryBox.tsx +0 -550
- package/src/components/booking/ItineraryBuilder.tsx +0 -82
- package/src/components/booking/ItineraryPlaceholder.module.css +0 -45
- package/src/components/booking/ItineraryPlaceholder.tsx +0 -26
- package/src/components/booking/MealDrinkAddOnSelector.tsx +0 -338
- package/src/components/booking/PickupLocationSelector.module.css +0 -124
- package/src/components/booking/PickupLocationSelector.tsx +0 -1566
- package/src/components/booking/PickupTimeSelector.module.css +0 -134
- package/src/components/booking/PickupTimeSelector.tsx +0 -112
- package/src/components/booking/PriceBreakdown.tsx +0 -154
- package/src/components/booking/PriceSummary.tsx +0 -234
- package/src/components/booking/PrivateShuttleBookingFlow.module.css +0 -357
- package/src/components/booking/PrivateShuttleBookingFlow.tsx +0 -2662
- package/src/components/booking/PromoCodeInput.module.css +0 -166
- package/src/components/booking/PromoCodeInput.tsx +0 -99
- package/src/components/booking/ReturnTimeSelector.module.css +0 -173
- package/src/components/booking/ReturnTimeSelector.tsx +0 -145
- package/src/components/booking/TermsAcceptance.tsx +0 -111
- package/src/components/booking/TicketSelector.module.css +0 -164
- package/src/components/booking/TicketSelector.tsx +0 -199
- package/src/components/booking/TourDescription.module.css +0 -304
- package/src/components/booking/TourDescription.tsx +0 -273
- package/src/components/booking/booking-flow-ui.ts +0 -38
- package/src/components/booking/booking-flow.css +0 -944
- package/src/components/button.css +0 -245
- package/src/components/button.tsx +0 -152
- package/src/components/colorable-svg.tsx +0 -29
- package/src/components/image.css +0 -29
- package/src/components/image.tsx +0 -113
- package/src/components/partner/PartnerBookingPage.module.css +0 -130
- package/src/components/partner/PartnerBookingPage.tsx +0 -390
- package/src/components/partner/PartnerBookingPageWithBrowserMetadata.tsx +0 -45
- package/src/components/product-tag.module.css +0 -30
- package/src/components/product-tag.tsx +0 -34
- package/src/components/product-theme-pages/image-modal.tsx +0 -248
- package/src/components/product-theme-pages/photo-gallery.module.css +0 -200
- package/src/components/terms/TermsContent.tsx +0 -178
- package/src/components/value-pill.module.css +0 -59
- package/src/components/value-pill.tsx +0 -46
- package/src/constants/images.ts +0 -556
- package/src/constants/pill-values.ts +0 -210
- package/src/constants/products.ts +0 -155
- package/src/contexts/AvailabilitiesCacheContext.tsx +0 -125
- package/src/contexts/BookingAppContext.tsx +0 -134
- package/src/contexts/CompanyContext.tsx +0 -70
- package/src/data/dap-descriptions/session-couples-families-friends.en.json +0 -61
- package/src/data/dap-descriptions/session-elopements.en.json +0 -60
- package/src/data/dap-descriptions/session-proposals.en.json +0 -60
- package/src/data/product-descriptions/afternoon-delight.en.json +0 -35
- package/src/data/product-descriptions/emerald-lake-escape.en.json +0 -68
- package/src/data/product-descriptions/lake-louise-adventure.en.json +0 -74
- package/src/data/product-descriptions/moraine-lake-adventure.en.json +0 -78
- package/src/data/product-descriptions/moraine-lake-sunrise-lake-louise-golden-hour.en.json +0 -65
- package/src/data/product-descriptions/moraine-lake-sunrise.en.json +0 -64
- package/src/data/product-descriptions/private-tour.en.json +0 -80
- package/src/data/product-descriptions/two-lakes-combo.en.json +0 -65
- package/src/data/products-config.json +0 -101
- package/src/hooks/useBookingSourceMetadataFromLocation.ts +0 -21
- package/src/hooks/useIsBookingLaunchLive.ts +0 -49
- package/src/lib/analytics.ts +0 -197
- package/src/lib/booking/booking-source.ts +0 -51
- package/src/lib/booking/checkout-breakdown.ts +0 -69
- package/src/lib/booking/correlation-id.ts +0 -46
- package/src/lib/booking/i18n/config.ts +0 -21
- package/src/lib/booking/i18n/index.tsx +0 -144
- package/src/lib/booking/i18n/messages/en.json +0 -236
- package/src/lib/booking/i18n/messages/fr.json +0 -236
- package/src/lib/booking/itinerary-display.ts +0 -36
- package/src/lib/booking/itinerary-labels.ts +0 -70
- package/src/lib/booking/location-calculations.ts +0 -43
- package/src/lib/booking/location-utils.ts +0 -165
- package/src/lib/booking/map-utils.ts +0 -153
- package/src/lib/booking/marker-icons.ts +0 -113
- package/src/lib/booking/normalize-booking-product-id.ts +0 -21
- package/src/lib/booking/pickup-location-types.ts +0 -25
- package/src/lib/booking/places-api.ts +0 -154
- package/src/lib/booking/pricing.ts +0 -466
- package/src/lib/booking/product-option-id.ts +0 -35
- package/src/lib/booking/source-metadata.ts +0 -226
- package/src/lib/booking/sunday-week.ts +0 -14
- package/src/lib/booking/theme.ts +0 -83
- package/src/lib/booking/trace-context.ts +0 -62
- package/src/lib/booking/utils.ts +0 -9
- package/src/lib/booking-api.ts +0 -1793
- package/src/lib/booking-constants.ts +0 -23
- package/src/lib/booking-ref.ts +0 -13
- package/src/lib/booking-types.ts +0 -36
- package/src/lib/currency.ts +0 -81
- package/src/lib/dap-descriptions.ts +0 -50
- package/src/lib/dap-itinerary-preview.ts +0 -315
- package/src/lib/dependent-add-on-api.ts +0 -434
- package/src/lib/env.ts +0 -96
- package/src/lib/firebase.ts +0 -20
- package/src/lib/job-application-api.ts +0 -83
- package/src/lib/manage-booking-embed-print.ts +0 -16
- package/src/lib/manage-booking-post-checkout.ts +0 -68
- package/src/lib/photo-dap-config.ts +0 -228
- package/src/lib/photo-packages.ts +0 -75
- package/src/lib/pickup/map-utils.ts +0 -56
- package/src/lib/pickup/marker-icons.ts +0 -19
- package/src/lib/product-descriptions.ts +0 -66
- package/src/lib/products-config.ts +0 -73
- package/src/providers/booking-dialog-provider.tsx +0 -282
- package/src/providers/dependent-add-on-dialog-provider.tsx +0 -105
- package/src/radius.css +0 -5
- package/src/spacing.css +0 -7
- package/src/strings/en.json +0 -1774
- package/src/strings/es.json +0 -1573
- package/src/strings/fr.json +0 -1573
- package/src/strings/index.js +0 -23
- package/src/text-style.css +0 -97
- package/src/utils/currency-converter.ts +0 -101
|
@@ -1,236 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"common": {
|
|
3
|
-
"back": "Retour",
|
|
4
|
-
"continue": "Continuer",
|
|
5
|
-
"select": "Sélectionner",
|
|
6
|
-
"change": "Changer",
|
|
7
|
-
"cancel": "Annuler",
|
|
8
|
-
"close": "Fermer",
|
|
9
|
-
"videoPause": "Mettre en pause",
|
|
10
|
-
"videoPlay": "Lire la vidéo",
|
|
11
|
-
"videoMute": "Couper le son",
|
|
12
|
-
"videoUnmute": "Activer le son",
|
|
13
|
-
"loading": "Chargement...",
|
|
14
|
-
"error": "Erreur",
|
|
15
|
-
"total": "Total",
|
|
16
|
-
"email": "Courriel",
|
|
17
|
-
"emailPlaceholder": "votre@courriel.com",
|
|
18
|
-
"emailForConfirmation": "Courriel (pour confirmation)"
|
|
19
|
-
},
|
|
20
|
-
"booking": {
|
|
21
|
-
"selectDate": "Sélectionner la date",
|
|
22
|
-
"selectPickupTime": "Sélectionner l'heure de prise en charge",
|
|
23
|
-
"requestDifferentTime": "Demander une autre heure",
|
|
24
|
-
"preferredPickupTime": "Heure de prise en charge préférée",
|
|
25
|
-
"selectReturnTime": "Sélectionner l'heure de retour",
|
|
26
|
-
"selectPhotoSessionTime": "Choisir l'heure de la séance photo",
|
|
27
|
-
"dapPhotoSessionAddOn": "Séance photo (option)",
|
|
28
|
-
"dapYourCurrentItinerary": "Votre itinéraire actuel",
|
|
29
|
-
"dapRefItineraryLoading": "Recherche de votre réservation…",
|
|
30
|
-
"dapRefItineraryEmpty": "Nous n’avons pas encore d’horaires de navette pour cette référence. Votre réservation peut quand même être valide — choisissez une durée de séance (si besoin) et chargez les heures disponibles.",
|
|
31
|
-
"dapRefItineraryLookupFailed": "Nous n’avons pas trouvé de réservation avec cette référence, ou elle n’est pas admissible à cette option. Vérifiez le code dans votre courriel de confirmation.",
|
|
32
|
-
"dapItineraryFallbackFoot": "Après le paiement, vous verrez cette option avec l’itinéraire complet dans Gérer la réservation.",
|
|
33
|
-
"mostPopular": "Le plus populaire",
|
|
34
|
-
"pickupAtTourStart": "<b>Votre heure de prise en charge dépend de votre lieu de prise en charge.</b><br>Votre heure de prise en charge exacte sera confirmée une fois que vous aurez confirmé votre lieu de prise en charge. Les prises en charge commencent à Canmore et se terminent à Lake Louise.",
|
|
35
|
-
"pickupAtTourStartLocation": "lieu de départ du tour",
|
|
36
|
-
"pickupLocationUnknown": "Je ne sais pas",
|
|
37
|
-
"arrivalTimeMessage": "Vous arriverez à {destination} vers <b>{time}</b>.",
|
|
38
|
-
"yourItinerary": "Votre itinéraire",
|
|
39
|
-
"buildYourItinerary": "Construisez votre itinéraire",
|
|
40
|
-
"selectPickupTimeToSeeItinerary": "Sélectionnez une heure de prise en charge ci-dessous pour voir votre horaire.",
|
|
41
|
-
"selectTourOption": "Sélectionner l'option de tour",
|
|
42
|
-
"selectTourOptionToSeeItinerary": "Sélectionnez une option de tour ci-dessous pour voir votre itinéraire.",
|
|
43
|
-
"timesToBeDetermined": "heures à confirmer…",
|
|
44
|
-
"proposedStops": "Arrêts proposés",
|
|
45
|
-
"orderAndTimesToBeConfirmed": "(ordre et horaires à confirmer par notre équipe)",
|
|
46
|
-
"startingAtPerShuttle": "À partir de {price} par navette",
|
|
47
|
-
"hoursTour": "Tour de {hours} h",
|
|
48
|
-
"hoursTourStarting": "Tour commençant avec {hours} heures",
|
|
49
|
-
"startingAtForHours": "À partir de {price} par navette pour {hours}.",
|
|
50
|
-
"hoursUnit": "heures",
|
|
51
|
-
"additionalHoursAvailable": "Heures supplémentaires disponibles moyennant des frais.",
|
|
52
|
-
"pickupAt": "Prise en charge à",
|
|
53
|
-
"pickupAtPrefix": "Prise en charge à ",
|
|
54
|
-
"pickupAtLocation": "Prise en charge à {location}",
|
|
55
|
-
"arriveAt": "Arrivée à",
|
|
56
|
-
"arriveAtPlace": "Arrivée à {place}",
|
|
57
|
-
"departFrom": "Départ de",
|
|
58
|
-
"departFromPlace": "Départ de {place}",
|
|
59
|
-
"dropOffAt": "Retour à {location}",
|
|
60
|
-
"dropOffAtPrefix": "Retour à ",
|
|
61
|
-
"tripEnd": "Fin du voyage",
|
|
62
|
-
"stopAtPlaceTbd": "Arrêt à {place} (heure à confirmer)",
|
|
63
|
-
"placeTheDestination": "le lieu de destination",
|
|
64
|
-
"dropOffAtPickup": "Arrivée à {pickupLocation}",
|
|
65
|
-
"yourPickupLocation": "votre lieu de prise en charge",
|
|
66
|
-
"tickets": "Billets",
|
|
67
|
-
"overbookingWarnDeparture": "ALERTE SURRÉSERVATION : seulement {count} places pour le départ à {time}.",
|
|
68
|
-
"overbookingWarnReturn": "ALERTE SURRÉSERVATION : seulement {count} places pour le retour à {time}.",
|
|
69
|
-
"overbookingWarnBoth": "ALERTE SURRÉSERVATION : seulement {count} places sur les deux segments du trajet (aller et retour).",
|
|
70
|
-
"overbookingResourcesSuffix": "({count} ressources partagées.)",
|
|
71
|
-
"adminBookingLoadLine1": "Réservation {projected} /",
|
|
72
|
-
"adminBookingLoadLine2": "{total} au total",
|
|
73
|
-
"available": "disponible",
|
|
74
|
-
"soldOut": "Complet",
|
|
75
|
-
"continueToPayment": "Continuer vers le paiement",
|
|
76
|
-
"continueToSecurePayment": "Continuer vers le paiement sécurisé",
|
|
77
|
-
"preparingCheckout": "Préparation…",
|
|
78
|
-
"creatingReservation": "Création de la réservation...",
|
|
79
|
-
"securePayment": "Paiement sécurisé par Stripe",
|
|
80
|
-
"selectTimeAndTickets": "Veuillez sélectionner une heure et au moins un billet",
|
|
81
|
-
"selectPickupLocation": "Veuillez sélectionner un lieu de prise en charge",
|
|
82
|
-
"loadingTimes": "Chargement des heures disponibles...",
|
|
83
|
-
"noAvailability": "Aucune disponibilité trouvée pour les 30 prochains jours. Veuillez réessayer plus tard.",
|
|
84
|
-
"seeFullTourDescription": "Voir la description complète du circuit",
|
|
85
|
-
"seeFullAddOnDescription": "Voir tous les détails de l'expérience",
|
|
86
|
-
"communicationPreference": "Comment souhaitez-vous recevoir les communications futures (confirmation, rappels, etc.)?",
|
|
87
|
-
"communicationEmail": "Courriel",
|
|
88
|
-
"communicationEmailDesc": "Envoyer la confirmation par courriel",
|
|
89
|
-
"communicationWhatsApp": "WhatsApp",
|
|
90
|
-
"communicationWhatsAppDesc": "Envoyer la confirmation par WhatsApp",
|
|
91
|
-
"emailForConfirmation": "Courriel",
|
|
92
|
-
"phoneNumberForConfirmation": "Numéro de téléphone",
|
|
93
|
-
"phoneNumberPlaceholder": "(555) 123-4567",
|
|
94
|
-
"invalidEmail": "Veuillez entrer une adresse courriel valide",
|
|
95
|
-
"invalidPhoneNumber": "Veuillez entrer un numéro de téléphone valide",
|
|
96
|
-
"selectCommunicationPreference": "Veuillez sélectionner comment vous souhaitez recevoir votre confirmation",
|
|
97
|
-
"enterEmail": "Veuillez entrer votre adresse courriel",
|
|
98
|
-
"enterFirstName": "Veuillez entrer votre prénom",
|
|
99
|
-
"enterLastName": "Veuillez entrer votre nom de famille",
|
|
100
|
-
"enterPhoneNumber": "Veuillez entrer votre numéro de téléphone",
|
|
101
|
-
"firstName": "Prénom",
|
|
102
|
-
"firstNamePlaceholder": "Jeanne",
|
|
103
|
-
"lastName": "Nom de famille",
|
|
104
|
-
"lastNamePlaceholder": "Dupont",
|
|
105
|
-
"dapNoLastNameOnFile": "Nous n’avons pas trouvé de nom de famille pour cette réservation. Contactez-nous, ou utilisez Gérer la réservation avec le nom figurant sur votre courriel de confirmation.",
|
|
106
|
-
"dapCancellationPolicyHeading": "Politique d’annulation",
|
|
107
|
-
"dapCancellationPolicyBody": "Vous pouvez annuler cette option avec remboursement intégral jusqu’à {days} {daysUnit} avant votre séance photo prévue. Toute annulation après cette date peut entraîner la perte du montant total de l’option.",
|
|
108
|
-
"dapCancellationPolicyDayUnit": "jour",
|
|
109
|
-
"dapCancellationPolicyDaysUnit": "jours",
|
|
110
|
-
"noActiveOption": "Aucune option de produit disponible",
|
|
111
|
-
"people": "personnes",
|
|
112
|
-
"person": "personne",
|
|
113
|
-
"rounding": "Arrondi",
|
|
114
|
-
"deposit": "Acompte",
|
|
115
|
-
"totalOwedForBookingChange": "Montant dû pour le changement de réservation",
|
|
116
|
-
"subtotal": "Sous-total",
|
|
117
|
-
"tax": "Taxes et frais",
|
|
118
|
-
"returnOption": "Option de retour",
|
|
119
|
-
"fromPrice": "À partir de {price}",
|
|
120
|
-
"communicationPermission": "En fournissant vos coordonnées, vous autorisez la réception de confirmations de réservation, de rappels et de mises à jour par cette méthode.",
|
|
121
|
-
"communicationPermissionCheckbox": "J'autorise la réception de communications par cette méthode",
|
|
122
|
-
"communicationPermissionRequired": "Veuillez sélectionner au moins une méthode de communication",
|
|
123
|
-
"emailPermissionCheckbox": "Me contacter par courriel (nous ne vous enverrons que les communications pertinentes pour votre réservation)",
|
|
124
|
-
"whatsappPermissionCheckbox": "Me contacter par WhatsApp (nous ne vous enverrons que les communications pertinentes pour votre réservation)",
|
|
125
|
-
"reviewAndPay": "Réviser et payer",
|
|
126
|
-
"payNow": "Payer maintenant",
|
|
127
|
-
"paying": "Paiement en cours...",
|
|
128
|
-
"checkout": "Paiement",
|
|
129
|
-
"paymentNotConfigured": "Le paiement n'est pas configuré. Veuillez utiliser le paiement standard.",
|
|
130
|
-
"loadingPayment": "Chargement du formulaire de paiement...",
|
|
131
|
-
"promoCode": "Code promo",
|
|
132
|
-
"optionalPromoCode": "Promo / bon / carte cadeau",
|
|
133
|
-
"promoCodePlaceholder": "Entrez le code",
|
|
134
|
-
"applyPromo": "Appliquer",
|
|
135
|
-
"removePromo": "Retirer",
|
|
136
|
-
"promoApplied": "Appliqué : {{code}}",
|
|
137
|
-
"invalidPromoCode": "Code promo invalide ou expiré",
|
|
138
|
-
"promoCodesCannotStackWithDiscounts": "Les codes promo ne peuvent pas être cumulés avec les offres",
|
|
139
|
-
"discount": "Réduction",
|
|
140
|
-
"cancellationPolicy": "Politique d'annulation",
|
|
141
|
-
"promoIncludesCancellationPolicy": "Ce code promo inclut la politique d'annulation {label}",
|
|
142
|
-
"cancellationRefundTierDays": "Annuler <b>{days} jours avant</b> pour <b>{percent}% de remboursement</b>",
|
|
143
|
-
"cancellationRefundTierHours": "Annuler <b>{hours} heures avant</b> pour <b>{percent}% de remboursement</b>",
|
|
144
|
-
"cancellationNoRefunds": "<b>Pas d'annulation, pas de remboursement</b>. Vous pouvez modifier votre réservation jusqu'à <b>{days} jours avant</b>.",
|
|
145
|
-
"cancellationNoRefundsNoDays": "<b>Pas d'annulation, pas de remboursement</b>. Vous pouvez modifier votre réservation avant la date de votre réservation.",
|
|
146
|
-
"cancellationStandard": "Annulation standard",
|
|
147
|
-
"included": "Inclus",
|
|
148
|
-
"flexibleCancellation": "Annulation flexible",
|
|
149
|
-
"depositPaymentNotice": "Vous payez l'acompte aujourd'hui.",
|
|
150
|
-
"balanceChargeNotice": "Le solde restant sera facturé {days} jours avant votre réservation. Vous pouvez également le payer plus tôt depuis la page Gérer ma réservation.",
|
|
151
|
-
"balancePayEarlier": "Vous pouvez payer le solde restant à tout moment depuis la page Gérer ma réservation.",
|
|
152
|
-
"remainingBalance": "Solde restant"
|
|
153
|
-
},
|
|
154
|
-
"pickup": {
|
|
155
|
-
"title": "Savez-vous où vous souhaitez être pris en charge?",
|
|
156
|
-
"yesAddNow": "Oui, je peux l'ajouter maintenant",
|
|
157
|
-
"dontKnow": "Je ne sais pas encore",
|
|
158
|
-
"pickupLocation": "Lieu de prise en charge",
|
|
159
|
-
"enterAddress": "Entrez votre adresse de prise en charge",
|
|
160
|
-
"searchingLocation": "Recherche de l'emplacement...",
|
|
161
|
-
"locationNotFound": "Impossible de trouver cet emplacement. Veuillez essayer une autre adresse.",
|
|
162
|
-
"chooseNearby": "Choisissez un lieu de prise en charge à proximité",
|
|
163
|
-
"exactMatch": "Correspondance exacte trouvée",
|
|
164
|
-
"locationsInCity": "Points de ramassage à {{city}}",
|
|
165
|
-
"selectThisLocation": "Sélectionner ce lieu",
|
|
166
|
-
"yourLocation": "Votre emplacement",
|
|
167
|
-
"chooseClosest": "Choisissez un lieu de prise en charge ci-dessous pour voir l'option la plus proche.",
|
|
168
|
-
"useThisAddress": "Utiliser cette adresse",
|
|
169
|
-
"away": "de distance",
|
|
170
|
-
"walk": "à pied",
|
|
171
|
-
"drive": "en voiture",
|
|
172
|
-
"switchUnits": "Passer aux unités {unit}",
|
|
173
|
-
"metric": "métriques",
|
|
174
|
-
"imperial": "impériales",
|
|
175
|
-
"dontKnowSubtext": "Nous vous enverrons des rappels pour sélectionner votre lieu de prise en charge.",
|
|
176
|
-
"yesAddNowSubtext": "Vous pourrez modifier cela plus tard.",
|
|
177
|
-
"skipWarningTitle": "Avis important",
|
|
178
|
-
"skipWarningMessage": "Vous n'êtes pas garanti d'être pris en charge si vous ne <b>mettez pas à jour votre réservation avec votre lieu de prise en charge au moins 12 heures à l'avance</b>.",
|
|
179
|
-
"iUnderstand": "Je comprends",
|
|
180
|
-
"nevermindSelectLocation": "Annuler, je vais sélectionner mon lieu",
|
|
181
|
-
"outsideServiceArea": "Cette adresse est en dehors de notre zone de service. Nous proposons des prises en charge entre le lac Louise et Kananaskis. Veuillez choisir un lieu prédéfini ou rechercher une adresse dans cette zone."
|
|
182
|
-
},
|
|
183
|
-
"calendar": {
|
|
184
|
-
"previousWeeks": "2 semaines précédentes",
|
|
185
|
-
"nextWeeks": "2 semaines suivantes",
|
|
186
|
-
"soldOut": "Complet",
|
|
187
|
-
"left": "{count} restant",
|
|
188
|
-
"timesAvailable": "{count} départs",
|
|
189
|
-
"spotsAvailable": "{count} places",
|
|
190
|
-
"available": "Disponible",
|
|
191
|
-
"days": {
|
|
192
|
-
"sun": "DIM",
|
|
193
|
-
"mon": "LUN",
|
|
194
|
-
"tue": "MAR",
|
|
195
|
-
"wed": "MER",
|
|
196
|
-
"thu": "JEU",
|
|
197
|
-
"fri": "VEN",
|
|
198
|
-
"sat": "SAM"
|
|
199
|
-
},
|
|
200
|
-
"months": {
|
|
201
|
-
"january": "Janvier",
|
|
202
|
-
"february": "Février",
|
|
203
|
-
"march": "Mars",
|
|
204
|
-
"april": "Avril",
|
|
205
|
-
"may": "Mai",
|
|
206
|
-
"june": "Juin",
|
|
207
|
-
"july": "Juillet",
|
|
208
|
-
"august": "Août",
|
|
209
|
-
"september": "Septembre",
|
|
210
|
-
"october": "Octobre",
|
|
211
|
-
"november": "Novembre",
|
|
212
|
-
"december": "Décembre"
|
|
213
|
-
}
|
|
214
|
-
},
|
|
215
|
-
"products": {
|
|
216
|
-
"backToExperiences": "Retour aux expériences",
|
|
217
|
-
"from": "À partir de",
|
|
218
|
-
"noDescription": "Aucune description disponible",
|
|
219
|
-
"productGridFilters": {
|
|
220
|
-
"all": "Tous",
|
|
221
|
-
"moraineLake": "Lac Moraine",
|
|
222
|
-
"lakeLouise": "Lac Louise",
|
|
223
|
-
"emeraldLake": "Lac Émeraude",
|
|
224
|
-
"private": "Privé",
|
|
225
|
-
"sunrise": "Levé de soleil"
|
|
226
|
-
}
|
|
227
|
-
},
|
|
228
|
-
"terms": {
|
|
229
|
-
"title": "Conditions générales",
|
|
230
|
-
"viewTerms": "Conditions générales",
|
|
231
|
-
"acceptPrefix": "J'accepte les",
|
|
232
|
-
"acceptAndClose": "J'ai lu et j'accepte",
|
|
233
|
-
"content": "En finalisant cette réservation, vous acceptez les conditions générales suivantes.\n\n1. Réservation et paiement\nVotre réservation est confirmée une fois le paiement traité. Vous recevrez une confirmation par courriel ou par le mode de contact choisi.\n\n2. Annulation et modifications\nLes politiques d'annulation et de modification dépendent de l'option choisie au paiement. Veuillez consulter votre confirmation pour la politique applicable.\n\n3. Participation\nVous êtes responsable d'arriver à l'heure et au lieu indiqués. Un retard peut entraîner la perte de l'expérience sans remboursement.\n\n4. Responsabilité\nL'opérateur n'est pas responsable des pertes ou dommages au-delà de ce qu'exige la loi applicable. La participation est à vos risques lorsque les activités comportent des risques inhérents.\n\n5. Contact\nPour toute question ou modification de réservation, utilisez les coordonnées indiquées dans votre confirmation."
|
|
234
|
-
}
|
|
235
|
-
}
|
|
236
|
-
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Shared itinerary step labels for manage booking, change-booking dialog, etc.
|
|
3
|
-
* Keeps display consistent with BookingDetails.
|
|
4
|
-
*/
|
|
5
|
-
export type ItineraryStepForLabel = {
|
|
6
|
-
label?: string | null;
|
|
7
|
-
place?: string | null;
|
|
8
|
-
stepType?: string | null;
|
|
9
|
-
};
|
|
10
|
-
|
|
11
|
-
export function getItineraryStepLabel(step: ItineraryStepForLabel): string {
|
|
12
|
-
if (step.label?.trim()) return step.label.trim();
|
|
13
|
-
const place = step.place?.trim();
|
|
14
|
-
const placeDisplay =
|
|
15
|
-
place === 'your_pickup_location'
|
|
16
|
-
? 'your pickup location'
|
|
17
|
-
: place === 'the_destination'
|
|
18
|
-
? 'the destination'
|
|
19
|
-
: place ?? '';
|
|
20
|
-
switch (step.stepType) {
|
|
21
|
-
case 'pickup':
|
|
22
|
-
return placeDisplay ? `Pickup at ${placeDisplay}` : 'Pickup';
|
|
23
|
-
case 'drop_off':
|
|
24
|
-
return placeDisplay ? `Drop off at ${placeDisplay}` : 'Drop-off';
|
|
25
|
-
case 'arrive':
|
|
26
|
-
return placeDisplay ? `Arrive at ${placeDisplay}` : 'Arrive';
|
|
27
|
-
case 'depart':
|
|
28
|
-
return placeDisplay ? `Depart ${placeDisplay}` : 'Depart';
|
|
29
|
-
case 'trip_end':
|
|
30
|
-
return 'Trip ends';
|
|
31
|
-
case 'draft':
|
|
32
|
-
return placeDisplay || 'Stop';
|
|
33
|
-
default:
|
|
34
|
-
return placeDisplay || (step.stepType ?? 'Step');
|
|
35
|
-
}
|
|
36
|
-
}
|
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
import type { ItineraryDisplayStep } from '@/lib/booking-api';
|
|
2
|
-
|
|
3
|
-
export type TranslationFn = (key: string, params?: Record<string, string>) => string;
|
|
4
|
-
|
|
5
|
-
/** Step shape accepted for label building (stepType may be string when from JSON). */
|
|
6
|
-
type StepForLabel = Pick<ItineraryDisplayStep, 'time' | 'place'> & { stepType: string };
|
|
7
|
-
|
|
8
|
-
const EN_PLACE: Record<string, string> = {
|
|
9
|
-
your_pickup_location: 'your pickup location',
|
|
10
|
-
the_destination: 'the destination',
|
|
11
|
-
};
|
|
12
|
-
|
|
13
|
-
/**
|
|
14
|
-
* English-only label (for provider dashboard, email, or when t() is not available).
|
|
15
|
-
*/
|
|
16
|
-
export function getStepLabelEn(step: StepForLabel): string {
|
|
17
|
-
const place = step.place;
|
|
18
|
-
const placeDisplay = place ? (EN_PLACE[place] ?? place) : '';
|
|
19
|
-
|
|
20
|
-
switch (step.stepType) {
|
|
21
|
-
case 'pickup':
|
|
22
|
-
return `Pickup at ${placeDisplay}`;
|
|
23
|
-
case 'drop_off':
|
|
24
|
-
return `Drop off at ${placeDisplay}`;
|
|
25
|
-
case 'arrive':
|
|
26
|
-
return `Arrive at ${place ?? ''}`;
|
|
27
|
-
case 'depart':
|
|
28
|
-
return `Depart ${place ?? ''}`;
|
|
29
|
-
case 'trip_end':
|
|
30
|
-
return 'Trip ends';
|
|
31
|
-
case 'draft':
|
|
32
|
-
return `Stop at ${place ?? ''} (time TBD)`;
|
|
33
|
-
default:
|
|
34
|
-
return place ? `${place}` : step.stepType;
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
/**
|
|
39
|
-
* Builds the display label for an itinerary step from stepType + place.
|
|
40
|
-
* All labels are built on the FE so the user's language choice is respected.
|
|
41
|
-
*/
|
|
42
|
-
export function getStepLabel(
|
|
43
|
-
step: StepForLabel,
|
|
44
|
-
t: TranslationFn
|
|
45
|
-
): string {
|
|
46
|
-
const place = step.place;
|
|
47
|
-
const placeDisplay =
|
|
48
|
-
place === 'your_pickup_location'
|
|
49
|
-
? t('booking.yourPickupLocation')
|
|
50
|
-
: place === 'the_destination'
|
|
51
|
-
? t('booking.placeTheDestination')
|
|
52
|
-
: place ?? '';
|
|
53
|
-
|
|
54
|
-
switch (step.stepType) {
|
|
55
|
-
case 'pickup':
|
|
56
|
-
return t('booking.pickupAtLocation', { location: placeDisplay });
|
|
57
|
-
case 'drop_off':
|
|
58
|
-
return t('booking.dropOffAt', { location: placeDisplay });
|
|
59
|
-
case 'arrive':
|
|
60
|
-
return t('booking.arriveAtPlace', { place: place ?? '' });
|
|
61
|
-
case 'depart':
|
|
62
|
-
return t('booking.departFromPlace', { place: place ?? '' });
|
|
63
|
-
case 'trip_end':
|
|
64
|
-
return t('booking.tripEnd');
|
|
65
|
-
case 'draft':
|
|
66
|
-
return t('booking.stopAtPlaceTbd', { place: place ?? '' });
|
|
67
|
-
default:
|
|
68
|
-
return place ? `${place}` : step.stepType;
|
|
69
|
-
}
|
|
70
|
-
}
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Location calculation utilities
|
|
3
|
-
*/
|
|
4
|
-
|
|
5
|
-
import type { PickupLocation } from '@/lib/booking-api';
|
|
6
|
-
import type { Coordinates } from '@/lib/booking/location-utils';
|
|
7
|
-
import type { NearbyLocation } from '@/lib/booking/pickup-location-types';
|
|
8
|
-
import {
|
|
9
|
-
calculateDistance,
|
|
10
|
-
estimateWalkingTime,
|
|
11
|
-
estimateDrivingTime,
|
|
12
|
-
} from '@/lib/booking/location-utils';
|
|
13
|
-
|
|
14
|
-
const EXACT_MATCH_THRESHOLD_KM = 0.05; // 50 meters - tighter threshold for exact matches
|
|
15
|
-
|
|
16
|
-
/**
|
|
17
|
-
* Calculate nearby locations with distances and travel times
|
|
18
|
-
*/
|
|
19
|
-
export function calculateNearbyLocations(
|
|
20
|
-
searchCoordinates: Coordinates,
|
|
21
|
-
pickupLocations: PickupLocation[]
|
|
22
|
-
): NearbyLocation[] {
|
|
23
|
-
return pickupLocations
|
|
24
|
-
.filter((loc) => loc.coordinates)
|
|
25
|
-
.map((loc) => {
|
|
26
|
-
const distance = calculateDistance(searchCoordinates, loc.coordinates!);
|
|
27
|
-
return {
|
|
28
|
-
...loc,
|
|
29
|
-
distance,
|
|
30
|
-
walkingTime: estimateWalkingTime(distance),
|
|
31
|
-
drivingTime: estimateDrivingTime(distance),
|
|
32
|
-
};
|
|
33
|
-
})
|
|
34
|
-
.sort((a, b) => a.distance - b.distance);
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
/**
|
|
38
|
-
* Check if searched location is very close to a pickup location (exact match)
|
|
39
|
-
*/
|
|
40
|
-
export function isExactMatch(nearbyLocations: NearbyLocation[]): boolean {
|
|
41
|
-
return nearbyLocations.some((loc) => loc.distance < EXACT_MATCH_THRESHOLD_KM);
|
|
42
|
-
}
|
|
43
|
-
|
|
@@ -1,165 +0,0 @@
|
|
|
1
|
-
// Location utilities for distance calculation and travel time estimation
|
|
2
|
-
|
|
3
|
-
export interface Coordinates {
|
|
4
|
-
lat: number;
|
|
5
|
-
lng: number;
|
|
6
|
-
}
|
|
7
|
-
|
|
8
|
-
/**
|
|
9
|
-
* Calculate the distance between two coordinates using the Haversine formula
|
|
10
|
-
* Returns distance in kilometers
|
|
11
|
-
*/
|
|
12
|
-
export function calculateDistance(
|
|
13
|
-
coord1: Coordinates,
|
|
14
|
-
coord2: Coordinates
|
|
15
|
-
): number {
|
|
16
|
-
const R = 6371; // Earth's radius in kilometers
|
|
17
|
-
const dLat = toRadians(coord2.lat - coord1.lat);
|
|
18
|
-
const dLon = toRadians(coord2.lng - coord1.lng);
|
|
19
|
-
|
|
20
|
-
const a =
|
|
21
|
-
Math.sin(dLat / 2) * Math.sin(dLat / 2) +
|
|
22
|
-
Math.cos(toRadians(coord1.lat)) *
|
|
23
|
-
Math.cos(toRadians(coord2.lat)) *
|
|
24
|
-
Math.sin(dLon / 2) *
|
|
25
|
-
Math.sin(dLon / 2);
|
|
26
|
-
|
|
27
|
-
const c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a));
|
|
28
|
-
return R * c;
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
function toRadians(degrees: number): number {
|
|
32
|
-
return degrees * (Math.PI / 180);
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
/**
|
|
36
|
-
* Convert kilometers to miles
|
|
37
|
-
*/
|
|
38
|
-
export function kmToMiles(km: number): number {
|
|
39
|
-
return km * 0.621371;
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
/**
|
|
43
|
-
* Convert miles to kilometers
|
|
44
|
-
*/
|
|
45
|
-
export function milesToKm(miles: number): number {
|
|
46
|
-
return miles * 1.60934;
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
/**
|
|
50
|
-
* Estimate walking time in minutes
|
|
51
|
-
* Assumes average walking speed of 5 km/h
|
|
52
|
-
*/
|
|
53
|
-
export function estimateWalkingTime(distanceKm: number): number {
|
|
54
|
-
const walkingSpeedKmh = 5;
|
|
55
|
-
return Math.round((distanceKm / walkingSpeedKmh) * 60);
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
/**
|
|
59
|
-
* Estimate driving time in minutes
|
|
60
|
-
* Assumes average driving speed of 50 km/h (urban/suburban)
|
|
61
|
-
*/
|
|
62
|
-
export function estimateDrivingTime(distanceKm: number): number {
|
|
63
|
-
const drivingSpeedKmh = 50;
|
|
64
|
-
return Math.round((distanceKm / drivingSpeedKmh) * 60);
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
/**
|
|
68
|
-
* Format distance with appropriate unit
|
|
69
|
-
*/
|
|
70
|
-
export function formatDistance(
|
|
71
|
-
distanceKm: number,
|
|
72
|
-
useImperial: boolean = false
|
|
73
|
-
): string {
|
|
74
|
-
if (useImperial) {
|
|
75
|
-
const miles = kmToMiles(distanceKm);
|
|
76
|
-
if (miles < 0.1) {
|
|
77
|
-
return `${Math.round(miles * 5280)} ft`;
|
|
78
|
-
} else if (miles < 1) {
|
|
79
|
-
return `${miles.toFixed(1)} mi`;
|
|
80
|
-
} else {
|
|
81
|
-
return `${miles.toFixed(1)} mi`;
|
|
82
|
-
}
|
|
83
|
-
} else {
|
|
84
|
-
if (distanceKm < 0.1) {
|
|
85
|
-
return `${Math.round(distanceKm * 1000)} m`;
|
|
86
|
-
} else if (distanceKm < 1) {
|
|
87
|
-
return `${Math.round(distanceKm * 1000)} m`;
|
|
88
|
-
} else {
|
|
89
|
-
return `${distanceKm.toFixed(1)} km`;
|
|
90
|
-
}
|
|
91
|
-
}
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
/**
|
|
95
|
-
* Format time duration
|
|
96
|
-
*/
|
|
97
|
-
export function formatTime(minutes: number): string {
|
|
98
|
-
if (minutes < 60) {
|
|
99
|
-
return `${minutes} min`;
|
|
100
|
-
} else {
|
|
101
|
-
const hours = Math.floor(minutes / 60);
|
|
102
|
-
const mins = minutes % 60;
|
|
103
|
-
return mins > 0 ? `${hours} h ${mins} min` : `${hours} h`;
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
/**
|
|
108
|
-
* Service area for Private Shuttle custom pickups: Lake Louise to Kananaskis casino corridor.
|
|
109
|
-
* Bounding box encompasses: Lake Louise, Banff, Canmore, Kananaskis.
|
|
110
|
-
* Excludes Calgary and areas east.
|
|
111
|
-
*/
|
|
112
|
-
export const PRIVATE_SHUTTLE_SERVICE_BOUNDS = {
|
|
113
|
-
latMin: 51.0,
|
|
114
|
-
latMax: 51.5,
|
|
115
|
-
lngMin: -116.5,
|
|
116
|
-
lngMax: -114.8,
|
|
117
|
-
} as const;
|
|
118
|
-
|
|
119
|
-
/**
|
|
120
|
-
* Check if coordinates are within the Private Shuttle service area
|
|
121
|
-
* (corridor from Lake Louise to Kananaskis casino).
|
|
122
|
-
*/
|
|
123
|
-
export function isWithinPrivateShuttleServiceArea(coords: Coordinates): boolean {
|
|
124
|
-
const { latMin, latMax, lngMin, lngMax } = PRIVATE_SHUTTLE_SERVICE_BOUNDS;
|
|
125
|
-
return (
|
|
126
|
-
coords.lat >= latMin &&
|
|
127
|
-
coords.lat <= latMax &&
|
|
128
|
-
coords.lng >= lngMin &&
|
|
129
|
-
coords.lng <= lngMax
|
|
130
|
-
);
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
/**
|
|
134
|
-
* Geocode an address using Google Maps Geocoding API
|
|
135
|
-
* Note: This requires a Google Maps API key
|
|
136
|
-
*/
|
|
137
|
-
export async function geocodeAddress(
|
|
138
|
-
address: string,
|
|
139
|
-
apiKey?: string
|
|
140
|
-
): Promise<Coordinates | null> {
|
|
141
|
-
if (!apiKey) {
|
|
142
|
-
// Fallback: try to use browser geolocation or return null
|
|
143
|
-
console.warn('Google Maps API key not provided');
|
|
144
|
-
return null;
|
|
145
|
-
}
|
|
146
|
-
|
|
147
|
-
try {
|
|
148
|
-
const response = await fetch(
|
|
149
|
-
`https://maps.googleapis.com/maps/api/geocode/json?address=${encodeURIComponent(
|
|
150
|
-
address
|
|
151
|
-
)}&key=${apiKey}`
|
|
152
|
-
);
|
|
153
|
-
const data = await response.json();
|
|
154
|
-
|
|
155
|
-
if (data.status === 'OK' && data.results.length > 0) {
|
|
156
|
-
const location = data.results[0].geometry.location;
|
|
157
|
-
return { lat: location.lat, lng: location.lng };
|
|
158
|
-
}
|
|
159
|
-
return null;
|
|
160
|
-
} catch (error) {
|
|
161
|
-
console.error('Geocoding error:', error);
|
|
162
|
-
return null;
|
|
163
|
-
}
|
|
164
|
-
}
|
|
165
|
-
|