when showing results focus the results container

This commit is contained in:
Kovid Goyal 2021-05-20 15:26:20 +05:30
parent 2f3ab66ffe
commit 9d0c7def38
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

View File

@ -113,7 +113,7 @@ class SearchOverlay:
c.appendChild(E.hr()) c.appendChild(E.hr())
c.appendChild(E.div( c.appendChild(E.div(
style='display: none; overflow: auto', style='display: none; overflow: auto', tabindex='0',
E.div( E.div(
style='text-align: center', style='text-align: center',
E.div(create_spinner('4em', '4em')), E.div(create_spinner('4em', '4em')),
@ -160,6 +160,7 @@ class SearchOverlay:
c.style.display = 'block' c.style.display = 'block'
c.firstChild.style.display = 'none' c.firstChild.style.display = 'none'
c.lastChild.style.display = 'block' c.lastChild.style.display = 'block'
c.focus()
def clear_results(self): def clear_results(self):
clear(self.results_container) clear(self.results_container)