Skip to content
This repository was archived by the owner on Apr 30, 2018. It is now read-only.

Commit b06319f

Browse files
committed
gst
1 parent a6232bb commit b06319f

File tree

4 files changed

+6
-1
lines changed

4 files changed

+6
-1
lines changed

README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -399,6 +399,9 @@ _Example number field_
399399
>The password field allows password input, it uses an input with `type='password'`.
400400
##### default (string, optional)
401401

402+
##### trimWhitespace (boolean, optional)
403+
Unlike other formly fields, which use Angular's default setting to trim leading and trailing whitespace, the password field captures whitespace. You can override this by setting `trimWhitespace` to `true`.
404+
402405
_Example password field_
403406
```json
404407
{

src/directives/bootstrap/formly-field-password.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
aria-describedby="{{id}}_description"
1010
ng-required="options.required"
1111
ng-disabled="options.disabled"
12+
ng-trim="{{options.trimWhitespace || false}}"
1213
ng-model="value">
1314
<p id="{{id}}_description" class="help-block" ng-if="options.description">{{options.description}}</p>
1415
</div>

src/directives/formly-field-password.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
aria-describedby="{{id}}_description"
99
ng-required="options.required"
1010
ng-disabled="options.disabled"
11+
ng-trim="{{options.trimWhitespace || false}}"
1112
ng-model="value">
1213
<p id="{{id}}_description" ng-if="options.description">{{options.description}}</p>
1314
</div>

src/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
</div>
3030
</div>
3131

32-
<script src="bower_components/angular/angular.min.js"></script>
32+
<script src="bower_components/angular/angular.js"></script>
3333
<script src="bower_components/angular-highlightjs/angular-highlightjs.min.js"></script>
3434
<script src="bower_components/angular-ui-router/release/angular-ui-router.js"></script>
3535
<script src="bower_components/highlightjs/highlight.pack.js"></script>

0 commit comments

Comments
 (0)