You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I find that using safari 15.4, trying to navigate to a search result that is on the current page does not work. There's a bit of flicker on the page, so perhaps it is scrolling to the correct location, but then it scrolls immediately back to the top. Setting scroll-behvaior:smoooth; prevents this, but causes other issues (closing the search modal causes a jump to bottom and scroll back to the top).
I did a little more experimenting. If I remove the line I mentioned above, window.scrollTo?.(0, initialScrollY);, that indeed fixes this particular problem, but it causes #1260: when I close the modal without choosing a result, I scroll to the bottom.
Description
I find that using safari 15.4, trying to navigate to a search result that is on the current page does not work. There's a bit of flicker on the page, so perhaps it is scrolling to the correct location, but then it scrolls immediately back to the top. Setting
scroll-behvaior:smoooth;
prevents this, but causes other issues (closing the search modal causes a jump to bottom and scroll back to the top).This might be somewhat related to #1260.
I also wonder if
docsearch/packages/docsearch-react/src/DocSearchModal.tsx
Line 328 in 82b73a7
Steps to reproduce
scroll-behavior: smooth
is set, and disable it. (it's set on :root in a media query)7. Notice that it works.I take it back. It only works sometimes.
Expected behavior
Should be taken to the correct location in the current page
Environment
The text was updated successfully, but these errors were encountered: