@@ -14,13 +14,13 @@ var nullFormCtrl = {
14
14
*
15
15
* @property {boolean } $pristine True if user has not interacted with the form yet.
16
16
* @property {boolean } $dirty True if user has already interacted with the form.
17
- * @property {boolean } $valid True if all of the containg forms and controls are valid.
17
+ * @property {boolean } $valid True if all of the containing forms and controls are valid.
18
18
* @property {boolean } $invalid True if at least one containing control or form is invalid.
19
19
*
20
20
* @property {Object } $error Is an object hash, containing references to all invalid controls or
21
21
* forms, where:
22
22
*
23
- * - keys are validation tokens (error names) — such as `REQUIRED `, `URL ` or `EMAIL `),
23
+ * - keys are validation tokens (error names) — such as `required `, `url ` or `email `),
24
24
* - values are arrays of controls or forms that are invalid with given error.
25
25
*
26
26
* @description
@@ -133,7 +133,7 @@ function FormController(element, attrs) {
133
133
* does not allow nesting of form elements. It is useful to nest forms, for example if the validity of a
134
134
* sub-group of controls needs to be determined.
135
135
*
136
- * @param {string= } ngForm| name Name of the form. If specified, the form controller will be published into
136
+ * @param {string= } name|ngForm Name of the form. If specified, the form controller will be published into
137
137
* related scope, under this name.
138
138
*
139
139
*/
@@ -206,12 +206,12 @@ function FormController(element, attrs) {
206
206
</script>
207
207
<form name="myForm" ng-controller="Ctrl">
208
208
userType: <input name="input" ng-model="userType" required>
209
- <span class="error" ng-show="myForm.input.$error.REQUIRED ">Required!</span><br>
209
+ <span class="error" ng-show="myForm.input.$error.required ">Required!</span><br>
210
210
<tt>userType = {{userType}}</tt><br>
211
211
<tt>myForm.input.$valid = {{myForm.input.$valid}}</tt><br>
212
212
<tt>myForm.input.$error = {{myForm.input.$error}}</tt><br>
213
213
<tt>myForm.$valid = {{myForm.$valid}}</tt><br>
214
- <tt>myForm.$error.REQUIRED = {{!!myForm.$error.REQUIRED }}</tt><br>
214
+ <tt>myForm.$error.required = {{!!myForm.$error.required }}</tt><br>
215
215
</form>
216
216
</doc:source>
217
217
<doc:scenario>
0 commit comments