Add span to make extensibility easier

This commit is contained in:
Robin Ward 2018-01-23 15:44:42 -05:00
parent 86e142b39f
commit 0351565731
1 changed files with 2 additions and 0 deletions

View File

@ -7,11 +7,13 @@ export default Ember.Component.extend(bufferedRender({
rerenderTriggers: ['order', 'desc'],
buildBuffer(buffer) {
buffer.push("<span class='header-contents'>");
buffer.push(I18n.t(this.get('i18nKey')));
if (this.get('field') === this.get('order')) {
buffer.push(iconHTML(this.get('desc') ? 'chevron-down' : 'chevron-up'));
}
buffer.push("</span>");
},
click() {