-
Notifications
You must be signed in to change notification settings - Fork 518
ui(animation): smooth exit animation for image details panel #978
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
skyforge-glitch
wants to merge
1
commit into
AOSSIE-Org:main
Choose a base branch
from
skyforge-glitch:ui/animation-feedback
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
🏁 Script executed:
cat -n frontend/src/components/Media/MediaInfoPanel.tsx | head -100Repository: AOSSIE-Org/PictoPy
Length of output: 3868
🌐 Web query:
framer-motion 11.16.3 stability and React 19 compatibility AnimatePresence support💡 Result:
Short answer: framer-motion 11.16.3 is reported to still have React 19 compatibility problems (including TypeScript/JSX errors when using AnimatePresence) and some 11.x changes (since 11.3.0) introduced behaviour that forces React into certain builds. If you need stable React 19 support, either pin to React 18 or upgrade to a framer-motion/motion release that explicitly adds React 19 support (or check the project’s repo for the exact version that fixed the issues). Sources below show the active incompatibility reports and related bugs. [1][2][3][4]
Sources
Excellent animation implementation, but React 19 compatibility issue blocks this PR.
The AnimatePresence + motion.div setup correctly ensures the panel stays mounted during exit animation, and the symmetric entry/exit animations provide the smooth interaction intended. However, framer-motion 11.16.3 has reported incompatibility issues with React 19 that include TypeScript/JSX errors when using AnimatePresence. This project currently pairs React 19.1.0 with framer-motion 11.16.3, creating a breaking incompatibility.
Resolve by either:
This must be resolved before merge, as the current combination will cause runtime failures.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the review! This change only introduces an exit animation using AnimatePresence, which is already compatible with the existing Framer Motion usage in the project. The application runs correctly with the current React and framer-motion versions, and no dependency changes are required as part of this UI-only fix. Happy to revisit if maintainers prefer a different approach.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
🏁 Script executed:
Length of output: 296
🏁 Script executed:
Length of output: 4309
@skyforge-glitch You're absolutely right, and I apologize for the overstated concern. I've now verified that
AnimatePresenceis already successfully used in the codebase (e.g., inlanding-page/src/Pages/FaqPage/FAQ.tsx), and framer-motion is working correctly with React 19.1.0 throughout the project.Your implementation is consistent with the existing animation patterns in the codebase, and since the application runs correctly with the current dependency versions, there's no compatibility blocker here. The smooth exit animation using
AnimatePresence+motion.divis the right approach for this UI enhancement.Thank you for the clarification!
🧬 Code Graph Analysis Results
frontend/src/types/Media.ts
<line_range>13-23</line_range>