Skip to content

tenzen/angular-input-masks

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

60 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

angular-mask

Personalized and localized input masks for AngularJS

Installation

With Bower:

bower install --save angular-input-masks

How to use

  1. Include the module ui.utils.masks in your angular app.

  2. Include the directive ui-number-mask in your form:

<input type="text" name="field" ng-model="field" ui-number-mask>
  1. You can set the number of decimals (the default is 2):
<input type="text" name="field" ng-model="field" ui-number-mask="3">
  1. You can allow negative numbers using the ui-negative-number attribute:
<input type="text" name="field" ng-model="field" ui-number-mask="3" ui-negative-number>
  1. See more examples and other masks in demo/index.html

Tests

Uses Protractor.

Run throug gulp:

gulp test