commenting unused lines

This commit is contained in:
Antoine M 2024-09-12 12:58:55 +02:00
parent 72b7cec9af
commit 2a717bfd1d

View File

@ -5,24 +5,24 @@ import { motion } from "framer-motion";
export default function AnimatedPage({ children, className }) {
const location = useLocation();
const isNext = location.state && location.state.isNext;
const isPrev = location.state && location.state.isPrev;
const isGoingNext = location.state && location.state.isGoingNext;
// const isNext = location.state && location.state.isNext;
// const isPrev = location.state && location.state.isPrev;
// const isGoingNext = location.state && location.state.isGoingNext;
function getAnimationParameters() {
const animationParameters = { animate: { x: "0%", opacity: 1 } };
if (isNext === true) {
animationParameters.initial = { x: "50%", opacity: 0 };
} else {
animationParameters.initial = { x: "-50%", opacity: 0 };
}
if (isGoingNext === true) {
animationParameters.exit = { x: "-50%", opacity: 0 };
} else {
animationParameters.exit = { x: "50%", opacity: 0 };
}
return animationParameters;
}
// function getAnimationParameters() {
// const animationParameters = { animate: { x: "0%", opacity: 1 } };
// if (isNext === true) {
// animationParameters.initial = { x: "50%", opacity: 0 };
// } else {
// animationParameters.initial = { x: "-50%", opacity: 0 };
// }
// if (isGoingNext === true) {
// animationParameters.exit = { x: "-50%", opacity: 0 };
// } else {
// animationParameters.exit = { x: "50%", opacity: 0 };
// }
// return animationParameters;
// }
// const animationParameters = getAnimationParameters();
const animationParameters = {
initial: { x: "50%", opacity: 0 },