mirror of
https://github.com/antebudimir/feishin.git
synced 2025-12-31 10:03:33 +00:00
re-add page fade in
This commit is contained in:
parent
8c4a7f4f91
commit
1598642389
1 changed files with 3 additions and 11 deletions
|
|
@ -5,27 +5,19 @@ import { forwardRef } from 'react';
|
||||||
|
|
||||||
import styles from './animated-page.module.css';
|
import styles from './animated-page.module.css';
|
||||||
|
|
||||||
|
import { animationProps } from '/@/shared/components/animations/animation-props';
|
||||||
|
|
||||||
interface AnimatedPageProps {
|
interface AnimatedPageProps {
|
||||||
children: ReactNode;
|
children: ReactNode;
|
||||||
}
|
}
|
||||||
|
|
||||||
// const variants = {
|
|
||||||
// animate: { opacity: 1 },
|
|
||||||
// exit: { opacity: 0 },
|
|
||||||
// initial: { opacity: 0 },
|
|
||||||
// };
|
|
||||||
|
|
||||||
export const AnimatedPage = forwardRef(
|
export const AnimatedPage = forwardRef(
|
||||||
({ children }: AnimatedPageProps, ref: Ref<HTMLDivElement>) => {
|
({ children }: AnimatedPageProps, ref: Ref<HTMLDivElement>) => {
|
||||||
return (
|
return (
|
||||||
<motion.main
|
<motion.main
|
||||||
// animate="animate"
|
|
||||||
className={styles.animatedPage}
|
className={styles.animatedPage}
|
||||||
ref={ref}
|
ref={ref}
|
||||||
// exit="exit"
|
{...animationProps.fadeIn}
|
||||||
// initial="initial"
|
|
||||||
// transition={{ duration: 0.3, ease: 'easeIn' }}
|
|
||||||
// variants={variants}
|
|
||||||
>
|
>
|
||||||
{children}
|
{children}
|
||||||
</motion.main>
|
</motion.main>
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue