Skip to content

Commit

Permalink
fix(select): fix dirty true on init component
Browse files Browse the repository at this point in the history
  • Loading branch information
Enlcxx committed Feb 17, 2019
1 parent e9c4c03 commit f8e6093
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/lib/select/select.ts
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,6 @@ export class LySelect
if (val !== this.value && this._selectionModel) {
this._value = val;
this.writeValue(val);
this.onChange(val);
if (this.options) {
if (this.multiple) {
if (Array.isArray(this.value)) {
Expand Down Expand Up @@ -689,6 +688,7 @@ export class LyOption extends LyOptionMixinBase implements OnInit, OnChanges {
} else {
this.toggle();
}
this._select.onChange(this._select._value);
}

/**
Expand Down Expand Up @@ -765,7 +765,6 @@ export class LyOption extends LyOptionMixinBase implements OnInit, OnChanges {
}
}
}
this._select.onChange(this._select._value);
this._select._cd.markForCheck();
this._select.stateChanges.next();
this._cd.markForCheck();
Expand Down Expand Up @@ -794,7 +793,6 @@ export class LyOption extends LyOptionMixinBase implements OnInit, OnChanges {
}
}
}
this._select.onChange(this._select._value);
this._select._cd.markForCheck();
this._select.stateChanges.next();
this._cd.markForCheck();
Expand Down

0 comments on commit f8e6093

Please sign in to comment.