Hi SurveyJs team,
I'm implementing the lazy loading of API for dropdown JS. But I noticed a behavior on the dropdown, where it throws error after searching a value that have no matching results and re-selecting the dropdown.
Here are the steps to replicate:
- Go to https://codesandbox.io/s/g9qn2g?file=/src/json.js from the https://surveyjs.io/form-library/examples/lazy-loading-dropdown/reactjs#content-code
- Select a country from the dropdown.
- Type any string that have no matching results. For example: 00000
- From step 3, it will display 'No result'
- Hover out or remove the focus to the dropdown.
- Select the dropdown again
Result: Error is displayed
Cannot set properties of undefined (setting 'selectedValue')
./src/dropdownListModel.ts.DropdownListModel.beforeScrollToFocusedItem
see screenshot for full error
Appreciate your response and assistance.
Thank you!
Hello,
Thank you for reporting this issue. We will investigate it and post updates in the following GitHub thread: https://github.com/surveyjs/survey-library/issues/7114.
Please stay tuned.
Hello Eleazar,
We released v1.9.112 and it seems that the issue gets resolved. Would you please test it on your side and let us know whether you can reproduce the issue? You can test the Dropdown demo as it uses the most recent version.
I look forward to your reply.