feat: remove guest amount information
This commit is contained in:
@@ -1,9 +1,6 @@
|
||||
"use client"
|
||||
import { useIntl } from "react-intl"
|
||||
|
||||
import { dt } from "@/lib/dt"
|
||||
|
||||
import { CalendarIcon, PersonIcon } from "@/components/Icons"
|
||||
import { CalendarIcon } from "@/components/Icons"
|
||||
import Image from "@/components/Image"
|
||||
import Caption from "@/components/TempDesignSystem/Text/Caption"
|
||||
import Title from "@/components/TempDesignSystem/Text/Title"
|
||||
@@ -14,7 +11,6 @@ import type { StayCardProps } from "@/types/components/myPages/stays/stayCard"
|
||||
|
||||
export default function StayCard({ stay, lang }: StayCardProps) {
|
||||
const { checkinDate, checkoutDate, hotelInformation } = stay.attributes
|
||||
const { formatMessage } = useIntl()
|
||||
const arrival = dt(checkinDate).locale(lang)
|
||||
const arrivalDate = arrival.format("DD MMM")
|
||||
const arrivalDateTime = arrival.format("YYYY-MM-DD")
|
||||
@@ -22,8 +18,6 @@ export default function StayCard({ stay, lang }: StayCardProps) {
|
||||
const departDate = depart.format("DD MMM YYYY")
|
||||
const departDateTime = depart.format("YYYY-MM-DD")
|
||||
|
||||
const tempGuestAmount = 3
|
||||
|
||||
return (
|
||||
<article className={styles.stay}>
|
||||
<Image
|
||||
@@ -37,21 +31,16 @@ export default function StayCard({ stay, lang }: StayCardProps) {
|
||||
<Title as="h5" className={styles.hotel} level="h3">
|
||||
{hotelInformation.hotelName}
|
||||
</Title>
|
||||
<div className={styles.information}>
|
||||
<div className={styles.date}>
|
||||
<CalendarIcon color="burgundy" className={styles.icon} />
|
||||
<Caption asChild>
|
||||
<time dateTime={arrivalDateTime}>{arrivalDate}</time>
|
||||
</Caption>
|
||||
{" - "}
|
||||
<Caption asChild>
|
||||
<time dateTime={departDateTime}>{departDate}</time>
|
||||
</Caption>
|
||||
</div>
|
||||
<div className={styles.guest}>
|
||||
<PersonIcon color="burgundy" className={styles.icon} />
|
||||
<Caption>{`${tempGuestAmount} ${tempGuestAmount > 1 ? formatMessage({ id: "Guests" }) : formatMessage({ id: "Guest" })}`}</Caption>
|
||||
</div>
|
||||
|
||||
<div className={styles.date}>
|
||||
<CalendarIcon color="burgundy" className={styles.icon} />
|
||||
<Caption asChild>
|
||||
<time dateTime={arrivalDateTime}>{arrivalDate}</time>
|
||||
</Caption>
|
||||
{" - "}
|
||||
<Caption asChild>
|
||||
<time dateTime={departDateTime}>{departDate}</time>
|
||||
</Caption>
|
||||
</div>
|
||||
</footer>
|
||||
</article>
|
||||
|
||||
@@ -32,13 +32,7 @@
|
||||
text-wrap: nowrap;
|
||||
}
|
||||
|
||||
.information {
|
||||
display: flex;
|
||||
gap: var(--Spacing-x2);
|
||||
}
|
||||
|
||||
.date,
|
||||
.guest {
|
||||
.date {
|
||||
align-items: center;
|
||||
display: flex;
|
||||
gap: var(--Spacing-x-half);
|
||||
|
||||
Reference in New Issue
Block a user