This repository has been archived by the owner on Sep 5, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 3.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
update(tabs): prevents autofill on demo page for autocomplete
- Loading branch information
Robert Messerle
committed
Mar 23, 2015
1 parent
49d8434
commit d484fc8
Showing
2 changed files
with
37 additions
and
43 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,23 @@ | ||
<div ng-app="autocompleteDemo" ng-controller="DemoCtrl as ctrl" layout="column"> | ||
|
||
<md-content class="md-padding" layout="column"> | ||
<p> | ||
Use <code><md-autocomplete></code> to search for matches from local or remote data sources. | ||
</p> | ||
|
||
<md-autocomplete | ||
ng-disabled="ctrl.isDisabled" | ||
md-no-cache="ctrl.noCache" | ||
md-selected-item="ctrl.selectedItem" | ||
md-search-text="ctrl.searchText" | ||
md-items="item in ctrl.querySearch(ctrl.searchText)" | ||
md-item-text="item.display" | ||
placeholder="What is your favorite US state?"> | ||
<span md-highlight-text="ctrl.searchText">{{item.display}}</span> | ||
</md-autocomplete> | ||
|
||
<br/> | ||
<md-checkbox ng-model="ctrl.simulateQuery">Simulate query for results?</md-checkbox> | ||
<md-checkbox ng-model="ctrl.noCache">Disable caching of queries?</md-checkbox> | ||
<md-checkbox ng-model="ctrl.isDisabled">Disable the input?</md-checkbox> | ||
|
||
<p style="padding-left: 15px;">By default, <code><md-autocomplete></code> will cache results when performing a query. After the initial call is performed, it will use the cached results to eliminate unnecessary server requests or lookup logic. This can be disabled above.</p> | ||
<form ng-submit="$event.preventDefault()"> | ||
<p>Use <code><md-autocomplete></code> to search for matches from local or remote data sources.</p> | ||
<md-autocomplete | ||
ng-disabled="ctrl.isDisabled" | ||
md-no-cache="ctrl.noCache" | ||
md-selected-item="ctrl.selectedItem" | ||
md-search-text="ctrl.searchText" | ||
md-items="item in ctrl.querySearch(ctrl.searchText)" | ||
md-item-text="item.display" | ||
placeholder="What is your favorite US state?"> | ||
<span md-highlight-text="ctrl.searchText">{{item.display}}</span> | ||
</md-autocomplete> | ||
<br/> | ||
<md-checkbox ng-model="ctrl.simulateQuery">Simulate query for results?</md-checkbox> | ||
<md-checkbox ng-model="ctrl.noCache">Disable caching of queries?</md-checkbox> | ||
<md-checkbox ng-model="ctrl.isDisabled">Disable the input?</md-checkbox> | ||
|
||
<p style="padding-left: 15px;">By default, <code><md-autocomplete></code> will cache results when performing a query. After the initial call is performed, it will use the cached results to eliminate unnecessary server requests or lookup logic. This can be disabled above.</p> | ||
</form> | ||
</md-content> | ||
|
||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,24 @@ | ||
<div ng-app="autocompleteFloatingLabelDemo" ng-controller="DemoCtrl as ctrl" layout="column"> | ||
|
||
<md-content class="md-padding" layout="column"> | ||
<p>The following example demonstrates floating labels being used as a normal form element.</p> | ||
|
||
<div layout-gt-sm="row"> | ||
<md-input-container flex> | ||
<label>Name</label> | ||
<input type="text"/> | ||
</md-input-container> | ||
<md-autocomplete flex | ||
ng-disabled="ctrl.isDisabled" | ||
md-no-cache="ctrl.noCache" | ||
md-selected-item="ctrl.selectedItem" | ||
md-search-text="ctrl.searchText" | ||
md-items="item in ctrl.querySearch(ctrl.searchText)" | ||
md-item-text="item.display" | ||
md-floating-label="Favorite state"> | ||
<span md-highlight-text="ctrl.searchText">{{item.display}}</span> | ||
</md-autocomplete> | ||
</div> | ||
|
||
<form ng-submit="$event.preventDefault()"> | ||
<p>The following example demonstrates floating labels being used as a normal form element.</p> | ||
<div layout-gt-sm="row"> | ||
<md-input-container flex> | ||
<label>Name</label> | ||
<input type="text"/> | ||
</md-input-container> | ||
<md-autocomplete flex | ||
ng-disabled="ctrl.isDisabled" | ||
md-no-cache="ctrl.noCache" | ||
md-selected-item="ctrl.selectedItem" | ||
md-search-text="ctrl.searchText" | ||
md-items="item in ctrl.querySearch(ctrl.searchText)" | ||
md-item-text="item.display" | ||
md-floating-label="Favorite state"> | ||
<span md-highlight-text="ctrl.searchText">{{item.display}}</span> | ||
</md-autocomplete> | ||
</div> | ||
</form> | ||
</md-content> | ||
|
||
</div> |