MCPcopy Index your code
hub / github.com/angular-ui/ui-router / cleanup

Function cleanup

test/angular/1.2/angular-animate.js:1052–1072  ·  view source on GitHub ↗
(element, className)

Source from the content-addressed store, hash-verified

1050 }
1051
1052 function cleanup(element, className) {
1053 if(isMatchingElement(element, $rootElement)) {
1054 if(!rootAnimateState.disabled) {
1055 rootAnimateState.running = false;
1056 rootAnimateState.structural = false;
1057 }
1058 } else if(className) {
1059 var data = element.data(NG_ANIMATE_STATE) || {};
1060
1061 var removeAnimations = className === true;
1062 if(!removeAnimations && data.active && data.active[className]) {
1063 data.totalActive--;
1064 delete data.active[className];
1065 }
1066
1067 if(removeAnimations || !data.totalActive) {
1068 element.removeClass(NG_ANIMATE_CLASS_NAME);
1069 element.removeData(NG_ANIMATE_STATE);
1070 }
1071 }
1072 }
1073
1074 function animationsDisabled(element, parentElement) {
1075 if (rootAnimateState.disabled) {

Callers 3

angular-animate.jsFile · 0.70
performAnimationFunction · 0.70
closeAnimationFunction · 0.70

Calls 1

isMatchingElementFunction · 0.70

Tested by

no test coverage detected