Skip to content

Commit

Permalink
Refactor #3321
Browse files Browse the repository at this point in the history
  • Loading branch information
tugcekucukoglu committed Nov 24, 2022
1 parent dcb17c9 commit 23840ec
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/components/orderlist/OrderList.vue
Original file line number Diff line number Diff line change
Expand Up @@ -147,8 +147,11 @@ export default {
return ObjectUtils.findIndexInList(item, this.d_selection) != -1;
},
onListFocus(event) {
const selectedFirstItem = DomHandler.findSingle(this.list, 'li.p-orderlist-item.p-highlight');
const index = selectedFirstItem ? ObjectUtils.findIndexInList(selectedFirstItem, this.list.children) : '0';
this.focused = true;
this.changeFocusedOptionIndex(0);
this.changeFocusedOptionIndex(index);
this.$emit('focus', event);
},
onListBlur(event) {
Expand Down

0 comments on commit 23840ec

Please sign in to comment.