Skip to content

Commit

Permalink
made songbook search keep focus and scroll position (#605)
Browse files Browse the repository at this point in the history
  • Loading branch information
Fiery-132 authored Nov 26, 2024
1 parent bd139b8 commit f2281c2
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/lib/components/SearchBar.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,14 @@
urlParams.delete("page");
await goto(`${i18n.route($page.url.pathname)}?${urlParams.toString()}`, {
replaceState: true,
keepFocus: true,
noScroll: true,
});
await tick();
setTimeout(() => {
inputField.focus();
isLoading = false;
}, 0);
}, 1000);
}, 500);
});
};
</script>

Expand Down

0 comments on commit f2281c2

Please sign in to comment.