mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-20 12:29:55 +08:00
Update select.ts
Added ability set selected text like md-selected-text
This commit is contained in:
@ -119,7 +119,7 @@ export const SELECT_VALUE_ACCESSOR = new Provider(
|
||||
selector: 'ion-select',
|
||||
template: `
|
||||
<div *ngIf="!_text" class="select-placeholder select-text">{{placeholder}}</div>
|
||||
<div *ngIf="_text" class="select-text">{{_text}}</div>
|
||||
<div *ngIf="_text" class="select-text">{{selectedText || _text}}</div>
|
||||
<div class="select-icon">
|
||||
<div class="select-icon-inner"></div>
|
||||
</div>
|
||||
@ -184,6 +184,11 @@ export class Select implements AfterContentInit, ControlValueAccessor, OnDestroy
|
||||
* @input {string} The interface the select should use: `action-sheet` or `alert`. Default: `alert`.
|
||||
*/
|
||||
@Input() interface: string = '';
|
||||
|
||||
/**
|
||||
* @input {string} The selected text should be showen.
|
||||
*/
|
||||
@Input() selectedText: string = '';
|
||||
|
||||
/**
|
||||
* @output {any} Any expression you want to evaluate when the selection has changed.
|
||||
|
Reference in New Issue
Block a user