mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-16 18:17:31 +08:00
fix(segment): only emit ionChange when user releases pointer from screen (#20495)
fixes #20500 fixes #20257
This commit is contained in:
@ -12,6 +12,13 @@ export class ValueAccessor implements ControlValueAccessor {
|
||||
constructor(protected el: ElementRef) {}
|
||||
|
||||
writeValue(value: any) {
|
||||
/**
|
||||
* TODO for Ionic 6:
|
||||
* Change `value == null ? '' : value;`
|
||||
* to `value`. This was a fix for IE9, but IE9
|
||||
* is no longer supported; however, this change
|
||||
* is potentially a breaking change
|
||||
*/
|
||||
this.el.nativeElement.value = this.lastValue = value == null ? '' : value;
|
||||
setIonicClasses(this.el);
|
||||
}
|
||||
|
Reference in New Issue
Block a user