import MyStay from "@/components/HotelReservation/MyStay"
import { setLang } from "@/i18n/serverContext"

import Tracking from "./tracking"

import type { LangParams, PageArgs } from "@/types/params"

export default async function MyStayPage(
  props: PageArgs<LangParams, { RefId?: string }>
) {
  const searchParams = await props.searchParams
  const params = await props.params
  setLang(params.lang)
  const refId = searchParams.RefId

  return (
    <>
      <MyStay refId={refId} lang={params.lang} />
      <Tracking />
    </>
  )
}
