Skip to content

Commit 2acde00

Browse files
fix: click open / close preview button (#1887)
1 parent 7e84263 commit 2acde00

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

assets/js/search-bar.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import {
88
hidePreview,
99
updateAutocompleteList,
1010
AUTOCOMPLETE_CONTAINER_SELECTOR,
11-
AUTOCOMPLETE_SUGGESTION_SELECTOR
11+
AUTOCOMPLETE_SUGGESTION_LIST_SELECTOR
1212
} from './autocomplete/autocomplete-list'
1313
import { isMacOS, qs } from './helpers'
1414

@@ -103,7 +103,7 @@ function addEventListeners () {
103103
if (relatedTarget) {
104104
// If blur is triggered caused by clicking on an autocomplete result,
105105
// then ignore it, because it's handled in the click handler below.
106-
if (relatedTarget.matches(AUTOCOMPLETE_SUGGESTION_SELECTOR)) {
106+
if (qs(AUTOCOMPLETE_SUGGESTION_LIST_SELECTOR).contains(relatedTarget)) {
107107
// Focus the input after a while, so that it's easier to close
108108
// or get back to after an accidental blur
109109
setTimeout(() => {

formatters/html/dist/html-F3KSH2DY.js renamed to formatters/html/dist/html-Y7ASKYHF.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)