@ticketboothapp/booking 0.1.19 → 0.1.20

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.
Files changed (154) hide show
  1. package/package.json +1 -1
  2. package/src/components/BookingWidget.tsx +282 -26
  3. package/src/components/ManageBookingView.tsx +75 -23
  4. package/src/components/booking/BookingProductGrid.tsx +1 -1
  5. package/src/components/booking/Calendar.module.css +3 -3
  6. package/src/components/booking/CheckoutForm.tsx +1 -1
  7. package/src/components/booking/InfoTooltip.tsx +2 -13
  8. package/src/components/booking/PickupLocationSelector.tsx +2 -2
  9. package/src/components/booking/PriceBreakdown.tsx +11 -34
  10. package/src/index.ts +3 -1
  11. package/src/app/photo-sessions/photo-packages.ts +0 -75
  12. package/src/assets/icons/minus.svg +0 -7
  13. package/src/assets/icons/partner-logos/getyourguide.svg +0 -8
  14. package/src/assets/icons/plus.svg +0 -3
  15. package/src/colours.css +0 -23
  16. package/src/components/BookingDetails.module.css +0 -1591
  17. package/src/components/BookingDetails.tsx +0 -2264
  18. package/src/components/JobApplicationDialog.module.css +0 -440
  19. package/src/components/JobApplicationDialog.tsx +0 -620
  20. package/src/components/PhoneInputWithCountry.module.css +0 -131
  21. package/src/components/PhoneInputWithCountry.tsx +0 -44
  22. package/src/components/PickupLocationDialog.module.css +0 -360
  23. package/src/components/PickupLocationDialog.tsx +0 -357
  24. package/src/components/PickupLocationMap.tsx +0 -110
  25. package/src/components/PostBookingDependentAddOnUpsell.module.css +0 -174
  26. package/src/components/PostBookingDependentAddOnUpsell.tsx +0 -407
  27. package/src/components/accordion.css +0 -27
  28. package/src/components/accordion.tsx +0 -29
  29. package/src/components/analytics/AnalyticsConsentRestore.tsx +0 -19
  30. package/src/components/analytics/AnalyticsScripts.tsx +0 -106
  31. package/src/components/analytics/CookieConsentBanner.css +0 -86
  32. package/src/components/analytics/CookieConsentBanner.tsx +0 -102
  33. package/src/components/bottom-sheet.module.css +0 -78
  34. package/src/components/bottom-sheet.tsx +0 -60
  35. package/src/components/breadcrumb.module.css +0 -40
  36. package/src/components/breadcrumb.tsx +0 -36
  37. package/src/components/button.css +0 -245
  38. package/src/components/button.tsx +0 -152
  39. package/src/components/client-bottom-sheet.tsx +0 -14
  40. package/src/components/colorable-svg.tsx +0 -29
  41. package/src/components/conditional-footer.tsx +0 -27
  42. package/src/components/contact-us.module.css +0 -147
  43. package/src/components/contact-us.tsx +0 -49
  44. package/src/components/email-signup.css +0 -151
  45. package/src/components/email-signup.tsx +0 -63
  46. package/src/components/faq-wrapper.module.css +0 -47
  47. package/src/components/faq-wrapper.tsx +0 -15
  48. package/src/components/footer.css +0 -187
  49. package/src/components/footer.tsx +0 -143
  50. package/src/components/global-simple-modal.tsx +0 -33
  51. package/src/components/google-review-summary.module.css +0 -77
  52. package/src/components/google-review-summary.tsx +0 -50
  53. package/src/components/hero-image.css +0 -13
  54. package/src/components/hero-image.tsx +0 -44
  55. package/src/components/image.css +0 -29
  56. package/src/components/image.tsx +0 -113
  57. package/src/components/language-aware-link.tsx +0 -72
  58. package/src/components/language-switcher.module.css +0 -124
  59. package/src/components/language-switcher.tsx +0 -75
  60. package/src/components/map-section.css +0 -59
  61. package/src/components/map-section.tsx +0 -63
  62. package/src/components/navbar.module.css +0 -152
  63. package/src/components/navbar.tsx +0 -125
  64. package/src/components/parallax-provider.tsx +0 -11
  65. package/src/components/product-tag.module.css +0 -30
  66. package/src/components/product-tag.tsx +0 -34
  67. package/src/components/product-theme-pages/best-option.module.css +0 -70
  68. package/src/components/product-theme-pages/best-option.tsx +0 -35
  69. package/src/components/product-theme-pages/extended-tour-options.module.css +0 -22
  70. package/src/components/product-theme-pages/extended-tour-options.tsx +0 -11
  71. package/src/components/product-theme-pages/image-modal.tsx +0 -248
  72. package/src/components/product-theme-pages/photo-gallery.module.css +0 -200
  73. package/src/components/product-theme-pages/photo-gallery.tsx +0 -90
  74. package/src/components/product-theme-pages/product-theme-page-layout.module.css +0 -13
  75. package/src/components/product-theme-pages/product-theme-page-layout.tsx +0 -67
  76. package/src/components/product-theme-pages/top-of-fold.module.css +0 -179
  77. package/src/components/product-theme-pages/top-of-fold.tsx +0 -80
  78. package/src/components/product-tile/image-only-product-tile-desktop.module.css +0 -106
  79. package/src/components/product-tile/image-only-product-tile-desktop.tsx +0 -56
  80. package/src/components/product-tile/image-only-product-tile-mobile.module.css +0 -122
  81. package/src/components/product-tile/image-only-product-tile-mobile.tsx +0 -89
  82. package/src/components/product-tile/image-only-product-tile.tsx +0 -44
  83. package/src/components/product-tile/product-tile-card.module.css +0 -84
  84. package/src/components/product-tile/product-tile-card.tsx +0 -61
  85. package/src/components/review-highlights-section.css +0 -85
  86. package/src/components/review-highlights-section.tsx +0 -127
  87. package/src/components/season-closure-overlay.module.css +0 -99
  88. package/src/components/season-closure-overlay.tsx +0 -98
  89. package/src/components/simple-modal.tsx +0 -69
  90. package/src/components/simple-top-of-fold.module.css +0 -76
  91. package/src/components/simple-top-of-fold.tsx +0 -34
  92. package/src/components/spacer.css +0 -41
  93. package/src/components/spacer.tsx +0 -23
  94. package/src/components/star-rating.module.css +0 -74
  95. package/src/components/star-rating.tsx +0 -48
  96. package/src/components/terms/TermsContent.tsx +0 -178
  97. package/src/components/title-subtitle.module.css +0 -10
  98. package/src/components/title-subtitle.tsx +0 -30
  99. package/src/components/translatable-reviews.tsx +0 -75
  100. package/src/components/value-pill.module.css +0 -59
  101. package/src/components/value-pill.tsx +0 -46
  102. package/src/components/value-props.css +0 -185
  103. package/src/components/value-props.tsx +0 -88
  104. package/src/constants/booking-guide-quiz.ts +0 -64
  105. package/src/constants/contact-info.ts +0 -2
  106. package/src/constants/faq.ts +0 -44
  107. package/src/constants/images.ts +0 -556
  108. package/src/constants/json-ld/faq-json-ld.tsx +0 -170
  109. package/src/constants/json-ld/homepage-json-ld.tsx +0 -138
  110. package/src/constants/json-ld/job-posting-json-ld.tsx +0 -92
  111. package/src/constants/json-ld/organization-json-ld.tsx +0 -62
  112. package/src/constants/json-ld/page-json-ld.tsx +0 -6
  113. package/src/constants/json-ld/product-json-ld.tsx +0 -154
  114. package/src/constants/json-ld/review-json-ld.tsx +0 -377
  115. package/src/constants/navigation-links/footer-links.ts +0 -48
  116. package/src/constants/navigation-links/nav-bar-links.ts +0 -41
  117. package/src/constants/navigation-links/navigation-link.ts +0 -6
  118. package/src/constants/pill-values.ts +0 -210
  119. package/src/constants/products.ts +0 -155
  120. package/src/constants/quiz-recommendations.ts +0 -506
  121. package/src/constants/reviews.ts +0 -75
  122. package/src/constants/staff.ts +0 -197
  123. package/src/constants/value-props.ts +0 -58
  124. package/src/data/dap-descriptions/session-couples-families-friends.en.json +0 -61
  125. package/src/data/dap-descriptions/session-elopements.en.json +0 -60
  126. package/src/data/dap-descriptions/session-proposals.en.json +0 -60
  127. package/src/data/product-descriptions/afternoon-delight.en.json +0 -35
  128. package/src/data/product-descriptions/emerald-lake-escape.en.json +0 -68
  129. package/src/data/product-descriptions/lake-louise-adventure.en.json +0 -74
  130. package/src/data/product-descriptions/moraine-lake-adventure.en.json +0 -78
  131. package/src/data/product-descriptions/moraine-lake-sunrise-lake-louise-golden-hour.en.json +0 -65
  132. package/src/data/product-descriptions/moraine-lake-sunrise.en.json +0 -64
  133. package/src/data/product-descriptions/private-tour.en.json +0 -80
  134. package/src/data/product-descriptions/two-lakes-combo.en.json +0 -65
  135. package/src/data/products-config.json +0 -101
  136. package/src/hooks/use-bottom-sheet.tsx +0 -15
  137. package/src/hooks/use-simple-modal.tsx +0 -27
  138. package/src/hooks/useBookingSourceMetadataFromLocation.ts +0 -21
  139. package/src/hooks/useEmailSubscription.tsx +0 -103
  140. package/src/hooks/useEmbeddedInIframe.ts +0 -16
  141. package/src/hooks/useIsBookingLaunchLive.ts +0 -49
  142. package/src/hooks/useQuiz.tsx +0 -210
  143. package/src/providers/bottom-sheet-provider.tsx +0 -40
  144. package/src/providers/dependent-add-on-dialog-provider.tsx +0 -105
  145. package/src/radius.css +0 -5
  146. package/src/spacing.css +0 -7
  147. package/src/strings/en.json +0 -1774
  148. package/src/strings/es.json +0 -1573
  149. package/src/strings/fr.json +0 -1573
  150. package/src/strings/index.js +0 -23
  151. package/src/text-style.css +0 -97
  152. package/src/types/fareharbor.d.ts +0 -12
  153. package/src/types/quiz.ts +0 -59
  154. package/src/utils/currency-converter.ts +0 -101
