Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

ember-radio-button

Package Overview
Dependencies
Maintainers
3
Versions
23
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ember-radio-button

provides a radio-button component

  • 1.0.2
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
14K
decreased by-5.4%
Maintainers
3
Weekly downloads
 
Created
Source

ember-radio-button Build Status Ember Observer Score

Note: ember-radio-button 1.0.0 requires using htmlbars. For applications not using htmlbars, use version 0.1.3 or the pre-htmlbars branch

This ember-cli addon provides a radio-button component.

Pass two properties to the component: value and groupValue. A radio-button will be in a checked state when groupValue === value.

Clicking on a radio-button will set groupValue to its value.

The component exposes a changed action that allows you to do something when a user interaction causes one of your radio buttons to update groupValue.

Template:

{{radio-button
    value="green"
    groupValue=color
    changed="colorChanged"}}

{{#radio-button
    value="blue"
    groupValue=color
    changed="colorChanged"}}
    Blue
{{/radio-button}}

Results in:

<input id="ember345" class="ember-view" type="radio" value="green">

<label id="ember346" class="ember-view ember-radio-button">
  <input id="ember347" class="ember-view" type="radio" value="blue">
  Blue
</label>

You can additionally provide disabled name and required properties to a radio-button

{{radio-button
    value="green"
    groupValue=color
    required=true
    disabled=true
    name="color"}}
<input id="ember345" class="ember-view" type="radio" value="green" name="color" required disabled>

Installing

ember install:addon ember-radio-button

Collaborating on this repo

  • git clone this repository
  • npm install
  • bower install

Running the dummy app

Running Tests

  • ember test
  • ember test --server

Building

  • ember build

For more information on using ember-cli, visit http://www.ember-cli.com/.

Keywords

FAQs

Package last updated on 14 Apr 2015

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc