diff options
Diffstat (limited to 'cgithub')
| -rw-r--r-- | cgithub/views/layout.eta | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/cgithub/views/layout.eta b/cgithub/views/layout.eta index ca6fff2..6d1b052 100644 --- a/cgithub/views/layout.eta +++ b/cgithub/views/layout.eta @@ -55,7 +55,9 @@ git clone git@github.com:<%= it.repo.owner %>/<%= it.repo.name %>.git</code></pr if (shortcut === "/") { e.preventDefault(); - document.getElementById('search-input').select(); + const input = document.getElementById('search-input'); + input.select(); + input.scrollIntoView({ block: "nearest" }); } }); </script> |
