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:
@ -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,
|
||||||
}}
|
}}
|
||||||
|
|||||||
Reference in New Issue
Block a user