@qite/tide-components 1.0.12 → 1.0.13

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.
@@ -65,6 +65,7 @@ var FLIGHTS_FORM$f = {
65
65
  AIRLINES: "شركات الطيران",
66
66
  AIRPORTS: "المطارات",
67
67
  NUMBER_OF_STOPS: "عدد التوقفات",
68
+ TRAVEL_CLASS: "درجة السفر",
68
69
  FLIGHT_OUTWARD: "رحلة الذهاب",
69
70
  DEPARTURE_TIME: "وقت المغادرة",
70
71
  TRAVEL_DURATION: "مدة السفر",
@@ -518,6 +519,7 @@ var FLIGHTS_FORM$e = {
518
519
  AIRLINES: "Flyselskaber",
519
520
  AIRPORTS: "Lufthavne",
520
521
  NUMBER_OF_STOPS: "Antal stop",
522
+ TRAVEL_CLASS: "Rejseklasse",
521
523
  FLIGHT_OUTWARD: "Udgående fly",
522
524
  DEPARTURE_TIME: "Afgangstid",
523
525
  TRAVEL_DURATION: "Rejsetid",
@@ -971,6 +973,7 @@ var FLIGHTS_FORM$d = {
971
973
  AIRLINES: "Fluggesellschaften",
972
974
  AIRPORTS: "Flughäfen",
973
975
  NUMBER_OF_STOPS: "Anzahl der Stopps",
976
+ TRAVEL_CLASS: "Reiseklasse",
974
977
  FLIGHT_OUTWARD: "Hinflug",
975
978
  DEPARTURE_TIME: "Abflugzeit",
976
979
  TRAVEL_DURATION: "Reisedauer",
@@ -1424,6 +1427,7 @@ var FLIGHTS_FORM$c = {
1424
1427
  AIRLINES: "Airlines",
1425
1428
  AIRPORTS: "Airports",
1426
1429
  NUMBER_OF_STOPS: "Number of stops",
1430
+ TRAVEL_CLASS: "Travel class",
1427
1431
  FLIGHT_OUTWARD: "Outbound flight",
1428
1432
  DEPARTURE_TIME: "Departure time",
1429
1433
  TRAVEL_DURATION: "Travel duration",
@@ -1881,6 +1885,7 @@ var FLIGHTS_FORM$b = {
1881
1885
  AIRLINES: "Aerolíneas",
1882
1886
  AIRPORTS: "Aeropuertos",
1883
1887
  NUMBER_OF_STOPS: "Número de escalas",
1888
+ TRAVEL_CLASS: "Clase de viaje",
1884
1889
  FLIGHT_OUTWARD: "Vuelo de ida",
1885
1890
  DEPARTURE_TIME: "Hora de salida",
1886
1891
  TRAVEL_DURATION: "Duración del viaje",
@@ -2334,6 +2339,7 @@ var FLIGHTS_FORM$a = {
2334
2339
  AIRLINES: "Compagnies aériennes",
2335
2340
  AIRPORTS: "Aéroports",
2336
2341
  NUMBER_OF_STOPS: "Nombre d'escales",
2342
+ TRAVEL_CLASS: "Classe de voyage",
2337
2343
  FLIGHT_OUTWARD: "Vol aller",
2338
2344
  DEPARTURE_TIME: "Heure de départ",
2339
2345
  TRAVEL_DURATION: "Durée du voyage",
@@ -2791,6 +2797,7 @@ var FLIGHTS_FORM$9 = {
2791
2797
  AIRLINES: "Compagnies aériennes",
2792
2798
  AIRPORTS: "Aéroports",
2793
2799
  NUMBER_OF_STOPS: "Nombre d'escales",
2800
+ TRAVEL_CLASS: "Classe de voyage",
2794
2801
  FLIGHT_OUTWARD: "Vol aller",
2795
2802
  DEPARTURE_TIME: "Heure de départ",
2796
2803
  TRAVEL_DURATION: "Durée du voyage",
@@ -3244,6 +3251,7 @@ var FLIGHTS_FORM$8 = {
3244
3251
  AIRLINES: "Flugfélög",
3245
3252
  AIRPORTS: "Flugvellir",
3246
3253
  NUMBER_OF_STOPS: "Fjöldi millilendinga",
3254
+ TRAVEL_CLASS: "Farrými",
3247
3255
  FLIGHT_OUTWARD: "Brottfararflug",
3248
3256
  DEPARTURE_TIME: "Brottfarartími",
3249
3257
  TRAVEL_DURATION: "Ferðalagstími",
@@ -3697,6 +3705,7 @@ var FLIGHTS_FORM$7 = {
3697
3705
  AIRLINES: "Compagnie aeree",
3698
3706
  AIRPORTS: "Aeroporti",
3699
3707
  NUMBER_OF_STOPS: "Numero di scali",
3708
+ TRAVEL_CLASS: "Classe di viaggio",
3700
3709
  FLIGHT_OUTWARD: "Volo di andata",
3701
3710
  DEPARTURE_TIME: "Orario di partenza",
3702
3711
  TRAVEL_DURATION: "Durata del viaggio",
@@ -4150,6 +4159,7 @@ var FLIGHTS_FORM$6 = {
4150
4159
  AIRLINES: "Luchtvaartmaatschappijen",
4151
4160
  AIRPORTS: "Luchthavens",
4152
4161
  NUMBER_OF_STOPS: "Aantal stops",
4162
+ TRAVEL_CLASS: "Reisklasse",
4153
4163
  FLIGHT_OUTWARD: "Vlucht heenreis",
4154
4164
  DEPARTURE_TIME: "Vertrektijd",
4155
4165
  TRAVEL_DURATION: "Reisduur",
@@ -4607,6 +4617,7 @@ var FLIGHTS_FORM$5 = {
4607
4617
  AIRLINES: "Luchtvaartmaatschappijen",
4608
4618
  AIRPORTS: "Luchthavens",
4609
4619
  NUMBER_OF_STOPS: "Aantal tussenstops",
4620
+ TRAVEL_CLASS: "Reisklasse",
4610
4621
  FLIGHT_OUTWARD: "Heenvlucht",
4611
4622
  DEPARTURE_TIME: "Vertrektijd",
4612
4623
  TRAVEL_DURATION: "Reisduur",
@@ -5060,6 +5071,7 @@ var FLIGHTS_FORM$4 = {
5060
5071
  AIRLINES: "Flyselskaper",
5061
5072
  AIRPORTS: "Flyplasser",
5062
5073
  NUMBER_OF_STOPS: "Antall mellomlandinger",
5074
+ TRAVEL_CLASS: "Reiseklasse",
5063
5075
  FLIGHT_OUTWARD: "Utreisefly",
5064
5076
  DEPARTURE_TIME: "Avgangstid",
5065
5077
  TRAVEL_DURATION: "Reisetid",
@@ -5513,6 +5525,7 @@ var FLIGHTS_FORM$3 = {
5513
5525
  AIRLINES: "Linie lotnicze",
5514
5526
  AIRPORTS: "Lotniska",
5515
5527
  NUMBER_OF_STOPS: "Liczba przesiadek",
5528
+ TRAVEL_CLASS: "Klasa podróży",
5516
5529
  FLIGHT_OUTWARD: "Lot wylotowy",
5517
5530
  DEPARTURE_TIME: "Godzina odlotu",
5518
5531
  TRAVEL_DURATION: "Czas podróży",
@@ -5966,6 +5979,7 @@ var FLIGHTS_FORM$2 = {
5966
5979
  AIRLINES: "Companhias aéreas",
5967
5980
  AIRPORTS: "Aeroportos",
5968
5981
  NUMBER_OF_STOPS: "Número de escalas",
5982
+ TRAVEL_CLASS: "Classe de viagem",
5969
5983
  FLIGHT_OUTWARD: "Voo de ida",
5970
5984
  DEPARTURE_TIME: "Hora de partida",
5971
5985
  TRAVEL_DURATION: "Duração da viagem",
@@ -6419,6 +6433,7 @@ var FLIGHTS_FORM$1 = {
6419
6433
  AIRLINES: "Flygbolag",
6420
6434
  AIRPORTS: "Flygplatser",
6421
6435
  NUMBER_OF_STOPS: "Antal mellanlandningar",
6436
+ TRAVEL_CLASS: "Reseklass",
6422
6437
  FLIGHT_OUTWARD: "Utresa",
6423
6438
  DEPARTURE_TIME: "Avgångstid",
6424
6439
  TRAVEL_DURATION: "Restid",
@@ -6872,6 +6887,7 @@ var FLIGHTS_FORM = {
6872
6887
  AIRLINES: "航空会社",
6873
6888
  AIRPORTS: "空港",
6874
6889
  NUMBER_OF_STOPS: "乗り継ぎ回数",
6890
+ TRAVEL_CLASS: "旅行クラス",
6875
6891
  FLIGHT_OUTWARD: "往路フライト",
6876
6892
  DEPARTURE_TIME: "出発時刻",
6877
6893
  TRAVEL_DURATION: "所要時間",
@@ -19995,6 +20011,7 @@ const buildFilterOptions = (outwardFlights, returnFlights, translations) => {
19995
20011
  const airports = [];
19996
20012
  const airlines = [];
19997
20013
  const numberOfStops = [];
20014
+ const travelClasses = [];
19998
20015
  const outwardDeparturePeriods = [];
19999
20016
  const returnDeparturePeriods = [];
20000
20017
  let lowestDepartureTravelDuration = 9999;
@@ -20013,6 +20030,14 @@ const buildFilterOptions = (outwardFlights, returnFlights, translations) => {
20013
20030
  isSelected: false
20014
20031
  });
20015
20032
  }
20033
+ if (firstLine.travelClass && !travelClasses.some((x) => x.value === firstLine.travelClass)) {
20034
+ travelClasses.push({
20035
+ value: firstLine.travelClass,
20036
+ label: firstLine.travelClass,
20037
+ count: 0,
20038
+ isSelected: false
20039
+ });
20040
+ }
20016
20041
  }
20017
20042
  if (!airlines.some((x) => x.value === airlineCode)) {
20018
20043
  airlines.push({
@@ -20086,6 +20111,7 @@ const buildFilterOptions = (outwardFlights, returnFlights, translations) => {
20086
20111
  airports: airports,
20087
20112
  airlines: airlines,
20088
20113
  numberOfStops: numberOfStops,
20114
+ travelClasses: travelClasses,
20089
20115
  outward: {
20090
20116
  departurePeriod: outwardDeparturePeriods,
20091
20117
  travelDuration: {
@@ -20134,6 +20160,10 @@ const filterGroupedFlights = (groups, filterOptions) => {
20134
20160
  const selectedNumberOfStops = filterOptions.numberOfStops.filter((x) => x.isSelected);
20135
20161
  filteredGroups = filteredGroups.filter((x) => selectedNumberOfStops.some((y) => parseInt(y.value) === x.outward.flightLines.length - 1));
20136
20162
  }
20163
+ if (filterOptions.travelClasses.some((x) => x.isSelected)) {
20164
+ const selectedTravelClasses = filterOptions.travelClasses.filter((x) => x.isSelected);
20165
+ filteredGroups = filteredGroups.filter((x) => selectedTravelClasses.some((y) => y.value === x.outward.travelClass));
20166
+ }
20137
20167
  filteredGroups = filterGroupedFlightByDirection(filteredGroups, true, filterOptions.outward);
20138
20168
  filteredGroups = filterGroupedFlightByDirection(filteredGroups, false, filterOptions.return);
20139
20169
  return filteredGroups;
@@ -20364,6 +20394,20 @@ const FlightFilter = ({ filterOptions, resultCount, applyFilter }) => {
20364
20394
  };
20365
20395
  applyFilter(updatedFilterOptions);
20366
20396
  };
20397
+ const updateTravelClassFilter = (value) => {
20398
+ const updatedFilterOptions = {
20399
+ ...filterOptions,
20400
+ travelClasses: filterOptions.travelClasses.map((x) => {
20401
+ if (x.value !== value)
20402
+ return x;
20403
+ return {
20404
+ ...x,
20405
+ isSelected: !x.isSelected
20406
+ };
20407
+ })
20408
+ };
20409
+ applyFilter(updatedFilterOptions);
20410
+ };
20367
20411
  const updateOutwardDeparture = (period) => {
20368
20412
  const updatedFilterOptions = {
20369
20413
  ...filterOptions,
@@ -20513,6 +20557,19 @@ const FlightFilter = ({ filterOptions, resultCount, applyFilter }) => {
20513
20557
  "(",
20514
20558
  option.count,
20515
20559
  ")"))))))))),
20560
+ React__default.createElement("div", { className: "flight__filter__group" },
20561
+ React__default.createElement("div", { className: "flight__filter__group__title" }, translations.FLIGHTS_FORM.TRAVEL_CLASS),
20562
+ React__default.createElement("div", { className: "flight__filter__group__wrapper" }, filterOptions.travelClasses.map((option, k) => (React__default.createElement("div", { className: "tree", key: k },
20563
+ React__default.createElement("div", { className: "checkbox flight__filter__checkbox" },
20564
+ React__default.createElement("label", { htmlFor: 'travel_class_' + option.value, className: "checkbox__label" },
20565
+ React__default.createElement("input", { type: "checkbox", id: 'travel_class_' + option.value, className: "checkbox__input checkbox__input--parent", onClick: () => updateTravelClassFilter(option.value) }),
20566
+ React__default.createElement("span", { className: "radiobutton__label-text" },
20567
+ option.label,
20568
+ " ",
20569
+ option.count > 0 && React__default.createElement("span", { className: "amount" },
20570
+ "(",
20571
+ option.count,
20572
+ ")"))))))))),
20516
20573
  React__default.createElement("div", { className: "flight__filter__group" },
20517
20574
  React__default.createElement("div", { className: "flight__filter__group__title" }, translations.FLIGHTS_FORM.FLIGHT_OUTWARD),
20518
20575
  React__default.createElement("div", { className: "flight__filter__group__wrapper" },
@@ -20741,7 +20798,7 @@ const FlightOption = ({ item, isSelected, currentPrice, onChange }) => {
20741
20798
  React__default.createElement("div", { className: "flight__flights" },
20742
20799
  React__default.createElement("div", { className: "flight__flight" },
20743
20800
  React__default.createElement("div", { className: "flight__flight__header" },
20744
- React__default.createElement("div", { className: "flight__status__container" }),
20801
+ React__default.createElement("div", { className: "flight__status__container" }, item.outward.travelClass && React__default.createElement("span", { className: "flight__status__badge" }, item.outward.travelClass)),
20745
20802
  React__default.createElement("div", { className: "flight__price" },
20746
20803
  !isSelected && (React__default.createElement("span", { className: buildClassName(['price', priceDifference > 0 && 'price--increase', priceDifference < 0 && 'price--decrease']) }, getPriceDifferenceText(priceDifference, currencyCode))),
20747
20804
  React__default.createElement("button", { type: "button", className: `cta ${isSelected ? 'cta--selected' : 'cta--select'}`, onClick: handleButtonClick }, isSelected ? translations.SHARED.SELECTED : translations.SHARED.SELECT)))),
@@ -22781,9 +22838,13 @@ const SummaryBookingOptionUnit = ({ unit }) => {
22781
22838
 
22782
22839
  const SummaryFlight = ({ flightMetaData, header }) => {
22783
22840
  const translations = useSelector(selectTranslations);
22841
+ const flightLines = parseFlightLines(flightMetaData);
22842
+ const travelClass = flightLines?.[0]?.travelClass;
22784
22843
  return (React__default.createElement("li", null,
22785
- React__default.createElement("h6", null, header),
22786
- parseFlightLines(flightMetaData)?.map((flightLine) => (React__default.createElement("p", { key: flightLine.departureAirportIata },
22844
+ React__default.createElement("h6", null,
22845
+ header,
22846
+ travelClass && ` - ${travelClass}`),
22847
+ flightLines?.map((flightLine) => (React__default.createElement("p", { key: flightLine.departureAirportIata },
22787
22848
  flightLine.departureAirportDescription,
22788
22849
  " (",
22789
22850
  flightLine.departureAirportIata,
@@ -22793,9 +22854,6 @@ const SummaryFlight = ({ flightMetaData, header }) => {
22793
22854
  flightLine.arrivalAirportIata,
22794
22855
  ") ",
22795
22856
  ' - ',
22796
- flightLine.travelClass,
22797
- " ",
22798
- ' - ',
22799
22857
  flightLine.airlineCode,
22800
22858
  flightLine.number,
22801
22859
  React__default.createElement("br", null),
@@ -32123,7 +32181,7 @@ const FlyIn = ({ srpType, isOpen, setIsOpen, className = '', onPanelRef, details
32123
32181
  dispatch(setBookPackagingEntry(true));
32124
32182
  }
32125
32183
  };
32126
- return (React__default.createElement("div", { className: `flyin ${isOpen ? 'flyin--active' : ''} ${className} ${isPackageEditFlow || flyInType === 'acco-results' || flyInType === 'traject-day-activities' ? 'flyin--large' : ''} ${flyInType === 'excursion-results' || flyInType === 'excursion-details' ? 'flyin--medium' : ''}
32184
+ return (React__default.createElement("div", { className: `flyin ${isOpen ? 'flyin--active' : ''} ${className} ${isPackageEditFlow || flyInType === 'acco-results' || flyInType === 'traject-day-activities' ? 'flyin--large' : ''} ${flyInType === 'excursion-results' || flyInType === 'excursion-details' ? 'flyin--medium' : ''}
32127
32185
  ${flyInType === 'flight-outward-results' || flyInType === 'flight-return-results' || flyInType === 'traject-flight-results' ? 'flyin--flight' : ''}` },
32128
32186
  React__default.createElement("div", { className: `flyin__panel ${isOpen ? 'flyin__panel--active' : ''}`, ref: panelRef },
32129
32187
  React__default.createElement("div", { className: "flyin__content" },
@@ -33716,20 +33774,20 @@ const buildFlightHtml = (line) => {
33716
33774
  */
33717
33775
  const buildFallbackHtml = (item, line) => {
33718
33776
  const details = [line?.accommodationName, line?.regimeName].filter(Boolean).join(' — ');
33719
- return `
33720
- <div class="itinerary-item__fallback">
33721
- <h3 class="itinerary-item__fallback-title">${escapeHtml(item.title)}</h3>
33722
- ${line ? buildFlightHtml(line) : ''}
33723
- ${details ? `<p class="itinerary-item__fallback-details">${escapeHtml(details)}</p>` : ''}
33724
- </div>
33777
+ return `
33778
+ <div class="itinerary-item__fallback">
33779
+ <h3 class="itinerary-item__fallback-title">${escapeHtml(item.title)}</h3>
33780
+ ${line ? buildFlightHtml(line) : ''}
33781
+ ${details ? `<p class="itinerary-item__fallback-details">${escapeHtml(details)}</p>` : ''}
33782
+ </div>
33725
33783
  `;
33726
33784
  };
33727
33785
  const buildItineraryHtml = (itinerary, translations, lines) => {
33728
33786
  if (!itinerary) {
33729
- return `
33730
- <div class="itinerary-shell">
33731
- <div class="itinerary-empty">Geen reisroute beschikbaar.</div>
33732
- </div>
33787
+ return `
33788
+ <div class="itinerary-shell">
33789
+ <div class="itinerary-empty">Geen reisroute beschikbaar.</div>
33790
+ </div>
33733
33791
  `;
33734
33792
  }
33735
33793
  const allNodes = itinerary.nodes ?? [];
@@ -33743,70 +33801,70 @@ const buildItineraryHtml = (itinerary, translations, lines) => {
33743
33801
  const hasAccommodationInCurrentNode = uniqueItems.some(isAccommodationItem);
33744
33802
  const activeAccommodation = findAccommodationForDay(allNodes, startDay);
33745
33803
  const accommodationBanner = !hasAccommodationInCurrentNode && activeAccommodation
33746
- ? `
33747
- <div class="itinerary-node__accommodation-banner">
33748
- Accommodatie voor deze dag: <strong>${escapeHtml(getAccommodationName(activeAccommodation))}</strong>
33749
- </div>
33804
+ ? `
33805
+ <div class="itinerary-node__accommodation-banner">
33806
+ Accommodatie voor deze dag: <strong>${escapeHtml(getAccommodationName(activeAccommodation))}</strong>
33807
+ </div>
33750
33808
  `
33751
33809
  : '';
33752
33810
  const itemsHtml = hasItems
33753
33811
  ? uniqueItems
33754
- .map((item) => `
33755
- <article class="itinerary-item" data-template="${escapeHtml(item.templateName)}">
33812
+ .map((item) => `
33813
+ <article class="itinerary-item" data-template="${escapeHtml(item.templateName)}">
33756
33814
  ${hasVisibleContent(item.contents)
33757
33815
  ? item.contents
33758
- : buildFallbackHtml(item, lines.find((line) => line.guid === item.itemGuid))}
33759
- </article>
33816
+ : buildFallbackHtml(item, lines.find((line) => line.guid === item.itemGuid))}
33817
+ </article>
33760
33818
  `)
33761
33819
  .join('')
33762
33820
  : `<div class="itinerary-node__empty">${translations.ITINERARY.NO_ITEMS}</div>`;
33763
- return `
33764
- <section class="itinerary-node">
33765
- <header class="itinerary-node__header">
33766
-
33767
- <div class="itinerary-node__day">
33768
- <p class="itinerary-node__day-day">${day}</p>
33769
- <p class="itinerary-node__day-month">${month}</p>
33770
- </div>
33771
-
33772
- <div>
33773
- <h2 class="itinerary-node__title">${escapeHtml(node.title)}</h2>
33774
- </div>
33775
- </header>
33776
-
33777
- <div class="itinerary-node__content">
33778
- ${accommodationBanner}
33779
- ${itemsHtml}
33780
- </div>
33781
- </section>
33821
+ return `
33822
+ <section class="itinerary-node">
33823
+ <header class="itinerary-node__header">
33824
+
33825
+ <div class="itinerary-node__day">
33826
+ <p class="itinerary-node__day-day">${day}</p>
33827
+ <p class="itinerary-node__day-month">${month}</p>
33828
+ </div>
33829
+
33830
+ <div>
33831
+ <h2 class="itinerary-node__title">${escapeHtml(node.title)}</h2>
33832
+ </div>
33833
+ </header>
33834
+
33835
+ <div class="itinerary-node__content">
33836
+ ${accommodationBanner}
33837
+ ${itemsHtml}
33838
+ </div>
33839
+ </section>
33782
33840
  `;
33783
33841
  })
33784
33842
  .join('');
33785
33843
  const defaultItemsHtml = itinerary.defaultItems && itinerary.defaultItems.length > 0
33786
- ? `
33787
- <section class="itinerary-default-items">
33788
- <h2 class="itinerary-default-items__title">Algemene info</h2>
33844
+ ? `
33845
+ <section class="itinerary-default-items">
33846
+ <h2 class="itinerary-default-items__title">Algemene info</h2>
33789
33847
  ${getUniqueItems(itinerary.defaultItems)
33790
- .map((item) => `
33791
- <article class="itinerary-item" data-template="${escapeHtml(item.templateName)}">
33848
+ .map((item) => `
33849
+ <article class="itinerary-item" data-template="${escapeHtml(item.templateName)}">
33792
33850
  ${hasVisibleContent(item.contents)
33793
33851
  ? item.contents
33794
- : buildFallbackHtml(item, lines.find((line) => line.guid === item.itemGuid))}
33795
- </article>
33852
+ : buildFallbackHtml(item, lines.find((line) => line.guid === item.itemGuid))}
33853
+ </article>
33796
33854
  `)
33797
- .join('')}
33798
- </section>
33855
+ .join('')}
33856
+ </section>
33799
33857
  `
33800
33858
  : '';
33801
- return `
33802
- <div class="itinerary-shell">
33803
- ${itinerary.title ? `<header class="itinerary-shell__header"><h1 class="itinerary-shell__title">${escapeHtml(itinerary.title)}</h1></header>` : ''}
33804
-
33805
- <div class="itinerary-shell__content">
33806
- ${nodesHtml}
33807
- ${defaultItemsHtml}
33808
- </div>
33809
- </div>
33859
+ return `
33860
+ <div class="itinerary-shell">
33861
+ ${itinerary.title ? `<header class="itinerary-shell__header"><h1 class="itinerary-shell__title">${escapeHtml(itinerary.title)}</h1></header>` : ''}
33862
+
33863
+ <div class="itinerary-shell__content">
33864
+ ${nodesHtml}
33865
+ ${defaultItemsHtml}
33866
+ </div>
33867
+ </div>
33810
33868
  `;
33811
33869
  };
33812
33870
  const FullItinerary = ({ isLoading }) => {
@@ -33828,170 +33886,170 @@ const FullItinerary = ({ isLoading }) => {
33828
33886
  }
33829
33887
  const shadowRoot = host.shadowRoot ?? host.attachShadow({ mode: 'open' });
33830
33888
  shadowRootRef.current = shadowRoot;
33831
- shadowRoot.innerHTML = `
33832
- <style>
33833
- :host {
33834
- all: initial;
33835
- display: block;
33836
- width: 100%;
33837
- }
33838
-
33839
- *,
33840
- *::before,
33841
- *::after {
33842
- box-sizing: border-box;
33843
- }
33844
-
33845
- .itinerary-shell {
33846
- width: 100%;
33847
- margin: 0 auto;
33848
- font-family: 'Outfit', sans-serif;
33849
- color: #222;
33850
- }
33851
-
33852
- .itinerary-shell__header {
33853
- margin-bottom: 24px;
33854
- }
33855
-
33856
- .itinerary-shell__title {
33857
- margin: 0;
33858
- font-size: 32px;
33859
- line-height: 1.2;
33860
- }
33861
-
33862
- .itinerary-shell__content {
33863
- display: grid;
33864
- gap: 24px;
33865
- }
33866
-
33867
- .itinerary-node {
33868
- border: 1px solid #e5e7eb;
33869
- border-radius: 16px;
33870
- overflow: hidden;
33871
- background: #fff;
33872
- box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
33873
- }
33874
-
33875
- .itinerary-node__header {
33876
- display: flex;
33877
- gap: 16px;
33878
- align-items: center;
33879
- border-bottom: 1px solid #eef0f2;
33880
- background: #fafafa;
33881
- }
33882
-
33883
- .itinerary-node__day {
33884
- flex: 50px 0 0;
33885
- display: flex;
33886
- flex-flow: column;
33887
- align-items: center;
33888
- justify-content: center;
33889
- background: #1f9470;
33890
- color: white;
33891
- border: 1.5px solid var(--tide-booking-color-secondary);
33892
- }
33893
-
33894
- .itinerary-node__day-month {
33895
- margin: 0px;
33896
- }
33897
-
33898
- .itinerary-node__day-day {
33899
- margin: 0px;
33900
- font-weight: var(--tide-booking-search-results-label-date-month-font-weight);
33901
- color: var(--tide-booking-search-results-label-date-month-color);
33902
- font-size: 24px;
33903
- }
33904
-
33905
- .itinerary-node__title {
33906
- margin: 0;
33907
- font-size: 22px;
33908
- line-height: 1.25;
33909
- }
33910
-
33911
- .itinerary-node__content {
33912
- display: grid;
33913
- gap: 20px;
33914
- padding: 20px;
33915
- }
33916
-
33917
- .itinerary-node__accommodation-banner {
33918
- padding: 12px 16px;
33919
- border: 1px solid #dbeafe;
33920
- border-radius: 12px;
33921
- background: #eff6ff;
33922
- color: #1e3a8a;
33923
- font-size: 14px;
33924
- line-height: 1.4;
33925
- }
33926
-
33927
- .itinerary-item {
33928
- display: block;
33929
- border-radius: 12px;
33930
- overflow: hidden;
33931
- background: #fff;
33932
- }
33933
-
33934
- /* An item whose template has no content view of its own still has to read as a service. */
33935
- .itinerary-item__fallback {
33936
- padding: 16px 20px;
33937
- border: 1px solid #e5e7eb;
33938
- border-radius: 12px;
33939
- }
33940
-
33941
- .itinerary-item__fallback-title {
33942
- margin: 0;
33943
- font-size: 16px;
33944
- font-weight: 600;
33945
- color: #111827;
33946
- }
33947
-
33948
- .itinerary-item__legs {
33949
- margin: 8px 0 0;
33950
- padding-left: 18px;
33951
- color: #374151;
33952
- }
33953
-
33954
- .itinerary-item__legs li + li {
33955
- margin-top: 4px;
33956
- }
33957
-
33958
- .itinerary-item__fallback-details {
33959
- margin: 8px 0 0;
33960
- color: #6b7280;
33961
- }
33962
-
33963
- .itinerary-node__empty,
33964
- .itinerary-empty {
33965
- padding: 20px;
33966
- border: 1px dashed #d1d5db;
33967
- border-radius: 12px;
33968
- color: #6b7280;
33969
- background: #fafafa;
33970
- }
33971
-
33972
- .itinerary-default-items {
33973
- border: 1px solid #e5e7eb;
33974
- border-radius: 16px;
33975
- padding: 20px;
33976
- background: #fff;
33977
- box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
33978
- }
33979
-
33980
- .itinerary-default-items__title {
33981
- margin: 0 0 16px;
33982
- font-size: 22px;
33983
- }
33984
-
33985
- @media (max-width: 768px) {
33986
- .itinerary-shell {
33987
- padding: 16px;
33988
- }
33989
- }
33990
-
33991
- ${itinerary?.styleSheetBody ?? ''}
33992
- </style>
33993
-
33994
- ${html}
33889
+ shadowRoot.innerHTML = `
33890
+ <style>
33891
+ :host {
33892
+ all: initial;
33893
+ display: block;
33894
+ width: 100%;
33895
+ }
33896
+
33897
+ *,
33898
+ *::before,
33899
+ *::after {
33900
+ box-sizing: border-box;
33901
+ }
33902
+
33903
+ .itinerary-shell {
33904
+ width: 100%;
33905
+ margin: 0 auto;
33906
+ font-family: 'Outfit', sans-serif;
33907
+ color: #222;
33908
+ }
33909
+
33910
+ .itinerary-shell__header {
33911
+ margin-bottom: 24px;
33912
+ }
33913
+
33914
+ .itinerary-shell__title {
33915
+ margin: 0;
33916
+ font-size: 32px;
33917
+ line-height: 1.2;
33918
+ }
33919
+
33920
+ .itinerary-shell__content {
33921
+ display: grid;
33922
+ gap: 24px;
33923
+ }
33924
+
33925
+ .itinerary-node {
33926
+ border: 1px solid #e5e7eb;
33927
+ border-radius: 16px;
33928
+ overflow: hidden;
33929
+ background: #fff;
33930
+ box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
33931
+ }
33932
+
33933
+ .itinerary-node__header {
33934
+ display: flex;
33935
+ gap: 16px;
33936
+ align-items: center;
33937
+ border-bottom: 1px solid #eef0f2;
33938
+ background: #fafafa;
33939
+ }
33940
+
33941
+ .itinerary-node__day {
33942
+ flex: 50px 0 0;
33943
+ display: flex;
33944
+ flex-flow: column;
33945
+ align-items: center;
33946
+ justify-content: center;
33947
+ background: #1f9470;
33948
+ color: white;
33949
+ border: 1.5px solid var(--tide-booking-color-secondary);
33950
+ }
33951
+
33952
+ .itinerary-node__day-month {
33953
+ margin: 0px;
33954
+ }
33955
+
33956
+ .itinerary-node__day-day {
33957
+ margin: 0px;
33958
+ font-weight: var(--tide-booking-search-results-label-date-month-font-weight);
33959
+ color: var(--tide-booking-search-results-label-date-month-color);
33960
+ font-size: 24px;
33961
+ }
33962
+
33963
+ .itinerary-node__title {
33964
+ margin: 0;
33965
+ font-size: 22px;
33966
+ line-height: 1.25;
33967
+ }
33968
+
33969
+ .itinerary-node__content {
33970
+ display: grid;
33971
+ gap: 20px;
33972
+ padding: 20px;
33973
+ }
33974
+
33975
+ .itinerary-node__accommodation-banner {
33976
+ padding: 12px 16px;
33977
+ border: 1px solid #dbeafe;
33978
+ border-radius: 12px;
33979
+ background: #eff6ff;
33980
+ color: #1e3a8a;
33981
+ font-size: 14px;
33982
+ line-height: 1.4;
33983
+ }
33984
+
33985
+ .itinerary-item {
33986
+ display: block;
33987
+ border-radius: 12px;
33988
+ overflow: hidden;
33989
+ background: #fff;
33990
+ }
33991
+
33992
+ /* An item whose template has no content view of its own still has to read as a service. */
33993
+ .itinerary-item__fallback {
33994
+ padding: 16px 20px;
33995
+ border: 1px solid #e5e7eb;
33996
+ border-radius: 12px;
33997
+ }
33998
+
33999
+ .itinerary-item__fallback-title {
34000
+ margin: 0;
34001
+ font-size: 16px;
34002
+ font-weight: 600;
34003
+ color: #111827;
34004
+ }
34005
+
34006
+ .itinerary-item__legs {
34007
+ margin: 8px 0 0;
34008
+ padding-left: 18px;
34009
+ color: #374151;
34010
+ }
34011
+
34012
+ .itinerary-item__legs li + li {
34013
+ margin-top: 4px;
34014
+ }
34015
+
34016
+ .itinerary-item__fallback-details {
34017
+ margin: 8px 0 0;
34018
+ color: #6b7280;
34019
+ }
34020
+
34021
+ .itinerary-node__empty,
34022
+ .itinerary-empty {
34023
+ padding: 20px;
34024
+ border: 1px dashed #d1d5db;
34025
+ border-radius: 12px;
34026
+ color: #6b7280;
34027
+ background: #fafafa;
34028
+ }
34029
+
34030
+ .itinerary-default-items {
34031
+ border: 1px solid #e5e7eb;
34032
+ border-radius: 16px;
34033
+ padding: 20px;
34034
+ background: #fff;
34035
+ box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
34036
+ }
34037
+
34038
+ .itinerary-default-items__title {
34039
+ margin: 0 0 16px;
34040
+ font-size: 22px;
34041
+ }
34042
+
34043
+ @media (max-width: 768px) {
34044
+ .itinerary-shell {
34045
+ padding: 16px;
34046
+ }
34047
+ }
34048
+
34049
+ ${itinerary?.styleSheetBody ?? ''}
34050
+ </style>
34051
+
34052
+ ${html}
33995
34053
  `;
33996
34054
  }, [html, itinerary?.styleSheetBody, isLoading]);
33997
34055
  return (React__default.createElement(React__default.Fragment, null,