From 191de7351a4fab7974d35d73af95670c549013ea Mon Sep 17 00:00:00 2001 From: Denys Konovalov Date: Wed, 3 Jan 2024 11:41:46 +0100 Subject: [PATCH] add autofocus to search field --- layouts/partials/head.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/layouts/partials/head.html b/layouts/partials/head.html index b252f67a..7488a4a0 100644 --- a/layouts/partials/head.html +++ b/layouts/partials/head.html @@ -36,7 +36,7 @@ } }); - $('#search').addEventListener('shown.bs.modal', () => { + $('#search').on('shown.bs.modal', () => { $('.pagefind-ui__search-input input').focus(); }); });