Skip to content

Commit 61ee3bd

Browse files
authored
svelte/SearchForm: Keep focus on search box after submitting (#12528)
This makes it possible to quickly fix any typos in the search query. see https://svelte.dev/docs/kit/link-options#data-sveltekit-keepfocus
1 parent a6d3c9b commit 61ee3bd

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

svelte/src/lib/components/SearchForm.svelte

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@
5555
class="form"
5656
class:size-big={size === 'big'}
5757
onsubmit={search}
58+
data-sveltekit-keepfocus
5859
>
5960
<!-- Large screen input with keyboard shortcut hint -->
6061
<input

0 commit comments

Comments
 (0)