Skip to content

Commit 32aaeb6

Browse files
committed
Merge pull request #164 from algolia/fix/searchBox-do-not-update-if-focused
fix(searchBox): do not update input's value if focused
2 parents 07e09e9 + 0e85f0d commit 32aaeb6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

widgets/search-box.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ function searchbox(params) {
5656
}
5757

5858
helper.on('change', function(state) {
59-
if (input.value !== state.query) {
59+
if (input !== document.activeElement && input.value !== state.query) {
6060
input.value = state.query;
6161
}
6262
});

0 commit comments

Comments
 (0)