File size: 676 Bytes
0bfe2e3
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
'use client';
import { PAGE_TRANSITION } from '@/components/shared/page-transition';
import { cn } from '@/components/ui/core/styling';
import { motion } from 'framer-motion';
import React from 'react';

type PageWrapperProps = {
  children?: React.ReactNode;
} & React.ComponentPropsWithoutRef<'div'>;

export function PageWrapper(props: PageWrapperProps) {
  const { children, className, ...rest } = props;

  return (
    <div data-page-wrapper-container>
      <motion.div
        data-page-wrapper
        {...PAGE_TRANSITION}
        {...(rest as any)}
        className={cn('z-[5] relative', className)}
      >
        {children}
      </motion.div>
    </div>
  );
}