ember-paper-input
Version:
An animated floating label addon for Ember.
48 lines (36 loc) • 1.25 kB
Markdown
An animated floating label addon for Ember.

```bash
ember install ember-paper-input
```
or add the addon in your package.json file
```bash
"ember-paper-input": "git+https://github.com/boseca/ember-paper-input.git"
```
Example with required input.
```hbs
{{
{{input id="txt-firstname" type="text" required=true placeholder='John'}}
<label for="txt-firstname">First name</label>
{{/ember-paper-input}}
```
Example with non-required input.
```hbs
{{
{{input value=model.address type="text" placeholder="123 Lawrence"}}
<label>Address</label>
{{/ember-paper-input}}
```
Example with 3rd party controls (in this case `power-select` control).
The addon will observe the value of `selected` and when it's changed it will animate the label.
```hbs
{{
{{
{{country.country}}
{{/power-select}}
<label>Country</label>
{{/ember-paper-input}}
```