feat(SW-1012): remove title components
This commit is contained in:
@@ -51,13 +51,18 @@ export default async function OpeningHours({
|
||||
})
|
||||
|
||||
function formatDayInterval(days: string[]) {
|
||||
if (days.length === 1) return days[0]
|
||||
return `${days[0]}-${days[days.length - 1]}`
|
||||
if (days.length === 1) {
|
||||
return days[0]
|
||||
} else {
|
||||
return `${days[0]}-${days[days.length - 1]}`
|
||||
}
|
||||
}
|
||||
|
||||
return (
|
||||
<div className={styles.wrapper}>
|
||||
<Body textTransform="bold">{openingHours.name}</Body>
|
||||
<Body textTransform="bold" asChild>
|
||||
<h5>{openingHours.name}</h5>
|
||||
</Body>
|
||||
{Object.entries(groupedOpeningHours).map(([time, days]) => {
|
||||
return (
|
||||
<Body color="uiTextHighContrast" key={time}>
|
||||
|
||||
@@ -1,9 +1,10 @@
|
||||
import NextLink from "next/link"
|
||||
|
||||
import { OpenInNewSmallIcon } from "@/components/Icons"
|
||||
import Image from "@/components/Image"
|
||||
import Button from "@/components/TempDesignSystem/Button"
|
||||
import Link from "@/components/TempDesignSystem/Link"
|
||||
import Subtitle from "@/components/TempDesignSystem/Text/Subtitle"
|
||||
import Title from "@/components/TempDesignSystem/Text/Title"
|
||||
import { getIntl } from "@/i18n"
|
||||
|
||||
import OpeningHours from "../OpeningHours"
|
||||
@@ -28,7 +29,7 @@ export default async function RestaurantBarItem({
|
||||
<div className={styles.restaurantBarItem}>
|
||||
<div className={styles.stickyHeading}>
|
||||
<Subtitle type="one" color="burgundy" asChild>
|
||||
<Title level="h3">{name}</Title>
|
||||
<h3>{name}</h3>
|
||||
</Subtitle>
|
||||
</div>
|
||||
{visibleImages.length ? (
|
||||
@@ -48,9 +49,7 @@ export default async function RestaurantBarItem({
|
||||
{openingDetails.length ? (
|
||||
<div className={styles.content}>
|
||||
<Subtitle type="two" asChild>
|
||||
<Title level="h4">
|
||||
{intl.formatMessage({ id: "Opening Hours" })}
|
||||
</Title>
|
||||
<h4>{intl.formatMessage({ id: "Opening Hours" })}</h4>
|
||||
</Subtitle>
|
||||
{openingDetails.map((details) => (
|
||||
<OpeningHours
|
||||
@@ -64,7 +63,7 @@ export default async function RestaurantBarItem({
|
||||
{menus.length ? (
|
||||
<div className={styles.content}>
|
||||
<Subtitle type="two" asChild>
|
||||
<Title level="h4">{intl.formatMessage({ id: "Menus" })}</Title>
|
||||
<h4>{intl.formatMessage({ id: "Menus" })}</h4>
|
||||
</Subtitle>
|
||||
<ul className={styles.menuList}>
|
||||
{menus.map(({ name, url }) => (
|
||||
@@ -88,21 +87,16 @@ export default async function RestaurantBarItem({
|
||||
<div className={styles.ctaWrapper}>
|
||||
{bookTableUrl ? (
|
||||
<Button fullWidth theme="base" intent="primary" asChild>
|
||||
<Link
|
||||
href={bookTableUrl}
|
||||
color="white"
|
||||
weight="bold"
|
||||
target="_blank"
|
||||
>
|
||||
<NextLink href={bookTableUrl} target="_blank">
|
||||
{intl.formatMessage({ id: "Book a table online" })}
|
||||
</Link>
|
||||
</NextLink>
|
||||
</Button>
|
||||
) : null}
|
||||
{ctaUrl ? (
|
||||
<Button fullWidth theme="base" intent="secondary" asChild>
|
||||
<Link href={ctaUrl} color="burgundy" weight="bold">
|
||||
<NextLink href={ctaUrl}>
|
||||
{`${intl.formatMessage({ id: "Discover" })} ${name}`}
|
||||
</Link>
|
||||
</NextLink>
|
||||
</Button>
|
||||
) : null}
|
||||
</div>
|
||||
|
||||
@@ -51,10 +51,6 @@ export const getHotelDataInputSchema = z.object({
|
||||
isCardOnlyPayment: z.boolean().optional(),
|
||||
})
|
||||
|
||||
export const getRestaurantsInputSchema = z.object({
|
||||
hotelId: z.string(),
|
||||
})
|
||||
|
||||
export type HotelDataInput = z.input<typeof getHotelDataInputSchema>
|
||||
|
||||
export const getBreakfastPackageInputSchema = z.object({
|
||||
|
||||
@@ -51,14 +51,6 @@ const getHotelCounter = meter.createCounter("trpc.hotel.get")
|
||||
const getHotelSuccessCounter = meter.createCounter("trpc.hotel.get-success")
|
||||
const getHotelFailCounter = meter.createCounter("trpc.hotel.get-fail")
|
||||
|
||||
const getRestaurantsCounter = meter.createCounter("trpc.hotel.restaurants.get")
|
||||
const getRestaurantsSuccessCounter = meter.createCounter(
|
||||
"trpc.hotel.restaurants.get-success"
|
||||
)
|
||||
const getRestaurantsFailCounter = meter.createCounter(
|
||||
"trpc.hotel.restaurants.get-fail"
|
||||
)
|
||||
|
||||
const getPackagesCounter = meter.createCounter("trpc.hotel.packages.get")
|
||||
const getPackagesSuccessCounter = meter.createCounter(
|
||||
"trpc.hotel.packages.get-success"
|
||||
|
||||
Reference in New Issue
Block a user