File tree Expand file tree Collapse file tree 2 files changed +6
-5
lines changed Expand file tree Collapse file tree 2 files changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -802,18 +802,19 @@ class Input extends UI5Element {
802
802
}
803
803
804
804
previewSuggestion ( item ) {
805
- const emptyValue = item . type === "Inactive" || item . group ;
806
805
this . valueBeforeItemSelection = this . value ;
807
- this . updateValueOnPreview ( emptyValue ? "" : item . effectiveTitle ) ;
806
+ this . updateValueOnPreview ( item ) ;
808
807
this . announceSelectedItem ( ) ;
809
808
this . _previewItem = item ;
810
809
}
811
810
812
811
/**
813
812
* Updates the input value on item preview.
814
- * @param {itemValue } itemValue The value of the item that is on preview
813
+ * @param {Object } item The item that is on preview
815
814
*/
816
- updateValueOnPreview ( itemValue ) {
815
+ updateValueOnPreview ( item ) {
816
+ const noPreview = item . type === "Inactive" || item . group ;
817
+ const itemValue = noPreview ? "" : ( item . effectiveTitle || item . textContent ) ;
817
818
this . value = itemValue ;
818
819
}
819
820
Original file line number Diff line number Diff line change @@ -318,7 +318,7 @@ class Suggestions {
318
318
}
319
319
320
320
_getItems ( ) {
321
- return [ ] . slice . call ( this . responsivePopover . querySelectorAll ( "ui5-li-groupheader, ui5-li-suggestion-item" ) ) ;
321
+ return [ ... this . responsivePopover . querySelectorAll ( "ui5-list>*" ) ] ;
322
322
}
323
323
324
324
_getComponent ( ) {
You can’t perform that action at this time.
0 commit comments