mirror of
https://github.com/snachodog/just-the-docs.git
synced 2025-09-12 21:03:32 -06:00
Improved search input for mobile
- font size 16px to prevent zooming on iOS Safari - search input is scrolled into view on iOS Safari - box-shadow is displayed correctly
This commit is contained in:
@@ -133,7 +133,9 @@ function searchLoaded(index, docs) {
|
||||
hideSearch();
|
||||
} else {
|
||||
showSearch();
|
||||
window.scroll(0, window.scrollY + mainHeader.getBoundingClientRect().top);
|
||||
// scroll search input into view, workaround for iOS Safari
|
||||
window.scroll(0, -1);
|
||||
setTimeout(function(){ window.scroll(0, 0); }, 0);
|
||||
}
|
||||
if (input === currentInput) {
|
||||
return;
|
||||
|
Reference in New Issue
Block a user