pydata / pydata-sphinx-theme

A clean, three-column Sphinx theme with Bootstrap for the PyData community
https://pydata-sphinx-theme.readthedocs.io
BSD 3-Clause "New" or "Revised" License
592 stars 309 forks source link

Right navbar column skips the section clicked #1965

Open dylanh724 opened 3 weeks ago

dylanh724 commented 3 weeks ago

This was originally reported for sphinx-book-theme that seems to also have this bug on their own docs site (but, iirc, their main theme comes from this repo). See a full report with GIFs and links here:

https://github.com/executablebooks/sphinx-book-theme/issues/853

Or repro the bug yourself here on your own docs:

https://pydata-sphinx-theme.readthedocs.io/en/stable/examples/kitchen-sink/admonitions.html#attention

  1. On the right column, click a header in the middle
  2. Now click the header +1 up. It will land on +2 up.

Edited by @trallard to copy content from the original issue in the executablebooks repo

context When I click a right column child header, it skips to the section above or below my cursor and awkwardly highlights the incorrect section:

expectation When I click on a header anchor link on the right column nav, I expect it to go straight there and highlight the correctly selected link.

electric-coder commented 3 weeks ago

I confirm this happens using Firefox 129.0.1 (64-bit) on Windows 10.

I had noticed this before but didn't bother reporting.

dbitouze commented 3 weeks ago

I don't confirm this using Firefox 129.0.2 (64 bits) on GNU/Linux.

ramevaf commented 1 week ago

Could this be related to Issue #1889 ?

dylanh724 commented 1 week ago

Could this be related to Issue #1889 ?

Very possible!

trallard commented 1 week ago

@dylanh724 or @electric-coder, what version of the PyData Sphinx Theme are you using?

I can see the behaviour on the admonition page as reported in https://github.com/pydata/pydata-sphinx-theme/issues/1965#issue-2479993007, but I cannot reproduce this on other pages (I tried various within the user and community guides in our docs in dev and 0.15.4, see the video below)

https://github.com/user-attachments/assets/5f789e38-df1e-45fd-a184-d23677445921

@gabalafou have you seen this before?

Could this be related to Issue https://github.com/pydata/pydata-sphinx-theme/issues/1889 ?

This should be unrelated to the above issue tho.