Skip to content

Commit

Permalink
version 1.0
Browse files Browse the repository at this point in the history
  • Loading branch information
Mark Manders committed Jun 10, 2016
1 parent f12444d commit afe8115
Show file tree
Hide file tree
Showing 4 changed files with 46 additions and 2 deletions.
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ng-iban",
"version": "0.9.0",
"version": "1.0.0",
"authors": [
"Mark Manders <[email protected]>"
],
Expand Down
22 changes: 22 additions & 0 deletions dist/ng-iban.js
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,28 @@
});
}
};
}).filter('iban', function () {
return function (string, separator) {
var isValidIban, parseIban, valid;
parseIban = function parseIban(value) {
if (value != null) {
return value.toUpperCase().replace(/\s/g, '');
} else {
return void 0;
}
};
isValidIban = function isValidIban(value) {
var iban;
iban = parseIban(value);
return IBAN.isValid(iban);
};
valid = isValidIban(string);
if (valid) {
return IBAN.printFormat(string, separator);
} else {
return string;
}
};
});

/***/ },
Expand Down
22 changes: 22 additions & 0 deletions lib/ng-iban.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ng-iban",
"version": "0.9.0",
"version": "1.0.0",
"description": "IBAN directive for AngularJS",
"main": "./lib/ng-iban.js",
"scripts": {
Expand Down

0 comments on commit afe8115

Please sign in to comment.