fix: Add translations for show all amenities text
This commit is contained in:
@@ -3,16 +3,18 @@ import { ChevronRightIcon } from "@/components/Icons"
|
||||
import Button from "@/components/TempDesignSystem/Button"
|
||||
import Body from "@/components/TempDesignSystem/Text/Body"
|
||||
import Subtitle from "@/components/TempDesignSystem/Text/Subtitle"
|
||||
import { getIntl } from "@/i18n"
|
||||
|
||||
import styles from "./amenitiesList.module.css"
|
||||
|
||||
import { HotelData } from "@/types/hotel"
|
||||
|
||||
export default function AmenitiesList({
|
||||
export default async function AmenitiesList({
|
||||
detailedFacilities,
|
||||
}: {
|
||||
detailedFacilities: HotelData["data"]["attributes"]["detailedFacilities"]
|
||||
}) {
|
||||
const { formatMessage } = await getIntl()
|
||||
const sortedAmenities = detailedFacilities
|
||||
.sort((a, b) => b.sortOrder - a.sortOrder)
|
||||
.slice(0, 5)
|
||||
@@ -31,13 +33,14 @@ export default function AmenitiesList({
|
||||
)
|
||||
})}
|
||||
</div>
|
||||
{/*TODO: This should open a side peek. Add once the Side Peek component has been merged. */}
|
||||
<Button
|
||||
className={styles.showAllButton}
|
||||
theme="base"
|
||||
variant="icon"
|
||||
intent="text"
|
||||
>
|
||||
Show all amenities
|
||||
{formatMessage({ id: "Show all amenities" })}
|
||||
<ChevronRightIcon />
|
||||
</Button>
|
||||
</section>
|
||||
|
||||
Reference in New Issue
Block a user