layout.tsx 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. import Script from 'next/script'
  2. import Header from './_header'
  3. import style from './page.module.css'
  4. import cn from '@/utils/classnames'
  5. import { IS_CE_EDITION } from '@/config'
  6. export default async function SignInLayout({ children }: any) {
  7. return <>
  8. {!IS_CE_EDITION && (
  9. <>
  10. <Script strategy="beforeInteractive" async src={'https://www.googletagmanager.com/gtag/js?id=AW-11217955271'}></Script>
  11. <Script
  12. id="ga-monitor-register"
  13. dangerouslySetInnerHTML={{
  14. __html: 'window.dataLayer2 = window.dataLayer2 || [];function gtag(){dataLayer2.push(arguments);}gtag(\'js\', new Date());gtag(\'config\', \'AW-11217955271"\');',
  15. }}
  16. >
  17. </Script>
  18. </>
  19. )}
  20. <div className={cn(
  21. style.background,
  22. 'flex w-full min-h-screen',
  23. 'sm:p-4 lg:p-8',
  24. 'gap-x-20',
  25. 'justify-center lg:justify-start',
  26. )}>
  27. <div className={
  28. cn(
  29. 'flex w-full flex-col bg-white shadow rounded-2xl shrink-0',
  30. 'space-between',
  31. )
  32. }>
  33. <Header />
  34. <div className={
  35. cn(
  36. 'flex flex-col items-center w-full grow justify-center',
  37. 'px-6',
  38. 'md:px-[108px]',
  39. )
  40. }>
  41. <div className='flex flex-col md:w-[400px]'>
  42. {children}
  43. </div>
  44. </div>
  45. <div className='px-8 py-6 system-xs-regular text-text-tertiary'>
  46. © {new Date().getFullYear()} LangGenius, Inc. All rights reserved.
  47. </div>
  48. </div>
  49. </div>
  50. </>
  51. }