Package Exports
- ractive-ez-radio
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (ractive-ez-radio) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
Ractive Ez Radio
Radio button component for ractive.js
Install
npm i ractive-ez-radioimport 'ractive-ez-radio';
import 'ractive-ez-radio/themes/blue.less';Theming requires less-loader. Icons require ractive-ez-icon
Usage
<EzRadioGroup value="{{ value }}" align="horizontal">
<EzRadioIcon value="1" />
<EzRadioIcon value="2" />
<EzRadioIcon value="3" />
</EzRadioGroup>EzRadioGroup
align: horizontal or verticalvalue: the value to bind to the selected radio buttonbutton: Passed to contained radio buttonsdisabled: Passed to contained radio buttonsiconChecked: Passed to contained radio buttonsiconUnchecked: Passed to contained radio buttons
EzRadio
value: The value this radio button assumesdisabled: True if the component is disabledbutton: Render as buttoniconChecked: When using ractive-ez-icon, can set an icon for the "checked" stateiconUnchecked: When using ractive-ez-icon, can set an icon for the "unchecked" state
Custom label format
If a text label is not sufficient for your radio button, you can override the label partial:
<EzRadio value="{{ value }}" label>
<b>Bold label</b>
</EzRadio>Shorthand subcomponents
EzRadio: The base componentEzRadioButton: Implied buttonEzRadioIcon: Implied radio icons (defaulting to radio-checked and radio-unchecked)EzRadioIconButton: Implied icon button