Skip to content

Commit

Permalink
fix: try fix animate
Browse files Browse the repository at this point in the history
Signed-off-by: Innei <i@innei.in>
  • Loading branch information
Innei committed Jul 6, 2023
1 parent 6c995d1 commit 79398af
Showing 1 changed file with 30 additions and 27 deletions.
57 changes: 30 additions & 27 deletions src/components/layout/header/internal/Activity.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ export function Activity() {
}

return (
<AnimatePresence>
<>
{!!media && (
<m.div className="absolute bottom-0 left-0 top-0 z-[10] flex items-center md:left-[-30px]">
<div className="absolute inset-0 z-[-1] flex center">
Expand All @@ -127,33 +127,36 @@ export function Activity() {
</FloatPopover>
</m.div>
)}

{!!appLabels[processName] && (
<m.div
key={processName}
className="pointer-events-auto absolute bottom-0 right-0 top-0 z-[10] flex animate-pulse items-center overflow-hidden md:right-[-25px]"
initial={false}
animate={{
opacity: 1,
x: 0,
}}
exit={{
opacity: 0.2,
x: -10,
}}
>
<FloatPopover
TriggerComponent={TriggerComponent}
triggerComponentProps={memoProcessName}
type="tooltip"
strategy="fixed"
<AnimatePresence>
{!!appLabels[processName] && (
<m.div
key={processName}
className="pointer-events-auto absolute bottom-0 right-0 top-0 z-[10] flex items-center overflow-hidden md:right-[-25px]"
initial={false}
animate={{
opacity: 1,
x: 0,
}}
exit={{
opacity: 0.2,
x: -10,
}}
>
{ownerName} 正在使用 {processName}
{appDescrption[processName] ? ` ${appDescrption[processName]}` : ''}
</FloatPopover>
</m.div>
)}
</AnimatePresence>
<FloatPopover
TriggerComponent={TriggerComponent}
triggerComponentProps={memoProcessName}
type="tooltip"
strategy="fixed"
>
{ownerName} 正在使用 {processName}
{appDescrption[processName]
? ` ${appDescrption[processName]}`
: ''}
</FloatPopover>
</m.div>
)}
</AnimatePresence>
</>
)
}
const cMusicProps = { processName: 'cmusic' }
Expand Down

1 comment on commit 79398af

@vercel
Copy link

@vercel vercel bot commented on 79398af Jul 6, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

shiro – ./

shiro-git-main-innei.vercel.app
shiro-innei.vercel.app
innei.in
springtide.vercel.app

Please sign in to comment.