Consistent Overlay Animation Properties for Menu and Calendar Components #16344
Labels
Status: Pending Review
Issue or pull request is being reviewed by Core Team
Milestone
Describe the bug
Hi PrimeNG Team,
I would like to request a feature enhancement regarding the overlay animations for the Menu and Calendar components. Currently, there is an inconsistency in how the animations are handled during the hide transition between these two components.
Menu Component:
The enter transition includes both opacity and a transform (scaleY) effect:
transition(':enter', [style({ opacity: 0, transform: 'scaleY(0.8)' }), animate('{{showTransitionParams}}')])
However, during the leave transition, only the opacity is animated, and the transform is omitted:
transition(':leave', [animate('{{hideTransitionParams}}', style({ opacity: 0 }))])
Calendar Component:
Similarly, for the Calendar, the enter transition uses both opacity and transform effects:
transition('void => visible', [style({ opacity: 0, transform: 'scaleY(0.8)' }), animate('{{showTransitionParams}}', style({ opacity: 1, transform: '*' }))])
The leave transition also only animates the opacity, even though the transform is included with a wildcard (*):
transition('visible => void', [animate('{{hideTransitionParams}}', style({ opacity: 0 }))])
Environment
prime ng version: 17.18.9
angular version: 18.1.0
Reproducer
No response
Angular version
18.1.0
PrimeNG version
17.18.9
Build / Runtime
Angular CLI App
Language
TypeScript
Node version (for AoT issues node --version)
20.15.1
Browser(s)
Chrome
Steps to reproduce the behavior
Expected behavior
Both components should include a transform animation in the hide transition, matching the enter transition for a smoother and more consistent animation, like other components which are using
Overlay
likeDropdown, Multiselect or Autocomplete
The text was updated successfully, but these errors were encountered: