When autoComplete contains a single item and the enter key is selected, then the item should be auto-selected.

Similar to using the down-arrow, enter combinations.
@ThomasBurleson This is supported already through the md-autoselect attribute.
@robertmesserle @ThomasBurleson Hello everyone, I am trying to use this in angular 4 & have a doubt that how can recognise the event after the single item is selected. i.e. I want to pass the selected item when enter key is pressed. I tried following keyup.enter but it only selects the item. the event is not triggered.
<md-autocomplete #auto="mdAutocomplete" id="autocomplete">
<md-option *ngFor="let result of filteredResults" [value]="result.name" (keyup.enter)="navigateToView(result)" (click)="navigateToView(result)">
<span class="row" *ngIf="result.empty">
<span class="no-results-title" *ngIf="!result.error">Your search <span class="error-message">"{{result.userInput}}"</span> was not found</span>
<span class="no-results-title" *ngIf="result.error">{{result.error}}</span>
</span>
<span class="row" *ngIf="!result.empty"> {{result.name | lowercase}}<span> in <span class="type"> {{result.type}} </span></span>
</span>
</md-option>
</md-autocomplete>
any suggestion?
Most helpful comment
@ThomasBurleson This is supported already through the
md-autoselectattribute.