Skip to content

Commit

Permalink
fix(uiSrefActive): Apply active classes on lazy loaded states
Browse files Browse the repository at this point in the history
Conflicts:
	test/stateDirectivesSpec.js
  • Loading branch information
kasperlewau authored and christopherthielen committed Jul 8, 2015
1 parent cdbe087 commit 6ae6fe2
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions src/stateDirectives.ts
Original file line number Diff line number Diff line change
Expand Up @@ -233,13 +233,13 @@ function $StateRefActiveDirective($state, $stateParams, $interpolate) {
// Allow uiSref to communicate with uiSrefActive[Equals]
this.$$addStateInfo = function (newState, newParams) {
var state = $state.get(newState, stateContext($element));
if (state) {
states.push({
state: state,
params: newParams
});
update();
}

states.push({
state: state || { name: newState },
params: newParams
});

update();
};

$scope.$on('$stateChangeSuccess', update);
Expand Down

0 comments on commit 6ae6fe2

Please sign in to comment.