File tree Expand file tree Collapse file tree 1 file changed +9
-6
lines changed Expand file tree Collapse file tree 1 file changed +9
-6
lines changed Original file line number Diff line number Diff line change @@ -215,13 +215,14 @@ export class MdCheckbox implements ControlValueAccessor {
215215 set indeterminate ( indeterminate : boolean ) {
216216 let changed = indeterminate != this . _indeterminate ;
217217 this . _indeterminate = indeterminate ;
218- if ( this . _indeterminate ) {
219- this . _transitionCheckState ( TransitionCheckState . Indeterminate ) ;
220- } else {
221- this . _transitionCheckState (
222- this . checked ? TransitionCheckState . Checked : TransitionCheckState . Unchecked ) ;
223- }
218+
224219 if ( changed ) {
220+ if ( this . _indeterminate ) {
221+ this . _transitionCheckState ( TransitionCheckState . Indeterminate ) ;
222+ } else {
223+ this . _transitionCheckState (
224+ this . checked ? TransitionCheckState . Checked : TransitionCheckState . Unchecked ) ;
225+ }
225226 this . indeterminateChange . emit ( this . _indeterminate ) ;
226227 }
227228 }
@@ -379,6 +380,8 @@ export class MdCheckbox implements ControlValueAccessor {
379380 // [checked] bound to it.
380381 if ( newState === TransitionCheckState . Checked ) {
381382 animSuffix = 'unchecked-checked' ;
383+ } else if ( newState == TransitionCheckState . Indeterminate ) {
384+ animSuffix = 'unchecked-indeterminate' ;
382385 } else {
383386 return '' ;
384387 }
You can’t perform that action at this time.
0 commit comments