chore: add load more functionality, with refactored css

This commit is contained in:
Matilda Landström
2024-04-26 10:51:05 +02:00
parent 204f0f45ce
commit 7480b212e2
31 changed files with 326 additions and 169 deletions

View File

@@ -1,5 +1,7 @@
import { UUID } from "crypto"
export type Stay = {
uid: string
uid: UUID
dateArrive: Date
dateDepart: Date
guests: number

View File

@@ -0,0 +1,4 @@
export type ShowMoreButtonParams = {
loadMoreData: () => void
disabled: boolean
}

View File

@@ -0,0 +1,6 @@
import type { Stay } from "../myPage/stay"
export type Page = {
data: Stay[]
nextCursor?: number
}

View File

@@ -0,0 +1,8 @@
import type { Lang } from "@/constants/languages"
import type { Stay } from "../myPage/stay"
export type StayCardProps = {
lang: Lang
shouldShowDayCount?: boolean
stay: Stay
}

View File

@@ -0,0 +1,7 @@
import type { Lang } from "@/constants/languages"
import type { Stay } from "../myPage/stay"
export type StayListProps = {
stays: Stay[]
lang: Lang
}

View File

@@ -1,8 +0,0 @@
import { Stay } from "../myPage/stay"
import { Lang } from "@/constants/languages"
export type StayCardProps = {
lang: Lang
showDayCount?: boolean
stay: Stay
}

View File

@@ -1,7 +0,0 @@
import { Lang } from "@/constants/languages"
import { Stay } from "../myPage/stay"
export type StayListProps = {
stays: Stay[]
lang: Lang
}