UNPKG

aurelia-form

Version:

Makes working with forms just a tad more pleasant.

29 lines (17 loc) 594 B
import {bindable, customElement, bindingMode} from 'aurelia-framework'; import {resolvedView} from 'aurelia-view-manager'; @resolvedView('spoonx/form', 'form-input') @customElement('form-input') export class FormInput { @bindable({defaultBindingMode: bindingMode.twoWay}) value; @bindable({defaultBindingMode: bindingMode.twoWay}) checked; @bindable type = 'text'; @bindable name = ''; @bindable classes = ''; @bindable placeholder = ''; @bindable readonly = false; @bindable disabled = false; @bindable options = {}; @bindable autofocus; @bindable required; }