Skip to content

Add before classes to animate.enter and animate.leave #63106

@rupisaini123

Description

@rupisaini123

Which @angular/* package(s) are the source of the bug?

animations, core

Is this a regression?

No

Description

we might have issue with animate.enter if using tailwind classes.
e.g. trying to animate the opacity of element and passing in animate.in="transition-opacity ease-linear duration-300 opacity-100"
the animation never runs as element was added with opacity-100 by default and these classes are never removed even after element have enter the DOM.

So, we should have a mechanism to part a starting classes, which are added initially and then immediatly removed and start processing animate.in, this will do the trick.

after this animate.out can work as expected

Please provide a link to a minimal reproduction of the bug

No response

Please provide the exception or error you saw


Please provide the environment you discovered this bug in (run ng version)


Anything else?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: coreIssues related to the framework runtimecore: animationsIssues related to `animate.enter` and `animate.leave`

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions