data-transfer.page.tsx 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. import type { GetServerSideProps } from 'next';
  2. import dynamic from 'next/dynamic';
  3. import type { NextPageWithLayout } from '../_app.page';
  4. import type { AdminCommonProps } from './_shared';
  5. import {
  6. createAdminPageLayout,
  7. getServerSideAdminCommonProps,
  8. } from './_shared';
  9. const G2GDataTransferPage = dynamic(
  10. // biome-ignore lint/style/noRestrictedImports: no-problem dynamic import
  11. () => import('~/client/components/Admin/G2GDataTransfer'),
  12. { ssr: false },
  13. );
  14. type Props = AdminCommonProps;
  15. const DataTransferPage: NextPageWithLayout<Props> = () => (
  16. <G2GDataTransferPage />
  17. );
  18. DataTransferPage.getLayout = createAdminPageLayout<Props>({
  19. title: (_p, t) => t('g2g_data_transfer.data_transfer', { ns: 'commons' }),
  20. containerFactories: [
  21. async () => {
  22. const AdminAppContainer =
  23. // biome-ignore lint/style/noRestrictedImports: no-problem dynamic import
  24. (await import('~/client/services/AdminAppContainer')).default;
  25. return new AdminAppContainer();
  26. },
  27. ],
  28. });
  29. export const getServerSideProps: GetServerSideProps<Props> =
  30. getServerSideAdminCommonProps;
  31. export default DataTransferPage;