Merged in feat/SW-1454-listing-skeletons (pull request #1301)

Feat/SW-1454 listing skeletons

* feat(SW-1453): added skeleton for city listning

* feat(SW-1454): added skeleton for hotel listning


Approved-by: Fredrik Thorsson
This commit is contained in:
Erik Tiekstra
2025-02-11 12:05:44 +00:00
parent 967c776ab8
commit ff820d1f31
17 changed files with 325 additions and 135 deletions

View File

@@ -2,6 +2,7 @@ import { cache } from "@/utils/cache"
import { serverClient } from "../server"
import type { Country } from "@/types/enums/country"
import type {
BreackfastPackagesInput,
PackagesInput,
@@ -198,11 +199,27 @@ export const getDestinationCountryPage = cache(
return serverClient().contentstack.destinationCountryPage.get()
}
)
export const getDestinationCityPagesByCountry = cache(
async function getMemoizedDestinationCityPagesByCountry(country: Country) {
return serverClient().contentstack.destinationCountryPage.cityPages({
country,
})
}
)
export const getDestinationCityPage = cache(
async function getMemoizedDestinationCityPage() {
return serverClient().contentstack.destinationCityPage.get()
}
)
export const getHotelListDataByCityIdentifier = cache(
async function getMemoizedHotelListDataByCityIdentifier(
cityIdentifier: string
) {
return serverClient().contentstack.destinationCityPage.hotelList({
cityIdentifier,
})
}
)
export const getStartPage = cache(async function getMemoizedStartPage() {
return serverClient().contentstack.startPage.get()