1 |
|
2 |
|
3 |
|
4 | import { r as registerInstance, h } from './index-8f15c9d4.js';
|
5 |
|
6 | const checkboxCss = ".radio,.checkbox{cursor:pointer;display:inline-block;line-height:1.25;position:relative}.radio input,.checkbox input{cursor:pointer}.radio:hover,.checkbox:hover{color:#363636}[disabled].radio,[disabled].checkbox,fieldset[disabled] .radio,fieldset[disabled] .checkbox,.radio input[disabled],.checkbox input[disabled]{color:#7a7a7a;cursor:not-allowed}.radio+.radio{margin-left:0.5em}bm-checkbox[disabled=true] .checkbox{color:#7a7a7a;cursor:not-allowed}";
|
7 |
|
8 | let Checkbox = class {
|
9 | constructor(hostRef) {
|
10 | registerInstance(this, hostRef);
|
11 | |
12 |
|
13 |
|
14 | this.inputClass = '';
|
15 | |
16 |
|
17 |
|
18 | this.labelClass = '';
|
19 | |
20 |
|
21 |
|
22 | this.checked = false;
|
23 | |
24 |
|
25 |
|
26 | this.disabled = false;
|
27 | }
|
28 | render() {
|
29 | return (h("label", { class: {
|
30 | checkbox: true,
|
31 | [this.labelClass]: Boolean(this.labelClass),
|
32 | } }, h("input", { type: "checkbox", class: {
|
33 | [this.inputClass]: Boolean(this.inputClass),
|
34 | }, disabled: this.disabled, checked: this.checked }), h("slot", null)));
|
35 | }
|
36 | };
|
37 | Checkbox.style = checkboxCss;
|
38 |
|
39 | export { Checkbox as bm_checkbox };
|