@@ -24,7 +24,7 @@ import {MdInkBar} from '../ink-bar';
2424import { MdRipple } from '../../core/ripple/index' ;
2525import { ViewportRuler } from '../../core/overlay/position/viewport-ruler' ;
2626import { Directionality , MD_RIPPLE_GLOBAL_OPTIONS , Platform , RippleGlobalOptions } from '../../core' ;
27- import { CanColor , mixinColor } from '../../core/common-behaviors/color' ;
27+ import { CanColor , mixinColor , ThemePalette } from '../../core/common-behaviors/color' ;
2828import { Observable } from 'rxjs/Observable' ;
2929import 'rxjs/add/operator/auditTime' ;
3030import 'rxjs/add/operator/takeUntil' ;
@@ -60,6 +60,20 @@ export class MdTabNav extends _MdTabNavMixinBase implements AfterContentInit, Ca
6060
6161 @ViewChild ( MdInkBar ) _inkBar : MdInkBar ;
6262
63+ /** Background color of the tab nav. */
64+ @Input ( )
65+ get background ( ) : ThemePalette { return this . _background ; }
66+ set background ( value : ThemePalette ) {
67+ if ( value ) {
68+ let nativeElement = this . _elementRef . nativeElement ;
69+
70+ this . _renderer . removeClass ( nativeElement , `mat-background-${ this . background } ` ) ;
71+ this . _renderer . addClass ( nativeElement , `mat-background-${ value } ` ) ;
72+ this . _background = value ;
73+ }
74+ }
75+ private _background : ThemePalette ;
76+
6377 constructor ( renderer : Renderer2 ,
6478 elementRef : ElementRef ,
6579 private _ngZone : NgZone ,
0 commit comments