/ember-frost-text

A simple text input component for frost http://ciena-frost.github.io/ember-frost-text/

Primary LanguageJavaScriptMIT LicenseMIT

ember-frost-text
Travis Coveralls NPM

Installation

ember install ember-frost-text

API

Attribute Type Value Description
autofocus boolean false default: Nothing to see here, just your average text input
true Look at me!
disabled boolean false default: Type to your heart's content
true 🚫 Can't update this! 🎶
on-input string <action-name> triggers associated action when the input value is changed
value string <value-text> what text to put in input

Examples

Focus on Input

{{frost-text
  autofocus=true
}}

Handle Changes to Value

{{frost-text
  on-input=(action 'closure')
}}

Bind Value

{{frost-text
  value=boundText
}}

Disable Input

{{frost-text
  disabled=true
  value="Disabled"
}}

Make Input Read Only

{{frost-text
  readOnly=true
  value="Read Only"
}}

Development

Setup

git clone git@github.com:ciena-frost/ember-frost-text.git
cd ember-frost-text
npm install && bower install

Development Server

A dummy application for development is available under ember-frost-text/tests/dummy. To run the server run ember server (or npm start) from the root of the repository and visit the app at http://localhost:4200.

Testing

Run npm test from the root of the project to run linting checks as well as execute the test suite and output code coverage.