UNPKG

aurelia-materialize-bridge

Version:
69 lines 2.33 kB
import { __decorate, __metadata } from "tslib"; import * as au from "../aurelia"; var MdRadio = /** @class */ (function () { function MdRadio(element) { this.element = element; this.disabled = false; this.readonly = false; this.gap = false; this.name = ""; this.value = ""; this.controlId = "md-radio-" + MdRadio_1.id++; } MdRadio_1 = MdRadio; MdRadio.prototype.disabledChanged = function (newValue) { if (this.radio) { this.radio.disabled = newValue; } }; MdRadio.prototype.attached = function () { this.attributeManager = new au.AttributeManager(this.radio); if (this.gap) { this.attributeManager.addClasses("with-gap"); } if (this.disabled) { this.radio.disabled = true; } }; MdRadio.prototype.detached = function () { this.attributeManager.removeClasses(["with-gap", "disabled"]); }; var MdRadio_1; MdRadio.id = 0; __decorate([ au.bindable({ defaultBindingMode: au.bindingMode.twoWay }), __metadata("design:type", Object) ], MdRadio.prototype, "checked", void 0); __decorate([ au.ato.bindable.booleanMd, __metadata("design:type", Boolean) ], MdRadio.prototype, "disabled", void 0); __decorate([ au.ato.bindable.booleanMd, __metadata("design:type", Boolean) ], MdRadio.prototype, "readonly", void 0); __decorate([ au.ato.bindable.booleanMd, __metadata("design:type", Boolean) ], MdRadio.prototype, "gap", void 0); __decorate([ au.bindable, __metadata("design:type", Object) ], MdRadio.prototype, "model", void 0); __decorate([ au.ato.bindable.stringMd, __metadata("design:type", String) ], MdRadio.prototype, "name", void 0); __decorate([ au.ato.bindable.stringMd, __metadata("design:type", String) ], MdRadio.prototype, "value", void 0); MdRadio = MdRadio_1 = __decorate([ au.customElement("md-radio"), au.autoinject, __metadata("design:paramtypes", [Element]) ], MdRadio); return MdRadio; }()); export { MdRadio }; //# sourceMappingURL=radio.js.map