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

Commit

Permalink
fix(mdList): remove focus state on blur
Browse files Browse the repository at this point in the history
Closes #2339.
  • Loading branch information
nicu authored and ThomasBurleson committed Apr 15, 2015
1 parent 17aecd2 commit 588e58c
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/components/list/list.js
Original file line number Diff line number Diff line change
Expand Up @@ -135,8 +135,8 @@ function mdListItemDirective($mdAria) {

// Check for a secondary item and move it outside
if ( secondaryItem && (
secondaryItem.hasAttribute('ng-click') ||
( tAttrs.ngClick &&
secondaryItem.hasAttribute('ng-click') ||
( tAttrs.ngClick &&
isProxiedElement(secondaryItem) )
)) {
tEl.addClass('md-with-secondary');
Expand All @@ -162,9 +162,9 @@ function mdListItemDirective($mdAria) {
proxy = angular.element(proxy);
proxy.on('focus', function() {
$element.addClass('md-focused');
proxy.on('blur', function() {
proxy.on('blur', function proxyOnBlur() {
$element.removeClass('md-focused');
proxy.off('blur');
proxy.off('blur', proxyOnBlur);
});
});
});
Expand All @@ -180,7 +180,7 @@ function mdListItemDirective($mdAria) {
}
}
function computeClickable() {
if (proxies.length || $element[0].firstElementChild.hasAttribute('ng-click')) {
if (proxies.length || $element[0].firstElementChild.hasAttribute('ng-click')) {
$element.addClass('md-clickable');
}
}
Expand Down

0 comments on commit 588e58c

Please sign in to comment.