import Header from "@/components/Current/Header"
import { setLang } from "@/i18n/serverContext"

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

export default function HeaderLayout({
  languageSwitcher,
  myPagesMobileDropdown,
  params,
}: LayoutArgs<LangParams> & {
  languageSwitcher: React.ReactNode
  myPagesMobileDropdown: React.ReactNode
}) {
  setLang(params.lang)
  return (
    <Header
      myPagesMobileDropdown={myPagesMobileDropdown}
      languageSwitcher={languageSwitcher}
    />
  )
}
