fix-right-drawer-bounces-when-opening-a-different-thread (#3691)

* fix-right-drawer-bounces-when-opening-a-different-thread

* fix
This commit is contained in:
bosiraphael
2024-01-30 13:38:34 +01:00
committed by GitHub
parent 0bfc63161b
commit 3a480f1506

View File

@ -83,14 +83,23 @@ export const RightDrawer = () => {
return <></>;
}
const variants = {
fullScreen: {
width: '100%',
},
normal: {
width: rightDrawerWidth,
},
closed: {
width: 0,
},
};
return (
<StyledContainer
initial={{
width: 0,
}}
animate={{
width: rightDrawerWidth,
}}
initial="closed"
animate={isRightDrawerOpen ? 'normal' : 'closed'}
variants={variants}
transition={{
duration: theme.animation.duration.normal,
}}