diff --git a/app/[lang]/(live)/(public)/hotelreservation/select-rate/page.tsx b/app/[lang]/(live)/(public)/hotelreservation/select-rate/page.tsx index a9103d2c4..532228434 100644 --- a/app/[lang]/(live)/(public)/hotelreservation/select-rate/page.tsx +++ b/app/[lang]/(live)/(public)/hotelreservation/select-rate/page.tsx @@ -1,6 +1,7 @@ import { getProfileSafely } from "@/lib/trpc/memoizedRequests" import { serverClient } from "@/lib/trpc/server" +import HotelInfoCard from "@/components/HotelReservation/SelectRate/HotelInfoCard" import RoomSelection from "@/components/HotelReservation/SelectRate/RoomSelection" import getHotelReservationQueryParams from "@/components/HotelReservation/SelectRate/RoomSelection/utils" import { setLang } from "@/i18n/serverContext" @@ -50,9 +51,8 @@ export default async function SelectRatePage({ return (
+
- {/* TODO: Add Hotel Listing Card */} -
Hotel Listing Card TBI
- +
diff --git a/components/HotelReservation/ReadMore/index.tsx b/components/HotelReservation/ReadMore/index.tsx index 5814eae54..c8d39fcbe 100644 --- a/components/HotelReservation/ReadMore/index.tsx +++ b/components/HotelReservation/ReadMore/index.tsx @@ -34,7 +34,7 @@ function getAmenitiesList(hotel: Hotel) { return [...detailedAmenities, ...simpleAmenities] } -export default function ReadMore({ hotel, hotelId }: ReadMoreProps) { +export default function ReadMore({ label, hotel, hotelId }: ReadMoreProps) { const intl = useIntl() const [sidePeekOpen, setSidePeekOpen] = useState(false) @@ -46,11 +46,12 @@ export default function ReadMore({ hotel, hotelId }: ReadMoreProps) { onPress={() => { setSidePeekOpen(true) }} - intent={"text"} - color="burgundy" + intent="text" + theme="base" + wrapping className={styles.detailsButton} > - {intl.formatMessage({ id: "See hotel details" })} + {label} b.sortOrder - a.sortOrder) + .slice(0, 5) + + return ( +
+ {hotelAttributes && ( +
+
+ {hotelAttributes.hotelContent.images.metaData.altText} + {hotelAttributes.ratings?.tripAdvisor && ( +
+ + + {hotelAttributes.ratings.tripAdvisor.rating} + +
+ )} + {/* TODO: gallery icon and image carousel */} +
+
+
+ + {hotelAttributes.name} + + + {`${hotelAttributes.address.streetAddress}, ${hotelAttributes.address.city} ∙ ${hotelAttributes.location.distanceToCentre} ${intl.formatMessage({ id: "km to city center" })}`} + + + {hotelAttributes.hotelContent.texts.descriptions.medium} + +
+ +
+
+ + {intl.formatMessage({ id: "At the hotel" })} + + {sortedFacilities?.map((facility) => { + const IconComponent = mapFacilityToIcon(facility.name) + return ( +
+ {IconComponent && ( + + )} + + {facility.name} + +
+ ) + })} +
+ +
+
+
+ )} +
+ ) +} diff --git a/types/components/hotelReservation/selectHotel/selectHotel.ts b/types/components/hotelReservation/selectHotel/selectHotel.ts index 6d1cecfca..b43779714 100644 --- a/types/components/hotelReservation/selectHotel/selectHotel.ts +++ b/types/components/hotelReservation/selectHotel/selectHotel.ts @@ -12,6 +12,7 @@ export interface DetailedAmenity { } export interface ReadMoreProps { + label: string hotelId: string hotel: Hotel } diff --git a/types/components/hotelReservation/selectRate/hotelInfoCardProps.ts b/types/components/hotelReservation/selectRate/hotelInfoCardProps.ts new file mode 100644 index 000000000..0a3526167 --- /dev/null +++ b/types/components/hotelReservation/selectRate/hotelInfoCardProps.ts @@ -0,0 +1,5 @@ +import type { HotelData } from "@/types/hotel" + +export type HotelInfoCardProps = { + hotelData: HotelData | null +}