refactor(item): all buttons inside of item receive .item-button

This commit is contained in:
Adam Bradley
2016-01-04 13:17:07 -06:00
parent aada9cc7c4
commit aefcbeeb00

View File

@ -1,4 +1,6 @@
import {Component} from 'angular2/core'; import {Component, ContentChildren} from 'angular2/core';
import {Button} from '../button/button';
/** /**
@ -57,4 +59,10 @@ import {Component} from 'angular2/core';
'class': 'item' 'class': 'item'
} }
}) })
export class Item {} export class Item {
@ContentChildren(Button)
set _buttons(buttons) {
Button.setRoles(buttons, 'item-button');
}
}