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 <></>; return <></>;
} }
const variants = {
fullScreen: {
width: '100%',
},
normal: {
width: rightDrawerWidth,
},
closed: {
width: 0,
},
};
return ( return (
<StyledContainer <StyledContainer
initial={{ initial="closed"
width: 0, animate={isRightDrawerOpen ? 'normal' : 'closed'}
}} variants={variants}
animate={{
width: rightDrawerWidth,
}}
transition={{ transition={{
duration: theme.animation.duration.normal, duration: theme.animation.duration.normal,
}} }}