Skip to content
This repository has been archived by the owner on Apr 12, 2024. It is now read-only.

Fix ngAnimateChildren + ngIf, add docs for the directive #13876

Closed
wants to merge 2 commits into from

Conversation

Narretz
Copy link
Contributor

@Narretz Narretz commented Jan 28, 2016

No description provided.

Previously, ngAnimateChildren would set the data on the element
in an $observe listener. This is too late when the element is
animated immediately after compilation, as happens with ngIf

Closes angular#13865
@@ -1492,6 +1492,22 @@ describe("animations", function() {
dealoc(element);
dealoc(child);
}));

it('should respect the value if the directive is on an element with ngIf',
inject(function($animate, $rootScope, $rootElement, $compile) {
Copy link
Member

Choose a reason for hiding this comment

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

Is $animate needed here ?

@gkalpak
Copy link
Member

gkalpak commented Jan 28, 2016

A few minor comments, but LGTM otherwise.

@Narretz Narretz closed this in 8aecf46 Jan 28, 2016
@Narretz
Copy link
Contributor Author

Narretz commented Jan 28, 2016

Thanks! Landed with your suggestions.

@Narretz Narretz deleted the fix-nganimatechildren branch January 28, 2016 20:41
Narretz added a commit that referenced this pull request Jan 28, 2016
Previously, ngAnimateChildren would set the data on the element
in an $observe listener, which means the data was available after one digest happend.
This is too late when the element is animated immediately after compilation, as happens with ngIf.
Now the data is also set right in the linking function.

Fixes #13865
Closes #13876
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants