@@ -389,6 +389,12 @@ class Input extends UI5Element {
389
389
if ( isEnter ( event ) ) {
390
390
return this . _handleEnter ( event ) ;
391
391
}
392
+
393
+ this . _keyDown = true ;
394
+ }
395
+
396
+ onkeyup ( ) {
397
+ this . _keyDown = false ;
392
398
}
393
399
394
400
/* Event handling */
@@ -417,7 +423,7 @@ class Input extends UI5Element {
417
423
}
418
424
}
419
425
420
- onfocusin ( ) {
426
+ onfocusin ( event ) {
421
427
this . focused = true ; // invalidating property
422
428
this . previousValue = this . value ;
423
429
}
@@ -437,7 +443,14 @@ class Input extends UI5Element {
437
443
event . stopImmediatePropagation ( ) ;
438
444
}
439
445
440
- this . fireEventByAction ( this . ACTION_USER_INPUT ) ;
446
+ /* skip calling change event when an input with a placeholder is focused on IE
447
+ - value of the host and the internal input should be differnt in case of actual input
448
+ - input is called when a key is pressed => keyup should not be called yet
449
+ */
450
+ const skipFiring = ( this . getInputDOMRef ( ) . value === this . value ) && isIE ( ) && ! this . _keyDown && this . placeholder ;
451
+
452
+ ! skipFiring && this . fireEventByAction ( this . ACTION_USER_INPUT ) ;
453
+
441
454
this . hasSuggestionItemSelected = false ;
442
455
443
456
if ( this . Suggestions ) {
@@ -562,12 +575,6 @@ class Input extends UI5Element {
562
575
} ;
563
576
}
564
577
565
- get inputPlaceholder ( ) {
566
- // We don`t support placeholder for IE,
567
- // because IE fires input events, when placeholder exists, leading to functional degredations.
568
- return isIE ( ) ? "" : this . placeholder ;
569
- }
570
-
571
578
get _readonly ( ) {
572
579
return this . readonly && ! this . disabled ;
573
580
}
0 commit comments