ember-cli-materialize
Version:
An ember-cli addon for using Materialize (CSS Framework based on Material Design) in Ember applications.
23 lines (19 loc) • 544 B
JavaScript
import { computed } from '@ember/object';
import Component from '@ember/component';
export default Component.extend({
actionArgs: null,
large: true,
actions: {
fireButtonAction() {
const actionArgs = this.get('actionArgs');
if (actionArgs) {
this.sendAction('action', actionArgs || null);
} else {
this.sendAction('action');
}
}
},
_btnClassString: computed('btnClass', function() {
return `${this.get('btnClass')} btn-floating ${this.get('large') ? 'btn-large' : ''}`;
})
});