@@ -1,23 +0,0 @@
1
- import enStrings from './en.json';
2
- import frStrings from './fr.json';
3
- import esStrings from './es.json';
4
-
5
- // This can be expanded later to handle different languages
6
- const strings = {
7
- en: enStrings,
8
- fr: frStrings,
9
- es: esStrings
10
- };
11
-
12
- export const SUPPORTED_LANGUAGES = ['en', 'fr', 'es'];
13
-
14
- // Default to English for now
15
- export const getStrings = (lang = 'en') => {
16
- if (!strings[lang]) {
17
- console.warn(`Language ${lang} not found, falling back to English`);
18
- return strings.en;
19
- }
20
- return strings[lang];
21
- };
22
-
23
- export default getStrings('en');
@@ -1,97 +0,0 @@
1
- @import url('./colours.css');
2
-
3
- @font-face {
4
- font-family: 'Poppins';
5
- font-weight: 800;
6
- src: url('assets/fonts/Poppins-ExtraBold.woff2') format('woff2'),
7
- url('assets/fonts/Poppins-ExtraBold.woff') format('woff');
8
- }
9
-
10
- @font-face {
11
- font-family: 'Figtree';
12
- font-weight: 400;
13
- src: url('assets/fonts/Figtree-Regular.woff2') format('woff2'),
14
- url('assets/fonts/Figtree-Regular.woff') format('woff');
15
- }
16
-
17
- @font-face {
18
- font-family: 'Figtree';
19
- font-weight: 700;
20
- src: url('assets/fonts/Figtree-Bold.woff2') format('woff2'),
21
- url('assets/fonts/Figtree-Bold.woff') format('woff');
22
- }
23
-
24
- @font-face {
25
- font-family: 'Northlake';
26
- font-weight: 400;
27
- src: url('assets/fonts/Northlake-Medium.woff2') format('woff2'),
28
- url('assets/fonts/Northlake-Medium.woff') format('woff');
29
- }
30
-
31
- @font-face {
32
- font-family: 'Ralders';
33
- font-weight: 800;
34
- src: url('assets/fonts/Ralders.woff2') format('woff2'),
35
- url('assets/fonts/Ralders.woff') format('woff');
36
- }
37
-
38
- @font-face {
39
- font-family: 'Snell Roundhand';
40
- font-weight: 900;
41
- src: url('assets/fonts/snellroundhand_black.woff2') format('woff2'),
42
- url('assets/fonts/snellroundhand_black.woff') format('woff');
43
- }
44
-
45
-
46
- /* Common styles for all headings */
47
- h1, h2, h3, h4, h5, h6 {
48
- font-family: 'Poppins';
49
- font-weight: 800;
50
- text-transform: lowercase;
51
- color: var(--accent-orange);
52
- text-align: center;
53
- margin: 0;
54
- }
55
-
56
- p, body {
57
- font-weight: 400;
58
- font-family: 'Figtree', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen',
59
- 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue',
60
- sans-serif;
61
- color: var(--primary-text);
62
- margin: 0;
63
- }
64
-
65
- a {
66
- color: var(--accent-orange);
67
- }
68
-
69
- /* Desktop */
70
- @media (min-width: 1024px) {
71
- h1 { font-size: 3rem; }
72
- h2 { font-size: 2.5rem; }
73
- h3 { font-size: 2rem; }
74
- h4 { font-size: 1.75rem; }
75
- h5 { font-size: 1.5rem; }
76
- p { font-size: 1.2rem; }
77
- }
78
-
79
- /* Tablet */
80
- @media (min-width: 768px) and (max-width: 1023px) {
81
- h1 { font-size: 2.5rem; }
82
- h2 { font-size: 2rem; }
83
- h3 { font-size: 1.75rem; }
84
- h4 { font-size: 1.5rem; }
85
- h5 { font-size: 1.25rem; }
86
- p { font-size: 1.2rem; }
87
- }
88
-
89
- /* Mobile */
90
- @media (max-width: 768px) {
91
- h1 { font-size: 2.5rem; }
92
- h2 { font-size: 1.75rem; }
93
- h3 { font-size: 1.5rem; }
94
- h4 { font-size: 1.25rem; }
95
- h5 { font-size: 1rem; }
96
- p { font-size: 1rem; }
97
- }
@@ -1,12 +0,0 @@
1
- interface FareHarborAPI {
2
- open: (options: {
3
- shortname: string;
4
- fallback: string;
5
- fullItems: string;
6
- view: string;
7
- }) => boolean;
8
- }
9
-
10
- interface Window {
11
- FH: FareHarborAPI;
12
- }
package/src/types/quiz.ts DELETED
@@ -1,59 +0,0 @@
1
- import { ImageData } from '@/constants/images';
2
-
3
- export interface Answer {
4
- id: string;
5
- text: string;
6
- image?: ImageData;
7
- subtext?: string;
8
- }
9
-
10
- export interface QuizQuestion {
11
- id: string;
12
- text: string;
13
- subtitle?: string;
14
- answers: Answer[];
15
- isMultiSelect?: boolean;
16
- showIf?: (answers: UserAnswers) => boolean;
17
- }
18
-
19
- export type UserAnswers = {
20
- [questionId: string]: string | string[]; // maps questionId to answerId(s)
21
- };
22
-
23
- export type MatchType = 'AND' | 'OR';
24
-
25
- export type AnswerMatch = {
26
- values: string[];
27
- matchType: MatchType;
28
- };
29
-
30
- // This type defines what answers lead to what recommendations
31
- export type RecommendationRule = {
32
- answers: {
33
- what_lakes?: AnswerMatch;
34
- sunrise?: string;
35
- what_activities?: AnswerMatch;
36
- hiking?: AnswerMatch;
37
- exclude?: {
38
- [questionId: string]: string[];
39
- };
40
- };
41
- recommendationIds: string[];
42
- recommendationDetails: {
43
- [productId: string]: string[];
44
- };
45
- isMultiDayGroup?: boolean;
46
- isAlternativeGroup?: boolean;
47
- alternativeGroupTitle?: string;
48
- dayGroups?: {
49
- day: number;
50
- dayTitle: string;
51
- recommendationIds: string[];
52
- }[];
53
- };
54
-
55
- export type QuizState = {
56
- currentQuestionIndex: number;
57
- answers: UserAnswers;
58
- isComplete: boolean;
59
- };
@@ -1,101 +0,0 @@
1
- type SupportedCurrency = 'CAD' | 'USD' | 'AUD' | 'MXN' | 'EUR' | 'GBP';
2
-
3
- interface CurrencyFormat {
4
- symbol: string;
5
- position: 'before' | 'after';
6
- rate: number; // Exchange rate from CAD
7
- }
8
-
9
- const currencyFormats: Record<SupportedCurrency, CurrencyFormat> = {
10
- CAD: { symbol: 'CA$', position: 'before', rate: 1 },
11
- USD: { symbol: 'US$', position: 'before', rate: 0.70 },
12
- AUD: { symbol: 'AU$', position: 'before', rate: 1.11 },
13
- MXN: { symbol: 'MX$', position: 'before', rate: 14.25 },
14
- EUR: { symbol: '€', position: 'before', rate: 0.65 },
15
- GBP: { symbol: '£', position: 'before', rate: 0.54 }
16
- };
17
-
18
- let cachedCurrency: SupportedCurrency | null = null;
19
-
20
- export function getUserCurrency(): SupportedCurrency {
21
- // Return CAD during server-side rendering
22
- if (typeof window === 'undefined') {
23
- return 'CAD';
24
- }
25
-
26
- // Use cached value if available
27
- if (cachedCurrency) {
28
- return cachedCurrency;
29
- }
30
-
31
- try {
32
- const locale = navigator.language;
33
- const languages = navigator.languages || [];
34
-
35
- // Try to find a Canadian locale in the language list
36
- const hasCanadianLocale = languages.some(lang =>
37
- lang.toLowerCase().includes('en-ca') ||
38
- lang.toLowerCase().includes('fr-ca')
39
- );
40
-
41
- // Check for Canadian region/timezone hints
42
- const timeZone = Intl.DateTimeFormat().resolvedOptions().timeZone;
43
- const isCanadianTimeZone = timeZone.includes('America') &&
44
- ['Vancouver', 'Edmonton', 'Calgary', 'Regina', 'Winnipeg', 'Toronto', 'Montreal', 'Halifax', 'St_Johns']
45
- .some(city => timeZone.includes(city));
46
-
47
- if (hasCanadianLocale || isCanadianTimeZone) {
48
- cachedCurrency = 'CAD';
49
- return cachedCurrency;
50
- }
51
-
52
- const country = locale.split('-')[1] || locale.split('_')[1];
53
-
54
- // Map common locales to currencies
55
- const currencyMap: Record<string, SupportedCurrency> = {
56
- 'CA': 'CAD',
57
- 'US': 'USD',
58
- 'AU': 'AUD',
59
- 'MX': 'MXN',
60
- 'GB': 'GBP'
61
- };
62
-
63
- // Check if we're in a European country
64
- const euroCountries = ['DE', 'FR', 'IT', 'ES', 'NL', 'BE', 'AT', 'IE', 'FI', 'PT'];
65
-
66
- // Check both country code and language for European detection
67
- if (euroCountries.includes(country) ||
68
- languages.some(lang => euroCountries.includes(lang.split('-')[1] || lang.split('_')[1]))) {
69
- cachedCurrency = 'EUR';
70
- return cachedCurrency;
71
- }
72
-
73
- cachedCurrency = currencyMap[country] || 'CAD';
74
- return cachedCurrency;
75
- } catch {
76
- cachedCurrency = 'CAD';
77
- return cachedCurrency;
78
- }
79
- }
80
-
81
- export function formatPrice(cadPrice: string, language?: 'en' | 'es' | 'fr'): string {
82
- // Extract numeric value from CAD price string
83
- const numericValue = parseFloat(cadPrice.replace(/[^0-9.]/g, ''));
84
- if (isNaN(numericValue)) return cadPrice;
85
-
86
- const userCurrency = getUserCurrency();
87
- const format = currencyFormats[userCurrency];
88
-
89
- // Convert price
90
- const convertedPrice = Math.round(numericValue * format.rate);
91
-
92
- // Handle French formatting
93
- if (language === 'fr') {
94
- return `${convertedPrice}$CA`;
95
- }
96
-
97
- // Format the price for other languages
98
- return format.position === 'before'
99
- ? `${format.symbol}${convertedPrice}`
100
- : `${convertedPrice}${format.symbol}`;
101
- }