@bulmil/core
Version:

34 lines (28 loc) • 1.45 kB
JavaScript
/*!
* Bulmil - MIT License
*/
'use strict';
Object.defineProperty(exports, '__esModule', { value: true });
const index = require('./index-d5e0586a.js');
const radioCss = ".radio,.checkbox{cursor:pointer;display:inline-block;line-height:1.25;position:relative}.radio input,.checkbox input{cursor:pointer}.radio:hover,.checkbox:hover{color:hsl(0, 0%, 21%)}[disabled].radio,[disabled].checkbox,fieldset[disabled] .radio,fieldset[disabled] .checkbox,.radio input[disabled],.checkbox input[disabled]{color:hsl(0, 0%, 48%);cursor:not-allowed}.radio+.radio{margin-left:0.5em}";
const BmRadioStyle0 = radioCss;
const Radio = class {
constructor(hostRef) {
index.registerInstance(this, hostRef);
this.inputClass = '';
this.labelClass = '';
this.name = undefined;
this.checked = false;
this.disabled = false;
}
render() {
return (index.h("label", { key: '51e78f52d2ed3ca894ae9a6a6b9ddd6f5f81a1df', class: {
radio: true,
[this.labelClass]: Boolean(this.labelClass),
} }, index.h("input", { key: 'f702c01797765ec97cc0d8c826f42cf27d1eac52', class: {
[this.inputClass]: Boolean(this.inputClass),
}, type: "radio", name: this.name, disabled: this.disabled, checked: this.checked }), index.h("slot", { key: 'd3244582ed6197fdeed7c5d75dd47a00d5035a31' })));
}
};
Radio.style = BmRadioStyle0;
exports.bm_radio = Radio;