@busy-web/components
Version:
Ember addon library for usefull components.
24 lines (20 loc) • 455 B
JavaScript
/**
* @module Components
*
*/
import TextField from '@ember/component/text-field';
import layout from '../templates/components/checkbox-input';
export default TextField.extend({
layout: layout,
classNameBindings: ['checked'],
attributeBindings: ['checked', 'group', 'disabled'],
type: 'checkbox',
group: null,
name: null,
disabled: false,
checked: false,
_value: false,
click() {
this.sendAction('onChange', !this.get('_value'));
}
});