44@namespace Namespace for all filters.
55@description
66# Overview
7- Validators are a standard way to check the user input against a specific criteria. For
7+ Validators are a standard way to check the user input against a specific criteria. For
88example, you might need to check that an input field contains a well-formed phone number.
99
1010# Syntax
@@ -29,20 +29,20 @@ Attach a validator on user input widgets using the `ng:validate` attribute.
2929
3030
3131# Writing your own Validators
32- Writing your own validator is easy. To make a function available as a
33- validator, just define the JavaScript function on the `angular.validator`
34- object. <angular/> passes in the input to validate as the first argument
35- to your function. Any additional validator arguments are passed in as
32+ Writing your own validator is easy. To make a function available as a
33+ validator, just define the JavaScript function on the `angular.validator`
34+ object. <angular/> passes in the input to validate as the first argument
35+ to your function. Any additional validator arguments are passed in as
3636additional arguments to your function.
3737
3838You can use these variables in the function:
3939
4040* `this` — The current scope.
4141* `this.$element` — The DOM element containing the binding. This allows the filter to manipulate
4242 the DOM in addition to transforming the input.
43-
44- In this example we have written a upsTrackingNo validator.
45- It marks the input text "valid" only when the user enters a well-formed
43+
44+ In this example we have written a upsTrackingNo validator.
45+ It marks the input text "valid" only when the user enters a well-formed
4646UPS tracking number.
4747
4848@css ng-validation-error
@@ -57,7 +57,7 @@ UPS tracking number.
5757 });
5858</script>
5959<input type="text" name="trackNo" size="40"
60- ng:validate="upsTrackingNo:'1Z 999 999 99 9999 999 9'"
60+ ng:validate="upsTrackingNo:'1Z 999 999 99 9999 999 9'"
6161 value="1Z 123 456 78 9012 345 6"/>
6262
6363@scenario
0 commit comments