mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-22 21:48:42 +08:00
fix(select): remove relative positioning and get options in correct order
This commit is contained in:
@ -4,8 +4,6 @@
|
|||||||
// --------------------------------------------------
|
// --------------------------------------------------
|
||||||
|
|
||||||
ion-select {
|
ion-select {
|
||||||
position: relative;
|
|
||||||
|
|
||||||
display: flex;
|
display: flex;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
|
|
||||||
@ -41,6 +39,7 @@ ion-select {
|
|||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// TODO item needs this class
|
||||||
.item-multiple-inputs ion-select {
|
.item-multiple-inputs ion-select {
|
||||||
position: relative;
|
position: relative;
|
||||||
}
|
}
|
||||||
|
@ -189,7 +189,7 @@ export class Select {
|
|||||||
@Listen('ionSelectOptionDidLoad')
|
@Listen('ionSelectOptionDidLoad')
|
||||||
optLoad(ev: HTMLIonSelectOptionElementEvent) {
|
optLoad(ev: HTMLIonSelectOptionElementEvent) {
|
||||||
const selectOption = ev.target;
|
const selectOption = ev.target;
|
||||||
this.childOpts.push(selectOption);
|
this.childOpts = Array.from(this.el.querySelectorAll('ion-select-option'));
|
||||||
|
|
||||||
if (this.value !== undefined && (Array.isArray(this.value) && this.value.indexOf(selectOption.value) > -1) || (selectOption.value === this.value)) {
|
if (this.value !== undefined && (Array.isArray(this.value) && this.value.indexOf(selectOption.value) > -1) || (selectOption.value === this.value)) {
|
||||||
// this select has a value and this
|
// this select has a value and this
|
||||||
|
Reference in New Issue
Block a user