@@ -116,7 +116,18 @@ function mdListDirective($mdTheming) {
116116 * - `md-menu` (Open)
117117 *
118118 * This means, when using a supported proxy item inside of `md-list-item`, the list item will
119- * become clickable and executes the associated action of the proxy element on click.
119+ * automatically become clickable and executes the associated action of the proxy element on click.
120+ *
121+ * It is possible to disable this behavior by applying the `md-no-proxy` class to the list item.
122+ *
123+ * <hljs lang="html">
124+ * <md-list-item class="md-no-proxy">
125+ * <span>No Proxy List</span>
126+ * <md-checkbox class="md-secondary"></md-checkbox>
127+ * </md-list-item>
128+ * </hljs>
129+ *
130+ * Here are a few examples of proxy elements inside of a list item.
120131 *
121132 * <hljs lang="html">
122133 * <md-list-item>
@@ -233,18 +244,21 @@ function mdListItemDirective($mdAria, $mdConstant, $mdUtil, $timeout) {
233244
234245 if ( tAttrs . ngClick || tAttrs . ngDblclick || tAttrs . ngHref || tAttrs . href || tAttrs . uiSref || tAttrs . ngAttrUiSref ) {
235246 wrapIn ( 'button' ) ;
236- } else {
247+ } else if ( ! tEl . hasClass ( 'md-no-proxy' ) ) {
248+
237249 for ( var i = 0 , type ; type = proxiedTypes [ i ] ; ++ i ) {
238250 if ( proxyElement = tEl [ 0 ] . querySelector ( type ) ) {
239251 hasProxiedElement = true ;
240252 break ;
241253 }
242254 }
255+
243256 if ( hasProxiedElement ) {
244257 wrapIn ( 'div' ) ;
245- } else if ( ! tEl [ 0 ] . querySelector ( 'md-button:not(.md-secondary):not(.md-exclude)' ) ) {
258+ } else {
246259 tEl . addClass ( 'md-no-proxy' ) ;
247260 }
261+
248262 }
249263
250264 wrapSecondaryItems ( ) ;
@@ -430,12 +444,13 @@ function mdListItemDirective($mdAria, $mdConstant, $mdUtil, $timeout) {
430444 firstElement = $element [ 0 ] . firstElementChild ,
431445 isButtonWrap = $element . hasClass ( '_md-button-wrap' ) ,
432446 clickChild = isButtonWrap ? firstElement . firstElementChild : firstElement ,
433- hasClick = clickChild && hasClickEvent ( clickChild ) ;
447+ hasClick = clickChild && hasClickEvent ( clickChild ) ,
448+ noProxies = $element . hasClass ( 'md-no-proxy' ) ;
434449
435450 computeProxies ( ) ;
436451 computeClickable ( ) ;
437452
438- if ( $element . hasClass ( 'md-proxy-focus' ) && proxies . length ) {
453+ if ( proxies . length ) {
439454 angular . forEach ( proxies , function ( proxy ) {
440455 proxy = angular . element ( proxy ) ;
441456
@@ -458,7 +473,8 @@ function mdListItemDirective($mdAria, $mdConstant, $mdUtil, $timeout) {
458473
459474
460475 function computeProxies ( ) {
461- if ( firstElement && firstElement . children && ! hasClick ) {
476+
477+ if ( firstElement && firstElement . children && ! hasClick && ! noProxies ) {
462478
463479 angular . forEach ( proxiedTypes , function ( type ) {
464480
0 commit comments