ember-cli-mdc-checkbox
v3.0.17
Published
ember-cli addons for @material/checkbox.
Downloads
318
Maintainers
Readme
ember-cli-mdc-checkbox
ember-cli addon for @material/checkbox
.
Installation
ember install ember-cli-mdc-checkbox
Components
This package contains the following top-level components.
MdcCheckbox
Description
A standalone checkbox input element that does not contain a label.
Usage
<MdcCheckbox @checked=checked @disabled=disabled />
Attributes
checked
- The checkbox is checked.disabled
- The checkbox is disabled.
Labels using Form Fields
Use the <MdcFormField>
component when you want to add a label to the checkbox
component. You can use the @label
attribute, or the <:label>
named template.
We recommend you use
@label
for simple labels, and<:label>
for complex labels.
<!-- This example use the @label attribute -->
<MdcFormField @label="This is an example checkbox with label">
<MdcCheckbox />
</MdcFormField>
<!-- This example use the <:label> named block -->
<MdcFormField @label="This is an example checkbox with label">
<:label>"This is an example checkbox with label"</:label>
<:default><MdcCheckbox /></:default>
</MdcFormField>