properly animate the profile hover card (#3590)
* properly implement with `isOpen` and `isPositioned` * well, this works just as well * add `willChange`
This commit is contained in:
@@ -289,12 +289,12 @@ export function ProfileHoverCardInner(props: ProfileHoverCardProps) {
|
||||
{props.children}
|
||||
{isVisible && (
|
||||
<Portal>
|
||||
<div style={animationStyle}>
|
||||
<div
|
||||
ref={refs.setFloating}
|
||||
style={floatingStyles}
|
||||
onPointerEnter={onPointerEnterCard}
|
||||
onPointerLeave={onPointerLeaveCard}>
|
||||
<div
|
||||
ref={refs.setFloating}
|
||||
style={floatingStyles}
|
||||
onPointerEnter={onPointerEnterCard}
|
||||
onPointerLeave={onPointerLeaveCard}>
|
||||
<div style={{willChange: 'transform', ...animationStyle}}>
|
||||
<Card did={props.did} hide={onPress} />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user