{"version":3,"file":"static/chunks/pages/_error-59f49aec31beb095.js","mappings":"2HAEO,IAAMA,EAAgB,IAAMC,CAAAA,EAAAA,EAAAA,EAAAA,CAAGA,CAAC,UAAW,kBAAkB,iBCDpE,4CACA,UACA,WACA,OAAe,EAAQ,KAA+B,CACtD,EACA,SAFsB,kICQP,SAASC,EAAgB,YAAEC,CAAU,CAAS,EAC3D,GAAM,GAAEC,CAAC,CAAE,CAAGC,CAAAA,EAAAA,EAAAA,EAAAA,CAAcA,CAAC,uBAG7B,MACE,iCACE,UAACC,EAAAA,CAAUA,CAAAA,CACTC,UAAWH,EALY,MAAfD,EAAqB,gBAAkB,iBAM/CK,kBAAkB,EAClBC,iBAAiB,EACjBC,WAAYV,CAAAA,EAAAA,EAAAA,CAAAA,CAAaA,KAE3B,UAACW,EAAAA,EAASA,CAAAA,CAACR,WAAY,GAAGA,EAAAA,CAAY,KAG5C","sources":["webpack://_N_E/./utils/constants.ts","webpack://_N_E/?adae","webpack://_N_E/./pages/_error.tsx"],"sourcesContent":["import { env } from '@dx-ui/framework-env';\n\nexport const getAppVersion = () => env('APP_VER', 'dx-brands-ui:0');\n","\n    (window.__NEXT_P = window.__NEXT_P || []).push([\n      \"/_error\",\n      function () {\n        return require(\"private-next-pages/_error.tsx\");\n      }\n    ]);\n    if(module.hot) {\n      module.hot.dispose(function () {\n        window.__NEXT_P.push([\"/_error\"])\n      });\n    }\n  ","import type { GetServerSideProps } from 'next';\nimport { serverSideTranslations } from 'next-i18next/serverSideTranslations';\nimport nextI18nextConfig from '../next-i18next.config';\nimport { useTranslation } from 'next-i18next';\nimport { Error as ErrorPage } from '@dx-ui/cpm-mapping-brands';\nimport { CustomHead } from '@dx-ui/osc-marketing-layout';\nimport { getAppVersion } from '../utils/constants';\n\ntype Props = {\n  statusCode: 404 | 500;\n};\n\nexport default function CustomErrorPage({ statusCode }: Props) {\n  const { t } = useTranslation('osc-marketing-error');\n  const title = statusCode === 404 ? '404.pageTitle' : '500.pageTitle';\n\n  return (\n    <>\n      <CustomHead\n        pageTitle={t(title)}\n        hideSearchEngine={true}\n        isBrandHomePage={false}\n        appVersion={getAppVersion()}\n      />\n      <ErrorPage statusCode={`${statusCode}`} />\n    </>\n  );\n}\n\nexport const getServerSideProps: GetServerSideProps<Props> = async ({ res }) => {\n  return {\n    props: {\n      ...(await serverSideTranslations(\n        'en',\n        ['osc-marketing-error', 'osc-error-page'],\n        nextI18nextConfig\n      )),\n      statusCode: res.statusCode === 404 ? 404 : 500,\n    },\n  };\n};\n"],"names":["getAppVersion","env","CustomErrorPage","statusCode","t","useTranslation","CustomHead","pageTitle","hideSearchEngine","isBrandHomePage","appVersion","ErrorPage"],"sourceRoot":"","ignoreList":[]}