Skip to content

chickahoona/angular-complexify

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

28 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Angular-complexify v0.3.7 Build Status

password strength validation

AngularJS port of jquery.complexify.js

Installing

var myApp = angular.module('myApp', [
  'angular-complexify'
]);

Usage

Provider
myApp.controller('SomeCtrl', ['$scope', 'Complexify', function($scope, Complexify) {
  $scope.complexify = Complexify('somePassword');
}]);
Standard directive
<input type="text" ng-model="password">

<p ng-show="password">
 <span complexify="password"></span>%,
 <span complexify="password" type="verbal"></span>
</p>
Validation directive
<form name="form">
  <input name="password" type="password" ng-model="password" complexify-validate="60">
</form>

ng-invalid-password-complexity or ng-valid-password-complexity is added as user types. Above example sets 60% complexity as threshold.

Filter (ui-bootstrap progressbar)
<progressbar value="password | complexify"></progressbar>

Tests

npm install
grunt karma:unit

--- © 2014 [Maciej Podsiedlak](http://mpodsiedlak.com) (WTFPL v2 licence)

About

AngularJS port of Dan Palmer's jquery.complexify.js

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 100.0%