feat: css and syntax changes

This commit is contained in:
Fredrik Thorsson
2024-08-06 09:44:45 +02:00
parent d88de5424b
commit c7bef7d1cf
5 changed files with 10 additions and 13 deletions

View File

@@ -1,7 +1,7 @@
.main {
display: grid;
grid-template-columns: repeat(3, minmax(min-content, max-content));
padding: 32px 32px 0px 32px;
grid-template-columns: repeat(3, auto);
padding: var(--Spacing-x4) var(--Spacing-x4) 0 var(--Spacing-x4);
height: 100dvh;
background-color: var(--Scandic-Brand-Warm-White);
}

View File

@@ -16,13 +16,13 @@ export default async function SelectHotelPage({
})
const hotels = [attributes]
const hotelFitlers = await serverClient().hotel.getFilters({
const hotelFilters = await serverClient().hotel.getFilters({
hotelId: "d98c7ab1-ebaa-4102-b351-758daf1ddf55",
})
return (
<main className={styles.main}>
<HotelFilter filter={hotelFitlers} />
<HotelFilter filter={hotelFilters} />
<section className={styles.section}>
{hotels.map((hotel) => (
<HotelCard key={hotel.name} hotel={hotel} />

View File

@@ -3,7 +3,6 @@
}
.facilities {
flex-direction: column;
font-family: var(--typography-Body-Bold-fontFamily);
margin-bottom: var(--Spacing-x3);
}

View File

@@ -1,5 +1,3 @@
import { serverClient } from "@/lib/trpc/server"
import { getIntl } from "@/i18n"
import styles from "./hotelFilter.module.css"

View File

@@ -468,7 +468,7 @@ export const getHotelDataSchema = z.object({
included: z.array(RoomSchema).optional(),
})
const Rate = z.object({
const rate = z.object({
id: z.number(),
name: z.string(),
description: z.string(),
@@ -478,11 +478,11 @@ const Rate = z.object({
imageSrc: z.string(),
})
export const getRatesSchema = z.array(Rate)
export const getRatesSchema = z.array(rate)
export type Rate = z.infer<typeof Rate>
export type Rate = z.infer<typeof rate>
const HotelFilter = z.object({
const hotelFilter = z.object({
filter: z.object({
roomFacilities: z.array(z.string()),
hotelFacilities: z.array(z.string()),
@@ -490,5 +490,5 @@ const HotelFilter = z.object({
}),
})
export const getFiltersSchema = z.array(HotelFilter)
export type HotelFilter = z.infer<typeof HotelFilter>
export const getFiltersSchema = z.array(hotelFilter)
export type HotelFilter = z.infer<typeof hotelFilter>